diff --git a/.clang-tidy b/.clang-tidy index 580234c0fad0a3..5a6f103705fc39 100644 --- a/.clang-tidy +++ b/.clang-tidy @@ -1,6 +1,7 @@ --- Checks: > bugprone-*, + modernize-redundant-void-arg, modernize-use-bool-literals, modernize-use-nullptr, performance-for-range-copy, diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index b5da6c153e4d7f..70c206f1058ce3 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -17,7 +17,7 @@ "build": { "dockerfile": "Dockerfile", "args": { - "BUILD_VERSION": "0.6.06" + "BUILD_VERSION": "0.6.18" } }, "remoteUser": "vscode", diff --git a/.github/.wordlist.txt b/.github/.wordlist.txt index ca364bc513ae9c..c78b7f05e5907a 100644 --- a/.github/.wordlist.txt +++ b/.github/.wordlist.txt @@ -301,6 +301,7 @@ contrib controllee conv CopperConcentrationMeasurement +Corstone cortexa cp cpio @@ -676,7 +677,6 @@ instantiation integrations IntelliSense InteractionModelVersion -Interation Interoperable introvideos InvokeCommandRequests @@ -886,6 +886,7 @@ MyPASSWORD MySSID NAMESERVER NAMESPACE +namespaces namespacing nano natively @@ -1144,11 +1145,13 @@ rsn RSSI RST rsync +RTC rtd RTL rtld RTOS RTT +RTX RUNAS RunMain runtime @@ -1254,6 +1257,7 @@ subdirectory subfolder submodule submodules +subnet subprocess SubscribeResponse SubscriptionId @@ -1326,6 +1330,7 @@ Tizen TKIP tlsr TLV +TLS tmp tngvndl TODO diff --git a/.github/workflows/bloat_check.yaml b/.github/workflows/bloat_check.yaml index 8646c1c0f0550d..b5325da5ec1ff3 100644 --- a/.github/workflows/bloat_check.yaml +++ b/.github/workflows/bloat_check.yaml @@ -30,7 +30,7 @@ jobs: runs-on: ubuntu-latest container: - image: connectedhomeip/chip-build:0.6.06 + image: connectedhomeip/chip-build:0.6.18 steps: - uses: Wandalen/wretry.action@v1.0.36 diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 276b1f264e0cee..443210b15c3c05 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -23,7 +23,11 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: + build_linux_gcc_debug: name: Build on Linux (gcc_debug) timeout-minutes: 85 @@ -32,7 +36,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build:0.6.06 + image: connectedhomeip/chip-build:0.6.18 volumes: - "/tmp/log_output:/tmp/test_logs" options: --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0 @@ -74,7 +78,7 @@ jobs: .environment/gn_out/.ninja_log .environment/pigweed-venv/*.log - name: Setup Build - run: scripts/build/gn_gen.sh --args="chip_config_memory_debug_checks=true chip_config_memory_debug_dmalloc=true" + run: scripts/build/gn_gen.sh --args="chip_config_memory_debug_checks=true chip_config_memory_debug_dmalloc=false" - name: Run Build timeout-minutes: 20 run: scripts/run_in_build_env.sh "ninja -C ./out" @@ -125,6 +129,7 @@ jobs: # path: out/ # # objdirs are big; don't hold on to them too long. # retention-days: 5 + build_linux: name: Build on Linux (fake, gcc_release, clang, simulated) timeout-minutes: 150 @@ -133,7 +138,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build:0.6.06 + image: connectedhomeip/chip-build:0.6.18 volumes: - "/tmp/log_output:/tmp/test_logs" options: --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0 @@ -219,7 +224,6 @@ jobs: run: | ./scripts/run_in_build_env.sh \ "./scripts/run-clang-tidy-on-compile-commands.py \ - --no-log-timestamps \ --compile-database out/sanitizers/compile_commands.json \ --file-exclude-regex '/(repo|zzz_generated|lwip/standalone)/' \ check \ @@ -228,18 +232,34 @@ jobs: timeout-minutes: 60 run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps \ - --target linux-x64-all-clusters-ipv6only-clang \ - --target linux-x64-chip-tool-ipv6only-clang \ + "./scripts/build/build_examples.py \ --target linux-x64-minmdns-ipv6only-clang \ --target linux-x64-rpc-console \ build \ " + - name: Create a pre-generate directory and ensure compile-time codegen would fail + run: | + ./scripts/run_in_build_env.sh "./scripts/codepregen.py ./zzz_pregenerated" + mv scripts/codegen.py scripts/codegen.py.renamed + - name: Build using build_examples.py (pregen) + timeout-minutes: 60 + run: | + ./scripts/run_in_build_env.sh \ + "./scripts/build/build_examples.py \ + --target linux-x64-all-clusters-ipv6only-clang \ + --target linux-x64-chip-tool-ipv6only-clang \ + --pregen-dir ./zzz_pregenerated \ + build \ + " + - name: Undo code pre-generation changes (make compile time codegen work again) + run: | + rm -rf ./zzz_pregenerated + mv scripts/codegen.py.renamed scripts/codegen.py - name: Run fake linux tests with build_examples timeout-minutes: 15 run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps --target linux-fake-tests build" + "./scripts/build/build_examples.py --target linux-fake-tests build" - name: Uploading core files uses: actions/upload-artifact@v3 if: ${{ failure() && !env.ACT }} @@ -279,6 +299,7 @@ jobs: # - name: Perform CodeQL Analysis # if: ${{ github.event_name == 'push' && github.event.ref == 'refs/heads/master' }} # uses: github/codeql-action/analyze@v1 + build_linux_python_lib: name: Build on Linux (python_lib) timeout-minutes: 60 @@ -287,7 +308,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build:0.6.06 + image: connectedhomeip/chip-build:0.6.18 volumes: - "/tmp/log_output:/tmp/test_logs" options: --sysctl "net.ipv6.conf.all.disable_ipv6=0 @@ -414,7 +435,6 @@ jobs: run: | ./scripts/run_in_build_env.sh \ "./scripts/run-clang-tidy-on-compile-commands.py \ - --no-log-timestamps \ --compile-database out/default/compile_commands.json \ check \ " diff --git a/.github/workflows/chef.yaml b/.github/workflows/chef.yaml index 8f06a341f15dd7..3a7a91d60663e9 100644 --- a/.github/workflows/chef.yaml +++ b/.github/workflows/chef.yaml @@ -29,7 +29,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build:0.6.06 + image: connectedhomeip/chip-build:0.6.18 options: --user root steps: @@ -57,7 +57,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-esp32:0.6.06 + image: connectedhomeip/chip-build-esp32:0.6.18 options: --user root steps: @@ -85,7 +85,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-nrf-platform:0.6.06 + image: connectedhomeip/chip-build-nrf-platform:0.6.18 options: --user root steps: diff --git a/.github/workflows/cirque.yaml b/.github/workflows/cirque.yaml index 950650638a14b9..c55e84b7a9273d 100644 --- a/.github/workflows/cirque.yaml +++ b/.github/workflows/cirque.yaml @@ -29,7 +29,7 @@ jobs: timeout-minutes: 90 env: - DOCKER_RUN_VERSION: 0.6.06 + DOCKER_RUN_VERSION: 0.6.18 GITHUB_CACHE_PATH: /tmp/cirque-cache/ runs-on: ubuntu-latest @@ -38,7 +38,7 @@ jobs: # need to run with privilege, which isn't supported by job.XXX.contaner # https://github.com/actions/container-action/issues/2 # container: - # image: connectedhomeip/chip-build-cirque:0.6.06 + # image: connectedhomeip/chip-build-cirque:0.6.18 # volumes: # - "/tmp:/tmp" # - "/dev/pts:/dev/pts" diff --git a/.github/workflows/darwin-tests.yaml b/.github/workflows/darwin-tests.yaml index aa9c9a7ac5c236..7d1db5f479dc6c 100644 --- a/.github/workflows/darwin-tests.yaml +++ b/.github/workflows/darwin-tests.yaml @@ -25,6 +25,9 @@ concurrency: 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: test_suites_chip_tool_darwin: name: Test Suites - Darwin diff --git a/.github/workflows/doxygen.yaml b/.github/workflows/doxygen.yaml index 675690ac97337c..d5f84576ff0fc7 100644 --- a/.github/workflows/doxygen.yaml +++ b/.github/workflows/doxygen.yaml @@ -82,7 +82,7 @@ jobs: runs-on: ubuntu-20.04 container: - image: connectedhomeip/chip-build-doxygen:0.6.06 + image: connectedhomeip/chip-build-doxygen:0.6.18 if: github.actor != 'restyled-io[bot]' diff --git a/.github/workflows/examples-ameba.yaml b/.github/workflows/examples-ameba.yaml index e46876ba3aba3b..6986e6b6bda00b 100644 --- a/.github/workflows/examples-ameba.yaml +++ b/.github/workflows/examples-ameba.yaml @@ -22,6 +22,9 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: ameba: name: Ameba @@ -32,7 +35,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-ameba:0.6.06 + image: connectedhomeip/chip-build-ameba:0.6.18 options: --user root steps: diff --git a/.github/workflows/examples-bouffalolab.yaml b/.github/workflows/examples-bouffalolab.yaml index 11539d512f579f..a62e0dad3c74dd 100644 --- a/.github/workflows/examples-bouffalolab.yaml +++ b/.github/workflows/examples-bouffalolab.yaml @@ -17,21 +17,25 @@ name: Build example - BouffaloLab on: push: pull_request: + workflow_dispatch: concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: - bl602: - name: BL602 + bouffalolab: + name: Bouffalo Lab timeout-minutes: 90 runs-on: ubuntu-latest if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build:0.6.06 + image: connectedhomeip/chip-build-bouffalolab:0.6.18 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" steps: @@ -44,91 +48,75 @@ jobs: attempt_limit: 3 attempt_delay: 2000 - name: Checkout submodules - run: scripts/checkout_submodules.py --shallow --platform bl602 + run: scripts/checkout_submodules.py --shallow --platform bouffalolab --recursive - name: Set up environment for size reports if: ${{ !env.ACT }} env: GH_CONTEXT: ${{ toJson(github) }} run: scripts/tools/memory/gh_sizes_environment.py "${GH_CONTEXT}" - + + - name: Bootstrap + timeout-minutes: 25 + run: scripts/build/gn_bootstrap.sh + - name: Uploading bootstrap logs + uses: actions/upload-artifact@v3 + if: ${{ always() && !env.ACT }} + with: + name: bootstrap-logs + path: | + .environment/gn_out/.ninja_log + .environment/pigweed-venv/*.log - name: Build example BL602 Lighting App timeout-minutes: 30 run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --target bouffalolab-bl602-iot-matter-v1-light build" - - - name: Get Lighting size stats + "./scripts/build/build_examples.py \ + --target bouffalolab-bl602-iot-matter-v1-light \ + --target bouffalolab-bl602-iot-matter-v1-light-115200-rpc \ + build \ + --copy-artifacts-to out/artifacts \ + " + - name: Prepare some bloat report from the previous builds run: | - .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py bl602 bl602 lighting-app \ - out/bouffalolab-bl602-iot-matter-v1-light/chip-bl602-lighting-example.out /tmp/bloat_reports/ - - - name: Build example BL602 Lighting App with RPCs - timeout-minutes: 30 - run: | - ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --target bouffalolab-bl602-iot-matter-v1-light-115200-rpc build" - .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py bl602 bl602+rpc lighting-app \ - out/bouffalolab-bl602-iot-matter-v1-light-115200-rpc/chip-bl602-lighting-example.out /tmp/bloat_reports/ - - - name: Uploading Size Reports - uses: actions/upload-artifact@v3 - if: ${{ !env.ACT }} - with: - name: Size,BL602-Examples,${{ env.GH_EVENT_PR }},${{ env.GH_EVENT_HASH }},${{ env.GH_EVENT_PARENT }},${{ github.event_name }} - path: | - /tmp/bloat_reports/ - - bl702: - name: BL702 - timeout-minutes: 90 - - runs-on: ubuntu-latest - if: github.actor != 'restyled-io[bot]' - - container: - image: connectedhomeip/chip-build:0.6.06 - volumes: - - "/tmp/bloat_reports:/tmp/bloat_reports" - steps: - - uses: Wandalen/wretry.action@v1.0.36 - name: Checkout - with: - action: actions/checkout@v3 - with: | - token: ${{ github.token }} - attempt_limit: 3 - attempt_delay: 2000 - - name: Checkout submodules - run: scripts/checkout_submodules.py --shallow --platform bouffalolab - - - name: Set up environment for size reports - if: ${{ !env.ACT }} - env: - GH_CONTEXT: ${{ toJson(github) }} - run: scripts/tools/memory/gh_sizes_environment.py "${GH_CONTEXT}" - + .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ + bl602 bl602 lighting-app \ + out/artifacts/bouffalolab-bl602-iot-matter-v1-light/chip-bl602-lighting-example.out \ + /tmp/bloat_reports/ + .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ + bl602 bl602+rpc lighting-app \ + out/artifacts/bouffalolab-bl602-iot-matter-v1-light-115200-rpc/chip-bl602-lighting-example.out \ + /tmp/bloat_reports/ + - name: Clean out build output + run: rm -rf ./out - name: Build example BL702 Lighting App timeout-minutes: 30 run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --target bouffalolab-xt-zb6-devkit-light build" - .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py bl702 bl702 lighting-app \ - out/bouffalolab-xt-zb6-devkit-light/chip-bl702-lighting-example.out /tmp/bloat_reports/ - - - name: Build example BL702 Lighting App with RPCs - timeout-minutes: 30 + "./scripts/build/build_examples.py \ + --target bouffalolab-xt-zb6-devkit-light \ + --target bouffalolab-xt-zb6-devkit-light-115200-rpc \ + build \ + --copy-artifacts-to out/artifacts \ + " + - name: Prepare some bloat report from the previous builds run: | - ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --target bouffalolab-xt-zb6-devkit-light-115200-rpc build" - .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py bl702 bl702+rpc lighting-app \ - out/bouffalolab-xt-zb6-devkit-light-115200-rpc/chip-bl702-lighting-example.out /tmp/bloat_reports/ + .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ + bl702 bl702 lighting-app \ + out/artifacts/bouffalolab-xt-zb6-devkit-light/chip-bl702-lighting-example.out \ + /tmp/bloat_reports/ + .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ + bl702 bl702+rpc lighting-app \ + out/artifacts/bouffalolab-xt-zb6-devkit-light-115200-rpc/chip-bl702-lighting-example.out \ + /tmp/bloat_reports/ + - name: Clean out build output + run: rm -rf ./out - name: Uploading Size Reports uses: actions/upload-artifact@v3 if: ${{ !env.ACT }} with: - name: Size,BL702-Examples,${{ env.GH_EVENT_PR }},${{ env.GH_EVENT_HASH }},${{ env.GH_EVENT_PARENT }},${{ github.event_name }} + name: Size,BouffaloLab-Examples,${{ env.GH_EVENT_PR }},${{ env.GH_EVENT_HASH }},${{ env.GH_EVENT_PARENT }},${{ github.event_name }} path: | /tmp/bloat_reports/ diff --git a/.github/workflows/examples-cc13x2x7_26x2x7.yaml b/.github/workflows/examples-cc13x2x7_26x2x7.yaml index d1ebf8a7cca703..d8598c6561eba9 100644 --- a/.github/workflows/examples-cc13x2x7_26x2x7.yaml +++ b/.github/workflows/examples-cc13x2x7_26x2x7.yaml @@ -22,6 +22,9 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: cc26x2x7: name: cc26x2x7 @@ -34,7 +37,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-ti:0.6.06 + image: connectedhomeip/chip-build-ti:0.6.18 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" steps: diff --git a/.github/workflows/examples-efr32.yaml b/.github/workflows/examples-efr32.yaml index d245cea56323f5..33fd567bc2846c 100644 --- a/.github/workflows/examples-efr32.yaml +++ b/.github/workflows/examples-efr32.yaml @@ -22,6 +22,9 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: efr32: name: EFR32 @@ -35,7 +38,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-efr32:0.6.06 + image: connectedhomeip/chip-build-efr32:0.6.18 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" steps: diff --git a/.github/workflows/examples-esp32.yaml b/.github/workflows/examples-esp32.yaml index 6755e3f64b7bbe..61d9d032042c9d 100644 --- a/.github/workflows/examples-esp32.yaml +++ b/.github/workflows/examples-esp32.yaml @@ -22,6 +22,9 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: esp32: name: ESP32 @@ -31,7 +34,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-esp32:0.6.06 + image: connectedhomeip/chip-build-esp32:0.6.18 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" @@ -71,11 +74,29 @@ jobs: "./scripts/build/build_examples.py \ --enable-flashbundle \ --target esp32-m5stack-all-clusters \ + build \ + --copy-artifacts-to out/artifacts \ + " + - name: Prepare code pregen and ensure compile time pregen not possible + run: | + ./scripts/run_in_build_env.sh "./scripts/codepregen.py ./zzz_pregenerated" + mv scripts/codegen.py scripts/codegen.py.renamed + - name: Build some M5Stack variations with pregen + timeout-minutes: 60 + run: | + ./scripts/run_in_build_env.sh \ + "./scripts/build/build_examples.py \ + --enable-flashbundle \ --target esp32-m5stack-all-clusters-minimal \ --target esp32-m5stack-all-clusters-rpc-ipv6only \ + --pregen-dir ./zzz_pregenerated \ build \ --copy-artifacts-to out/artifacts \ " + - name: Undo code pregeneration changes + run: | + rm -rf ./zzz_pregenerated + mv scripts/codegen.py.renamed scripts/codegen.py - name: Prepare bloat report run: | .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ @@ -119,7 +140,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-esp32:0.6.06 + image: connectedhomeip/chip-build-esp32:0.6.18 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" diff --git a/.github/workflows/examples-infineon.yaml b/.github/workflows/examples-infineon.yaml index 1f9fb326fe49d9..51d89d81c0b316 100644 --- a/.github/workflows/examples-infineon.yaml +++ b/.github/workflows/examples-infineon.yaml @@ -23,6 +23,9 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: infineon: name: Infineon examples building @@ -32,7 +35,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-infineon:0.6.06 + image: connectedhomeip/chip-build-infineon:0.6.18 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" steps: @@ -69,7 +72,7 @@ jobs: run: | scripts/run_in_build_env.sh \ "scripts/build/build_examples.py \ - --enable-flashbundle --no-log-timestamps \ + --enable-flashbundle \ --target infineon-psoc6-lock \ build \ --copy-artifacts-to out/artifacts \ @@ -83,7 +86,7 @@ jobs: run: | scripts/run_in_build_env.sh \ "scripts/build/build_examples.py \ - --enable-flashbundle --no-log-timestamps \ + --enable-flashbundle \ --target infineon-psoc6-all-clusters \ build \ --copy-artifacts-to out/artifacts \ @@ -97,7 +100,7 @@ jobs: run: | scripts/run_in_build_env.sh \ "scripts/build/build_examples.py \ - --enable-flashbundle --no-log-timestamps \ + --enable-flashbundle \ --target infineon-psoc6-all-clusters-minimal \ build \ --copy-artifacts-to out/artifacts \ @@ -111,7 +114,7 @@ jobs: run: | scripts/run_in_build_env.sh \ "scripts/build/build_examples.py \ - --enable-flashbundle --no-log-timestamps \ + --enable-flashbundle \ --target infineon-psoc6-light \ build \ --copy-artifacts-to out/artifacts \ diff --git a/.github/workflows/examples-k32w.yaml b/.github/workflows/examples-k32w.yaml index 8df18b8485cf1b..76f8d8237f2d56 100644 --- a/.github/workflows/examples-k32w.yaml +++ b/.github/workflows/examples-k32w.yaml @@ -22,6 +22,9 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: k32w: name: K32W @@ -34,7 +37,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-k32w:0.6.06 + image: connectedhomeip/chip-build-k32w:0.6.18 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" steps: @@ -67,7 +70,7 @@ jobs: .environment/gn_out/.ninja_log .environment/pigweed-venv/*.log - name: Build examples - timeout-minutes: 30 + timeout-minutes: 40 run: | scripts/run_in_build_env.sh "\ ./scripts/build/build_examples.py \ diff --git a/.github/workflows/examples-linux-arm.yaml b/.github/workflows/examples-linux-arm.yaml index d43cfd557adcb6..1a5b9c07395482 100644 --- a/.github/workflows/examples-linux-arm.yaml +++ b/.github/workflows/examples-linux-arm.yaml @@ -22,6 +22,9 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: arm_crosscompile: name: Linux ARM Cross compile @@ -31,7 +34,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-crosscompile:0.6.06 + image: connectedhomeip/chip-build-crosscompile:0.6.18 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" @@ -64,11 +67,13 @@ jobs: path: | .environment/gn_out/.ninja_log .environment/pigweed-venv/*.log + - name: Build Some samples timeout-minutes: 45 run: | ./scripts/run_in_build_env.sh \ "./scripts/build/build_examples.py \ + --target linux-arm64-chip-cert \ --target linux-arm64-all-clusters-clang \ --target linux-arm64-chip-tool-ipv6only-clang \ --target linux-arm64-lock-clang \ diff --git a/.github/workflows/examples-linux-imx.yaml b/.github/workflows/examples-linux-imx.yaml index dbae52ae17833f..b8bfdc0c086c14 100644 --- a/.github/workflows/examples-linux-imx.yaml +++ b/.github/workflows/examples-linux-imx.yaml @@ -22,6 +22,9 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: imx: name: Linux i.MX Build @@ -31,7 +34,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-imx:0.6.06 + image: connectedhomeip/chip-build-imx:0.6.18 steps: - uses: Wandalen/wretry.action@v1.0.36 @@ -45,18 +48,25 @@ jobs: - name: Checkout submodules run: scripts/checkout_submodules.py --shallow --platform linux - - name: Build App + - name: Bootstrap + run: scripts/build/gn_bootstrap.sh + + - name: Build lighting-app timeout-minutes: 30 run: | - ./scripts/examples/imxlinux_example.sh \ - examples/lighting-app/linux/ examples/lighting-app/linux/out/aarch64 + ./scripts/run_in_build_env.sh \ + "./scripts/build/build_examples.py \ + --target imx-lighting-app \ + build" - name: Clean out build output run: rm -rf ./out - name: Build chip-tool timeout-minutes: 30 run: | - ./scripts/examples/imxlinux_example.sh \ - examples/chip-tool examples/chip-tool/out/aarch64 + ./scripts/run_in_build_env.sh \ + "./scripts/build/build_examples.py \ + --target imx-chip-tool \ + build" - name: Clean out build output run: rm -rf ./out - name: Build thermostat @@ -64,8 +74,8 @@ jobs: run: | ./scripts/run_in_build_env.sh \ "./scripts/build/build_examples.py \ - --target imx-thermostat build \ - " + --target imx-thermostat \ + build" - name: Clean out build output run: rm -rf ./out - name: Build all-cluster @@ -73,8 +83,8 @@ jobs: run: | ./scripts/run_in_build_env.sh \ "./scripts/build/build_examples.py \ - --target imx-all-clusters-app build \ - " + --target imx-all-clusters-app \ + build" - name: Clean out build output run: rm -rf ./out - name: Build all-cluster-minimal @@ -82,8 +92,8 @@ jobs: run: | ./scripts/run_in_build_env.sh \ "./scripts/build/build_examples.py \ - --target imx-all-clusters-minimal-app build \ - " + --target imx-all-clusters-minimal-app \ + build" - name: Clean out build output run: rm -rf ./out - name: Build ota-provider-app @@ -91,7 +101,7 @@ jobs: run: | ./scripts/run_in_build_env.sh \ "./scripts/build/build_examples.py \ - --target imx-ota-provider-app build - " + --target imx-ota-provider-app \ + build" - name: Clean out build output run: rm -rf ./out diff --git a/.github/workflows/examples-linux-standalone.yaml b/.github/workflows/examples-linux-standalone.yaml index 12f35418695f73..2c09f5871e7f7f 100644 --- a/.github/workflows/examples-linux-standalone.yaml +++ b/.github/workflows/examples-linux-standalone.yaml @@ -22,19 +22,19 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: linux_standalone: name: Linux Standalone timeout-minutes: 90 - env: - BUILD_TYPE: gn_linux - runs-on: ubuntu-latest if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build:0.6.06 + image: connectedhomeip/chip-build:0.6.18 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" @@ -67,59 +67,75 @@ jobs: path: | .environment/gn_out/.ninja_log .environment/pigweed-venv/*.log + - name: Build Standalone cert tool timeout-minutes: 10 run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps \ - --target linux-x64-chip-cert \ - --target linux-arm64-chip-cert \ - build \ - " + "./scripts/build/build_examples.py \ + --target linux-x64-chip-cert \ + build" - name: Build minmdns example with platform dns timeout-minutes: 10 run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps --target linux-x64-address-resolve-tool-platform-mdns-ipv6only build" + "./scripts/build/build_examples.py \ + --target linux-x64-address-resolve-tool-platform-mdns-ipv6only \ + build" - name: Build example Standalone Echo Client timeout-minutes: 10 run: | - scripts/examples/gn_build_example.sh examples/chip-tool out/chip_tool_debug + ./scripts/run_in_build_env.sh \ + "./scripts/build/build_examples.py \ + --target linux-x64-chip-tool \ + build" .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ linux debug chip-tool \ - out/chip_tool_debug/chip-tool \ + out/linux-x64-chip-tool/chip-tool \ /tmp/bloat_reports/ - name: Build example Standalone Shell timeout-minutes: 10 run: | - scripts/examples/gn_build_example.sh examples/shell/standalone out/shell_debug + ./scripts/run_in_build_env.sh \ + "./scripts/build/build_examples.py \ + --target linux-x64-shell \ + build" .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ linux debug shell \ - out/shell_debug/chip-shell \ + out/linux-x64-shell/chip-shell \ /tmp/bloat_reports/ - name: Build example Standalone All Clusters Server timeout-minutes: 10 run: | - scripts/examples/gn_build_example.sh examples/all-clusters-app/linux out/all_clusters_debug + ./scripts/run_in_build_env.sh \ + "./scripts/build/build_examples.py \ + --target linux-x64-all-clusters \ + build" .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ linux debug all-clusters-app \ - out/all_clusters_debug/chip-all-clusters-app \ + out/linux-x64-all-clusters/chip-all-clusters-app \ /tmp/bloat_reports/ - - name: Build example Standalone All Clusters Mininal Server + - name: Build example Standalone All Clusters Minimal Server timeout-minutes: 10 run: | - scripts/examples/gn_build_example.sh examples/all-clusters-minimal-app/linux out/all_clusters_minimal_debug + ./scripts/run_in_build_env.sh \ + "./scripts/build/build_examples.py \ + --target linux-x64-all-clusters-minimal \ + build" .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ linux debug all-clusters-minimal-app \ - out/all_clusters_minimal_debug/chip-all-clusters-minimal-app \ + out/linux-x64-all-clusters-minimal/chip-all-clusters-minimal-app \ /tmp/bloat_reports/ - name: Build example TV app timeout-minutes: 10 run: | - scripts/examples/gn_build_example.sh examples/tv-app/linux out/tv_app_debug + ./scripts/run_in_build_env.sh \ + "./scripts/build/build_examples.py \ + --target linux-x64-tv-app \ + build" .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ linux debug tv-app \ - out/tv_app_debug/chip-tv-app \ + out/linux-x64-tv-app/chip-tv-app \ /tmp/bloat_reports/ - name: Build example Standalone TV Casting App timeout-minutes: 10 @@ -135,37 +151,47 @@ jobs: - name: Build example lighting app with RPCs timeout-minutes: 10 run: | - scripts/examples/gn_build_example.sh examples/lighting-app/linux out/lighting_app_debug_rpc \ - 'import("//with_pw_rpc.gni")' + ./scripts/run_in_build_env.sh \ + "./scripts/build/build_examples.py \ + --target linux-x64-light-rpc \ + build" .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ linux debug+rpc lighting-app \ - out/lighting_app_debug_rpc/chip-lighting-app \ + out/linux-x64-light-rpc/chip-lighting-app \ /tmp/bloat_reports/ - name: Build example Standalone Bridge timeout-minutes: 10 run: | - scripts/examples/gn_build_example.sh examples/bridge-app/linux out/bridge_debug + ./scripts/run_in_build_env.sh \ + "./scripts/build/build_examples.py \ + --target linux-x64-bridge \ + build" .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ - linux debug+rpc bridge-app \ - out/bridge_debug/chip-bridge-app \ + linux debug bridge-app \ + out/linux-x64-bridge/chip-bridge-app \ /tmp/bloat_reports/ - name: Build example OTA Provider timeout-minutes: 10 run: | - scripts/examples/gn_build_example.sh examples/ota-provider-app/linux out/ota_provider_debug + ./scripts/run_in_build_env.sh \ + "./scripts/build/build_examples.py \ + --target linux-x64-ota-provider \ + build" .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ linux debug ota-provider-app \ - out/ota_provider_debug/chip-ota-provider-app \ + out/linux-x64-ota-provider/chip-ota-provider-app \ /tmp/bloat_reports/ - name: Build example OTA Requestor timeout-minutes: 10 run: | - scripts/examples/gn_build_example.sh examples/ota-requestor-app/linux out/ota_requestor_debug + ./scripts/run_in_build_env.sh \ + "./scripts/build/build_examples.py \ + --target linux-x64-ota-requestor \ + build" .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ linux debug ota-requestor-app \ - out/ota_requestor_debug/chip-ota-requestor-app \ + out/linux-x64-ota-requestor/chip-ota-requestor-app \ /tmp/bloat_reports/ - - name: Build example Standalone Lock App timeout-minutes: 10 run: | @@ -177,6 +203,7 @@ jobs: linux debug lock-app \ out/linux-x64-lock/chip-lock-app \ /tmp/bloat_reports/ + - name: Uploading Size Reports uses: actions/upload-artifact@v3 if: ${{ !env.ACT }} diff --git a/.github/workflows/examples-mbed.yaml b/.github/workflows/examples-mbed.yaml index 442d520103e252..3a9d522b1aa676 100644 --- a/.github/workflows/examples-mbed.yaml +++ b/.github/workflows/examples-mbed.yaml @@ -23,6 +23,9 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: mbedos: name: Mbed OS examples building @@ -37,7 +40,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-mbed-os:0.6.06 + image: connectedhomeip/chip-build-mbed-os:0.6.18 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" @@ -150,7 +153,7 @@ jobs: mbed $APP_TARGET+$APP_PROFILE shell \ examples/ota-requestor-app/mbed/build-CY8CPROTO_062_4343W/release/chip-mbed-ota-requestor-app-example.elf \ /tmp/bloat_reports/ - + - name: Build unit tests # Temporarily disable build due to running out of flash space if: false diff --git a/.github/workflows/examples-mw320.yaml b/.github/workflows/examples-mw320.yaml index 091a624a88d3b4..aedded0398df28 100755 --- a/.github/workflows/examples-mw320.yaml +++ b/.github/workflows/examples-mw320.yaml @@ -22,6 +22,9 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: mw320: name: MW320 @@ -34,7 +37,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build:0.6.06 + image: connectedhomeip/chip-build:0.6.18 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" steps: diff --git a/.github/workflows/examples-nrfconnect.yaml b/.github/workflows/examples-nrfconnect.yaml index 4b9430d38a4b96..7d0c274dc2d029 100644 --- a/.github/workflows/examples-nrfconnect.yaml +++ b/.github/workflows/examples-nrfconnect.yaml @@ -22,6 +22,9 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: nrfconnect: name: nRF Connect SDK @@ -34,7 +37,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-nrf-platform:0.6.06 + image: connectedhomeip/chip-build-nrf-platform:0.6.18 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" @@ -209,7 +212,7 @@ jobs: .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ nrfconnect nrf7002dk_nrf5340_cpuapp light-switch-app \ examples/light-switch-app/nrfconnect/build/zephyr/zephyr.elf \ - /tmp/bloat_reports/ + /tmp/bloat_reports/ - name: Build example nRF Connect SDK Lighting App on nRF7002 PDK if: github.event_name == 'push' || steps.changed_paths.outputs.nrfconnect == 'true' timeout-minutes: 20 @@ -218,7 +221,7 @@ jobs: .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ nrfconnect nrf7002dk_nrf5340_cpuapp lighting-app \ examples/light-switch-app/nrfconnect/build/zephyr/zephyr.elf \ - /tmp/bloat_reports/ + /tmp/bloat_reports/ - name: Build example nRF Connect SDK All Clusters App on nRF7002 PDK timeout-minutes: 20 run: | diff --git a/.github/workflows/examples-openiotsdk.yaml b/.github/workflows/examples-openiotsdk.yaml new file mode 100644 index 00000000000000..981c97d74f5990 --- /dev/null +++ b/.github/workflows/examples-openiotsdk.yaml @@ -0,0 +1,114 @@ +# Copyright (c) 2021 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +name: Build example - Open IoT SDK + +on: + push: + pull_request: + workflow_dispatch: + +concurrency: + group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} + cancel-in-progress: true + +jobs: + openiotsdk: + name: Open IoT SDK examples building + timeout-minutes: 140 + + env: + TEST_NETWORK_NAME: OIStest + + runs-on: ubuntu-latest + if: github.actor != 'restyled-io[bot]' + + container: + image: connectedhomeip/chip-build-openiotsdk:0.6.18 + volumes: + - "/tmp/bloat_reports:/tmp/bloat_reports" + options: --privileged + + steps: + - uses: Wandalen/wretry.action@v1.0.36 + name: Checkout + with: + action: actions/checkout@v3 + with: | + token: ${{ github.token }} + attempt_limit: 3 + attempt_delay: 2000 + - name: Checkout submodules + run: scripts/checkout_submodules.py --shallow --recursive --platform openiotsdk + + - name: Set up environment for size reports + if: ${{ !env.ACT }} + env: + GH_CONTEXT: ${{ toJson(github) }} + run: scripts/tools/memory/gh_sizes_environment.py "${GH_CONTEXT}" + + - name: Bootstrap + timeout-minutes: 10 + run: scripts/build/gn_bootstrap.sh + + - name: Build and install Python controller + timeout-minutes: 10 + run: | + scripts/run_in_build_env.sh './scripts/build_python.sh --install_wheel build-env' + + - name: Build shell example + id: build_shell + timeout-minutes: 10 + run: | + scripts/examples/openiotsdk_example.sh shell + .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ + openiotsdk release shell \ + examples/shell/openiotsdk/build/chip-openiotsdk-shell-example.elf \ + /tmp/bloat_reports/ + + - name: Build lock-app example + id: build_lock_app + timeout-minutes: 10 + run: | + scripts/examples/openiotsdk_example.sh lock-app + .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ + openiotsdk release lock-app \ + examples/lock-app/openiotsdk/build/chip-openiotsdk-lock-app-example.elf \ + /tmp/bloat_reports/ + + - name: Build unit tests + id: build_unit_tests + timeout-minutes: 10 + run: | + scripts/examples/openiotsdk_example.sh unit-tests + + - name: Test shell example + if: steps.build_shell.outcome == 'success' + timeout-minutes: 5 + run: | + scripts/examples/openiotsdk_example.sh -C test shell + + - name: Test lock-app example + if: steps.build_lock_app.outcome == 'success' + timeout-minutes: 5 + run: | + scripts/setup/openiotsdk/network_setup.sh -n $TEST_NETWORK_NAME up + scripts/run_in_ns.sh ${TEST_NETWORK_NAME}ns scripts/examples/openiotsdk_example.sh -C test -n ${TEST_NETWORK_NAME}tap lock-app + scripts/setup/openiotsdk/network_setup.sh -n $TEST_NETWORK_NAME down + + - name: Run unit tests + if: steps.build_unit_tests.outcome == 'success' && github.event_name == 'pull_request' + timeout-minutes: 90 + run: | + scripts/examples/openiotsdk_example.sh -C run unit-tests diff --git a/.github/workflows/examples-qpg.yaml b/.github/workflows/examples-qpg.yaml index c5f97823e34d53..c32dd590ddc930 100644 --- a/.github/workflows/examples-qpg.yaml +++ b/.github/workflows/examples-qpg.yaml @@ -22,6 +22,9 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: qpg: name: QPG @@ -34,7 +37,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build:0.6.06 + image: connectedhomeip/chip-build:0.6.18 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" steps: diff --git a/.github/workflows/examples-telink.yaml b/.github/workflows/examples-telink.yaml index d4f1a9bd8f0991..2099621e165ed3 100644 --- a/.github/workflows/examples-telink.yaml +++ b/.github/workflows/examples-telink.yaml @@ -22,6 +22,9 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: telink: name: Telink @@ -32,7 +35,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-telink:0.6.06 + image: connectedhomeip/chip-build-telink:0.6.18 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" @@ -57,7 +60,7 @@ jobs: - name: Build example Telink All Clusters App run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps --target 'telink-tlsr9518adk80d-all-clusters' build" + "./scripts/build/build_examples.py --target 'telink-tlsr9518adk80d-all-clusters' build" .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ telink tlsr9518adk80d all-clusters-app \ out/telink-tlsr9518adk80d-all-clusters/zephyr/zephyr.elf \ @@ -66,7 +69,7 @@ jobs: - name: Build example Telink All Clusters Minimal App run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps --target 'telink-tlsr9518adk80d-all-clusters-minimal' build" + "./scripts/build/build_examples.py --target 'telink-tlsr9518adk80d-all-clusters-minimal' build" .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ telink tlsr9518adk80d all-clusters-minimal-app \ out/telink-tlsr9518adk80d-all-clusters-minimal/zephyr/zephyr.elf \ @@ -75,7 +78,7 @@ jobs: - name: Build example Telink Lighting App run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps --target 'telink-tlsr9518adk80d-light' build" + "./scripts/build/build_examples.py --target 'telink-tlsr9518adk80d-light' build" .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ telink tlsr9518adk80d lighting-app \ out/telink-tlsr9518adk80d-light/zephyr/zephyr.elf \ @@ -84,7 +87,7 @@ jobs: - name: Build example Telink Light Switch App run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps --target 'telink-tlsr9518adk80d-light-switch' build" + "./scripts/build/build_examples.py --target 'telink-tlsr9518adk80d-light-switch' build" .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ telink tlsr9518adk80d light-switch-app \ out/telink-tlsr9518adk80d-light-switch/zephyr/zephyr.elf \ @@ -93,7 +96,7 @@ jobs: - name: Build example Telink OTA Requestor App run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps --target 'telink-tlsr9518adk80d-ota-requestor' build" + "./scripts/build/build_examples.py --target 'telink-tlsr9518adk80d-ota-requestor' build" .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ telink tlsr9518adk80d ota-requestor-app \ out/telink-tlsr9518adk80d-ota-requestor/zephyr/zephyr.elf \ @@ -102,7 +105,7 @@ jobs: - name: Build example Telink Thermostat App run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps --target 'telink-tlsr9518adk80d-thermostat' build" + "./scripts/build/build_examples.py --target 'telink-tlsr9518adk80d-thermostat' build" .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \ telink tlsr9518adk80d thermostat \ out/telink-tlsr9518adk80d-thermostat/zephyr/zephyr.elf \ diff --git a/.github/workflows/examples-tizen.yaml b/.github/workflows/examples-tizen.yaml index 05fae3cba514fb..259733a008237c 100644 --- a/.github/workflows/examples-tizen.yaml +++ b/.github/workflows/examples-tizen.yaml @@ -22,17 +22,18 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: tizen: name: Tizen - env: - BUILD_TYPE: tizen runs-on: ubuntu-latest if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-tizen:0.6.06 + image: connectedhomeip/chip-build-tizen:0.6.18 options: --user root volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" @@ -49,6 +50,10 @@ jobs: attempt_delay: 2000 - name: Checkout submodules run: scripts/checkout_submodules.py --shallow --platform tizen + + - name: Bootstrap + run: scripts/build/gn_bootstrap.sh + - name: Build Tizen examples run: | ./scripts/run_in_build_env.sh \ @@ -56,7 +61,7 @@ jobs: --enable-flashbundle \ --target tizen-arm-all-clusters \ --target tizen-arm-all-clusters-minimal-no-wifi \ - --target chip-tool \ + --target chip-tool-ubsan \ --target light \ --target light-no-ble-no-wifi \ build \ diff --git a/.github/workflows/full-android.yaml b/.github/workflows/full-android.yaml index dc038407f8edb7..1173adaf7c82d5 100644 --- a/.github/workflows/full-android.yaml +++ b/.github/workflows/full-android.yaml @@ -22,6 +22,9 @@ concurrency: group: full-${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: full_android: name: Run @@ -34,7 +37,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-android:0.6.06 + image: connectedhomeip/chip-build-android:0.6.18 volumes: - "/tmp/log_output:/tmp/test_logs" @@ -73,35 +76,35 @@ jobs: - name: Build Android arm-chip-tool run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps --target android-arm-chip-tool build" + "./scripts/build/build_examples.py --target android-arm-chip-tool build" - name: Clean out build output run: rm -rf ./out - name: Build Android arm-tv-casting-app run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps --target android-arm-tv-casting-app build" + "./scripts/build/build_examples.py --target android-arm-tv-casting-app build" - name: Clean out build output run: rm -rf ./out - name: Build Android arm-tv-server run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps --target android-arm-tv-server build" + "./scripts/build/build_examples.py --target android-arm-tv-server build" - name: Clean out build output run: rm -rf ./out - name: Build Android arm64-tv-casting-app run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps --target android-arm64-tv-casting-app build" + "./scripts/build/build_examples.py --target android-arm64-tv-casting-app build" - name: Clean out build output run: rm -rf ./out - name: Build Android arm64-tv-server run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps --target android-arm64-tv-server build" + "./scripts/build/build_examples.py --target android-arm64-tv-server build" - name: Build Android arm64-chip-tool run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps --target android-arm64-chip-tool build" + "./scripts/build/build_examples.py --target android-arm64-chip-tool build" - name: Run Android build rule tests run: | ./scripts/run_in_build_env.sh \ @@ -111,4 +114,4 @@ jobs: # - name: Build Android Studio build (arm64 only) # run: | # ./scripts/run_in_build_env.sh \ - # "./scripts/build/build_examples.py --no-log-timestamps --target android-androidstudio-arm64-chip-tool build" + # "./scripts/build/build_examples.py --target android-androidstudio-arm64-chip-tool build" diff --git a/.github/workflows/fuzzing-build.yaml b/.github/workflows/fuzzing-build.yaml index 1999f806dc6329..bd96ff35792e31 100644 --- a/.github/workflows/fuzzing-build.yaml +++ b/.github/workflows/fuzzing-build.yaml @@ -22,6 +22,9 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: build_linux_fuzzing: name: Build on Linux @@ -31,7 +34,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build:0.6.06 + image: connectedhomeip/chip-build:0.6.18 volumes: - "/tmp/log_output:/tmp/test_logs" diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 7e468d2e0acb87..89e8c44d26a37f 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -28,7 +28,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build:0.6.06 + image: connectedhomeip/chip-build:0.6.18 steps: - uses: Wandalen/wretry.action@v1.0.36 diff --git a/.github/workflows/qemu.yaml b/.github/workflows/qemu.yaml index 8eb3b87abb441e..1a0c88e28d47b3 100644 --- a/.github/workflows/qemu.yaml +++ b/.github/workflows/qemu.yaml @@ -22,6 +22,9 @@ concurrency: group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: qemu: name: ESP32 @@ -34,7 +37,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-esp32-qemu:0.6.06 + image: connectedhomeip/chip-build-esp32-qemu:0.6.18 volumes: - "/tmp/log_output:/tmp/test_logs" diff --git a/.github/workflows/release_artifacts.yaml b/.github/workflows/release_artifacts.yaml index 4795f36bdcc6c5..6b57156ba01f2d 100644 --- a/.github/workflows/release_artifacts.yaml +++ b/.github/workflows/release_artifacts.yaml @@ -29,7 +29,7 @@ jobs: runs-on: ubuntu-latest container: - image: connectedhomeip/chip-build-esp32:0.6.06 + image: connectedhomeip/chip-build-esp32:0.6.18 steps: - uses: Wandalen/wretry.action@v1.0.36 @@ -75,7 +75,7 @@ jobs: runs-on: ubuntu-latest container: - image: connectedhomeip/chip-build-efr32:0.6.06 + image: connectedhomeip/chip-build-efr32:0.6.18 steps: - uses: Wandalen/wretry.action@v1.0.36 name: Checkout diff --git a/.github/workflows/smoketest-android.yaml b/.github/workflows/smoketest-android.yaml index 5874ba9f40c0db..04c4c8ecb77d2b 100644 --- a/.github/workflows/smoketest-android.yaml +++ b/.github/workflows/smoketest-android.yaml @@ -22,6 +22,9 @@ concurrency: group: smoke-${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: android: name: Smoke Run - Android @@ -34,7 +37,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-android:0.6.06 + image: connectedhomeip/chip-build-android:0.6.18 volumes: - "/tmp/log_output:/tmp/test_logs" @@ -63,7 +66,7 @@ jobs: - name: Build Android CHIPTool and CHIPTest (ARM64) run: | ./scripts/run_in_build_env.sh \ - "./scripts/build/build_examples.py --no-log-timestamps --target android-arm64-chip-tool build" + "./scripts/build/build_examples.py --target android-arm64-chip-tool build" - name: Run Android build rule tests run: | ./scripts/run_in_build_env.sh \ diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 6fb4aacaacf6ab..41cc18134456a9 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -25,6 +25,9 @@ concurrency: 'workflow_dispatch' && github.run_number) || github.sha }} cancel-in-progress: true +env: + CHIP_NO_LOG_TIMESTAMPS: true + jobs: test_suites_linux: name: Test Suites - Linux @@ -44,7 +47,7 @@ jobs: runs-on: ubuntu-latest container: - image: connectedhomeip/chip-build:0.6.06 + image: connectedhomeip/chip-build:0.6.18 options: --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0 net.ipv4.conf.all.forwarding=1 net.ipv6.conf.all.forwarding=1" @@ -86,7 +89,7 @@ jobs: path: | .environment/gn_out/.ninja_log .environment/pigweed-venv/*.log - - name: Validate that xml are parseable + - name: Validate that xml are parsable timeout-minutes: 10 # The sub-items being run here are the same as the input XMLs listed # at src/app/zap-templates/zcl/zcl.json @@ -96,9 +99,9 @@ jobs: # unit tests) # # Also note ordering: global attributes are parsed first because other XML files may - # reference these. + # reference these. # - # TODO: some multipass/postprocess may be more appropriate to allow any ordering of + # TODO: some multipass/postprocess may be more appropriate to allow any ordering of # things. run: | ./scripts/run_in_build_env.sh \ @@ -225,6 +228,7 @@ jobs: path: objdir-clone/ # objdirs are big; don't hold on to them too long. retention-days: 5 + test_suites_darwin: name: Test Suites - Darwin timeout-minutes: 150 @@ -336,6 +340,7 @@ jobs: path: objdir-clone/ # objdirs are big; don't hold on to them too long. retention-days: 5 + repl_tests_linux: name: REPL Tests - Linux timeout-minutes: 130 @@ -347,7 +352,7 @@ jobs: runs-on: ubuntu-latest container: - image: connectedhomeip/chip-build:0.6.06 + image: connectedhomeip/chip-build:0.6.18 options: --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0 net.ipv4.conf.all.forwarding=0 net.ipv6.conf.all.forwarding=0" @@ -408,6 +413,7 @@ jobs: path: objdir-clone/ # objdirs are big; don't hold on to them too long. retention-days: 5 + java_tests_linux: name: Java Tests - Linux timeout-minutes: 130 @@ -420,7 +426,7 @@ jobs: runs-on: ubuntu-latest container: - image: connectedhomeip/chip-build:0.6.06 + image: connectedhomeip/chip-build:0.6.18 options: --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0 net.ipv4.conf.all.forwarding=0 net.ipv6.conf.all.forwarding=0" @@ -456,11 +462,23 @@ jobs: --target linux-x64-java-matter-controller \ build \ " + - name: Run Tests + timeout-minutes: 65 + run: | + scripts/run_in_build_env.sh \ + './scripts/tests/run_java_test.py \ + --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app \ + --app-args "--discriminator 3840 --interface-id -1" \ + --tool-path out/linux-x64-java-matter-controller \ + --tool-cluster "pairing" \ + --tool-args "--nodeid 1 --setup-payload 20202021 --discriminator 3840 -t 1000" \ + --factoryreset \ + ' - name: Uploading core files uses: actions/upload-artifact@v3 if: ${{ failure() && !env.ACT }} with: - name: crash-core-linux-python-repl + name: crash-core-linux-java-controller path: /tmp/cores/ # Cores are big; don't hold on to them too long. retention-days: 5 @@ -468,7 +486,7 @@ jobs: uses: actions/upload-artifact@v3 if: ${{ failure() && !env.ACT }} with: - name: crash-objdir-linux-python-repl + name: crash-objdir-linux-java-controller path: objdir-clone/ # objdirs are big; don't hold on to them too long. retention-days: 5 diff --git a/.github/workflows/unit_integration_test.yaml b/.github/workflows/unit_integration_test.yaml index d1067b10e6bb94..a0ea6842e24dc0 100644 --- a/.github/workflows/unit_integration_test.yaml +++ b/.github/workflows/unit_integration_test.yaml @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -name: Unit / Interation Tests +name: Unit / Integration Tests on: push: @@ -24,7 +24,7 @@ concurrency: jobs: unit_tests: - name: Unit / Interation Tests + name: Unit / Integration Tests timeout-minutes: 60 if: github.actor != 'restyled-io[bot]' @@ -37,7 +37,7 @@ jobs: runs-on: ubuntu-latest container: - image: connectedhomeip/chip-build:0.6.06 + image: connectedhomeip/chip-build:0.6.18 volumes: - "/tmp/log_output:/tmp/test_logs" options: --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0 net.ipv4.conf.all.forwarding=1 net.ipv6.conf.all.forwarding=1" diff --git a/.github/workflows/zap_regeneration.yaml b/.github/workflows/zap_regeneration.yaml index 11f9492abdd16d..1654fdb416dcab 100644 --- a/.github/workflows/zap_regeneration.yaml +++ b/.github/workflows/zap_regeneration.yaml @@ -28,7 +28,7 @@ jobs: runs-on: ubuntu-20.04 container: - image: connectedhomeip/chip-build:0.6.11 + image: connectedhomeip/chip-build:0.6.18 defaults: run: shell: sh diff --git a/.github/workflows/zap_templates.yaml b/.github/workflows/zap_templates.yaml index ba21cfc103a1b1..6bc8206cce1684 100644 --- a/.github/workflows/zap_templates.yaml +++ b/.github/workflows/zap_templates.yaml @@ -29,7 +29,7 @@ jobs: runs-on: ubuntu-20.04 container: - image: connectedhomeip/chip-build:0.6.11 + image: connectedhomeip/chip-build:0.6.18 defaults: run: shell: sh diff --git a/.gitmodules b/.gitmodules index a68fbf7fc095da..f211ca385789ff 100644 --- a/.gitmodules +++ b/.gitmodules @@ -58,7 +58,7 @@ path = third_party/freertos/repo url = https://github.com/FreeRTOS/FreeRTOS-Kernel.git branch = V10.3.1-kernel-only - platforms = ameba,cc13x2_26x2,bl602,efr32,esp32,k32w0,infineon,qpg + platforms = ameba,cc13x2_26x2,bouffalolab,efr32,esp32,k32w0,infineon,qpg [submodule "simw-top-mini"] path = third_party/simw-top-mini/repo url = https://github.com/NXP/plug-and-trust.git @@ -220,10 +220,6 @@ path = third_party/infineon/psoc6/psoc6_sdk/libs/serial-flash url = https://github.com/Infineon/serial-flash platforms = infineon -[submodule "third_party/telink_sdk/repo"] - path = third_party/telink_sdk/repo - url = https://github.com/telink-semi/telink_b91_ble_single_connection_sdk_matter - platforms = telink [submodule "ti_simplelink_sdk"] path = third_party/ti_simplelink_sdk/repo_cc13xx_cc26xx url = https://github.com/TexasInstruments/cc13xx_cc26xx_sdk.git @@ -264,11 +260,6 @@ [submodule "third_party/boringssl/repo/src"] path = third_party/boringssl/repo/src url = https://github.com/google/boringssl.git -[submodule "boufalolab_repo"] - path = third_party/bouffalolab/repo - url = https://github.com/bouffalolab/bl_iot_sdk.git - branch = master - platforms = bouffalolab,bl602 [submodule "third_party/mt793x_sdk/filogic"] path = third_party/mt793x_sdk/filogic url = https://github.com/MediaTek-Labs/genio-matter-bsp.git @@ -293,4 +284,9 @@ path = third_party/open-iot-sdk/storage url = https://git.gitlab.arm.com/iot/open-iot-sdk/storage.git branch = main - platforms = openiotsdk + platforms = openiotsdk +[submodule "bouffalolab_sdk"] + path = third_party/bouffalolab/repo + url = https://github.com/bouffalolab/bl_iot_sdk_tiny.git + branch = main + platforms = bouffalolab diff --git a/.vscode/launch.json b/.vscode/launch.json index aca86897789a1c..bf83cc0d85d6e4 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -424,6 +424,35 @@ "/tmp/ota-image.bin" ], "cwd": "${workspaceFolder}" + }, + + { + "name": "Debug Open IoT SDK example application", + "type": "cortex-debug", + "request": "launch", + "cwd": "${workspaceRoot}/examples/${input:openiotsdkApp}/openiotsdk", + "executable": "./build/chip-openiotsdk-${input:openiotsdkApp}-example.elf", + "armToolchainPath": "${env:ARM_GCC_TOOLCHAIN_PATH}/bin", + "servertype": "external", + "gdbTarget": "${input:openiotsdkRemoteHost}:31627", //GDBserver port on FVP + "overrideLaunchCommands": ["-enable-pretty-printing"], + "runToEntryPoint": "main", + "preLaunchTask": "Debug Open IoT SDK example", + "showDevDebugOutput": "parsed" + }, + { + "name": "Debug Open IoT SDK unit-tests application", + "type": "cortex-debug", + "request": "launch", + "cwd": "${workspaceRoot}/src/test_driver/openiotsdk/unit-tests", + "executable": "./build/${input:openiotsdkUnittest}.elf", + "armToolchainPath": "${env:ARM_GCC_TOOLCHAIN_PATH}/bin", + "servertype": "external", + "gdbTarget": ":31627", //GDBserver port on FVP + "overrideLaunchCommands": ["-enable-pretty-printing"], + "runToEntryPoint": "main", + "preLaunchTask": "Debug Open IoT SDK unit-tests", + "showDevDebugOutput": "parsed" } ], "inputs": [ @@ -479,6 +508,52 @@ "description": "What mbed target do you want to use?", "options": ["CY8CPROTO_062_4343W"], "default": "CY8CPROTO_062_4343W" + }, + { + "type": "pickString", + "id": "openiotsdkApp", + "description": "What Open IoT SDK example do you want to use?", + "options": ["shell", "lock-app"], + "default": "shell" + }, + { + "type": "promptString", + "id": "openiotsdkRemoteHost", + "description": "Type the hostname/IP address of external GDB target that you want to connect to. Leave blank for internal GDB server", + "default": "" + }, + { + "type": "pickString", + "id": "openiotsdkUnittest", + "description": "What Open IoT SDK unit test do you want to use?", + "options": [ + "accesstest", + "AppTests", + "ASN1Tests", + "BDXTests", + "ChipCryptoTests", + "ControllerTests", + "CoreTests", + "CredentialsTest", + "DataModelTests", + "InetLayerTests", + "MdnsTests", + "MessagingLayerTests", + "MinimalMdnsCoreTests", + "MinimalMdnsRecordsTests", + "MinimalMdnsRespondersTests", + "PlatformTests", + "RawTransportTests", + "RetransmitTests", + "SecureChannelTests", + "SetupPayloadTests", + "SupportTests", + "SystemLayerTests", + "TestShell", + "TransportLayerTests", + "UserDirectedCommissioningTests" + ], + "default": "accesstest" } ] } diff --git a/.vscode/tasks.json b/.vscode/tasks.json index f8cf998bd15e2a..fd815494affee7 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -242,6 +242,151 @@ "showReuseMessage": true, "clear": true } + }, + { + "label": "Build Open IoT SDK example", + "type": "shell", + "command": "scripts/examples/openiotsdk_example.sh", + "args": [ + "-Cbuild", + "-d${input:openiotsdkDebugMode}", + "${input:openiotsdkExample}" + ], + "group": "build", + "problemMatcher": { + "pattern": { + "regexp": "^(.*):(\\d+):(\\d+):\\s+(warning|error):\\s+(.*)$", + "file": 1, + "line": 2, + "message": 5 + } + } + }, + { + "label": "Build Open IoT SDK unit-tests", + "type": "shell", + "command": "scripts/examples/openiotsdk_example.sh", + "args": ["-Cbuild", "-d${input:openiotsdkDebugMode}", "unit-tests"], + "group": "build", + "problemMatcher": { + "pattern": { + "regexp": "^(.*):(\\d+):(\\d+):\\s+(warning|error):\\s+(.*)$", + "file": 1, + "line": 2, + "message": 5 + } + } + }, + { + "label": "Run Open IoT SDK example", + "type": "shell", + "command": "scripts/run_in_ns.sh", + "args": [ + "${input:openiotsdkNetworkNamespace}", + "scripts/examples/openiotsdk_example.sh", + "-Crun", + "-n${input:openiotsdkNetworkInterface}", + "${input:openiotsdkExample}" + ], + "group": "test", + "problemMatcher": { + "pattern": { + "regexp": "^(.*):(\\d+):(\\d+):\\s+(warning|error):\\s+(.*)$", + "file": 1, + "line": 2, + "message": 5 + } + } + }, + { + "label": "Run Open IoT SDK unit-tests", + "type": "shell", + "command": "scripts/examples/openiotsdk_example.sh", + "args": ["-Crun", "unit-tests", "${input:openiotsdkUnitTest}"], + "group": "test", + "problemMatcher": { + "pattern": { + "regexp": "^(.*):(\\d+):(\\d+):\\s+(warning|error):\\s+(.*)$", + "file": 1, + "line": 2, + "message": 5 + } + } + }, + { + "label": "Test Open IoT SDK example", + "type": "shell", + "command": "scripts/run_in_ns.sh", + "args": [ + "${input:openiotsdkNetworkNamespace}", + "scripts/examples/openiotsdk_example.sh", + "-Ctest", + "-n${input:openiotsdkNetworkInterface}", + "${input:openiotsdkExample}" + ], + "group": "test", + "problemMatcher": { + "pattern": { + "regexp": "^(.*):(\\d+):(\\d+):\\s+(warning|error):\\s+(.*)$", + "file": 1, + "line": 2, + "message": 5 + } + } + }, + { + "label": "Debug Open IoT SDK example", + "type": "shell", + "command": "scripts/run_in_ns.sh", + "args": [ + "${input:openiotsdkNetworkNamespace}", + "scripts/examples/openiotsdk_example.sh", + "-Crun", + "-n${input:openiotsdkNetworkInterface}", + "-dtrue", + "${input:openiotsdkExample}" + ], + "group": "none", + "isBackground": true, + "problemMatcher": { + "pattern": { + "regexp": "^(.*):(\\d+):(\\d+):\\s+(warning|error):\\s+(.*)$", + "file": 1, + "line": 2, + "message": 5 + }, + "background": { + "activeOnStart": true, + "beginsPattern": "^.*Trying*", + "endsPattern": "^.*Connected to localhost*" + } + } + }, + { + "label": "Debug Open IoT SDK unit-tests", + "type": "shell", + "command": "scripts/examples/openiotsdk_example.sh", + "args": [ + "-Crun", + "-dtrue", + "unit-tests", + "${input:openiotsdkUnitTest}" + ], + "group": "none", + "isBackground": true, + "problemMatcher": { + "pattern": { + "regexp": "^(.*):(\\d+):(\\d+):\\s+(warning|error):\\s+(.*)$", + "file": 1, + "line": 2, + "message": 5 + }, + "background": { + "activeOnStart": true, + "beginsPattern": "^.*Trying*", + "endsPattern": "^.*Connected to localhost*" + } + } } ], "inputs": [ @@ -287,6 +432,66 @@ "options": ["simple", "boot", "upgrade"], "default": "simple" }, + { + "type": "pickString", + "id": "openiotsdkDebugMode", + "description": "Do you want to use debug mode?", + "options": ["false", "true"], + "default": "false" + }, + { + "type": "pickString", + "id": "openiotsdkExample", + "description": "What Open IoT SDK example application do you want to use?", + "options": ["shell", "lock-app"], + "default": "shell" + }, + { + "type": "pickString", + "id": "openiotsdkUnitTest", + "description": "What unit test do you want to use?", + "options": [ + "all", + "accesstest", + "AppTests", + "ASN1Tests", + "BDXTests", + "ChipCryptoTests", + "ControllerTests", + "CoreTests", + "CredentialsTest", + "DataModelTests", + "InetLayerTests", + "MdnsTests", + "MessagingLayerTests", + "MinimalMdnsCoreTests", + "MinimalMdnsRecordsTests", + "MinimalMdnsRespondersTests", + "PlatformTests", + "RawTransportTests", + "RetransmitTests", + "SecureChannelTests", + "SetupPayloadTests", + "SupportTests", + "SystemLayerTests", + "TestShell", + "TransportLayerTests", + "UserDirectedCommissioningTests" + ], + "default": "all" + }, + { + "type": "promptString", + "id": "openiotsdkNetworkNamespace", + "description": "Type the network namespace that you want to use. \"default\" means host default network namespace", + "default": "default" + }, + { + "type": "promptString", + "id": "openiotsdkNetworkInterface", + "description": "Type the network interface name that you want to use. \"user\" means user network mode", + "default": "user" + }, { "type": "promptString", "id": "exampleGlob", @@ -428,6 +633,8 @@ "nrf-nrf5340-pump", "nrf-nrf5340-pump-controller", "nrf-nrf5340-shell", + "openiotsdk-lock", + "openiotsdk-shell", "qpg-qpg6100-lock", "telink-tlsr9518adk80d-all-clusters", "telink-tlsr9518adk80d-all-clusters-minimal", diff --git a/README.md b/README.md index d552a52da0a64f..ed56ea18d308c1 100644 --- a/README.md +++ b/README.md @@ -11,10 +11,11 @@ [![Examples - QPG](https://github.com/project-chip/connectedhomeip/workflows/Build%20example%20-%20QPG/badge.svg)](https://github.com/project-chip/connectedhomeip/actions/workflows/examples-qpg.yaml) [![Examples - TI CC26X2X7](https://github.com/project-chip/connectedhomeip/workflows/Build%20example%20-%20TI%20CC26X2X7/badge.svg)](https://github.com/project-chip/connectedhomeip/actions/workflows/examples-cc13x2x7_26x2x7.yaml) [![Build example - Infineon](https://github.com/project-chip/connectedhomeip/actions/workflows/examples-infineon.yaml/badge.svg)](https://github.com/project-chip/connectedhomeip/actions/workflows/examples-infineon.yaml) +[![Build example - BouffaloLab](https://github.com/project-chip/connectedhomeip/workflows/Build%20example%20-%20BouffaloLab/badge.svg)](https://github.com/project-chip/connectedhomeip/actions/workflows/examples-bouffalolab.yaml) [![Android](https://github.com/project-chip/connectedhomeip/workflows/Android/badge.svg)](https://github.com/project-chip/connectedhomeip/actions/workflows/android.yaml) -[![Unit / Interation Tests](https://github.com/project-chip/connectedhomeip/workflows/Unit%20/%20Interation%20Tests/badge.svg)](https://github.com/project-chip/connectedhomeip/actions/workflows/unit_integration_test.yaml) +[![Unit / Integration Tests](https://github.com/project-chip/connectedhomeip/workflows/Unit%20/%20Integration%20Tests/badge.svg)](https://github.com/project-chip/connectedhomeip/actions/workflows/unit_integration_test.yaml) [![Cirque](https://github.com/project-chip/connectedhomeip/workflows/Cirque/badge.svg)](https://github.com/project-chip/connectedhomeip/actions/workflows/cirque.yaml) [![QEMU](https://github.com/project-chip/connectedhomeip/workflows/QEMU/badge.svg)](https://github.com/project-chip/connectedhomeip/actions/workflows/qemu.yaml) diff --git a/build/chip/chip_codegen.cmake b/build/chip/chip_codegen.cmake index 17e3844fb45ba9..885d189f43f6de 100644 --- a/build/chip/chip_codegen.cmake +++ b/build/chip/chip_codegen.cmake @@ -31,40 +31,71 @@ function(chip_codegen TARGET_NAME) ${ARGN} ) - set(GEN_FOLDER "${CMAKE_BINARY_DIR}/gen/${TARGET_NAME}/${ARG_GENERATOR}") + set(CHIP_CODEGEN_PREGEN_DIR "" CACHE PATH "Pre-generated directory to use instead of compile-time code generation.") - string(REPLACE ";" "\n" OUTPUT_AS_NEWLINES "${ARG_OUTPUTS}") + if ("${CHIP_CODEGEN_PREGEN_DIR}" STREQUAL "") + set(GEN_FOLDER "${CMAKE_BINARY_DIR}/gen/${TARGET_NAME}/${ARG_GENERATOR}") - file(MAKE_DIRECTORY "${GEN_FOLDER}") - file(GENERATE - OUTPUT "${GEN_FOLDER}/expected.outputs" - CONTENT "${OUTPUT_AS_NEWLINES}" - ) + string(REPLACE ";" "\n" OUTPUT_AS_NEWLINES "${ARG_OUTPUTS}") + file(MAKE_DIRECTORY "${GEN_FOLDER}") + file(GENERATE + OUTPUT "${GEN_FOLDER}/expected.outputs" + CONTENT "${OUTPUT_AS_NEWLINES}" + ) + + + set(OUT_NAMES) + foreach(NAME IN LISTS ARG_OUTPUTS) + list(APPEND OUT_NAMES "${GEN_FOLDER}/${NAME}") + endforeach() + + # Python is expected to be in the path + # + # find_package(Python3 REQUIRED) + add_custom_command( + OUTPUT ${OUT_NAMES} + COMMAND "${CHIP_ROOT}/scripts/codegen.py" + ARGS "--generator" "${ARG_GENERATOR}" + "--output-dir" "${GEN_FOLDER}" + "--expected-outputs" "${GEN_FOLDER}/expected.outputs" + "${ARG_INPUT}" + DEPENDS + "${ARG_INPUT}" + VERBATIM + ) + + add_custom_target(${TARGET_NAME} DEPENDS "${OUT_NAMES}") + + # Forward outputs to the parent + set(${ARG_OUTPUT_FILES} "${OUT_NAMES}" PARENT_SCOPE) + set(${ARG_OUTPUT_PATH} "${GEN_FOLDER}" PARENT_SCOPE) + else() + # Gets a path such as: + # examples/lock-app/lock-common/lock-app.matter + file(RELATIVE_PATH MATTER_FILE_PATH "${CHIP_ROOT}" ${ARG_INPUT}) + + # Removes the trailing file extension to get something like: + # examples/lock-app/lock-common/lock-app + string(REGEX REPLACE "\.matter$" "" CODEGEN_DIR_PATH "${MATTER_FILE_PATH}") + + + # Build the final location within the pregen directory + set(GEN_FOLDER "${CHIP_CODEGEN_PREGEN_DIR}/${CODEGEN_DIR_PATH}/codegen/${ARG_GENERATOR}") + + # TODO: build a fake target of ${TARGET_NAME} + + # Here we have ${CHIP_CODEGEN_PREGEN_DIR} + set(OUT_NAMES) + foreach(NAME IN LISTS ARG_OUTPUTS) + list(APPEND OUT_NAMES "${GEN_FOLDER}/${NAME}") + endforeach() - set(OUT_NAMES) - foreach(NAME IN LISTS ARG_OUTPUTS) - list(APPEND OUT_NAMES "${GEN_FOLDER}/${NAME}") - endforeach() - - # Python is expected to be in the path - # - # find_package(Python3 REQUIRED) - add_custom_command( - OUTPUT ${OUT_NAMES} - COMMAND "${CHIP_ROOT}/scripts/codegen.py" - ARGS "--generator" "${ARG_GENERATOR}" - "--output-dir" "${GEN_FOLDER}" - "--expected-outputs" "${GEN_FOLDER}/expected.outputs" - "${ARG_INPUT}" - DEPENDS - "${ARG_INPUT}" - VERBATIM - ) - add_custom_target(${TARGET_NAME} DEPENDS "${OUT_NAMES}") + set(${ARG_OUTPUT_FILES} "${OUT_NAMES}" PARENT_SCOPE) + set(${ARG_OUTPUT_PATH} "${GEN_FOLDER}" PARENT_SCOPE) - # Forward outputs to the parent - set(${ARG_OUTPUT_FILES} "${OUT_NAMES}" PARENT_SCOPE) - set(${ARG_OUTPUT_PATH} "${GEN_FOLDER}" PARENT_SCOPE) + # allow adding dependencies to a phony target since no codegen is done + add_custom_target(${TARGET_NAME}) + endif() endfunction() diff --git a/build/chip/chip_codegen.gni b/build/chip/chip_codegen.gni index bab79934bd37f5..533cd02b27ea76 100644 --- a/build/chip/chip_codegen.gni +++ b/build/chip/chip_codegen.gni @@ -17,6 +17,81 @@ import("//build_overrides/chip.gni") import("//build_overrides/pigweed.gni") import("$dir_pw_build/python.gni") +import("${chip_root}/scripts/idl/files.gni") + +declare_args() { + # Location where code has been pre-generated + chip_code_pre_generated_directory = "" +} + +# Code generation that will happen at build time. +# +# +template("_chip_build_time_codegen") { + _name = target_name + _generator = invoker.generator + + config("${_name}_config") { + include_dirs = [ target_gen_dir ] + } + + pw_python_action("${_name}_codegen") { + script = "${chip_root}/scripts/codegen.py" + + # TODO: this seems to touch internals. Is this ok? speeds up builds! + _pw_internal_run_in_venv = false + + _idl_file = invoker.input + _expected_outputs = "${target_gen_dir}/${_name}.expected.outputs" + + write_file(_expected_outputs, invoker.outputs, "list lines") + + args = [ + "--generator", + _generator, + "--output-dir", + rebase_path(target_gen_dir, root_build_dir), + "--expected-outputs", + rebase_path(_expected_outputs, root_build_dir), + rebase_path(_idl_file, root_build_dir), + ] + + inputs = [ + _idl_file, + _expected_outputs, + ] + + # ensure any change in codegen files will result in a rebuild + inputs += matter_idl_generator_files + + sources = [ _idl_file ] + + outputs = [] + foreach(name, invoker.outputs) { + outputs += [ "${target_gen_dir}/${name}" ] + } + } + + source_set(_name) { + sources = [] + foreach(name, invoker.outputs) { + sources += [ "${target_gen_dir}/${name}" ] + } + + public_configs = [ ":${_name}_config" ] + + if (defined(invoker.public_configs)) { + public_configs += invoker.public_configs + } + + forward_variables_from(invoker, [ "deps" ]) + + if (!defined(deps)) { + deps = [] + } + deps += [ ":${_name}_codegen" ] + } +} # Defines a target that runs code generation based on # scripts/codegen.py @@ -32,13 +107,29 @@ import("$dir_pw_build/python.gni") # Explicit names of the expected outputs. Enforced to validate that # expected outputs are generated when processing input files. # +# deps, public_configs +# Forwarded to the resulting source set +# +# Command line parameters: +# +# chip_code_pre_generated_directory: +# - If this is set, generation will NOT happen at compile time but rather +# the code generation is assumed to have already happened and reside in +# the given location. +# - The TOP LEVEL directory is assumed to be given. Actual location for +# individual generators is expected to be of the form +# // +# # NOTE: content of "outputs" is verified to match the output of codegen.py # exactly. It is not inferred on purpose, to make build-rules explicit -# and verifiable (even though codege.py can at runtime report its outputs) +# and verifiable (even though codegen.py can at runtime report its outputs) # # To find the list of generated files, you can run codegen.py with the # "--name-only" argument # +# NOTE: +# the result of the target_name WILL BE a `source_set`. Treat it as such. +# # Example usage: # # chip_codegen("java-jni-generate") { @@ -53,43 +144,46 @@ import("$dir_pw_build/python.gni") # } # template("chip_codegen") { - _name = target_name - _generator = invoker.generator - - config("${_name}_config") { - include_dirs = [ target_gen_dir ] - } + if (chip_code_pre_generated_directory == "") { + _chip_build_time_codegen(target_name) { + forward_variables_from(invoker, + [ + "deps", + "generator", + "input", + "outputs", + "public_configs", + ]) + } + } else { + _name = target_name - pw_python_action(_name) { - script = "${chip_root}/scripts/codegen.py" + # This contstructs a path like: + # FROM all-clusters-app.matter (inside examples/all-clusters-app/all-clusters-common/) + # USING "cpp-app" for generator: + # => ${pregen_dir}/examples/all-clusters-app/all-clusters-common/all-clusters-app/codegen/cpp-app + _generation_dir = + chip_code_pre_generated_directory + "/" + + string_replace(rebase_path(invoker.input, chip_root), ".matter", "") + + "/codegen/" + invoker.generator - _idl_file = invoker.input - _expected_outputs = "${target_gen_dir}/${_name}.expected.outputs" - - write_file(_expected_outputs, invoker.outputs, "list lines") + config("${_name}_config") { + include_dirs = [ "${_generation_dir}" ] + } - args = [ - "--generator", - _generator, - "--output-dir", - rebase_path(target_gen_dir, root_build_dir), - "--expected-outputs", - rebase_path(_expected_outputs, root_build_dir), - rebase_path(_idl_file, root_build_dir), - ] + source_set(_name) { + public_configs = [ ":${_name}_config" ] - deps = [ "${chip_root}/scripts/idl" ] - public_configs = [ ":${_name}_config" ] + if (defined(invoker.public_configs)) { + public_configs += invoker.public_configs + } - inputs = [ - _idl_file, - _expected_outputs, - ] - sources = [ _idl_file ] + forward_variables_from(invoker, [ "deps" ]) - outputs = [] - foreach(name, invoker.outputs) { - outputs += [ "${target_gen_dir}/${name}" ] + sources = [] + foreach(name, invoker.outputs) { + sources += [ "${_generation_dir}/${name}" ] + } } } } diff --git a/build/chip/chip_test_suite.gni b/build/chip/chip_test_suite.gni index caaf06f5028f2b..336450ca459487 100644 --- a/build/chip/chip_test_suite.gni +++ b/build/chip/chip_test_suite.gni @@ -94,15 +94,9 @@ template("chip_test_suite") { public_deps = [] } - # TODO: figure out a way to auto-define dependency on stdio logging. - # This dep is required since libSupportLayer now does not include - # a default implementation. - # - # Tests such as TestInetEndPoint need to exercise the system event - # loop however they do not seem to include a logging binding so this - # is forcefully added here. if (current_os != "zephyr" && current_os != "mbed") { - public_deps += [ "${chip_root}/src/platform/logging:stdio" ] + # Depend on stdio logging, and have it take precedence over the default platform backend + public_deps += [ "${chip_root}/src/platform/logging:force_stdio" ] } } diff --git a/build/chip/tools.gni b/build/chip/tools.gni index 374a69b26fdad9..efb25d3fa4a43a 100644 --- a/build/chip/tools.gni +++ b/build/chip/tools.gni @@ -23,5 +23,5 @@ declare_args() { (chip_crypto == "" && (current_os != "android" && current_os != "freertos" && current_os != "zephyr" && current_os != "mbed" && - current_os != "webos")) + current_os != "webos" && current_os != "cmsis-rtos")) } diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn index 96cdcd00256e3f..f00770a3c6e8c6 100644 --- a/build/config/compiler/BUILD.gn +++ b/build/config/compiler/BUILD.gn @@ -225,7 +225,8 @@ config("warnings_common") { } if (current_os != "mac" && current_os != "ios" && current_os != "linux" && - current_os != "win" && current_os != "tizen" && current_os != "webos") { + current_os != "win" && current_os != "tizen" && current_os != "webos" && + current_os != "cmsis-rtos") { cflags += [ "-Wstack-usage=8192" ] } } @@ -384,7 +385,6 @@ config("sanitize_address") { config("sanitize_thread") { cflags = [ "-fsanitize=thread" ] - ldflags = cflags } @@ -402,11 +402,16 @@ config("sanitize_undefined_behavior") { "-fvisibility=hidden", "-fsanitize=undefined", "-fsanitize=float-divide-by-zero", - "-fsanitize=unsigned-integer-overflow", - "-fsanitize=implicit-conversion", - "-fsanitize=nullability", - "-fno-sanitize=vptr,function", ] + if (is_clang) { + cflags += [ + "-fsanitize=unsigned-integer-overflow", + "-fsanitize=implicit-conversion", + "-fsanitize=nullability", + "-fno-sanitize=vptr,function", + ] + } + ldflags = cflags } diff --git a/build/config/compiler/compiler.gni b/build/config/compiler/compiler.gni index 842500c73f5c0c..d97ea02cc4b674 100644 --- a/build/config/compiler/compiler.gni +++ b/build/config/compiler/compiler.gni @@ -20,8 +20,8 @@ declare_args() { optimize_for_size = true # Optimize debug builds with -Og. - optimize_debug = - current_os == "freertos" || current_os == "zephyr" || current_os == "mbed" + optimize_debug = current_os == "freertos" || current_os == "zephyr" || + current_os == "mbed" || current_os == "cmsis-rtos" # Optimization level for debug. Only has an effect if optimize_debug is true. optimize_debug_level = "g" diff --git a/build_overrides/bouffalolab_iot_sdk.gni b/build_overrides/bouffalolab_iot_sdk.gni index 165bf5944f16d8..77ab3440927271 100644 --- a/build_overrides/bouffalolab_iot_sdk.gni +++ b/build_overrides/bouffalolab_iot_sdk.gni @@ -19,6 +19,5 @@ declare_args() { # Root directory for bl702 SDK build files. bl702_sdk_build_root = "//third_party/bouffalolab/bl702" - # Root directory of toolchain of Bouffalolab chips - bouffalolab_toolchain = "//third_party/bouffalolab/repo/toolchain/riscv" + bouffalolab_sdk_root = "/opt/bouffalolab_sdk" } diff --git a/config/esp32/components/chip/CMakeLists.txt b/config/esp32/components/chip/CMakeLists.txt index 44f923808e17e6..d7cb69a6a8fa34 100644 --- a/config/esp32/components/chip/CMakeLists.txt +++ b/config/esp32/components/chip/CMakeLists.txt @@ -101,6 +101,10 @@ if(CONFIG_DISABLE_IPV4) chip_gn_arg_append("chip_inet_config_enable_ipv4" "false") endif() +if(CHIP_CODEGEN_PREGEN_DIR) + chip_gn_arg_append("chip_code_pre_generated_directory" "\"${CHIP_CODEGEN_PREGEN_DIR}\"") +endif() + if(CONFIG_ENABLE_PW_RPC) string(APPEND chip_gn_args "import(\"//build_overrides/pigweed.gni\")\n") chip_gn_arg_append("remove_default_configs" "[\"//third_party/connectedhomeip/third_party/pigweed/repo/pw_build:toolchain_cpp_standard\"]") diff --git a/config/nrfconnect/chip-gn/args.gni b/config/nrfconnect/chip-gn/args.gni index 0ac19884ce2e5e..0963be64b3b289 100644 --- a/config/nrfconnect/chip-gn/args.gni +++ b/config/nrfconnect/chip-gn/args.gni @@ -14,6 +14,8 @@ import("//build_overrides/chip.gni") +import("${chip_root}/src/crypto/crypto.gni") + chip_device_platform = "nrfconnect" chip_build_tests = false @@ -22,6 +24,9 @@ chip_project_config_include = "" chip_system_project_config_include = "" chip_ble_project_config_include = "" +chip_crypto = "mbedtls" +chip_external_mbedtls = true + custom_toolchain = "${chip_root}/config/nrfconnect/chip-gn/toolchain:zephyr" pw_build_PIP_CONSTRAINTS = [ "${chip_root}/scripts/constraints.txt" ] diff --git a/config/nrfconnect/chip-module/CMakeLists.txt b/config/nrfconnect/chip-module/CMakeLists.txt index 68e0e31d19abb5..cef54d4bd014f6 100644 --- a/config/nrfconnect/chip-module/CMakeLists.txt +++ b/config/nrfconnect/chip-module/CMakeLists.txt @@ -87,7 +87,8 @@ if (NOT CHIP_ROOT) get_filename_component(CHIP_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/../../.. REALPATH) endif() -set(GN_ROOT_TARGET ${CHIP_ROOT}/config/nrfconnect/chip-gn) +set(CHIP_LIB_DIR ${CMAKE_CURRENT_BINARY_DIR}/lib) +set(CHIP_GN_ROOT_TARGET ${CHIP_ROOT}/config/nrfconnect/chip-gn) # Prepare compiler flags @@ -105,16 +106,16 @@ if (CONFIG_POSIX_API) endif() if (CONFIG_NORDIC_SECURITY_BACKEND) - zephyr_include_directories_raw($) - zephyr_include_directories_raw($) + zephyr_include_directories($) + zephyr_include_directories($) if(TARGET platform_cc3xx) - zephyr_include_directories_raw($) + zephyr_include_directories($) endif() list(APPEND CHIP_CFLAGS -DMBEDTLS_CONFIG_FILE=) endif() if (CONFIG_NRF_802154_RADIO_DRIVER) - zephyr_include_directories_raw($) + zephyr_include_directories($) endif() zephyr_get_compile_flags(CHIP_CFLAGS_C C) @@ -131,6 +132,15 @@ if (NOT CHIP_LIBRARIES) set(CHIP_LIBRARIES -lCHIP) endif() +if (CONFIG_CHIP_EXAMPLE_DEVICE_INFO_PROVIDER) + list(APPEND CHIP_LIBRARIES -lMatterDeviceInfoProviderExample) +endif() + +list(TRANSFORM CHIP_LIBRARIES REPLACE + "-l(.*)" + "${CHIP_LIB_DIR}/lib\\1.a" +) + # Set up CHIP project configuration file if (CONFIG_CHIP_PROJECT_CONFIG) @@ -167,30 +177,20 @@ get_property(CHIP_COMPILER_LAUNCHER GLOBAL PROPERTY RULE_LAUNCH_COMPILE) # Find required programs -find_program(GN_EXECUTABLE gn) -if (${GN_EXECUTABLE} STREQUAL GN_EXECUTABLE-NOTFOUND) - message(FATAL_ERROR "The 'gn' command was not found. Make sure you have GN installed.") -else() - # Parse the 'gn --version' output to find the installed version. - set(MIN_GN_VERSION 1851) - execute_process( - COMMAND - ${GN_EXECUTABLE} --version - OUTPUT_VARIABLE gn_version_output - ERROR_VARIABLE gn_error_output - RESULT_VARIABLE gn_status - ) +find_package(Python3 REQUIRED) +find_program(GN_EXECUTABLE gn REQUIRED) - if(${gn_status} EQUAL 0) - if(gn_version_output VERSION_LESS ${MIN_GN_VERSION}) - message(FATAL_ERROR "Found unsuitable version of 'gn'. Required is at least ${MIN_GN_VERSION}") - endif() - else() - message(FATAL_ERROR "Could NOT find working gn: Found gn (${GN_EXECUTABLE}), but failed to load with:\n ${gn_error_output}") - endif() -endif() +# Parse the 'gn --version' output to find the installed version. -find_package(Python3 REQUIRED) +set(MIN_GN_VERSION 1851) +execute_process( + COMMAND ${GN_EXECUTABLE} --version + OUTPUT_VARIABLE GN_VERSION + COMMAND_ERROR_IS_FATAL ANY +) +if (GN_VERSION VERSION_LESS MIN_GN_VERSION) + message(FATAL_ERROR "Found unsupported version of gn: ${MIN_GN_VERSION}+ is required") +endif() # ============================================================================== # Generate configuration for CHIP GN build system @@ -217,20 +217,20 @@ chip_gn_arg_bool ("chip_build_libshell" CONFIG_CHIP_LIB_SHEL chip_gn_arg_bool ("chip_error_logging" CONFIG_MATTER_LOG_LEVEL GREATER_EQUAL 1) chip_gn_arg_bool ("chip_progress_logging" CONFIG_MATTER_LOG_LEVEL GREATER_EQUAL 3) chip_gn_arg_bool ("chip_detail_logging" CONFIG_MATTER_LOG_LEVEL GREATER_EQUAL 4) -chip_gn_arg_bool ("chip_automation_logging" "false") +chip_gn_arg_bool ("chip_automation_logging" FALSE) chip_gn_arg_bool ("chip_malloc_sys_heap" CONFIG_CHIP_MALLOC_SYS_HEAP) chip_gn_arg_bool ("chip_enable_wifi" CONFIG_WIFI_NRF700X) if (CONFIG_CHIP_FACTORY_DATA) - chip_gn_arg_bool ("chip_use_transitional_commissionable_data_provider" "false") - chip_gn_arg_bool ("chip_enable_factory_data" "true") + chip_gn_arg_bool("chip_use_transitional_commissionable_data_provider" FALSE) + chip_gn_arg_bool("chip_enable_factory_data" TRUE) elseif (CONFIG_CHIP_FACTORY_DATA_CUSTOM_BACKEND) - chip_gn_arg_bool ("chip_use_transitional_commissionable_data_provider" "false") + chip_gn_arg_bool("chip_use_transitional_commissionable_data_provider" FALSE) endif() if (CONFIG_CHIP_ROTATING_DEVICE_ID) - chip_gn_arg_bool("chip_enable_rotating_device_id" "true") - chip_gn_arg_bool("chip_enable_additional_data_advertising" "true") + chip_gn_arg_bool("chip_enable_rotating_device_id" TRUE) + chip_gn_arg_bool("chip_enable_additional_data_advertising" TRUE) endif() if (CONFIG_NET_L2_OPENTHREAD) @@ -272,8 +272,7 @@ if (CONFIG_CHIP_PW_RPC) endif() if (CONFIG_CHIP_EXAMPLE_DEVICE_INFO_PROVIDER) - chip_gn_arg_bool("chip_build_example_providers" "true") - list(APPEND CHIP_LIBRARIES -lMatterDeviceInfoProviderExample) + chip_gn_arg_bool("chip_build_example_providers" TRUE) endif() file(GENERATE OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/args.tmp" CONTENT ${CHIP_GN_ARGS}) @@ -291,8 +290,8 @@ ExternalProject_Add( @args.tmp > args.gn && ${GN_EXECUTABLE} --root=${CHIP_ROOT} - --root-target=${GN_ROOT_TARGET} - --dotfile=${GN_ROOT_TARGET}/.gn + --root-target=${CHIP_GN_ROOT_TARGET} + --dotfile=${CHIP_GN_ROOT_TARGET}/.gn --script-executable=${Python3_EXECUTABLE} --export-compile-commands gen --check --fail-on-unused-args . && @@ -300,7 +299,6 @@ ExternalProject_Add( INSTALL_COMMAND "" BUILD_BYPRODUCTS ${CHIP_LIBRARIES} BUILD_ALWAYS TRUE - USES_TERMINAL_CONFIGURE TRUE USES_TERMINAL_BUILD TRUE ) add_dependencies(chip-gn kernel) @@ -314,21 +312,24 @@ target_compile_definitions(chip INTERFACE CHIP_HAVE_CONFIG_H) target_include_directories(chip INTERFACE ${CHIP_ROOT}/src ${CHIP_ROOT}/src/include - ${CHIP_ROOT}/src/lib ${CHIP_ROOT}/third_party/nlassert/repo/include ${CHIP_ROOT}/third_party/nlio/repo/include ${CHIP_ROOT}/zzz_generated/app-common ${CMAKE_CURRENT_BINARY_DIR}/gen/include ) -target_link_directories(chip INTERFACE ${CMAKE_CURRENT_BINARY_DIR}/lib) -if (CONFIG_CHIP_LIB_SHELL) - target_link_options(chip INTERFACE -Wl,--whole-archive -lCHIPShell -Wl,--no-whole-archive) -endif() if (CONFIG_CHIP_EXAMPLE_DEVICE_INFO_PROVIDER) target_include_directories(chip INTERFACE ${CHIP_ROOT}/examples/providers) endif() +if (CONFIG_CHIP_LIB_SHELL) + target_link_options(chip INTERFACE -Wl,--whole-archive ${CHIP_LIB_DIR}/libCHIPShell.a -Wl,--no-whole-archive) +endif() + +if (CONFIG_CHIP_BUILD_TESTS) + target_link_options(chip INTERFACE -Wl,--whole-archive ${CHIP_LIB_DIR}/libCHIP_tests.a -Wl,--no-whole-archive) +endif() + if (CONFIG_CHIP_MALLOC_SYS_HEAP_OVERRIDE) target_link_options(chip INTERFACE -Wl,--wrap=malloc @@ -351,20 +352,17 @@ add_dependencies(chip chip-gn) # ============================================================================== if (CONFIG_CHIP_OTA_IMAGE_BUILD) - chip_ota_image(chip-ota-image INPUT_FILES ${PROJECT_BINARY_DIR}/dfu_multi_image.bin OUTPUT_FILE ${PROJECT_BINARY_DIR}/${CONFIG_CHIP_OTA_IMAGE_FILE_NAME} ) - - add_dependencies(chip-ota-image dfu_multi_image_pkg) endif() # ============================================================================== # Define 'factory_data' target for generating a factory data partition # ============================================================================== -if(CONFIG_CHIP_FACTORY_DATA_BUILD) +if (CONFIG_CHIP_FACTORY_DATA_BUILD) nrfconnect_generate_factory_data() endif() diff --git a/config/openiotsdk/CMakeLists.txt b/config/openiotsdk/CMakeLists.txt new file mode 100644 index 00000000000000..414f591095f1dc --- /dev/null +++ b/config/openiotsdk/CMakeLists.txt @@ -0,0 +1,272 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# +# @file +# CMake sub-project defining 'chip' target which represents CHIP library +# and other optional libraries like unit tests, built with 'open-iot-sdk' +# platform. +# Since CHIP doesn't provide native CMake support, ExternalProject +# module is used to build the required artifacts with GN meta-build +# system. +# + +include(ExternalProject) +include(util.cmake) + +# ============================================================================== +# Declare configuration variables and define constants +# ============================================================================== +# C/C++ compiler flags passed to CHIP build system +list(APPEND CHIP_CFLAGS \"-Wno-unused-function\") + +# C compiler flags passed to CHIP build system +list(APPEND CHIP_CFLAGS_C ${CMAKE_C_FLAGS}) + +# C++ compiler flags passed to CHIP build system +list(APPEND CHIP_CFLAGS_CC ${CMAKE_CXX_FLAGS}) + +# GN meta-build system arguments in the form of 'key1 = value1\nkey2 = value2...' string +string(APPEND CHIP_GN_ARGS) + +# ============================================================================== +# Helper macros +# ============================================================================== +macro(chip_gn_arg_import FILE) + string(APPEND CHIP_GN_ARGS "--module\n${FILE}\n") +endmacro() + +macro(chip_gn_arg_string ARG STRING) + string(APPEND CHIP_GN_ARGS "--arg-string\n${ARG}\n${STRING}\n") +endmacro() + +macro(chip_gn_arg_bool ARG) + if (${ARGN}) + string(APPEND CHIP_GN_ARGS "--arg\n${ARG}\ntrue\n") + else() + string(APPEND CHIP_GN_ARGS "--arg\n${ARG}\nfalse\n") + endif() +endmacro() + +macro(chip_gn_arg_cflags ARG CFLAGS) + string(APPEND CHIP_GN_ARGS "--arg-cflags\n${ARG}\n${CFLAGS}\n") +endmacro() + +macro(chip_gn_arg_cflags_lang ARG CFLAGS) + string(APPEND CHIP_GN_ARGS "--arg-cflags-lang\n${ARG}\n${CFLAGS}\n") +endmacro() + +macro(chip_gn_arg ARG VALUE) + string(APPEND CHIP_GN_ARGS "--arg\n${ARG}\n${VALUE}\n") +endmacro() + +# Select gnu++ standard based on project configuration +macro(get_gnu_cpp_standard VAR) + if (CONFIG_STD_CPP11) + list(APPEND ${VAR} -std=gnu++11) + elseif (CONFIG_STD_CPP14) + list(APPEND ${VAR} -std=gnu++14) + elseif (CONFIG_STD_CPP17) + list(APPEND ${VAR} -std=gnu++17) + elseif (CONFIG_STD_CPP2A) + list(APPEND ${VAR} -std=gnu++20) + endif() +endmacro() + +# ============================================================================== +# Prepare CHIP configuration based on the project configuration +# ============================================================================== +# Set paths +if (NOT CHIP_ROOT) + get_filename_component(CHIP_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/../.. REALPATH) +endif() + +set(GN_ROOT_TARGET ${CHIP_ROOT}/config/openiotsdk/chip-gn) + +# Prepare compiler flags +# All Open IoT SDK targets +list(APPEND ALL_SDK_TARGETS) + +foreach(source_dir ${SDK_SOURCES_BINARY_DIRS}) + get_all_cmake_targets(SDK_TARGETS ${source_dir}) + list(APPEND ALL_SDK_TARGETS ${SDK_TARGETS}) +endforeach() + +# Exclude unnecessary targets +list(FILTER ALL_SDK_TARGETS EXCLUDE REGEX "^.*linker.*|.*example.*|.*apps.*|.*doc.*|dist|lib$") + +foreach(target ${ALL_SDK_TARGETS}) + get_target_common_compile_flags(SDK_TARGET_CFLAGS ${target}) + list(APPEND CHIP_CFLAGS ${SDK_TARGET_CFLAGS}) +endforeach() + +# Remove duplicated flags +list(REMOVE_DUPLICATES CHIP_CFLAGS) + +get_gnu_cpp_standard(CHIP_CFLAGS_CC) + +# CFLAGS are put in random order, sort them before converting them to a string +list(SORT CHIP_CFLAGS) +list(SORT CHIP_CFLAGS_C) +list(SORT CHIP_CFLAGS_CC) + +set(SEPARATOR ",") +convert_list_of_flags_to_string_of_flags(CHIP_CFLAGS CHIP_CFLAGS ${SEPARATOR}) +set(SEPARATOR " ") +convert_list_of_flags_to_string_of_flags(CHIP_CFLAGS_C CHIP_CFLAGS_C ${SEPARATOR}) +convert_list_of_flags_to_string_of_flags(CHIP_CFLAGS_CC CHIP_CFLAGS_CC ${SEPARATOR}) + +# Prepare CHIP libraries that the application should be linked with +set(CHIP_LIBRARIES "${CMAKE_CURRENT_BINARY_DIR}/lib/libCHIP.a") + +if (CONFIG_CHIP_LIB_SHELL) + list(APPEND CHIP_LIBRARIES "${CMAKE_CURRENT_BINARY_DIR}/lib/libCHIPShell.a") +endif() + +# Set up CHIP project configuration file + +if (CONFIG_CHIP_PROJECT_CONFIG) + get_filename_component(CHIP_PROJECT_CONFIG + ${CONFIG_CHIP_PROJECT_CONFIG} + REALPATH + BASE_DIR ${CMAKE_SOURCE_DIR} + ) + set(CHIP_PROJECT_CONFIG "<${CHIP_PROJECT_CONFIG}>") +else() + set(CHIP_PROJECT_CONFIG "") +endif() + +if (${CMAKE_BUILD_TYPE} STREQUAL "Debug") + set(CONFIG_DEBUG YES) +endif() + +# Find required programs + +find_program(GN_EXECUTABLE gn) +if (${GN_EXECUTABLE} STREQUAL GN_EXECUTABLE-NOTFOUND) + message(FATAL_ERROR "The 'gn' command was not found. Make sure you have GN installed.") +else() + # Parse the 'gn --version' output to find the installed version. + set(MIN_GN_VERSION 1851) + execute_process( + COMMAND + ${GN_EXECUTABLE} --version + OUTPUT_VARIABLE gn_version_output + ERROR_VARIABLE gn_error_output + RESULT_VARIABLE gn_status + ) + + if(${gn_status} EQUAL 0) + if(gn_version_output VERSION_LESS ${MIN_GN_VERSION}) + message(FATAL_ERROR "Found unsuitable version of 'gn'. Required is at least ${MIN_GN_VERSION}") + endif() + else() + message(FATAL_ERROR "Could NOT find working gn: Found gn (${GN_EXECUTABLE}), but failed to load with:\n ${gn_error_output}") + endif() +endif() + +find_package(Python3 REQUIRED) + +# ============================================================================== +# Generate configuration for CHIP GN build system +# ============================================================================== +chip_gn_arg_string("target_cpu" "${CMAKE_SYSTEM_PROCESSOR}") +chip_gn_arg_cflags("target_cflags" ${CHIP_CFLAGS}) +chip_gn_arg_cflags_lang("target_cflags_c" ${CHIP_CFLAGS_C}) +chip_gn_arg_cflags_lang("target_cflags_cc" ${CHIP_CFLAGS_CC}) +chip_gn_arg_string("openiotsdk_ar" ${CMAKE_AR}) +chip_gn_arg_string("openiotsdk_cc" ${CMAKE_C_COMPILER}) +chip_gn_arg_string("openiotsdk_cxx" ${CMAKE_CXX_COMPILER}) +chip_gn_arg_string("chip_project_config_include" "${CHIP_PROJECT_CONFIG}") +chip_gn_arg_string("chip_system_project_config_include" "${CHIP_PROJECT_CONFIG}") +chip_gn_arg_bool ("is_debug" CONFIG_DEBUG) +chip_gn_arg_bool ("chip_build_tests" CONFIG_CHIP_LIB_TESTS) +chip_gn_arg_bool ("chip_monolithic_tests" CONFIG_CHIP_LIB_TESTS) +chip_gn_arg_bool ("chip_build_libshell" CONFIG_CHIP_LIB_SHELL) +chip_gn_arg_bool ("chip_detail_logging" CONFIG_CHIP_DETAIL_LOGGING) +chip_gn_arg_bool ("chip_progress_logging" CONFIG_CHIP_PROGRESS_LOGGING) +chip_gn_arg_bool ("chip_automation_logging" CONFIG_CHIP_AUTOMATION_LOGGING) +chip_gn_arg_bool ("chip_error_logging" CONFIG_CHIP_ERROR_LOGGING) +if (TARGET cmsis-rtos-api) + chip_gn_arg_string("target_os" "cmsis-rtos") +endif() +chip_gn_arg_string("optimize_debug_level" "s") + +file(GENERATE OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/args.tmp" CONTENT ${CHIP_GN_ARGS}) + +# ============================================================================== +# Define 'chip-gn' target that builds CHIP library(ies) with GN build system +# ============================================================================== +ExternalProject_Add( + chip-gn + PREFIX ${CMAKE_CURRENT_BINARY_DIR} + SOURCE_DIR ${CHIP_ROOT} + BINARY_DIR ${CMAKE_CURRENT_BINARY_DIR} + CONFIGURE_COMMAND ${Python3_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/make_gn_args.py + @args.tmp > args.gn && + ${GN_EXECUTABLE} + --root=${CHIP_ROOT} + --root-target=${GN_ROOT_TARGET} + --dotfile=${GN_ROOT_TARGET}/.gn + --script-executable=${Python3_EXECUTABLE} + gen --check --fail-on-unused-args ${CMAKE_CURRENT_BINARY_DIR} + BUILD_COMMAND ninja + INSTALL_COMMAND "" + BUILD_BYPRODUCTS ${CHIP_LIBRARIES} + BUILD_ALWAYS TRUE + USES_TERMINAL_CONFIGURE TRUE + USES_TERMINAL_BUILD TRUE +) + +# ============================================================================== +# Define 'openiotsdk-chip' target that exposes CHIP and Open IoT SDK +# headers & libraries to the application +# ============================================================================== +add_library(openiotsdk-chip INTERFACE) +target_compile_definitions(openiotsdk-chip INTERFACE CHIP_HAVE_CONFIG_H) +target_include_directories(openiotsdk-chip INTERFACE + ${CHIP_ROOT}/src + ${CHIP_ROOT}/src/include + ${CHIP_ROOT}/src/lib + ${CHIP_ROOT}/third_party/nlassert/repo/include + ${CHIP_ROOT}/third_party/nlio/repo/include + ${CHIP_ROOT}/zzz_generated/app-common + ${CMAKE_CURRENT_BINARY_DIR}/gen/include +) +target_link_directories(openiotsdk-chip INTERFACE ${CMAKE_CURRENT_BINARY_DIR}/lib) +target_link_libraries(openiotsdk-chip INTERFACE -Wl,--start-group ${CHIP_LIBRARIES} -Wl,--end-group) +target_link_libraries(openiotsdk-chip INTERFACE + $<$:mcu-driver-hal> + $<$:mcu-driver-bootstrap> + $<$:mdh-reference-platforms-for-arm> + $<$:mbedtls> + $<$:lwipcore> + $<$:iotsdk-ip-network-api> + $<$:iotsdk-tdbstore> + $<$:iotsdk-blockdevice> + $<$:$> +) +add_dependencies(openiotsdk-chip chip-gn) + +target_include_directories(openiotsdk-chip INTERFACE + ${CHIP_ROOT}/config/openiotsdk/mbedtls +) + +if (NOT ${CMAKE_BUILD_TYPE} STREQUAL "Debug") + target_compile_definitions(openiotsdk-chip INTERFACE + NDEBUG + ) +endif() diff --git a/config/openiotsdk/chip-gn/.gn b/config/openiotsdk/chip-gn/.gn new file mode 100644 index 00000000000000..4b9894b0f943ac --- /dev/null +++ b/config/openiotsdk/chip-gn/.gn @@ -0,0 +1,29 @@ +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/build.gni") +import("//build_overrides/chip.gni") + +# The location of the build configuration file. +buildconfig = "//build/config/BUILDCONFIG.gn" + +# CHIP uses angle bracket includes. +check_system_includes = true + +default_args = { + target_cpu = "arm" + target_os = "cmsis-rtos" + + import("${chip_root}/config/openiotsdk/chip-gn/args.gni") +} diff --git a/config/openiotsdk/chip-gn/BUILD.gn b/config/openiotsdk/chip-gn/BUILD.gn new file mode 100644 index 00000000000000..6e6fb51d404bb1 --- /dev/null +++ b/config/openiotsdk/chip-gn/BUILD.gn @@ -0,0 +1,28 @@ +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/chip.gni") +import("${chip_root}/build/chip/tests.gni") + +group("openiotsdk") { + deps = [ "${chip_root}/src/lib" ] + + if (chip_build_tests) { + deps += [ "${chip_root}/src:tests" ] + } +} + +group("default") { + deps = [ ":openiotsdk" ] +} diff --git a/config/openiotsdk/chip-gn/args.gni b/config/openiotsdk/chip-gn/args.gni new file mode 100644 index 00000000000000..87c43e7a343dc2 --- /dev/null +++ b/config/openiotsdk/chip-gn/args.gni @@ -0,0 +1,38 @@ +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/chip.gni") + +import("${chip_root}/src/crypto/crypto.gni") + +chip_device_platform = "openiotsdk" + +chip_build_tests = false + +chip_project_config_include = "" +chip_system_project_config_include = "" +chip_device_project_config_include = "" +chip_ble_project_config_include = "" + +chip_config_network_layer_ble = false +chip_system_config_use_lwip = true +lwip_platform = "external" +chip_system_config_use_sockets = false + +chip_crypto = "mbedtls" +chip_external_mbedtls = true + +custom_toolchain = "${chip_root}/config/openiotsdk/chip-gn/toolchain:openiotsdk" + +pw_build_PIP_CONSTRAINTS = [ "${chip_root}/scripts/constraints.txt" ] diff --git a/config/openiotsdk/chip-gn/toolchain/BUILD.gn b/config/openiotsdk/chip-gn/toolchain/BUILD.gn new file mode 100644 index 00000000000000..024a993aad6b43 --- /dev/null +++ b/config/openiotsdk/chip-gn/toolchain/BUILD.gn @@ -0,0 +1,32 @@ +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build/toolchain/arm_gcc/arm_toolchain.gni") + +declare_args() { + openiotsdk_ar = "" + openiotsdk_cc = "" + openiotsdk_cxx = "" +} + +gcc_toolchain("openiotsdk") { + ar = openiotsdk_ar + cc = openiotsdk_cc + cxx = openiotsdk_cxx + + toolchain_args = { + current_os = target_os + is_clang = false + } +} diff --git a/config/openiotsdk/cmake/chip.cmake b/config/openiotsdk/cmake/chip.cmake new file mode 100644 index 00000000000000..985d7f05bf74db --- /dev/null +++ b/config/openiotsdk/cmake/chip.cmake @@ -0,0 +1,33 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# +# @file +# CMake for CHIP library configuration +# + +# Default CHIP build configuration +set(CONFIG_CHIP_PROJECT_CONFIG "main/include/CHIPProjectConfig.h" CACHE STRING "") +set(CONFIG_CHIP_LIB_TESTS NO CACHE BOOL "") +set(CONFIG_CHIP_LIB_SHELL NO CACHE BOOL "") + +set(CONFIG_CHIP_DETAIL_LOGGING YES CACHE BOOL "Enable logging at detail level") +set(CONFIG_CHIP_PROGRESS_LOGGING YES CACHE BOOL "Enable logging at progress level") +set(CONFIG_CHIP_AUTOMATION_LOGGING YES CACHE BOOL "Enable logging at automation level") +set(CONFIG_CHIP_ERROR_LOGGING YES CACHE BOOL "Enable logging at error level") + +# Add CHIP sources +add_subdirectory(${OPEN_IOT_SDK_CONFIG} ./chip_build) diff --git a/config/openiotsdk/cmake/linker.cmake b/config/openiotsdk/cmake/linker.cmake new file mode 100644 index 00000000000000..032b95f54afd60 --- /dev/null +++ b/config/openiotsdk/cmake/linker.cmake @@ -0,0 +1,39 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# +# @file +# CMake linker configuration for target +# + +function(set_target_link target) + target_link_libraries(${target} + mdh-arm-corstone-300-startup + ) + + if (NOT LINKER_SCRIPT) + set(LINKER_SCRIPT ${OPEN_IOT_SDK_CONFIG}/ld/cs300_gcc.ld) + endif() + target_link_options(${APP_TARGET} PRIVATE -T ${LINKER_SCRIPT}) + set_target_properties(${APP_TARGET} PROPERTIES LINK_DEPENDS ${LINKER_SCRIPT}) + + target_link_options(${target} + PRIVATE + "-Wl,-Map=${APP_TARGET}.map" + ) +endfunction() + +set(CMAKE_EXECUTABLE_SUFFIX_CXX .elf) diff --git a/config/openiotsdk/cmake/sdk.cmake b/config/openiotsdk/cmake/sdk.cmake new file mode 100644 index 00000000000000..c87dad8412579d --- /dev/null +++ b/config/openiotsdk/cmake/sdk.cmake @@ -0,0 +1,144 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# +# @file +# CMake for Open IoT SDK configuration +# + +include(FetchContent) + +get_filename_component(OPEN_IOT_SDK_SOURCE ${CHIP_ROOT}/third_party/open-iot-sdk/sdk REALPATH) +get_filename_component(OPEN_IOT_SDK_STORAGE_SOURCE ${CHIP_ROOT}/third_party/open-iot-sdk/storage REALPATH) + +# List of binary directories to Open IoT SDK sources +list(APPEND SDK_SOURCES_BINARY_DIRS) + +# Open IoT SDK configuration +set(IOTSDK_MDH_ARM ON) +set(MDH_PLATFORM "ARM_AN552_MPS3") +set(MDH_ARM_BUILD_EXAMPLES OFF) +set(IOTSDK_CMSIS_RTOS_API ON) +set(IOTSDK_FREERTOS ON) +set(IOTSDK_MBEDTLS ON) +set(IOTSDK_LWIP ON) +set(FETCHCONTENT_QUIET OFF) +set(IOTSDK_EXAMPLES OFF) +set(BUILD_TESTING NO) +set(VARIANT "FVP") + +# Add Open IoT SDK source +add_subdirectory(${OPEN_IOT_SDK_SOURCE} ./sdk_build) +list(APPEND SDK_SOURCES_BINARY_DIRS ${CMAKE_CURRENT_BINARY_DIR}/sdk_build) + +# Add Open IoT SDK modules to path +list(APPEND CMAKE_MODULE_PATH ${open-iot-sdk_SOURCE_DIR}/cmake) + +# CMSIS-RTOS configuration +# CMSIS 5 require projects to provide configuration macros via RTE_Components.h +# and CMSIS_device_header. The macro CMSIS_device_header is not automatically set +# based on CMAKE_SYSTEM_PROCESSOR in the place where cmsis-core is first defined, +# because a project may want to provide its own device header. +if(TARGET cmsis-rtos-api) + target_include_directories(cmsis-rtos-api + PUBLIC + cmsis-config + ) +endif() + +if(TARGET cmsis-core) + target_compile_definitions(cmsis-core + INTERFACE + $<$:CMSIS_device_header="ARMCM55.h"> + ) +endif() + +# LwIP configuration +if(TARGET lwip-cmsis-port) + # lwipcore requires the config defined by lwip-cmsis-port + target_link_libraries(lwipcore + PUBLIC + lwip-cmsis-port + ) + + # provide method to use for tracing by the lwip port (optional) + target_compile_definitions(lwipopts + INTERFACE + DEBUG_PRINT=printf + ) + + if(TARGET lwip-cmsis-port) + # Link the emac factory to LwIP port + target_link_libraries(lwip-cmsis-port PUBLIC iotsdk-emac-factory) + endif() +endif() + +# MDH configuration +if(TARGET ethernet-lan91c111) + target_compile_definitions(ethernet-lan91c111 + INTERFACE + LAN91C111_RFS_MULTICAST_SUPPORT + ) +endif() + +# Mbedtls config +if(TARGET mbedtls-config) + target_include_directories(mbedtls-config + INTERFACE + ${OPEN_IOT_SDK_CONFIG}/mbedtls + ) + + target_sources(mbedtls-config + INTERFACE + ${OPEN_IOT_SDK_CONFIG}/mbedtls/platform_alt.cpp + ) + + target_compile_definitions(mbedtls-config + INTERFACE + MBEDTLS_CONFIG_FILE="mbedtls_config.h" + ) + + target_link_libraries(mbedtls-config + INTERFACE + mbedtls-threading-cmsis-rtos + ) +endif() + +# Declare RTOS interface target +add_library(cmsis-rtos-implementation INTERFACE) + +if(TARGET freertos-kernel) + target_link_libraries(cmsis-rtos-implementation + INTERFACE + freertos-cmsis-rtos + freertos-kernel-heap-3 + ) + target_include_directories(cmsis-rtos-implementation + INTERFACE + ${CMAKE_CURRENT_SOURCE_DIR}/freertos-config + ) +elseif(TARGET cmsis-rtx) + target_link_libraries(cmsis-rtos-implementation + INTERFACE + cmsis-rtx + cmsis-rtos-api + cmsis-rtx-freertos-alloc-wrapper + ) +endif() + +# Add Open IoT SDK storage source +add_subdirectory(${OPEN_IOT_SDK_STORAGE_SOURCE} ./sdk_storage_build) +list(APPEND SDK_SOURCES_BINARY_DIRS ${CMAKE_CURRENT_BINARY_DIR}/sdk_storage_build) diff --git a/config/openiotsdk/cmake/toolchain.cmake b/config/openiotsdk/cmake/toolchain.cmake new file mode 100644 index 00000000000000..ef0a8d1a3995a9 --- /dev/null +++ b/config/openiotsdk/cmake/toolchain.cmake @@ -0,0 +1,29 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# +# @file +# CMake for toolchain configuration +# + +include(FetchContent) + +FetchContent_Declare(iotsdk-toolchains + GIT_REPOSITORY https://git.gitlab.arm.com/iot/open-iot-sdk/toolchain.git + GIT_TAG v2022.09 + SOURCE_DIR ${CMAKE_BINARY_DIR}/toolchains +) +FetchContent_MakeAvailable(iotsdk-toolchains) diff --git a/config/openiotsdk/fvp/cs300.conf b/config/openiotsdk/fvp/cs300.conf new file mode 100644 index 00000000000000..5fc302cef68d2b --- /dev/null +++ b/config/openiotsdk/fvp/cs300.conf @@ -0,0 +1,25 @@ +## Turn off terminal1 terminal2 and termimal5, keep terminal0 open +mps3_board.telnetterminal1.quiet=1 +mps3_board.telnetterminal2.quiet=1 +mps3_board.telnetterminal5.quiet=1 + +## Suppress the telnet/xterm to be launched, so that model agent can talk to the port +mps3_board.telnetterminal0.start_telnet=0 + +## Turn the rate limite off, make FVP runs as fast as possiable +mps3_board.visualisation.rate_limit-enable=0 + +## Enable SMSC_91C111 controller +mps3_board.smsc_91c111.enabled=1 + +## Turn off GUI windows +mps3_board.visualisation.disable-visualisation=1 + +## Enable semihosting SVC traps +cpu0.semihosting-enable=1 + +## Disable Memory gating logic +mps3_board.DISABLE_GATING=1 + +## Set Clock Rate Multiplier +core_clk.mul=100000000 diff --git a/config/openiotsdk/ld/cs300_gcc.ld b/config/openiotsdk/ld/cs300_gcc.ld new file mode 100644 index 00000000000000..850e91200bc0d5 --- /dev/null +++ b/config/openiotsdk/ld/cs300_gcc.ld @@ -0,0 +1,161 @@ +; +MEMORY +{ + ITCM (rx) : ORIGIN = 0x00000000, LENGTH = 32K + /* Vector table is copied to RAM, so RAM address needs to be adjusted */ + DTCM (rwx) : ORIGIN = 0x20000000, LENGTH = 32K + DATA_SRAM (rwx) : ORIGIN = 0x21000000, LENGTH = 2M + QSPI_RAM (rx) : ORIGIN = 0x28000000, LENGTH = 8M +} + +__stack_size__ = 0x1000; + +/* Library configurations */ +GROUP(libgcc.a libc.a libm.a libnosys.a) + +SECTIONS +{ + .vectors : + { + KEEP(*(.vectors)) + __Vectors_End = .; + __Vectors_Size = __Vectors_End - __Vectors; + __end__ = .; + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + } > ITCM + + .text : + { + *(.text*) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > QSPI_RAM + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > QSPI_RAM + + __exidx_start = .; + + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > QSPI_RAM + + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * define etext2/data2_start/data2_end */ + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (DEFINED(__etext2) ? __etext2 : 0) + LONG (DEFINED(__data2_start__) ? __data2_start__ : 0) + LONG (DEFINED(__data2_start__) ? __data2_end__ - __data2_start__ : 0) + __copy_table_end__ = .; + } > QSPI_RAM + + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (DEFINED(__bss2_start__) ? __bss2_start__ : 0) + LONG (DEFINED(__bss2_start__) ? __bss2_end__ - __bss2_start__ : 0) + __zero_table_end__ = .; + } > QSPI_RAM + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(4); + /* All data end */ + __data_end__ = .; + } > DATA_SRAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > DATA_SRAM + + bss_size = __bss_end__ - __bss_start__; + + .stack : + { + . = ALIGN(8); + __StackLimit = .; + KEEP(*(.stack*)) + . += __stack_size__; + __StackTop = .; + } > DTCM + PROVIDE(__stack = __StackTop); + + .heap (COPY): + { + . = ALIGN(8); + __HeapBase = .; + __end__ = .; + end = __end__; + KEEP(*(.heap*)) + . += (ORIGIN(DATA_SRAM) + LENGTH(DATA_SRAM) - .); + __HeapLimit = .; + __heap_limit = .; + } > DATA_SRAM + + ASSERT(__StackTop <= (ORIGIN(DTCM) + LENGTH(DTCM)), "RAM region overflowed") +} diff --git a/config/openiotsdk/lwip/user_lwipopts.h b/config/openiotsdk/lwip/user_lwipopts.h new file mode 100644 index 00000000000000..8bf38b1129fc56 --- /dev/null +++ b/config/openiotsdk/lwip/user_lwipopts.h @@ -0,0 +1,51 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef USER_LWIPOPTS_H +#define USER_LWIPOPTS_H + +#define LWIP_STATS (0) +#define LWIP_IGMP (1) +#define LWIP_RAW (1) + +#define MEM_LIBC_MALLOC (1) +#define MEM_USE_POOLS (0) + +#ifdef LWIP_DEBUG + +// Debug Options +#define NETIF_DEBUG LWIP_DBG_ON +#define IP_DEBUG LWIP_DBG_ON +#define TCP_DEBUG LWIP_DBG_ON +#define UDP_DEBUG LWIP_DBG_ON +#define IP6_DEBUG LWIP_DBG_ON + +#define LWIP_DBG_TYPES_ON LWIP_DBG_ON +#define LWIP_DBG_MIN_LEVEL LWIP_DBG_LEVEL_ALL +#endif + +#ifndef LWIP_PLATFORM_DIAG +#define LWIP_PLATFORM_DIAG(x) \ + do \ + { \ + DEBUG_PRINT x; \ + DEBUG_PRINT("\r"); \ + } while (0) +#endif + +#endif /* USER_LWIPOPTS_H */ diff --git a/config/openiotsdk/make_gn_args.py b/config/openiotsdk/make_gn_args.py new file mode 100755 index 00000000000000..074645140deeb0 --- /dev/null +++ b/config/openiotsdk/make_gn_args.py @@ -0,0 +1,78 @@ +#!/usr/bin/env python3 + +# +# Copyright (c) 2022 Project CHIP Authors +# All rights reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +import argparse +import re +import sys + +GN_SPECIAL_CHARACTERS = r'(["$\\])' +GN_CFLAG_EXCLUDES = [ + '-fno-asynchronous-unwind-tables', + '-fno-common', + '-fno-defer-pop', + '-fno-reorder-functions', + '-ffunction-sections', + '-fdata-sections', + '-g*', + '-O*', + '-W*', +] + + +def escape_strings(gn_args): + return [[key, re.sub(GN_SPECIAL_CHARACTERS, r'\\\1', value)] for key, value in gn_args] + + +def write_gn_args(args): + if args.module: + sys.stdout.write('import("{}")\n'.format(args.module)) + + for key, value in args.arg: + sys.stdout.write('{} = {}\n'.format(key, value)) + + for key, value in args.arg_string: + sys.stdout.write('{} = "{}"\n'.format(key, value)) + + for key, value in args.arg_cflags: + # Remove empty include paths - fix generator expressions issue + filtered_value = [x for x in value.split(",") if x != '"-isystem"'] + sys.stdout.write('{} = [{}]\n'.format( + key, ",".join(filtered_value))) + + cflag_excludes = ', '.join(['"{}"'.format(exclude) + for exclude in GN_CFLAG_EXCLUDES]) + + for key, value in args.arg_cflags_lang: + sys.stdout.write('{} = filter_exclude(string_split("{}"), [{}])\n'.format( + key, value, cflag_excludes)) + + +def main(): + parser = argparse.ArgumentParser(fromfile_prefix_chars='@') + parser.add_argument('--module', action='store') + parser.add_argument('--arg', action='append', nargs=2, default=[]) + parser.add_argument('--arg-string', action='append', nargs=2, default=[]) + parser.add_argument('--arg-cflags', action='append', nargs=2, default=[]) + parser.add_argument('--arg-cflags-lang', action='append', nargs=2, default=[]) + args = parser.parse_args() + write_gn_args(args) + + +if __name__ == "__main__": + main() diff --git a/config/openiotsdk/mbedtls/mbedtls_config.h b/config/openiotsdk/mbedtls/mbedtls_config.h new file mode 100644 index 00000000000000..e12878adf14986 --- /dev/null +++ b/config/openiotsdk/mbedtls/mbedtls_config.h @@ -0,0 +1,3960 @@ +/** + * \file mbedtls_config.h + * + * \brief Configuration options (set of defines) + * + * This set of compile-time options may be used to enable + * or disable features selectively, and reduce the global + * memory footprint. + */ +/* + * Copyright The Mbed TLS Contributors + * SPDX-License-Identifier: Apache-2.0 + * + * 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. + */ + +#ifndef MBEDTLS_CONFIG_H +#define MBEDTLS_CONFIG_H + +#if defined(_MSC_VER) && !defined(_CRT_SECURE_NO_DEPRECATE) +#define _CRT_SECURE_NO_DEPRECATE 1 +#endif + +/** + * \name SECTION: System support + * + * This section sets system specific settings. + * \{ + */ + +/** + * \def MBEDTLS_HAVE_ASM + * + * The compiler has support for asm(). + * + * Requires support for asm() in compiler. + * + * Used in: + * library/aria.c + * library/timing.c + * include/mbedtls/bn_mul.h + * + * Required by: + * MBEDTLS_AESNI_C + * MBEDTLS_PADLOCK_C + * + * Comment to disable the use of assembly code. + */ +#define MBEDTLS_HAVE_ASM + +/** + * \def MBEDTLS_NO_UDBL_DIVISION + * + * The platform lacks support for double-width integer division (64-bit + * division on a 32-bit platform, 128-bit division on a 64-bit platform). + * + * Used in: + * include/mbedtls/bignum.h + * library/bignum.c + * + * The bignum code uses double-width division to speed up some operations. + * Double-width division is often implemented in software that needs to + * be linked with the program. The presence of a double-width integer + * type is usually detected automatically through preprocessor macros, + * but the automatic detection cannot know whether the code needs to + * and can be linked with an implementation of division for that type. + * By default division is assumed to be usable if the type is present. + * Uncomment this option to prevent the use of double-width division. + * + * Note that division for the native integer type is always required. + * Furthermore, a 64-bit type is always required even on a 32-bit + * platform, but it need not support multiplication or division. In some + * cases it is also desirable to disable some double-width operations. For + * example, if double-width division is implemented in software, disabling + * it can reduce code size in some embedded targets. + */ +//#define MBEDTLS_NO_UDBL_DIVISION + +/** + * \def MBEDTLS_NO_64BIT_MULTIPLICATION + * + * The platform lacks support for 32x32 -> 64-bit multiplication. + * + * Used in: + * library/poly1305.c + * + * Some parts of the library may use multiplication of two unsigned 32-bit + * operands with a 64-bit result in order to speed up computations. On some + * platforms, this is not available in hardware and has to be implemented in + * software, usually in a library provided by the toolchain. + * + * Sometimes it is not desirable to have to link to that library. This option + * removes the dependency of that library on platforms that lack a hardware + * 64-bit multiplier by embedding a software implementation in Mbed TLS. + * + * Note that depending on the compiler, this may decrease performance compared + * to using the library function provided by the toolchain. + */ +//#define MBEDTLS_NO_64BIT_MULTIPLICATION + +/** + * \def MBEDTLS_HAVE_SSE2 + * + * CPU supports SSE2 instruction set. + * + * Uncomment if the CPU supports SSE2 (IA-32 specific). + */ +//#define MBEDTLS_HAVE_SSE2 + +/** + * \def MBEDTLS_HAVE_TIME + * + * System has time.h and time(). + * The time does not need to be correct, only time differences are used, + * by contrast with MBEDTLS_HAVE_TIME_DATE + * + * Defining MBEDTLS_HAVE_TIME allows you to specify MBEDTLS_PLATFORM_TIME_ALT, + * MBEDTLS_PLATFORM_TIME_MACRO, MBEDTLS_PLATFORM_TIME_TYPE_MACRO and + * MBEDTLS_PLATFORM_STD_TIME. + * + * Comment if your system does not support time functions + */ +#define MBEDTLS_HAVE_TIME + +/** + * \def MBEDTLS_HAVE_TIME_DATE + * + * System has time.h, time(), and an implementation for + * mbedtls_platform_gmtime_r() (see below). + * The time needs to be correct (not necessarily very accurate, but at least + * the date should be correct). This is used to verify the validity period of + * X.509 certificates. + * + * Comment if your system does not have a correct clock. + * + * \note mbedtls_platform_gmtime_r() is an abstraction in platform_util.h that + * behaves similarly to the gmtime_r() function from the C standard. Refer to + * the documentation for mbedtls_platform_gmtime_r() for more information. + * + * \note It is possible to configure an implementation for + * mbedtls_platform_gmtime_r() at compile-time by using the macro + * MBEDTLS_PLATFORM_GMTIME_R_ALT. + */ +//#define MBEDTLS_HAVE_TIME_DATE + +/** + * \def MBEDTLS_PLATFORM_MEMORY + * + * Enable the memory allocation layer. + * + * By default mbed TLS uses the system-provided calloc() and free(). + * This allows different allocators (self-implemented or provided) to be + * provided to the platform abstraction layer. + * + * Enabling MBEDTLS_PLATFORM_MEMORY without the + * MBEDTLS_PLATFORM_{FREE,CALLOC}_MACROs will provide + * "mbedtls_platform_set_calloc_free()" allowing you to set an alternative calloc() and + * free() function pointer at runtime. + * + * Enabling MBEDTLS_PLATFORM_MEMORY and specifying + * MBEDTLS_PLATFORM_{CALLOC,FREE}_MACROs will allow you to specify the + * alternate function at compile time. + * + * Requires: MBEDTLS_PLATFORM_C + * + * Enable this layer to allow use of alternative memory allocators. + */ +//#define MBEDTLS_PLATFORM_MEMORY + +/** + * \def MBEDTLS_PLATFORM_NO_STD_FUNCTIONS + * + * Do not assign standard functions in the platform layer (e.g. calloc() to + * MBEDTLS_PLATFORM_STD_CALLOC and printf() to MBEDTLS_PLATFORM_STD_PRINTF) + * + * This makes sure there are no linking errors on platforms that do not support + * these functions. You will HAVE to provide alternatives, either at runtime + * via the platform_set_xxx() functions or at compile time by setting + * the MBEDTLS_PLATFORM_STD_XXX defines, or enabling a + * MBEDTLS_PLATFORM_XXX_MACRO. + * + * Requires: MBEDTLS_PLATFORM_C + * + * Uncomment to prevent default assignment of standard functions in the + * platform layer. + */ +//#define MBEDTLS_PLATFORM_NO_STD_FUNCTIONS + +/** + * \def MBEDTLS_PLATFORM_EXIT_ALT + * + * MBEDTLS_PLATFORM_XXX_ALT: Uncomment a macro to let mbed TLS support the + * function in the platform abstraction layer. + * + * Example: In case you uncomment MBEDTLS_PLATFORM_PRINTF_ALT, mbed TLS will + * provide a function "mbedtls_platform_set_printf()" that allows you to set an + * alternative printf function pointer. + * + * All these define require MBEDTLS_PLATFORM_C to be defined! + * + * \note MBEDTLS_PLATFORM_SNPRINTF_ALT is required on Windows; + * it will be enabled automatically by check_config.h + * + * \warning MBEDTLS_PLATFORM_XXX_ALT cannot be defined at the same time as + * MBEDTLS_PLATFORM_XXX_MACRO! + * + * Requires: MBEDTLS_PLATFORM_TIME_ALT requires MBEDTLS_HAVE_TIME + * + * Uncomment a macro to enable alternate implementation of specific base + * platform function + */ +//#define MBEDTLS_PLATFORM_EXIT_ALT +//#define MBEDTLS_PLATFORM_TIME_ALT +//#define MBEDTLS_PLATFORM_FPRINTF_ALT +//#define MBEDTLS_PLATFORM_PRINTF_ALT +//#define MBEDTLS_PLATFORM_SNPRINTF_ALT +//#define MBEDTLS_PLATFORM_VSNPRINTF_ALT +#define MBEDTLS_PLATFORM_NV_SEED_ALT +#define MBEDTLS_PLATFORM_SETUP_TEARDOWN_ALT + +/** + * \def MBEDTLS_DEPRECATED_WARNING + * + * Mark deprecated functions and features so that they generate a warning if + * used. Functionality deprecated in one version will usually be removed in the + * next version. You can enable this to help you prepare the transition to a + * new major version by making sure your code is not using this functionality. + * + * This only works with GCC and Clang. With other compilers, you may want to + * use MBEDTLS_DEPRECATED_REMOVED + * + * Uncomment to get warnings on using deprecated functions and features. + */ +//#define MBEDTLS_DEPRECATED_WARNING + +/** + * \def MBEDTLS_DEPRECATED_REMOVED + * + * Remove deprecated functions and features so that they generate an error if + * used. Functionality deprecated in one version will usually be removed in the + * next version. You can enable this to help you prepare the transition to a + * new major version by making sure your code is not using this functionality. + * + * Uncomment to get errors on using deprecated functions and features. + */ +//#define MBEDTLS_DEPRECATED_REMOVED + +/** + * \def MBEDTLS_CHECK_PARAMS + * + * This configuration option controls whether the library validates more of + * the parameters passed to it. + * + * When this flag is not defined, the library only attempts to validate an + * input parameter if: (1) they may come from the outside world (such as the + * network, the filesystem, etc.) or (2) not validating them could result in + * internal memory errors such as overflowing a buffer controlled by the + * library. On the other hand, it doesn't attempt to validate parameters whose + * values are fully controlled by the application (such as pointers). + * + * When this flag is defined, the library additionally attempts to validate + * parameters that are fully controlled by the application, and should always + * be valid if the application code is fully correct and trusted. + * + * For example, when a function accepts as input a pointer to a buffer that may + * contain untrusted data, and its documentation mentions that this pointer + * must not be NULL: + * - The pointer is checked to be non-NULL only if this option is enabled. + * - The content of the buffer is always validated. + * + * When this flag is defined, if a library function receives a parameter that + * is invalid: + * 1. The function will invoke the macro MBEDTLS_PARAM_FAILED(). + * 2. If MBEDTLS_PARAM_FAILED() did not terminate the program, the function + * will immediately return. If the function returns an Mbed TLS error code, + * the error code in this case is MBEDTLS_ERR_xxx_BAD_INPUT_DATA. + * + * When defining this flag, you also need to arrange a definition for + * MBEDTLS_PARAM_FAILED(). You can do this by any of the following methods: + * - By default, the library defines MBEDTLS_PARAM_FAILED() to call a + * function mbedtls_param_failed(), but the library does not define this + * function. If you do not make any other arrangements, you must provide + * the function mbedtls_param_failed() in your application. + * See `platform_util.h` for its prototype. + * - If you enable the macro #MBEDTLS_CHECK_PARAMS_ASSERT, then the + * library defines MBEDTLS_PARAM_FAILED(\c cond) to be `assert(cond)`. + * You can still supply an alternative definition of + * MBEDTLS_PARAM_FAILED(), which may call `assert`. + * - If you define a macro MBEDTLS_PARAM_FAILED() before including `config.h` + * or you uncomment the definition of MBEDTLS_PARAM_FAILED() in `config.h`, + * the library will call the macro that you defined and will not supply + * its own version. Note that if MBEDTLS_PARAM_FAILED() calls `assert`, + * you need to enable #MBEDTLS_CHECK_PARAMS_ASSERT so that library source + * files include ``. + * + * Uncomment to enable validation of application-controlled parameters. + */ +//#define MBEDTLS_CHECK_PARAMS + +/** + * \def MBEDTLS_CHECK_PARAMS_ASSERT + * + * Allow MBEDTLS_PARAM_FAILED() to call `assert`, and make it default to + * `assert`. This macro is only used if #MBEDTLS_CHECK_PARAMS is defined. + * + * If this macro is not defined, then MBEDTLS_PARAM_FAILED() defaults to + * calling a function mbedtls_param_failed(). See the documentation of + * #MBEDTLS_CHECK_PARAMS for details. + * + * Uncomment to allow MBEDTLS_PARAM_FAILED() to call `assert`. + */ +//#define MBEDTLS_CHECK_PARAMS_ASSERT + +/* \} name SECTION: System support */ + +/** + * \name SECTION: mbed TLS feature support + * + * This section sets support for features that are or are not needed + * within the modules that are enabled. + * \{ + */ + +/** + * \def MBEDTLS_TIMING_ALT + * + * Uncomment to provide your own alternate implementation for mbedtls_timing_hardclock(), + * mbedtls_timing_get_timer(), mbedtls_set_alarm(), mbedtls_set/get_delay() + * + * Only works if you have MBEDTLS_TIMING_C enabled. + * + * You will need to provide a header "timing_alt.h" and an implementation at + * compile time. + */ +//#define MBEDTLS_TIMING_ALT + +/** + * \def MBEDTLS_AES_ALT + * + * MBEDTLS__MODULE_NAME__ALT: Uncomment a macro to let mbed TLS use your + * alternate core implementation of a symmetric crypto, an arithmetic or hash + * module (e.g. platform specific assembly optimized implementations). Keep + * in mind that the function prototypes should remain the same. + * + * This replaces the whole module. If you only want to replace one of the + * functions, use one of the MBEDTLS__FUNCTION_NAME__ALT flags. + * + * Example: In case you uncomment MBEDTLS_AES_ALT, mbed TLS will no longer + * provide the "struct mbedtls_aes_context" definition and omit the base + * function declarations and implementations. "aes_alt.h" will be included from + * "aes.h" to include the new function definitions. + * + * Uncomment a macro to enable alternate implementation of the corresponding + * module. + * + * \warning MD2, MD4, MD5, ARC4, DES and SHA-1 are considered weak and their + * use constitutes a security risk. If possible, we recommend + * avoiding dependencies on them, and considering stronger message + * digests and ciphers instead. + * + */ +//#define MBEDTLS_AES_ALT +//#define MBEDTLS_ARC4_ALT +//#define MBEDTLS_ARIA_ALT +//#define MBEDTLS_BLOWFISH_ALT +//#define MBEDTLS_CAMELLIA_ALT +//#define MBEDTLS_CCM_ALT +//#define MBEDTLS_CHACHA20_ALT +//#define MBEDTLS_CHACHAPOLY_ALT +//#define MBEDTLS_CMAC_ALT +//#define MBEDTLS_DES_ALT +//#define MBEDTLS_DHM_ALT +//#define MBEDTLS_ECJPAKE_ALT +//#define MBEDTLS_GCM_ALT +//#define MBEDTLS_NIST_KW_ALT +//#define MBEDTLS_MD2_ALT +//#define MBEDTLS_MD4_ALT +//#define MBEDTLS_MD5_ALT +//#define MBEDTLS_POLY1305_ALT +//#define MBEDTLS_RIPEMD160_ALT +//#define MBEDTLS_RSA_ALT +//#define MBEDTLS_SHA1_ALT +//#define MBEDTLS_SHA256_ALT +//#define MBEDTLS_SHA512_ALT +//#define MBEDTLS_XTEA_ALT + +/* + * When replacing the elliptic curve module, pleace consider, that it is + * implemented with two .c files: + * - ecp.c + * - ecp_curves.c + * You can replace them very much like all the other MBEDTLS__MODULE_NAME__ALT + * macros as described above. The only difference is that you have to make sure + * that you provide functionality for both .c files. + */ +//#define MBEDTLS_ECP_ALT + +/** + * \def MBEDTLS_MD2_PROCESS_ALT + * + * MBEDTLS__FUNCTION_NAME__ALT: Uncomment a macro to let mbed TLS use you + * alternate core implementation of symmetric crypto or hash function. Keep in + * mind that function prototypes should remain the same. + * + * This replaces only one function. The header file from mbed TLS is still + * used, in contrast to the MBEDTLS__MODULE_NAME__ALT flags. + * + * Example: In case you uncomment MBEDTLS_SHA256_PROCESS_ALT, mbed TLS will + * no longer provide the mbedtls_sha1_process() function, but it will still provide + * the other function (using your mbedtls_sha1_process() function) and the definition + * of mbedtls_sha1_context, so your implementation of mbedtls_sha1_process must be compatible + * with this definition. + * + * \note Because of a signature change, the core AES encryption and decryption routines are + * currently named mbedtls_aes_internal_encrypt and mbedtls_aes_internal_decrypt, + * respectively. When setting up alternative implementations, these functions should + * be overridden, but the wrapper functions mbedtls_aes_decrypt and mbedtls_aes_encrypt + * must stay untouched. + * + * \note If you use the AES_xxx_ALT macros, then is is recommended to also set + * MBEDTLS_AES_ROM_TABLES in order to help the linker garbage-collect the AES + * tables. + * + * Uncomment a macro to enable alternate implementation of the corresponding + * function. + * + * \warning MD2, MD4, MD5, DES and SHA-1 are considered weak and their use + * constitutes a security risk. If possible, we recommend avoiding + * dependencies on them, and considering stronger message digests + * and ciphers instead. + * + * \warning If both MBEDTLS_ECDSA_SIGN_ALT and MBEDTLS_ECDSA_DETERMINISTIC are + * enabled, then the deterministic ECDH signature functions pass the + * the static HMAC-DRBG as RNG to mbedtls_ecdsa_sign(). Therefore + * alternative implementations should use the RNG only for generating + * the ephemeral key and nothing else. If this is not possible, then + * MBEDTLS_ECDSA_DETERMINISTIC should be disabled and an alternative + * implementation should be provided for mbedtls_ecdsa_sign_det_ext() + * (and for mbedtls_ecdsa_sign_det() too if backward compatibility is + * desirable). + * + */ +//#define MBEDTLS_MD2_PROCESS_ALT +//#define MBEDTLS_MD4_PROCESS_ALT +//#define MBEDTLS_MD5_PROCESS_ALT +//#define MBEDTLS_RIPEMD160_PROCESS_ALT +//#define MBEDTLS_SHA1_PROCESS_ALT +//#define MBEDTLS_SHA256_PROCESS_ALT +//#define MBEDTLS_SHA512_PROCESS_ALT +//#define MBEDTLS_DES_SETKEY_ALT +//#define MBEDTLS_DES_CRYPT_ECB_ALT +//#define MBEDTLS_DES3_CRYPT_ECB_ALT +//#define MBEDTLS_AES_SETKEY_ENC_ALT +//#define MBEDTLS_AES_SETKEY_DEC_ALT +//#define MBEDTLS_AES_ENCRYPT_ALT +//#define MBEDTLS_AES_DECRYPT_ALT +//#define MBEDTLS_ECDH_GEN_PUBLIC_ALT +//#define MBEDTLS_ECDH_COMPUTE_SHARED_ALT +//#define MBEDTLS_ECDSA_VERIFY_ALT +//#define MBEDTLS_ECDSA_SIGN_ALT +//#define MBEDTLS_ECDSA_GENKEY_ALT + +/** + * \def MBEDTLS_ECP_INTERNAL_ALT + * + * Expose a part of the internal interface of the Elliptic Curve Point module. + * + * MBEDTLS_ECP__FUNCTION_NAME__ALT: Uncomment a macro to let mbed TLS use your + * alternative core implementation of elliptic curve arithmetic. Keep in mind + * that function prototypes should remain the same. + * + * This partially replaces one function. The header file from mbed TLS is still + * used, in contrast to the MBEDTLS_ECP_ALT flag. The original implementation + * is still present and it is used for group structures not supported by the + * alternative. + * + * The original implementation can in addition be removed by setting the + * MBEDTLS_ECP_NO_FALLBACK option, in which case any function for which the + * corresponding MBEDTLS_ECP__FUNCTION_NAME__ALT macro is defined will not be + * able to fallback to curves not supported by the alternative implementation. + * + * Any of these options become available by defining MBEDTLS_ECP_INTERNAL_ALT + * and implementing the following functions: + * unsigned char mbedtls_internal_ecp_grp_capable( + * const mbedtls_ecp_group *grp ) + * int mbedtls_internal_ecp_init( const mbedtls_ecp_group *grp ) + * void mbedtls_internal_ecp_free( const mbedtls_ecp_group *grp ) + * The mbedtls_internal_ecp_grp_capable function should return 1 if the + * replacement functions implement arithmetic for the given group and 0 + * otherwise. + * The functions mbedtls_internal_ecp_init and mbedtls_internal_ecp_free are + * called before and after each point operation and provide an opportunity to + * implement optimized set up and tear down instructions. + * + * Example: In case you set MBEDTLS_ECP_INTERNAL_ALT and + * MBEDTLS_ECP_DOUBLE_JAC_ALT, mbed TLS will still provide the ecp_double_jac() + * function, but will use your mbedtls_internal_ecp_double_jac() if the group + * for the operation is supported by your implementation (i.e. your + * mbedtls_internal_ecp_grp_capable() function returns 1 for this group). If the + * group is not supported by your implementation, then the original mbed TLS + * implementation of ecp_double_jac() is used instead, unless this fallback + * behaviour is disabled by setting MBEDTLS_ECP_NO_FALLBACK (in which case + * ecp_double_jac() will return MBEDTLS_ERR_ECP_FEATURE_UNAVAILABLE). + * + * The function prototypes and the definition of mbedtls_ecp_group and + * mbedtls_ecp_point will not change based on MBEDTLS_ECP_INTERNAL_ALT, so your + * implementation of mbedtls_internal_ecp__function_name__ must be compatible + * with their definitions. + * + * Uncomment a macro to enable alternate implementation of the corresponding + * function. + */ +/* Required for all the functions in this section */ +//#define MBEDTLS_ECP_INTERNAL_ALT +/* Turn off software fallback for curves not supported in hardware */ +//#define MBEDTLS_ECP_NO_FALLBACK +/* Support for Weierstrass curves with Jacobi representation */ +//#define MBEDTLS_ECP_RANDOMIZE_JAC_ALT +//#define MBEDTLS_ECP_ADD_MIXED_ALT +//#define MBEDTLS_ECP_DOUBLE_JAC_ALT +//#define MBEDTLS_ECP_NORMALIZE_JAC_MANY_ALT +//#define MBEDTLS_ECP_NORMALIZE_JAC_ALT +/* Support for curves with Montgomery arithmetic */ +//#define MBEDTLS_ECP_DOUBLE_ADD_MXZ_ALT +//#define MBEDTLS_ECP_RANDOMIZE_MXZ_ALT +//#define MBEDTLS_ECP_NORMALIZE_MXZ_ALT + +/** + * \def MBEDTLS_TEST_NULL_ENTROPY + * + * Enables testing and use of mbed TLS without any configured entropy sources. + * This permits use of the library on platforms before an entropy source has + * been integrated (see for example the MBEDTLS_ENTROPY_HARDWARE_ALT or the + * MBEDTLS_ENTROPY_NV_SEED switches). + * + * WARNING! This switch MUST be disabled in production builds, and is suitable + * only for development. + * Enabling the switch negates any security provided by the library. + * + * Requires MBEDTLS_ENTROPY_C, MBEDTLS_NO_DEFAULT_ENTROPY_SOURCES + * + */ +//#define MBEDTLS_TEST_NULL_ENTROPY + +/** + * \def MBEDTLS_ENTROPY_HARDWARE_ALT + * + * Uncomment this macro to let mbed TLS use your own implementation of a + * hardware entropy collector. + * + * Your function must be called \c mbedtls_hardware_poll(), have the same + * prototype as declared in entropy_poll.h, and accept NULL as first argument. + * + * Uncomment to use your own hardware entropy collector. + */ +//#define MBEDTLS_ENTROPY_HARDWARE_ALT + +/** + * \def MBEDTLS_AES_ROM_TABLES + * + * Use precomputed AES tables stored in ROM. + * + * Uncomment this macro to use precomputed AES tables stored in ROM. + * Comment this macro to generate AES tables in RAM at runtime. + * + * Tradeoff: Using precomputed ROM tables reduces RAM usage by ~8kb + * (or ~2kb if \c MBEDTLS_AES_FEWER_TABLES is used) and reduces the + * initialization time before the first AES operation can be performed. + * It comes at the cost of additional ~8kb ROM use (resp. ~2kb if \c + * MBEDTLS_AES_FEWER_TABLES below is used), and potentially degraded + * performance if ROM access is slower than RAM access. + * + * This option is independent of \c MBEDTLS_AES_FEWER_TABLES. + * + */ +#define MBEDTLS_AES_ROM_TABLES + +/** + * \def MBEDTLS_AES_FEWER_TABLES + * + * Use less ROM/RAM for AES tables. + * + * Uncommenting this macro omits 75% of the AES tables from + * ROM / RAM (depending on the value of \c MBEDTLS_AES_ROM_TABLES) + * by computing their values on the fly during operations + * (the tables are entry-wise rotations of one another). + * + * Tradeoff: Uncommenting this reduces the RAM / ROM footprint + * by ~6kb but at the cost of more arithmetic operations during + * runtime. Specifically, one has to compare 4 accesses within + * different tables to 4 accesses with additional arithmetic + * operations within the same table. The performance gain/loss + * depends on the system and memory details. + * + * This option is independent of \c MBEDTLS_AES_ROM_TABLES. + * + */ +//#define MBEDTLS_AES_FEWER_TABLES + +/** + * \def MBEDTLS_CAMELLIA_SMALL_MEMORY + * + * Use less ROM for the Camellia implementation (saves about 768 bytes). + * + * Uncomment this macro to use less memory for Camellia. + */ +//#define MBEDTLS_CAMELLIA_SMALL_MEMORY + +/** + * \def MBEDTLS_CIPHER_MODE_CBC + * + * Enable Cipher Block Chaining mode (CBC) for symmetric ciphers. + */ +#define MBEDTLS_CIPHER_MODE_CBC + +/** + * \def MBEDTLS_CIPHER_MODE_CFB + * + * Enable Cipher Feedback mode (CFB) for symmetric ciphers. + */ +#define MBEDTLS_CIPHER_MODE_CFB + +/** + * \def MBEDTLS_CIPHER_MODE_CTR + * + * Enable Counter Block Cipher mode (CTR) for symmetric ciphers. + */ +#define MBEDTLS_CIPHER_MODE_CTR + +/** + * \def MBEDTLS_CIPHER_MODE_OFB + * + * Enable Output Feedback mode (OFB) for symmetric ciphers. + */ +//#define MBEDTLS_CIPHER_MODE_OFB + +/** + * \def MBEDTLS_CIPHER_MODE_XTS + * + * Enable Xor-encrypt-xor with ciphertext stealing mode (XTS) for AES. + */ +//#define MBEDTLS_CIPHER_MODE_XTS + +/** + * \def MBEDTLS_CIPHER_NULL_CIPHER + * + * Enable NULL cipher. + * Warning: Only do so when you know what you are doing. This allows for + * encryption or channels without any security! + * + * Requires MBEDTLS_ENABLE_WEAK_CIPHERSUITES as well to enable + * the following ciphersuites: + * MBEDTLS_TLS_ECDH_ECDSA_WITH_NULL_SHA + * MBEDTLS_TLS_ECDH_RSA_WITH_NULL_SHA + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_NULL_SHA + * MBEDTLS_TLS_ECDHE_RSA_WITH_NULL_SHA + * MBEDTLS_TLS_ECDHE_PSK_WITH_NULL_SHA384 + * MBEDTLS_TLS_ECDHE_PSK_WITH_NULL_SHA256 + * MBEDTLS_TLS_ECDHE_PSK_WITH_NULL_SHA + * MBEDTLS_TLS_DHE_PSK_WITH_NULL_SHA384 + * MBEDTLS_TLS_DHE_PSK_WITH_NULL_SHA256 + * MBEDTLS_TLS_DHE_PSK_WITH_NULL_SHA + * MBEDTLS_TLS_RSA_WITH_NULL_SHA256 + * MBEDTLS_TLS_RSA_WITH_NULL_SHA + * MBEDTLS_TLS_RSA_WITH_NULL_MD5 + * MBEDTLS_TLS_RSA_PSK_WITH_NULL_SHA384 + * MBEDTLS_TLS_RSA_PSK_WITH_NULL_SHA256 + * MBEDTLS_TLS_RSA_PSK_WITH_NULL_SHA + * MBEDTLS_TLS_PSK_WITH_NULL_SHA384 + * MBEDTLS_TLS_PSK_WITH_NULL_SHA256 + * MBEDTLS_TLS_PSK_WITH_NULL_SHA + * + * Uncomment this macro to enable the NULL cipher and ciphersuites + */ +//#define MBEDTLS_CIPHER_NULL_CIPHER + +/** + * \def MBEDTLS_CIPHER_PADDING_PKCS7 + * + * MBEDTLS_CIPHER_PADDING_XXX: Uncomment or comment macros to add support for + * specific padding modes in the cipher layer with cipher modes that support + * padding (e.g. CBC) + * + * If you disable all padding modes, only full blocks can be used with CBC. + * + * Enable padding modes in the cipher layer. + */ +#define MBEDTLS_CIPHER_PADDING_PKCS7 +#define MBEDTLS_CIPHER_PADDING_ONE_AND_ZEROS +#define MBEDTLS_CIPHER_PADDING_ZEROS_AND_LEN +#define MBEDTLS_CIPHER_PADDING_ZEROS + +/** \def MBEDTLS_CTR_DRBG_USE_128_BIT_KEY + * + * Uncomment this macro to use a 128-bit key in the CTR_DRBG module. + * By default, CTR_DRBG uses a 256-bit key. + */ +//#define MBEDTLS_CTR_DRBG_USE_128_BIT_KEY + +/** + * \def MBEDTLS_ENABLE_WEAK_CIPHERSUITES + * + * Enable weak ciphersuites in SSL / TLS. + * Warning: Only do so when you know what you are doing. This allows for + * channels with virtually no security at all! + * + * This enables the following ciphersuites: + * MBEDTLS_TLS_RSA_WITH_DES_CBC_SHA + * MBEDTLS_TLS_DHE_RSA_WITH_DES_CBC_SHA + * + * Uncomment this macro to enable weak ciphersuites + * + * \warning DES is considered a weak cipher and its use constitutes a + * security risk. We recommend considering stronger ciphers instead. + */ +//#define MBEDTLS_ENABLE_WEAK_CIPHERSUITES + +/** + * \def MBEDTLS_REMOVE_ARC4_CIPHERSUITES + * + * Remove RC4 ciphersuites by default in SSL / TLS. + * This flag removes the ciphersuites based on RC4 from the default list as + * returned by mbedtls_ssl_list_ciphersuites(). However, it is still possible to + * enable (some of) them with mbedtls_ssl_conf_ciphersuites() by including them + * explicitly. + * + * Uncomment this macro to remove RC4 ciphersuites by default. + */ +#define MBEDTLS_REMOVE_ARC4_CIPHERSUITES + +/** + * \def MBEDTLS_REMOVE_3DES_CIPHERSUITES + * + * Remove 3DES ciphersuites by default in SSL / TLS. + * This flag removes the ciphersuites based on 3DES from the default list as + * returned by mbedtls_ssl_list_ciphersuites(). However, it is still possible + * to enable (some of) them with mbedtls_ssl_conf_ciphersuites() by including + * them explicitly. + * + * A man-in-the-browser attacker can recover authentication tokens sent through + * a TLS connection using a 3DES based cipher suite (see "On the Practical + * (In-)Security of 64-bit Block Ciphers" by Karthikeyan Bhargavan and Gaëtan + * Leurent, see https://sweet32.info/SWEET32_CCS16.pdf). If this attack falls + * in your threat model or you are unsure, then you should keep this option + * enabled to remove 3DES based cipher suites. + * + * Comment this macro to keep 3DES in the default ciphersuite list. + */ +#define MBEDTLS_REMOVE_3DES_CIPHERSUITES + +/** + * \def MBEDTLS_ECP_DP_SECP192R1_ENABLED + * + * MBEDTLS_ECP_XXXX_ENABLED: Enables specific curves within the Elliptic Curve + * module. By default all supported curves are enabled. + * + * Comment macros to disable the curve and functions for it + */ +/* Short Weierstrass curves (supporting ECP, ECDH, ECDSA) */ +//#define MBEDTLS_ECP_DP_SECP192R1_ENABLED +//#define MBEDTLS_ECP_DP_SECP224R1_ENABLED +#define MBEDTLS_ECP_DP_SECP256R1_ENABLED +//#define MBEDTLS_ECP_DP_SECP384R1_ENABLED +//#define MBEDTLS_ECP_DP_SECP521R1_ENABLED +//#define MBEDTLS_ECP_DP_SECP192K1_ENABLED +//#define MBEDTLS_ECP_DP_SECP224K1_ENABLED +//#define MBEDTLS_ECP_DP_SECP256K1_ENABLED +//#define MBEDTLS_ECP_DP_BP256R1_ENABLED +//#define MBEDTLS_ECP_DP_BP384R1_ENABLED +//#define MBEDTLS_ECP_DP_BP512R1_ENABLED +/* Montgomery curves (supporting ECP) */ +//#define MBEDTLS_ECP_DP_CURVE25519_ENABLED +//#define MBEDTLS_ECP_DP_CURVE448_ENABLED + +/** + * \def MBEDTLS_ECP_NIST_OPTIM + * + * Enable specific 'modulo p' routines for each NIST prime. + * Depending on the prime and architecture, makes operations 4 to 8 times + * faster on the corresponding curve. + * + * Comment this macro to disable NIST curves optimisation. + */ +#define MBEDTLS_ECP_NIST_OPTIM + +/** + * \def MBEDTLS_ECP_NO_INTERNAL_RNG + * + * When this option is disabled, mbedtls_ecp_mul() will make use of an + * internal RNG when called with a NULL \c f_rng argument, in order to protect + * against some side-channel attacks. + * + * This protection introduces a dependency of the ECP module on one of the + * DRBG modules. For very constrained implementations that don't require this + * protection (for example, because you're only doing signature verification, + * so not manipulating any secret, or because local/physical side-channel + * attacks are outside your threat model), it might be desirable to get rid of + * that dependency. + * + * \warning Enabling this option makes some uses of ECP vulnerable to some + * side-channel attacks. Only enable it if you know that's not a problem for + * your use case. + * + * Uncomment this macro to disable some counter-measures in ECP. + */ +//#define MBEDTLS_ECP_NO_INTERNAL_RNG + +/** + * \def MBEDTLS_ECP_RESTARTABLE + * + * Enable "non-blocking" ECC operations that can return early and be resumed. + * + * This allows various functions to pause by returning + * #MBEDTLS_ERR_ECP_IN_PROGRESS (or, for functions in the SSL module, + * #MBEDTLS_ERR_SSL_CRYPTO_IN_PROGRESS) and then be called later again in + * order to further progress and eventually complete their operation. This is + * controlled through mbedtls_ecp_set_max_ops() which limits the maximum + * number of ECC operations a function may perform before pausing; see + * mbedtls_ecp_set_max_ops() for more information. + * + * This is useful in non-threaded environments if you want to avoid blocking + * for too long on ECC (and, hence, X.509 or SSL/TLS) operations. + * + * Uncomment this macro to enable restartable ECC computations. + * + * \note This option only works with the default software implementation of + * elliptic curve functionality. It is incompatible with + * MBEDTLS_ECP_ALT, MBEDTLS_ECDH_XXX_ALT, MBEDTLS_ECDSA_XXX_ALT + * and MBEDTLS_ECDH_LEGACY_CONTEXT. + */ +//#define MBEDTLS_ECP_RESTARTABLE + +/** + * \def MBEDTLS_ECDH_LEGACY_CONTEXT + * + * Use a backward compatible ECDH context. + * + * Mbed TLS supports two formats for ECDH contexts (#mbedtls_ecdh_context + * defined in `ecdh.h`). For most applications, the choice of format makes + * no difference, since all library functions can work with either format, + * except that the new format is incompatible with MBEDTLS_ECP_RESTARTABLE. + + * The new format used when this option is disabled is smaller + * (56 bytes on a 32-bit platform). In future versions of the library, it + * will support alternative implementations of ECDH operations. + * The new format is incompatible with applications that access + * context fields directly and with restartable ECP operations. + * + * Define this macro if you enable MBEDTLS_ECP_RESTARTABLE or if you + * want to access ECDH context fields directly. Otherwise you should + * comment out this macro definition. + * + * This option has no effect if #MBEDTLS_ECDH_C is not enabled. + * + * \note This configuration option is experimental. Future versions of the + * library may modify the way the ECDH context layout is configured + * and may modify the layout of the new context type. + */ +//#define MBEDTLS_ECDH_LEGACY_CONTEXT + +/** + * \def MBEDTLS_ECDSA_DETERMINISTIC + * + * Enable deterministic ECDSA (RFC 6979). + * Standard ECDSA is "fragile" in the sense that lack of entropy when signing + * may result in a compromise of the long-term signing key. This is avoided by + * the deterministic variant. + * + * Requires: MBEDTLS_HMAC_DRBG_C, MBEDTLS_ECDSA_C + * + * Comment this macro to disable deterministic ECDSA. + */ +//#define MBEDTLS_ECDSA_DETERMINISTIC + +/** + * \def MBEDTLS_KEY_EXCHANGE_PSK_ENABLED + * + * Enable the PSK based ciphersuite modes in SSL / TLS. + * + * This enables the following ciphersuites (if other requisites are + * enabled as well): + * MBEDTLS_TLS_PSK_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_PSK_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_PSK_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_PSK_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_PSK_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_PSK_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_PSK_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_PSK_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_PSK_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_PSK_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_PSK_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_PSK_WITH_RC4_128_SHA + */ +//#define MBEDTLS_KEY_EXCHANGE_PSK_ENABLED + +/** + * \def MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED + * + * Enable the DHE-PSK based ciphersuite modes in SSL / TLS. + * + * Requires: MBEDTLS_DHM_C + * + * This enables the following ciphersuites (if other requisites are + * enabled as well): + * MBEDTLS_TLS_DHE_PSK_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_DHE_PSK_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_DHE_PSK_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_DHE_PSK_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_DHE_PSK_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_DHE_PSK_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_DHE_PSK_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_DHE_PSK_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_DHE_PSK_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_DHE_PSK_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_DHE_PSK_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_DHE_PSK_WITH_RC4_128_SHA + * + * \warning Using DHE constitutes a security risk as it + * is not possible to validate custom DH parameters. + * If possible, it is recommended users should consider + * preferring other methods of key exchange. + * See dhm.h for more details. + * + */ +//#define MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED + +/** + * \def MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED + * + * Enable the ECDHE-PSK based ciphersuite modes in SSL / TLS. + * + * Requires: MBEDTLS_ECDH_C + * + * This enables the following ciphersuites (if other requisites are + * enabled as well): + * MBEDTLS_TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_ECDHE_PSK_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_ECDHE_PSK_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_ECDHE_PSK_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_ECDHE_PSK_WITH_RC4_128_SHA + */ +//#define MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED + +/** + * \def MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED + * + * Enable the RSA-PSK based ciphersuite modes in SSL / TLS. + * + * Requires: MBEDTLS_RSA_C, MBEDTLS_PKCS1_V15, + * MBEDTLS_X509_CRT_PARSE_C + * + * This enables the following ciphersuites (if other requisites are + * enabled as well): + * MBEDTLS_TLS_RSA_PSK_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_RSA_PSK_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_RSA_PSK_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_RSA_PSK_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_RSA_PSK_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_RSA_PSK_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_RSA_PSK_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_RSA_PSK_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_RSA_PSK_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_RSA_PSK_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_RSA_PSK_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_RSA_PSK_WITH_RC4_128_SHA + */ +//#define MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED + +/** + * \def MBEDTLS_KEY_EXCHANGE_RSA_ENABLED + * + * Enable the RSA-only based ciphersuite modes in SSL / TLS. + * + * Requires: MBEDTLS_RSA_C, MBEDTLS_PKCS1_V15, + * MBEDTLS_X509_CRT_PARSE_C + * + * This enables the following ciphersuites (if other requisites are + * enabled as well): + * MBEDTLS_TLS_RSA_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_RSA_WITH_AES_256_CBC_SHA256 + * MBEDTLS_TLS_RSA_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_RSA_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_RSA_WITH_CAMELLIA_256_CBC_SHA256 + * MBEDTLS_TLS_RSA_WITH_CAMELLIA_256_CBC_SHA + * MBEDTLS_TLS_RSA_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_RSA_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_RSA_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_RSA_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_RSA_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_RSA_WITH_CAMELLIA_128_CBC_SHA + * MBEDTLS_TLS_RSA_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_RSA_WITH_RC4_128_SHA + * MBEDTLS_TLS_RSA_WITH_RC4_128_MD5 + */ +//#define MBEDTLS_KEY_EXCHANGE_RSA_ENABLED + +/** + * \def MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED + * + * Enable the DHE-RSA based ciphersuite modes in SSL / TLS. + * + * Requires: MBEDTLS_DHM_C, MBEDTLS_RSA_C, MBEDTLS_PKCS1_V15, + * MBEDTLS_X509_CRT_PARSE_C + * + * This enables the following ciphersuites (if other requisites are + * enabled as well): + * MBEDTLS_TLS_DHE_RSA_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_DHE_RSA_WITH_AES_256_CBC_SHA256 + * MBEDTLS_TLS_DHE_RSA_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_DHE_RSA_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA256 + * MBEDTLS_TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA + * MBEDTLS_TLS_DHE_RSA_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_DHE_RSA_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_DHE_RSA_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_DHE_RSA_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA + * MBEDTLS_TLS_DHE_RSA_WITH_3DES_EDE_CBC_SHA + * + * \warning Using DHE constitutes a security risk as it + * is not possible to validate custom DH parameters. + * If possible, it is recommended users should consider + * preferring other methods of key exchange. + * See dhm.h for more details. + * + */ +//#define MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED + +/** + * \def MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED + * + * Enable the ECDHE-RSA based ciphersuite modes in SSL / TLS. + * + * Requires: MBEDTLS_ECDH_C, MBEDTLS_RSA_C, MBEDTLS_PKCS1_V15, + * MBEDTLS_X509_CRT_PARSE_C + * + * This enables the following ciphersuites (if other requisites are + * enabled as well): + * MBEDTLS_TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_ECDHE_RSA_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_ECDHE_RSA_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_ECDHE_RSA_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_ECDHE_RSA_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_ECDHE_RSA_WITH_RC4_128_SHA + */ +#define MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED + +/** + * \def MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED + * + * Enable the ECDHE-ECDSA based ciphersuite modes in SSL / TLS. + * + * Requires: MBEDTLS_ECDH_C, MBEDTLS_ECDSA_C, MBEDTLS_X509_CRT_PARSE_C, + * + * This enables the following ciphersuites (if other requisites are + * enabled as well): + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_RC4_128_SHA + */ +#define MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED + +/** + * \def MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED + * + * Enable the ECDH-ECDSA based ciphersuite modes in SSL / TLS. + * + * Requires: MBEDTLS_ECDH_C, MBEDTLS_ECDSA_C, MBEDTLS_X509_CRT_PARSE_C + * + * This enables the following ciphersuites (if other requisites are + * enabled as well): + * MBEDTLS_TLS_ECDH_ECDSA_WITH_RC4_128_SHA + * MBEDTLS_TLS_ECDH_ECDSA_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_CAMELLIA_256_GCM_SHA384 + */ +//#define MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED + +/** + * \def MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED + * + * Enable the ECDH-RSA based ciphersuite modes in SSL / TLS. + * + * Requires: MBEDTLS_ECDH_C, MBEDTLS_RSA_C, MBEDTLS_X509_CRT_PARSE_C + * + * This enables the following ciphersuites (if other requisites are + * enabled as well): + * MBEDTLS_TLS_ECDH_RSA_WITH_RC4_128_SHA + * MBEDTLS_TLS_ECDH_RSA_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_ECDH_RSA_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_ECDH_RSA_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_ECDH_RSA_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_ECDH_RSA_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_ECDH_RSA_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_ECDH_RSA_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_ECDH_RSA_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_ECDH_RSA_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_ECDH_RSA_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_ECDH_RSA_WITH_CAMELLIA_256_GCM_SHA384 + */ +//#define MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED + +/** + * \def MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED + * + * Enable the ECJPAKE based ciphersuite modes in SSL / TLS. + * + * \warning This is currently experimental. EC J-PAKE support is based on the + * Thread v1.0.0 specification; incompatible changes to the specification + * might still happen. For this reason, this is disabled by default. + * + * Requires: MBEDTLS_ECJPAKE_C + * MBEDTLS_SHA256_C + * MBEDTLS_ECP_DP_SECP256R1_ENABLED + * + * This enables the following ciphersuites (if other requisites are + * enabled as well): + * MBEDTLS_TLS_ECJPAKE_WITH_AES_128_CCM_8 + */ +//#define MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED + +/** + * \def MBEDTLS_PK_PARSE_EC_EXTENDED + * + * Enhance support for reading EC keys using variants of SEC1 not allowed by + * RFC 5915 and RFC 5480. + * + * Currently this means parsing the SpecifiedECDomain choice of EC + * parameters (only known groups are supported, not arbitrary domains, to + * avoid validation issues). + * + * Disable if you only need to support RFC 5915 + 5480 key formats. + */ +//#define MBEDTLS_PK_PARSE_EC_EXTENDED + +/** + * \def MBEDTLS_ERROR_STRERROR_DUMMY + * + * Enable a dummy error function to make use of mbedtls_strerror() in + * third party libraries easier when MBEDTLS_ERROR_C is disabled + * (no effect when MBEDTLS_ERROR_C is enabled). + * + * You can safely disable this if MBEDTLS_ERROR_C is enabled, or if you're + * not using mbedtls_strerror() or error_strerror() in your application. + * + * Disable if you run into name conflicts and want to really remove the + * mbedtls_strerror() + */ +//#define MBEDTLS_ERROR_STRERROR_DUMMY + +/** + * \def MBEDTLS_GENPRIME + * + * Enable the prime-number generation code. + * + * Requires: MBEDTLS_BIGNUM_C + */ +#define MBEDTLS_GENPRIME + +/** + * \def MBEDTLS_FS_IO + * + * Enable functions that use the filesystem. + */ +//#define MBEDTLS_FS_IO + +/** + * \def MBEDTLS_NO_DEFAULT_ENTROPY_SOURCES + * + * Do not add default entropy sources. These are the platform specific, + * mbedtls_timing_hardclock and HAVEGE based poll functions. + * + * This is useful to have more control over the added entropy sources in an + * application. + * + * Uncomment this macro to prevent loading of default entropy functions. + */ +//#define MBEDTLS_NO_DEFAULT_ENTROPY_SOURCES + +/** + * \def MBEDTLS_NO_PLATFORM_ENTROPY + * + * Do not use built-in platform entropy functions. + * This is useful if your platform does not support + * standards like the /dev/urandom or Windows CryptoAPI. + * + * Uncomment this macro to disable the built-in platform entropy functions. + */ +#define MBEDTLS_NO_PLATFORM_ENTROPY + +/** + * \def MBEDTLS_ENTROPY_FORCE_SHA256 + * + * Force the entropy accumulator to use a SHA-256 accumulator instead of the + * default SHA-512 based one (if both are available). + * + * Requires: MBEDTLS_SHA256_C + * + * On 32-bit systems SHA-256 can be much faster than SHA-512. Use this option + * if you have performance concerns. + * + * This option is only useful if both MBEDTLS_SHA256_C and + * MBEDTLS_SHA512_C are defined. Otherwise the available hash module is used. + */ +#define MBEDTLS_ENTROPY_FORCE_SHA256 + +/** + * \def MBEDTLS_ENTROPY_NV_SEED + * + * Enable the non-volatile (NV) seed file-based entropy source. + * (Also enables the NV seed read/write functions in the platform layer) + * + * This is crucial (if not required) on systems that do not have a + * cryptographic entropy source (in hardware or kernel) available. + * + * Requires: MBEDTLS_ENTROPY_C, MBEDTLS_PLATFORM_C + * + * \note The read/write functions that are used by the entropy source are + * determined in the platform layer, and can be modified at runtime and/or + * compile-time depending on the flags (MBEDTLS_PLATFORM_NV_SEED_*) used. + * + * \note If you use the default implementation functions that read a seedfile + * with regular fopen(), please make sure you make a seedfile with the + * proper name (defined in MBEDTLS_PLATFORM_STD_NV_SEED_FILE) and at + * least MBEDTLS_ENTROPY_BLOCK_SIZE bytes in size that can be read from + * and written to or you will get an entropy source error! The default + * implementation will only use the first MBEDTLS_ENTROPY_BLOCK_SIZE + * bytes from the file. + * + * \note The entropy collector will write to the seed file before entropy is + * given to an external source, to update it. + */ +#define MBEDTLS_ENTROPY_NV_SEED + +/* MBEDTLS_PSA_CRYPTO_KEY_ID_ENCODES_OWNER + * + * Enable key identifiers that encode a key owner identifier. + * + * The owner of a key is identified by a value of type ::mbedtls_key_owner_id_t + * which is currently hard-coded to be int32_t. + * + * Note that this option is meant for internal use only and may be removed + * without notice. It is incompatible with MBEDTLS_USE_PSA_CRYPTO. + */ +//#define MBEDTLS_PSA_CRYPTO_KEY_ID_ENCODES_OWNER + +/** + * \def MBEDTLS_MEMORY_DEBUG + * + * Enable debugging of buffer allocator memory issues. Automatically prints + * (to stderr) all (fatal) messages on memory allocation issues. Enables + * function for 'debug output' of allocated memory. + * + * Requires: MBEDTLS_MEMORY_BUFFER_ALLOC_C + * + * Uncomment this macro to let the buffer allocator print out error messages. + */ +//#define MBEDTLS_MEMORY_DEBUG + +/** + * \def MBEDTLS_MEMORY_BACKTRACE + * + * Include backtrace information with each allocated block. + * + * Requires: MBEDTLS_MEMORY_BUFFER_ALLOC_C + * GLIBC-compatible backtrace() an backtrace_symbols() support + * + * Uncomment this macro to include backtrace information + */ +//#define MBEDTLS_MEMORY_BACKTRACE + +/** + * \def MBEDTLS_PK_RSA_ALT_SUPPORT + * + * Support external private RSA keys (eg from a HSM) in the PK layer. + * + * Comment this macro to disable support for external private RSA keys. + */ +#define MBEDTLS_PK_RSA_ALT_SUPPORT + +/** + * \def MBEDTLS_PKCS1_V15 + * + * Enable support for PKCS#1 v1.5 encoding. + * + * Requires: MBEDTLS_RSA_C + * + * This enables support for PKCS#1 v1.5 operations. + */ +#define MBEDTLS_PKCS1_V15 + +/** + * \def MBEDTLS_PKCS1_V21 + * + * Enable support for PKCS#1 v2.1 encoding. + * + * Requires: MBEDTLS_MD_C, MBEDTLS_RSA_C + * + * This enables support for RSAES-OAEP and RSASSA-PSS operations. + */ +//#define MBEDTLS_PKCS1_V21 + +/** \def MBEDTLS_PSA_CRYPTO_CLIENT + * + * Enable support for PSA crypto client. + * + * \note This option allows to include the code necessary for a PSA + * crypto client when the PSA crypto implementation is not included in + * the library (MBEDTLS_PSA_CRYPTO_C disabled). The code included is the + * code to set and get PSA key attributes. + * The development of PSA drivers partially relying on the library to + * fulfill the hardware gaps is another possible usage of this option. + * + * \warning This interface is experimental and may change or be removed + * without notice. + */ +//#define MBEDTLS_PSA_CRYPTO_CLIENT + +/** \def MBEDTLS_PSA_CRYPTO_DRIVERS + * + * Enable support for the experimental PSA crypto driver interface. + * + * Requires: MBEDTLS_PSA_CRYPTO_C + * + * \warning This interface is experimental and may change or be removed + * without notice. + */ +//#define MBEDTLS_PSA_CRYPTO_DRIVERS + +/** \def MBEDTLS_PSA_CRYPTO_EXTERNAL_RNG + * + * Make the PSA Crypto module use an external random generator provided + * by a driver, instead of Mbed TLS's entropy and DRBG modules. + * + * \note This random generator must deliver random numbers with cryptographic + * quality and high performance. It must supply unpredictable numbers + * with a uniform distribution. The implementation of this function + * is responsible for ensuring that the random generator is seeded + * with sufficient entropy. If you have a hardware TRNG which is slow + * or delivers non-uniform output, declare it as an entropy source + * with mbedtls_entropy_add_source() instead of enabling this option. + * + * If you enable this option, you must configure the type + * ::mbedtls_psa_external_random_context_t in psa/crypto_platform.h + * and define a function called mbedtls_psa_external_get_random() + * with the following prototype: + * ``` + * psa_status_t mbedtls_psa_external_get_random( + * mbedtls_psa_external_random_context_t *context, + * uint8_t *output, size_t output_size, size_t *output_length); + * ); + * ``` + * The \c context value is initialized to 0 before the first call. + * The function must fill the \c output buffer with \p output_size bytes + * of random data and set \c *output_length to \p output_size. + * + * Requires: MBEDTLS_PSA_CRYPTO_C + * + * \warning If you enable this option, code that uses the PSA cryptography + * interface will not use any of the entropy sources set up for + * the entropy module, nor the NV seed that MBEDTLS_ENTROPY_NV_SEED + * enables. + * + * \note This option is experimental and may be removed without notice. + */ +//#define MBEDTLS_PSA_CRYPTO_EXTERNAL_RNG + +/** + * \def MBEDTLS_PSA_CRYPTO_SPM + * + * When MBEDTLS_PSA_CRYPTO_SPM is defined, the code is built for SPM (Secure + * Partition Manager) integration which separates the code into two parts: a + * NSPE (Non-Secure Process Environment) and an SPE (Secure Process + * Environment). + * + * Module: library/psa_crypto.c + * Requires: MBEDTLS_PSA_CRYPTO_C + * + */ +//#define MBEDTLS_PSA_CRYPTO_SPM + +/** + * \def MBEDTLS_PSA_INJECT_ENTROPY + * + * Enable support for entropy injection at first boot. This feature is + * required on systems that do not have a built-in entropy source (TRNG). + * This feature is currently not supported on systems that have a built-in + * entropy source. + * + * Requires: MBEDTLS_PSA_CRYPTO_STORAGE_C, MBEDTLS_ENTROPY_NV_SEED + * + */ +//#define MBEDTLS_PSA_INJECT_ENTROPY + +/** + * \def MBEDTLS_RSA_NO_CRT + * + * Do not use the Chinese Remainder Theorem + * for the RSA private operation. + * + * Uncomment this macro to disable the use of CRT in RSA. + * + */ +//#define MBEDTLS_RSA_NO_CRT + +/** + * \def MBEDTLS_SELF_TEST + * + * Enable the checkup functions (*_self_test). + */ +//#define MBEDTLS_SELF_TEST + +/** + * \def MBEDTLS_SHA256_SMALLER + * + * Enable an implementation of SHA-256 that has lower ROM footprint but also + * lower performance. + * + * The default implementation is meant to be a reasonnable compromise between + * performance and size. This version optimizes more aggressively for size at + * the expense of performance. Eg on Cortex-M4 it reduces the size of + * mbedtls_sha256_process() from ~2KB to ~0.5KB for a performance hit of about + * 30%. + * + * Uncomment to enable the smaller implementation of SHA256. + */ +//#define MBEDTLS_SHA256_SMALLER + +/** + * \def MBEDTLS_SHA512_SMALLER + * + * Enable an implementation of SHA-512 that has lower ROM footprint but also + * lower performance. + * + * Uncomment to enable the smaller implementation of SHA512. + */ +//#define MBEDTLS_SHA512_SMALLER + +/** + * \def MBEDTLS_SHA512_NO_SHA384 + * + * Disable the SHA-384 option of the SHA-512 module. Use this to save some + * code size on devices that don't use SHA-384. + * + * Requires: MBEDTLS_SHA512_C + * + * Uncomment to disable SHA-384 + */ +//#define MBEDTLS_SHA512_NO_SHA384 + +/** + * \def MBEDTLS_SSL_ALL_ALERT_MESSAGES + * + * Enable sending of alert messages in case of encountered errors as per RFC. + * If you choose not to send the alert messages, mbed TLS can still communicate + * with other servers, only debugging of failures is harder. + * + * The advantage of not sending alert messages, is that no information is given + * about reasons for failures thus preventing adversaries of gaining intel. + * + * Enable sending of all alert messages + */ +#define MBEDTLS_SSL_ALL_ALERT_MESSAGES + +/** + * \def MBEDTLS_SSL_RECORD_CHECKING + * + * Enable the function mbedtls_ssl_check_record() which can be used to check + * the validity and authenticity of an incoming record, to verify that it has + * not been seen before. These checks are performed without modifying the + * externally visible state of the SSL context. + * + * See mbedtls_ssl_check_record() for more information. + * + * Uncomment to enable support for record checking. + */ +//#define MBEDTLS_SSL_RECORD_CHECKING + +/** + * \def MBEDTLS_SSL_DTLS_CONNECTION_ID + * + * Enable support for the DTLS Connection ID extension + * (version draft-ietf-tls-dtls-connection-id-05, + * https://tools.ietf.org/html/draft-ietf-tls-dtls-connection-id-05) + * which allows to identify DTLS connections across changes + * in the underlying transport. + * + * Setting this option enables the SSL APIs `mbedtls_ssl_set_cid()`, + * `mbedtls_ssl_get_peer_cid()` and `mbedtls_ssl_conf_cid()`. + * See the corresponding documentation for more information. + * + * \warning The Connection ID extension is still in draft state. + * We make no stability promises for the availability + * or the shape of the API controlled by this option. + * + * The maximum lengths of outgoing and incoming CIDs can be configured + * through the options + * - MBEDTLS_SSL_CID_OUT_LEN_MAX + * - MBEDTLS_SSL_CID_IN_LEN_MAX. + * + * Requires: MBEDTLS_SSL_PROTO_DTLS + * + * Uncomment to enable the Connection ID extension. + */ +//#define MBEDTLS_SSL_DTLS_CONNECTION_ID + +/** + * \def MBEDTLS_SSL_ASYNC_PRIVATE + * + * Enable asynchronous external private key operations in SSL. This allows + * you to configure an SSL connection to call an external cryptographic + * module to perform private key operations instead of performing the + * operation inside the library. + * + */ +//#define MBEDTLS_SSL_ASYNC_PRIVATE + +/** + * \def MBEDTLS_SSL_CONTEXT_SERIALIZATION + * + * Enable serialization of the TLS context structures, through use of the + * functions mbedtls_ssl_context_save() and mbedtls_ssl_context_load(). + * + * This pair of functions allows one side of a connection to serialize the + * context associated with the connection, then free or re-use that context + * while the serialized state is persisted elsewhere, and finally deserialize + * that state to a live context for resuming read/write operations on the + * connection. From a protocol perspective, the state of the connection is + * unaffected, in particular this is entirely transparent to the peer. + * + * Note: this is distinct from TLS session resumption, which is part of the + * protocol and fully visible by the peer. TLS session resumption enables + * establishing new connections associated to a saved session with shorter, + * lighter handshakes, while context serialization is a local optimization in + * handling a single, potentially long-lived connection. + * + * Enabling these APIs makes some SSL structures larger, as 64 extra bytes are + * saved after the handshake to allow for more efficient serialization, so if + * you don't need this feature you'll save RAM by disabling it. + * + * Comment to disable the context serialization APIs. + */ +//#define MBEDTLS_SSL_CONTEXT_SERIALIZATION + +/** + * \def MBEDTLS_SSL_DEBUG_ALL + * + * Enable the debug messages in SSL module for all issues. + * Debug messages have been disabled in some places to prevent timing + * attacks due to (unbalanced) debugging function calls. + * + * If you need all error reporting you should enable this during debugging, + * but remove this for production servers that should log as well. + * + * Uncomment this macro to report all debug messages on errors introducing + * a timing side-channel. + * + */ +//#define MBEDTLS_SSL_DEBUG_ALL + +/** \def MBEDTLS_SSL_ENCRYPT_THEN_MAC + * + * Enable support for Encrypt-then-MAC, RFC 7366. + * + * This allows peers that both support it to use a more robust protection for + * ciphersuites using CBC, providing deep resistance against timing attacks + * on the padding or underlying cipher. + * + * This only affects CBC ciphersuites, and is useless if none is defined. + * + * Requires: MBEDTLS_SSL_PROTO_TLS1 or + * MBEDTLS_SSL_PROTO_TLS1_1 or + * MBEDTLS_SSL_PROTO_TLS1_2 + * + * Comment this macro to disable support for Encrypt-then-MAC + */ +#define MBEDTLS_SSL_ENCRYPT_THEN_MAC + +/** \def MBEDTLS_SSL_EXTENDED_MASTER_SECRET + * + * Enable support for RFC 7627: Session Hash and Extended Master Secret + * Extension. + * + * This was introduced as "the proper fix" to the Triple Handshake familiy of + * attacks, but it is recommended to always use it (even if you disable + * renegotiation), since it actually fixes a more fundamental issue in the + * original SSL/TLS design, and has implications beyond Triple Handshake. + * + * Requires: MBEDTLS_SSL_PROTO_TLS1 or + * MBEDTLS_SSL_PROTO_TLS1_1 or + * MBEDTLS_SSL_PROTO_TLS1_2 + * + * Comment this macro to disable support for Extended Master Secret. + */ +#define MBEDTLS_SSL_EXTENDED_MASTER_SECRET + +/** + * \def MBEDTLS_SSL_FALLBACK_SCSV + * + * Enable support for RFC 7507: Fallback Signaling Cipher Suite Value (SCSV) + * for Preventing Protocol Downgrade Attacks. + * + * For servers, it is recommended to always enable this, unless you support + * only one version of TLS, or know for sure that none of your clients + * implements a fallback strategy. + * + * For clients, you only need this if you're using a fallback strategy, which + * is not recommended in the first place, unless you absolutely need it to + * interoperate with buggy (version-intolerant) servers. + * + * Comment this macro to disable support for FALLBACK_SCSV + */ +//#define MBEDTLS_SSL_FALLBACK_SCSV + +/** + * \def MBEDTLS_SSL_KEEP_PEER_CERTIFICATE + * + * This option controls the availability of the API mbedtls_ssl_get_peer_cert() + * giving access to the peer's certificate after completion of the handshake. + * + * Unless you need mbedtls_ssl_peer_cert() in your application, it is + * recommended to disable this option for reduced RAM usage. + * + * \note If this option is disabled, mbedtls_ssl_get_peer_cert() is still + * defined, but always returns \c NULL. + * + * \note This option has no influence on the protection against the + * triple handshake attack. Even if it is disabled, Mbed TLS will + * still ensure that certificates do not change during renegotiation, + * for exaple by keeping a hash of the peer's certificate. + * + * Comment this macro to disable storing the peer's certificate + * after the handshake. + */ +//#define MBEDTLS_SSL_KEEP_PEER_CERTIFICATE + +/** + * \def MBEDTLS_SSL_HW_RECORD_ACCEL + * + * Enable hooking functions in SSL module for hardware acceleration of + * individual records. + * + * \deprecated This option is deprecated and will be removed in a future + * version of Mbed TLS. + * + * Uncomment this macro to enable hooking functions. + */ +//#define MBEDTLS_SSL_HW_RECORD_ACCEL + +/** + * \def MBEDTLS_SSL_CBC_RECORD_SPLITTING + * + * Enable 1/n-1 record splitting for CBC mode in SSLv3 and TLS 1.0. + * + * This is a countermeasure to the BEAST attack, which also minimizes the risk + * of interoperability issues compared to sending 0-length records. + * + * Comment this macro to disable 1/n-1 record splitting. + */ +//#define MBEDTLS_SSL_CBC_RECORD_SPLITTING + +/** + * \def MBEDTLS_SSL_RENEGOTIATION + * + * Enable support for TLS renegotiation. + * + * The two main uses of renegotiation are (1) refresh keys on long-lived + * connections and (2) client authentication after the initial handshake. + * If you don't need renegotiation, it's probably better to disable it, since + * it has been associated with security issues in the past and is easy to + * misuse/misunderstand. + * + * Comment this to disable support for renegotiation. + * + * \note Even if this option is disabled, both client and server are aware + * of the Renegotiation Indication Extension (RFC 5746) used to + * prevent the SSL renegotiation attack (see RFC 5746 Sect. 1). + * (See \c mbedtls_ssl_conf_legacy_renegotiation for the + * configuration of this extension). + * + */ +//#define MBEDTLS_SSL_RENEGOTIATION + +/** + * \def MBEDTLS_SSL_SRV_SUPPORT_SSLV2_CLIENT_HELLO + * + * Enable support for receiving and parsing SSLv2 Client Hello messages for the + * SSL Server module (MBEDTLS_SSL_SRV_C). + * + * \deprecated This option is deprecated and will be removed in a future + * version of Mbed TLS. + * + * Uncomment this macro to enable support for SSLv2 Client Hello messages. + */ +//#define MBEDTLS_SSL_SRV_SUPPORT_SSLV2_CLIENT_HELLO + +/** + * \def MBEDTLS_SSL_SRV_RESPECT_CLIENT_PREFERENCE + * + * Pick the ciphersuite according to the client's preferences rather than ours + * in the SSL Server module (MBEDTLS_SSL_SRV_C). + * + * Uncomment this macro to respect client's ciphersuite order + */ +//#define MBEDTLS_SSL_SRV_RESPECT_CLIENT_PREFERENCE + +/** + * \def MBEDTLS_SSL_MAX_FRAGMENT_LENGTH + * + * Enable support for RFC 6066 max_fragment_length extension in SSL. + * + * Comment this macro to disable support for the max_fragment_length extension + */ +#define MBEDTLS_SSL_MAX_FRAGMENT_LENGTH + +/** + * \def MBEDTLS_SSL_PROTO_SSL3 + * + * Enable support for SSL 3.0. + * + * Requires: MBEDTLS_MD5_C + * MBEDTLS_SHA1_C + * + * \deprecated This option is deprecated and will be removed in a future + * version of Mbed TLS. + * + * Comment this macro to disable support for SSL 3.0 + */ +//#define MBEDTLS_SSL_PROTO_SSL3 + +/** + * \def MBEDTLS_SSL_PROTO_TLS1 + * + * Enable support for TLS 1.0. + * + * Requires: MBEDTLS_MD5_C + * MBEDTLS_SHA1_C + * + * Comment this macro to disable support for TLS 1.0 + */ +//#define MBEDTLS_SSL_PROTO_TLS1 + +/** + * \def MBEDTLS_SSL_PROTO_TLS1_1 + * + * Enable support for TLS 1.1 (and DTLS 1.0 if DTLS is enabled). + * + * Requires: MBEDTLS_MD5_C + * MBEDTLS_SHA1_C + * + * Comment this macro to disable support for TLS 1.1 / DTLS 1.0 + */ +//#define MBEDTLS_SSL_PROTO_TLS1_1 + +/** + * \def MBEDTLS_SSL_PROTO_TLS1_2 + * + * Enable support for TLS 1.2 (and DTLS 1.2 if DTLS is enabled). + * + * Requires: MBEDTLS_SHA1_C or MBEDTLS_SHA256_C or MBEDTLS_SHA512_C + * (Depends on ciphersuites) + * + * Comment this macro to disable support for TLS 1.2 / DTLS 1.2 + */ +#define MBEDTLS_SSL_PROTO_TLS1_2 + +/** + * \def MBEDTLS_SSL_PROTO_TLS1_3_EXPERIMENTAL + * + * This macro is used to selectively enable experimental parts + * of the code that contribute to the ongoing development of + * the prototype TLS 1.3 and DTLS 1.3 implementation, and provide + * no other purpose. + * + * \warning TLS 1.3 and DTLS 1.3 aren't yet supported in Mbed TLS, + * and no feature exposed through this macro is part of the + * public API. In particular, features under the control + * of this macro are experimental and don't come with any + * stability guarantees. + * + * Uncomment this macro to enable experimental and partial + * functionality specific to TLS 1.3. + */ +//#define MBEDTLS_SSL_PROTO_TLS1_3_EXPERIMENTAL + +/** + * \def MBEDTLS_SSL_PROTO_DTLS + * + * Enable support for DTLS (all available versions). + * + * Enable this and MBEDTLS_SSL_PROTO_TLS1_1 to enable DTLS 1.0, + * and/or this and MBEDTLS_SSL_PROTO_TLS1_2 to enable DTLS 1.2. + * + * Requires: MBEDTLS_SSL_PROTO_TLS1_1 + * or MBEDTLS_SSL_PROTO_TLS1_2 + * + * Comment this macro to disable support for DTLS + */ +//#define MBEDTLS_SSL_PROTO_DTLS + +/** + * \def MBEDTLS_SSL_ALPN + * + * Enable support for RFC 7301 Application Layer Protocol Negotiation. + * + * Comment this macro to disable support for ALPN. + */ +//#define MBEDTLS_SSL_ALPN + +/** + * \def MBEDTLS_SSL_DTLS_ANTI_REPLAY + * + * Enable support for the anti-replay mechanism in DTLS. + * + * Requires: MBEDTLS_SSL_TLS_C + * MBEDTLS_SSL_PROTO_DTLS + * + * \warning Disabling this is often a security risk! + * See mbedtls_ssl_conf_dtls_anti_replay() for details. + * + * Comment this to disable anti-replay in DTLS. + */ +//#define MBEDTLS_SSL_DTLS_ANTI_REPLAY + +/** + * \def MBEDTLS_SSL_DTLS_HELLO_VERIFY + * + * Enable support for HelloVerifyRequest on DTLS servers. + * + * This feature is highly recommended to prevent DTLS servers being used as + * amplifiers in DoS attacks against other hosts. It should always be enabled + * unless you know for sure amplification cannot be a problem in the + * environment in which your server operates. + * + * \warning Disabling this can ba a security risk! (see above) + * + * Requires: MBEDTLS_SSL_PROTO_DTLS + * + * Comment this to disable support for HelloVerifyRequest. + */ +//#define MBEDTLS_SSL_DTLS_HELLO_VERIFY + +/** + * \def MBEDTLS_SSL_DTLS_SRTP + * + * Enable support for negotiation of DTLS-SRTP (RFC 5764) + * through the use_srtp extension. + * + * \note This feature provides the minimum functionality required + * to negotiate the use of DTLS-SRTP and to allow the derivation of + * the associated SRTP packet protection key material. + * In particular, the SRTP packet protection itself, as well as the + * demultiplexing of RTP and DTLS packets at the datagram layer + * (see Section 5 of RFC 5764), are not handled by this feature. + * Instead, after successful completion of a handshake negotiating + * the use of DTLS-SRTP, the extended key exporter API + * mbedtls_ssl_conf_export_keys_ext_cb() should be used to implement + * the key exporter described in Section 4.2 of RFC 5764 and RFC 5705 + * (this is implemented in the SSL example programs). + * The resulting key should then be passed to an SRTP stack. + * + * Setting this option enables the runtime API + * mbedtls_ssl_conf_dtls_srtp_protection_profiles() + * through which the supported DTLS-SRTP protection + * profiles can be configured. You must call this API at + * runtime if you wish to negotiate the use of DTLS-SRTP. + * + * Requires: MBEDTLS_SSL_PROTO_DTLS + * + * Uncomment this to enable support for use_srtp extension. + */ +//#define MBEDTLS_SSL_DTLS_SRTP + +/** + * \def MBEDTLS_SSL_DTLS_CLIENT_PORT_REUSE + * + * Enable server-side support for clients that reconnect from the same port. + * + * Some clients unexpectedly close the connection and try to reconnect using the + * same source port. This needs special support from the server to handle the + * new connection securely, as described in section 4.2.8 of RFC 6347. This + * flag enables that support. + * + * Requires: MBEDTLS_SSL_DTLS_HELLO_VERIFY + * + * Comment this to disable support for clients reusing the source port. + */ +//#define MBEDTLS_SSL_DTLS_CLIENT_PORT_REUSE + +/** + * \def MBEDTLS_SSL_DTLS_BADMAC_LIMIT + * + * Enable support for a limit of records with bad MAC. + * + * See mbedtls_ssl_conf_dtls_badmac_limit(). + * + * Requires: MBEDTLS_SSL_PROTO_DTLS + */ +//#define MBEDTLS_SSL_DTLS_BADMAC_LIMIT + +/** + * \def MBEDTLS_SSL_SESSION_TICKETS + * + * Enable support for RFC 5077 session tickets in SSL. + * Client-side, provides full support for session tickets (maintenance of a + * session store remains the responsibility of the application, though). + * Server-side, you also need to provide callbacks for writing and parsing + * tickets, including authenticated encryption and key management. Example + * callbacks are provided by MBEDTLS_SSL_TICKET_C. + * + * Comment this macro to disable support for SSL session tickets + */ +//#define MBEDTLS_SSL_SESSION_TICKETS + +/** + * \def MBEDTLS_SSL_EXPORT_KEYS + * + * Enable support for exporting key block and master secret. + * This is required for certain users of TLS, e.g. EAP-TLS. + * + * Comment this macro to disable support for key export + */ +//#define MBEDTLS_SSL_EXPORT_KEYS + +/** + * \def MBEDTLS_SSL_SERVER_NAME_INDICATION + * + * Enable support for RFC 6066 server name indication (SNI) in SSL. + * + * Requires: MBEDTLS_X509_CRT_PARSE_C + * + * Comment this macro to disable support for server name indication in SSL + */ +#define MBEDTLS_SSL_SERVER_NAME_INDICATION + +/** + * \def MBEDTLS_SSL_TRUNCATED_HMAC + * + * Enable support for RFC 6066 truncated HMAC in SSL. + * + * Comment this macro to disable support for truncated HMAC in SSL + */ +//#define MBEDTLS_SSL_TRUNCATED_HMAC + +/** + * \def MBEDTLS_SSL_TRUNCATED_HMAC_COMPAT + * + * Fallback to old (pre-2.7), non-conforming implementation of the truncated + * HMAC extension which also truncates the HMAC key. Note that this option is + * only meant for a transitory upgrade period and will be removed in a future + * version of the library. + * + * \warning The old implementation is non-compliant and has a security weakness + * (2^80 brute force attack on the HMAC key used for a single, + * uninterrupted connection). This should only be enabled temporarily + * when (1) the use of truncated HMAC is essential in order to save + * bandwidth, and (2) the peer is an Mbed TLS stack that doesn't use + * the fixed implementation yet (pre-2.7). + * + * \deprecated This option is deprecated and will be removed in a + * future version of Mbed TLS. + * + * Uncomment to fallback to old, non-compliant truncated HMAC implementation. + * + * Requires: MBEDTLS_SSL_TRUNCATED_HMAC + */ +//#define MBEDTLS_SSL_TRUNCATED_HMAC_COMPAT + +/** + * \def MBEDTLS_SSL_VARIABLE_BUFFER_LENGTH + * + * When this option is enabled, the SSL buffer will be resized automatically + * based on the negotiated maximum fragment length in each direction. + * + * Requires: MBEDTLS_SSL_MAX_FRAGMENT_LENGTH + */ +//#define MBEDTLS_SSL_VARIABLE_BUFFER_LENGTH + +/** + * \def MBEDTLS_TEST_CONSTANT_FLOW_MEMSAN + * + * Enable testing of the constant-flow nature of some sensitive functions with + * clang's MemorySanitizer. This causes some existing tests to also test + * this non-functional property of the code under test. + * + * This setting requires compiling with clang -fsanitize=memory. The test + * suites can then be run normally. + * + * \warning This macro is only used for extended testing; it is not considered + * part of the library's API, so it may change or disappear at any time. + * + * Uncomment to enable testing of the constant-flow nature of selected code. + */ +//#define MBEDTLS_TEST_CONSTANT_FLOW_MEMSAN + +/** + * \def MBEDTLS_TEST_CONSTANT_FLOW_VALGRIND + * + * Enable testing of the constant-flow nature of some sensitive functions with + * valgrind's memcheck tool. This causes some existing tests to also test + * this non-functional property of the code under test. + * + * This setting requires valgrind headers for building, and is only useful for + * testing if the tests suites are run with valgrind's memcheck. This can be + * done for an individual test suite with 'valgrind ./test_suite_xxx', or when + * using CMake, this can be done for all test suites with 'make memcheck'. + * + * \warning This macro is only used for extended testing; it is not considered + * part of the library's API, so it may change or disappear at any time. + * + * Uncomment to enable testing of the constant-flow nature of selected code. + */ +//#define MBEDTLS_TEST_CONSTANT_FLOW_VALGRIND + +/** + * \def MBEDTLS_TEST_HOOKS + * + * Enable features for invasive testing such as introspection functions and + * hooks for fault injection. This enables additional unit tests. + * + * Merely enabling this feature should not change the behavior of the product. + * It only adds new code, and new branching points where the default behavior + * is the same as when this feature is disabled. + * However, this feature increases the attack surface: there is an added + * risk of vulnerabilities, and more gadgets that can make exploits easier. + * Therefore this feature must never be enabled in production. + * + * See `docs/architecture/testing/mbed-crypto-invasive-testing.md` for more + * information. + * + * Uncomment to enable invasive tests. + */ +//#define MBEDTLS_TEST_HOOKS + +/** + * \def MBEDTLS_THREADING_ALT + * + * Provide your own alternate threading implementation. + * + * Requires: MBEDTLS_THREADING_C + * + * Uncomment this to allow your own alternate threading implementation. + */ +#define MBEDTLS_THREADING_ALT + +/** + * \def MBEDTLS_THREADING_PTHREAD + * + * Enable the pthread wrapper layer for the threading layer. + * + * Requires: MBEDTLS_THREADING_C + * + * Uncomment this to enable pthread mutexes. + */ +//#define MBEDTLS_THREADING_PTHREAD + +/** + * \def MBEDTLS_USE_PSA_CRYPTO + * + * Make the X.509 and TLS library use PSA for cryptographic operations, and + * enable new APIs for using keys handled by PSA Crypto. + * + * \note Development of this option is currently in progress, and parts of Mbed + * TLS's X.509 and TLS modules are not ported to PSA yet. However, these parts + * will still continue to work as usual, so enabling this option should not + * break backwards compatibility. + * + * \warning The PSA Crypto API is in beta stage. While you're welcome to + * experiment using it, incompatible API changes are still possible, and some + * parts may not have reached the same quality as the rest of Mbed TLS yet. + * + * \warning This option enables new Mbed TLS APIs that are dependent on the + * PSA Crypto API, so can't come with the same stability guarantees as the + * rest of the Mbed TLS APIs. You're welcome to experiment with them, but for + * now, access to these APIs is opt-in (via enabling the present option), in + * order to clearly differentiate them from the stable Mbed TLS APIs. + * + * Requires: MBEDTLS_PSA_CRYPTO_C. + * + * Uncomment this to enable internal use of PSA Crypto and new associated APIs. + */ +//#define MBEDTLS_USE_PSA_CRYPTO + +/** + * \def MBEDTLS_PSA_CRYPTO_CONFIG + * + * This setting allows support for cryptographic mechanisms through the PSA + * API to be configured separately from support through the mbedtls API. + * + * Uncomment this to enable use of PSA Crypto configuration settings which + * can be found in include/psa/crypto_config.h. + * + * If you enable this option and write your own configuration file, you must + * include mbedtls/config_psa.h in your configuration file. The default + * provided mbedtls/config.h contains the necessary inclusion. + * + * This feature is still experimental and is not ready for production since + * it is not completed. + */ +//#define MBEDTLS_PSA_CRYPTO_CONFIG + +/** + * \def MBEDTLS_VERSION_FEATURES + * + * Allow run-time checking of compile-time enabled features. Thus allowing users + * to check at run-time if the library is for instance compiled with threading + * support via mbedtls_version_check_feature(). + * + * Requires: MBEDTLS_VERSION_C + * + * Comment this to disable run-time checking and save ROM space + */ +//#define MBEDTLS_VERSION_FEATURES + +/** + * \def MBEDTLS_X509_ALLOW_EXTENSIONS_NON_V3 + * + * If set, the X509 parser will not break-off when parsing an X509 certificate + * and encountering an extension in a v1 or v2 certificate. + * + * Uncomment to prevent an error. + */ +//#define MBEDTLS_X509_ALLOW_EXTENSIONS_NON_V3 + +/** + * \def MBEDTLS_X509_ALLOW_UNSUPPORTED_CRITICAL_EXTENSION + * + * If set, the X509 parser will not break-off when parsing an X509 certificate + * and encountering an unknown critical extension. + * + * \warning Depending on your PKI use, enabling this can be a security risk! + * + * Uncomment to prevent an error. + */ +//#define MBEDTLS_X509_ALLOW_UNSUPPORTED_CRITICAL_EXTENSION + +/** + * \def MBEDTLS_X509_TRUSTED_CERTIFICATE_CALLBACK + * + * If set, this enables the X.509 API `mbedtls_x509_crt_verify_with_ca_cb()` + * and the SSL API `mbedtls_ssl_conf_ca_cb()` which allow users to configure + * the set of trusted certificates through a callback instead of a linked + * list. + * + * This is useful for example in environments where a large number of trusted + * certificates is present and storing them in a linked list isn't efficient + * enough, or when the set of trusted certificates changes frequently. + * + * See the documentation of `mbedtls_x509_crt_verify_with_ca_cb()` and + * `mbedtls_ssl_conf_ca_cb()` for more information. + * + * Uncomment to enable trusted certificate callbacks. + */ +//#define MBEDTLS_X509_TRUSTED_CERTIFICATE_CALLBACK + +/** + * \def MBEDTLS_X509_CHECK_KEY_USAGE + * + * Enable verification of the keyUsage extension (CA and leaf certificates). + * + * Disabling this avoids problems with mis-issued and/or misused + * (intermediate) CA and leaf certificates. + * + * \warning Depending on your PKI use, disabling this can be a security risk! + * + * Comment to skip keyUsage checking for both CA and leaf certificates. + */ +#define MBEDTLS_X509_CHECK_KEY_USAGE + +/** + * \def MBEDTLS_X509_CHECK_EXTENDED_KEY_USAGE + * + * Enable verification of the extendedKeyUsage extension (leaf certificates). + * + * Disabling this avoids problems with mis-issued and/or misused certificates. + * + * \warning Depending on your PKI use, disabling this can be a security risk! + * + * Comment to skip extendedKeyUsage checking for certificates. + */ +#define MBEDTLS_X509_CHECK_EXTENDED_KEY_USAGE + +/** + * \def MBEDTLS_X509_RSASSA_PSS_SUPPORT + * + * Enable parsing and verification of X.509 certificates, CRLs and CSRS + * signed with RSASSA-PSS (aka PKCS#1 v2.1). + * + * Comment this macro to disallow using RSASSA-PSS in certificates. + */ +//#define MBEDTLS_X509_RSASSA_PSS_SUPPORT + +/** + * \def MBEDTLS_ZLIB_SUPPORT + * + * If set, the SSL/TLS module uses ZLIB to support compression and + * decompression of packet data. + * + * \warning TLS-level compression MAY REDUCE SECURITY! See for example the + * CRIME attack. Before enabling this option, you should examine with care if + * CRIME or similar exploits may be applicable to your use case. + * + * \note Currently compression can't be used with DTLS. + * + * \deprecated This feature is deprecated and will be removed + * in the next major revision of the library. + * + * Used in: library/ssl_tls.c + * library/ssl_cli.c + * library/ssl_srv.c + * + * This feature requires zlib library and headers to be present. + * + * Uncomment to enable use of ZLIB + */ +//#define MBEDTLS_ZLIB_SUPPORT +/* \} name SECTION: mbed TLS feature support */ + +/** + * \name SECTION: mbed TLS modules + * + * This section enables or disables entire modules in mbed TLS + * \{ + */ + +/** + * \def MBEDTLS_AESNI_C + * + * Enable AES-NI support on x86-64. + * + * Module: library/aesni.c + * Caller: library/aes.c + * + * Requires: MBEDTLS_HAVE_ASM + * + * This modules adds support for the AES-NI instructions on x86-64 + */ +//#define MBEDTLS_AESNI_C + +/** + * \def MBEDTLS_AES_C + * + * Enable the AES block cipher. + * + * Module: library/aes.c + * Caller: library/cipher.c + * library/pem.c + * library/ctr_drbg.c + * + * This module enables the following ciphersuites (if other requisites are + * enabled as well): + * MBEDTLS_TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_ECDH_RSA_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_ECDH_RSA_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_ECDH_RSA_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_ECDH_RSA_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_ECDH_RSA_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_ECDH_RSA_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_DHE_RSA_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_DHE_RSA_WITH_AES_256_CBC_SHA256 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_DHE_RSA_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_DHE_RSA_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_DHE_RSA_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_DHE_RSA_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_DHE_PSK_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_DHE_PSK_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_DHE_PSK_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_DHE_PSK_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_DHE_PSK_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_DHE_PSK_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_RSA_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_RSA_WITH_AES_256_CBC_SHA256 + * MBEDTLS_TLS_RSA_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_RSA_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_RSA_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_RSA_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_RSA_PSK_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_RSA_PSK_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_RSA_PSK_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_RSA_PSK_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_RSA_PSK_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_RSA_PSK_WITH_AES_128_CBC_SHA + * MBEDTLS_TLS_PSK_WITH_AES_256_GCM_SHA384 + * MBEDTLS_TLS_PSK_WITH_AES_256_CBC_SHA384 + * MBEDTLS_TLS_PSK_WITH_AES_256_CBC_SHA + * MBEDTLS_TLS_PSK_WITH_AES_128_GCM_SHA256 + * MBEDTLS_TLS_PSK_WITH_AES_128_CBC_SHA256 + * MBEDTLS_TLS_PSK_WITH_AES_128_CBC_SHA + * + * PEM_PARSE uses AES for decrypting encrypted keys. + */ +#define MBEDTLS_AES_C + +/** + * \def MBEDTLS_ARC4_C + * + * Enable the ARCFOUR stream cipher. + * + * Module: library/arc4.c + * Caller: library/cipher.c + * + * This module enables the following ciphersuites (if other requisites are + * enabled as well): + * MBEDTLS_TLS_ECDH_ECDSA_WITH_RC4_128_SHA + * MBEDTLS_TLS_ECDH_RSA_WITH_RC4_128_SHA + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_RC4_128_SHA + * MBEDTLS_TLS_ECDHE_RSA_WITH_RC4_128_SHA + * MBEDTLS_TLS_ECDHE_PSK_WITH_RC4_128_SHA + * MBEDTLS_TLS_DHE_PSK_WITH_RC4_128_SHA + * MBEDTLS_TLS_RSA_WITH_RC4_128_SHA + * MBEDTLS_TLS_RSA_WITH_RC4_128_MD5 + * MBEDTLS_TLS_RSA_PSK_WITH_RC4_128_SHA + * MBEDTLS_TLS_PSK_WITH_RC4_128_SHA + * + * \warning ARC4 is considered a weak cipher and its use constitutes a + * security risk. If possible, we recommend avoidng dependencies on + * it, and considering stronger ciphers instead. + * + */ +//#define MBEDTLS_ARC4_C + +/** + * \def MBEDTLS_ASN1_PARSE_C + * + * Enable the generic ASN1 parser. + * + * Module: library/asn1.c + * Caller: library/x509.c + * library/dhm.c + * library/pkcs12.c + * library/pkcs5.c + * library/pkparse.c + */ +#define MBEDTLS_ASN1_PARSE_C + +/** + * \def MBEDTLS_ASN1_WRITE_C + * + * Enable the generic ASN1 writer. + * + * Module: library/asn1write.c + * Caller: library/ecdsa.c + * library/pkwrite.c + * library/x509_create.c + * library/x509write_crt.c + * library/x509write_csr.c + */ +#define MBEDTLS_ASN1_WRITE_C + +/** + * \def MBEDTLS_BASE64_C + * + * Enable the Base64 module. + * + * Module: library/base64.c + * Caller: library/pem.c + * + * This module is required for PEM support (required by X.509). + */ +#define MBEDTLS_BASE64_C + +/** + * \def MBEDTLS_BIGNUM_C + * + * Enable the multi-precision integer library. + * + * Module: library/bignum.c + * Caller: library/dhm.c + * library/ecp.c + * library/ecdsa.c + * library/rsa.c + * library/rsa_internal.c + * library/ssl_tls.c + * + * This module is required for RSA, DHM and ECC (ECDH, ECDSA) support. + */ +#define MBEDTLS_BIGNUM_C + +/** + * \def MBEDTLS_BLOWFISH_C + * + * Enable the Blowfish block cipher. + * + * Module: library/blowfish.c + */ +//#define MBEDTLS_BLOWFISH_C + +/** + * \def MBEDTLS_CAMELLIA_C + * + * Enable the Camellia block cipher. + * + * Module: library/camellia.c + * Caller: library/cipher.c + * + * This module enables the following ciphersuites (if other requisites are + * enabled as well): + * MBEDTLS_TLS_ECDH_ECDSA_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_ECDH_RSA_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_ECDH_RSA_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_ECDH_RSA_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_ECDH_RSA_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_ECDHE_RSA_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_DHE_RSA_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_ECDHE_RSA_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA256 + * MBEDTLS_TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_ECDHE_RSA_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_DHE_RSA_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_ECDHE_RSA_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA + * MBEDTLS_TLS_DHE_PSK_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_ECDHE_PSK_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_DHE_PSK_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_DHE_PSK_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_DHE_PSK_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_ECDHE_PSK_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_RSA_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_RSA_WITH_CAMELLIA_256_CBC_SHA256 + * MBEDTLS_TLS_RSA_WITH_CAMELLIA_256_CBC_SHA + * MBEDTLS_TLS_RSA_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_RSA_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_RSA_WITH_CAMELLIA_128_CBC_SHA + * MBEDTLS_TLS_RSA_PSK_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_RSA_PSK_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_RSA_PSK_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_RSA_PSK_WITH_CAMELLIA_128_CBC_SHA256 + * MBEDTLS_TLS_PSK_WITH_CAMELLIA_256_GCM_SHA384 + * MBEDTLS_TLS_PSK_WITH_CAMELLIA_256_CBC_SHA384 + * MBEDTLS_TLS_PSK_WITH_CAMELLIA_128_GCM_SHA256 + * MBEDTLS_TLS_PSK_WITH_CAMELLIA_128_CBC_SHA256 + */ +//#define MBEDTLS_CAMELLIA_C + +/** + * \def MBEDTLS_ARIA_C + * + * Enable the ARIA block cipher. + * + * Module: library/aria.c + * Caller: library/cipher.c + * + * This module enables the following ciphersuites (if other requisites are + * enabled as well): + * + * MBEDTLS_TLS_RSA_WITH_ARIA_128_CBC_SHA256 + * MBEDTLS_TLS_RSA_WITH_ARIA_256_CBC_SHA384 + * MBEDTLS_TLS_DHE_RSA_WITH_ARIA_128_CBC_SHA256 + * MBEDTLS_TLS_DHE_RSA_WITH_ARIA_256_CBC_SHA384 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_ARIA_128_CBC_SHA256 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_ARIA_256_CBC_SHA384 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_ARIA_128_CBC_SHA256 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_ARIA_256_CBC_SHA384 + * MBEDTLS_TLS_ECDHE_RSA_WITH_ARIA_128_CBC_SHA256 + * MBEDTLS_TLS_ECDHE_RSA_WITH_ARIA_256_CBC_SHA384 + * MBEDTLS_TLS_ECDH_RSA_WITH_ARIA_128_CBC_SHA256 + * MBEDTLS_TLS_ECDH_RSA_WITH_ARIA_256_CBC_SHA384 + * MBEDTLS_TLS_RSA_WITH_ARIA_128_GCM_SHA256 + * MBEDTLS_TLS_RSA_WITH_ARIA_256_GCM_SHA384 + * MBEDTLS_TLS_DHE_RSA_WITH_ARIA_128_GCM_SHA256 + * MBEDTLS_TLS_DHE_RSA_WITH_ARIA_256_GCM_SHA384 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_ARIA_128_GCM_SHA256 + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_ARIA_256_GCM_SHA384 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_ARIA_128_GCM_SHA256 + * MBEDTLS_TLS_ECDH_ECDSA_WITH_ARIA_256_GCM_SHA384 + * MBEDTLS_TLS_ECDHE_RSA_WITH_ARIA_128_GCM_SHA256 + * MBEDTLS_TLS_ECDHE_RSA_WITH_ARIA_256_GCM_SHA384 + * MBEDTLS_TLS_ECDH_RSA_WITH_ARIA_128_GCM_SHA256 + * MBEDTLS_TLS_ECDH_RSA_WITH_ARIA_256_GCM_SHA384 + * MBEDTLS_TLS_PSK_WITH_ARIA_128_CBC_SHA256 + * MBEDTLS_TLS_PSK_WITH_ARIA_256_CBC_SHA384 + * MBEDTLS_TLS_DHE_PSK_WITH_ARIA_128_CBC_SHA256 + * MBEDTLS_TLS_DHE_PSK_WITH_ARIA_256_CBC_SHA384 + * MBEDTLS_TLS_RSA_PSK_WITH_ARIA_128_CBC_SHA256 + * MBEDTLS_TLS_RSA_PSK_WITH_ARIA_256_CBC_SHA384 + * MBEDTLS_TLS_PSK_WITH_ARIA_128_GCM_SHA256 + * MBEDTLS_TLS_PSK_WITH_ARIA_256_GCM_SHA384 + * MBEDTLS_TLS_DHE_PSK_WITH_ARIA_128_GCM_SHA256 + * MBEDTLS_TLS_DHE_PSK_WITH_ARIA_256_GCM_SHA384 + * MBEDTLS_TLS_RSA_PSK_WITH_ARIA_128_GCM_SHA256 + * MBEDTLS_TLS_RSA_PSK_WITH_ARIA_256_GCM_SHA384 + * MBEDTLS_TLS_ECDHE_PSK_WITH_ARIA_128_CBC_SHA256 + * MBEDTLS_TLS_ECDHE_PSK_WITH_ARIA_256_CBC_SHA384 + */ +//#define MBEDTLS_ARIA_C + +/** + * \def MBEDTLS_CCM_C + * + * Enable the Counter with CBC-MAC (CCM) mode for 128-bit block cipher. + * + * Module: library/ccm.c + * + * Requires: MBEDTLS_AES_C or MBEDTLS_CAMELLIA_C + * + * This module enables the AES-CCM ciphersuites, if other requisites are + * enabled as well. + */ +#define MBEDTLS_CCM_C + +/** + * \def MBEDTLS_CERTS_C + * + * Enable the test certificates. + * + * Module: library/certs.c + * Caller: + * + * This module is used for testing (ssl_client/server). + */ +//#define MBEDTLS_CERTS_C + +/** + * \def MBEDTLS_CHACHA20_C + * + * Enable the ChaCha20 stream cipher. + * + * Module: library/chacha20.c + */ +//#define MBEDTLS_CHACHA20_C + +/** + * \def MBEDTLS_CHACHAPOLY_C + * + * Enable the ChaCha20-Poly1305 AEAD algorithm. + * + * Module: library/chachapoly.c + * + * This module requires: MBEDTLS_CHACHA20_C, MBEDTLS_POLY1305_C + */ +//#define MBEDTLS_CHACHAPOLY_C + +/** + * \def MBEDTLS_CIPHER_C + * + * Enable the generic cipher layer. + * + * Module: library/cipher.c + * Caller: library/ssl_tls.c + * + * Uncomment to enable generic cipher wrappers. + */ +#define MBEDTLS_CIPHER_C + +/** + * \def MBEDTLS_CMAC_C + * + * Enable the CMAC (Cipher-based Message Authentication Code) mode for block + * ciphers. + * + * Module: library/cmac.c + * + * Requires: MBEDTLS_AES_C or MBEDTLS_DES_C + * + */ +//#define MBEDTLS_CMAC_C + +/** + * \def MBEDTLS_CTR_DRBG_C + * + * Enable the CTR_DRBG AES-based random generator. + * The CTR_DRBG generator uses AES-256 by default. + * To use AES-128 instead, enable \c MBEDTLS_CTR_DRBG_USE_128_BIT_KEY above. + * + * \note To achieve a 256-bit security strength with CTR_DRBG, + * you must use AES-256 *and* use sufficient entropy. + * See ctr_drbg.h for more details. + * + * Module: library/ctr_drbg.c + * Caller: + * + * Requires: MBEDTLS_AES_C + * + * This module provides the CTR_DRBG AES random number generator. + */ +#define MBEDTLS_CTR_DRBG_C + +/** + * \def MBEDTLS_DEBUG_C + * + * Enable the debug functions. + * + * Module: library/debug.c + * Caller: library/ssl_cli.c + * library/ssl_srv.c + * library/ssl_tls.c + * + * This module provides debugging functions. + */ +#define MBEDTLS_DEBUG_C + +/** + * \def MBEDTLS_DES_C + * + * Enable the DES block cipher. + * + * Module: library/des.c + * Caller: library/pem.c + * library/cipher.c + * + * This module enables the following ciphersuites (if other requisites are + * enabled as well): + * MBEDTLS_TLS_ECDH_ECDSA_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_ECDH_RSA_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_ECDHE_ECDSA_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_DHE_RSA_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_ECDHE_PSK_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_DHE_PSK_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_RSA_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_RSA_PSK_WITH_3DES_EDE_CBC_SHA + * MBEDTLS_TLS_PSK_WITH_3DES_EDE_CBC_SHA + * + * PEM_PARSE uses DES/3DES for decrypting encrypted keys. + * + * \warning DES is considered a weak cipher and its use constitutes a + * security risk. We recommend considering stronger ciphers instead. + */ +//#define MBEDTLS_DES_C + +/** + * \def MBEDTLS_DHM_C + * + * Enable the Diffie-Hellman-Merkle module. + * + * Module: library/dhm.c + * Caller: library/ssl_cli.c + * library/ssl_srv.c + * + * This module is used by the following key exchanges: + * DHE-RSA, DHE-PSK + * + * \warning Using DHE constitutes a security risk as it + * is not possible to validate custom DH parameters. + * If possible, it is recommended users should consider + * preferring other methods of key exchange. + * See dhm.h for more details. + * + */ +//#define MBEDTLS_DHM_C + +/** + * \def MBEDTLS_ECDH_C + * + * Enable the elliptic curve Diffie-Hellman library. + * + * Module: library/ecdh.c + * Caller: library/ssl_cli.c + * library/ssl_srv.c + * + * This module is used by the following key exchanges: + * ECDHE-ECDSA, ECDHE-RSA, DHE-PSK + * + * Requires: MBEDTLS_ECP_C + */ +#define MBEDTLS_ECDH_C + +/** + * \def MBEDTLS_ECDSA_C + * + * Enable the elliptic curve DSA library. + * + * Module: library/ecdsa.c + * Caller: + * + * This module is used by the following key exchanges: + * ECDHE-ECDSA + * + * Requires: MBEDTLS_ECP_C, MBEDTLS_ASN1_WRITE_C, MBEDTLS_ASN1_PARSE_C, + * and at least one MBEDTLS_ECP_DP_XXX_ENABLED for a + * short Weierstrass curve. + */ +#define MBEDTLS_ECDSA_C + +/** + * \def MBEDTLS_ECJPAKE_C + * + * Enable the elliptic curve J-PAKE library. + * + * \warning This is currently experimental. EC J-PAKE support is based on the + * Thread v1.0.0 specification; incompatible changes to the specification + * might still happen. For this reason, this is disabled by default. + * + * Module: library/ecjpake.c + * Caller: + * + * This module is used by the following key exchanges: + * ECJPAKE + * + * Requires: MBEDTLS_ECP_C, MBEDTLS_MD_C + */ +//#define MBEDTLS_ECJPAKE_C + +/** + * \def MBEDTLS_ECP_C + * + * Enable the elliptic curve over GF(p) library. + * + * Module: library/ecp.c + * Caller: library/ecdh.c + * library/ecdsa.c + * library/ecjpake.c + * + * Requires: MBEDTLS_BIGNUM_C and at least one MBEDTLS_ECP_DP_XXX_ENABLED + */ +#define MBEDTLS_ECP_C + +/** + * \def MBEDTLS_ENTROPY_C + * + * Enable the platform-specific entropy code. + * + * Module: library/entropy.c + * Caller: + * + * Requires: MBEDTLS_SHA512_C or MBEDTLS_SHA256_C + * + * This module provides a generic entropy pool + */ +#define MBEDTLS_ENTROPY_C + +/** + * \def MBEDTLS_ERROR_C + * + * Enable error code to error string conversion. + * + * Module: library/error.c + * Caller: + * + * This module enables mbedtls_strerror(). + */ +#define MBEDTLS_ERROR_C + +/** + * \def MBEDTLS_GCM_C + * + * Enable the Galois/Counter Mode (GCM). + * + * Module: library/gcm.c + * + * Requires: MBEDTLS_AES_C or MBEDTLS_CAMELLIA_C or MBEDTLS_ARIA_C + * + * This module enables the AES-GCM and CAMELLIA-GCM ciphersuites, if other + * requisites are enabled as well. + */ +#define MBEDTLS_GCM_C + +/** + * \def MBEDTLS_HAVEGE_C + * + * Enable the HAVEGE random generator. + * + * Warning: the HAVEGE random generator is not suitable for virtualized + * environments + * + * Warning: the HAVEGE random generator is dependent on timing and specific + * processor traits. It is therefore not advised to use HAVEGE as + * your applications primary random generator or primary entropy pool + * input. As a secondary input to your entropy pool, it IS able add + * the (limited) extra entropy it provides. + * + * Module: library/havege.c + * Caller: + * + * Requires: MBEDTLS_TIMING_C + * + * Uncomment to enable the HAVEGE random generator. + */ +//#define MBEDTLS_HAVEGE_C + +/** + * \def MBEDTLS_HKDF_C + * + * Enable the HKDF algorithm (RFC 5869). + * + * Module: library/hkdf.c + * Caller: + * + * Requires: MBEDTLS_MD_C + * + * This module adds support for the Hashed Message Authentication Code + * (HMAC)-based key derivation function (HKDF). + */ +#define MBEDTLS_HKDF_C + +/** + * \def MBEDTLS_HMAC_DRBG_C + * + * Enable the HMAC_DRBG random generator. + * + * Module: library/hmac_drbg.c + * Caller: + * + * Requires: MBEDTLS_MD_C + * + * Uncomment to enable the HMAC_DRBG random number geerator. + */ +//#define MBEDTLS_HMAC_DRBG_C + +/** + * \def MBEDTLS_NIST_KW_C + * + * Enable the Key Wrapping mode for 128-bit block ciphers, + * as defined in NIST SP 800-38F. Only KW and KWP modes + * are supported. At the moment, only AES is approved by NIST. + * + * Module: library/nist_kw.c + * + * Requires: MBEDTLS_AES_C and MBEDTLS_CIPHER_C + */ +//#define MBEDTLS_NIST_KW_C + +/** + * \def MBEDTLS_MD_C + * + * Enable the generic message digest layer. + * + * Module: library/md.c + * Caller: + * + * Uncomment to enable generic message digest wrappers. + */ +#define MBEDTLS_MD_C + +/** + * \def MBEDTLS_MD2_C + * + * Enable the MD2 hash algorithm. + * + * Module: library/md2.c + * Caller: + * + * Uncomment to enable support for (rare) MD2-signed X.509 certs. + * + * \warning MD2 is considered a weak message digest and its use constitutes a + * security risk. If possible, we recommend avoiding dependencies on + * it, and considering stronger message digests instead. + * + */ +//#define MBEDTLS_MD2_C + +/** + * \def MBEDTLS_MD4_C + * + * Enable the MD4 hash algorithm. + * + * Module: library/md4.c + * Caller: + * + * Uncomment to enable support for (rare) MD4-signed X.509 certs. + * + * \warning MD4 is considered a weak message digest and its use constitutes a + * security risk. If possible, we recommend avoiding dependencies on + * it, and considering stronger message digests instead. + * + */ +//#define MBEDTLS_MD4_C + +/** + * \def MBEDTLS_MD5_C + * + * Enable the MD5 hash algorithm. + * + * Module: library/md5.c + * Caller: library/md.c + * library/pem.c + * library/ssl_tls.c + * + * This module is required for SSL/TLS up to version 1.1, and for TLS 1.2 + * depending on the handshake parameters. Further, it is used for checking + * MD5-signed certificates, and for PBKDF1 when decrypting PEM-encoded + * encrypted keys. + * + * \warning MD5 is considered a weak message digest and its use constitutes a + * security risk. If possible, we recommend avoiding dependencies on + * it, and considering stronger message digests instead. + * + */ +//#define MBEDTLS_MD5_C + +/** + * \def MBEDTLS_MEMORY_BUFFER_ALLOC_C + * + * Enable the buffer allocator implementation that makes use of a (stack) + * based buffer to 'allocate' dynamic memory. (replaces calloc() and free() + * calls) + * + * Module: library/memory_buffer_alloc.c + * + * Requires: MBEDTLS_PLATFORM_C + * MBEDTLS_PLATFORM_MEMORY (to use it within mbed TLS) + * + * Enable this module to enable the buffer memory allocator. + */ +//#define MBEDTLS_MEMORY_BUFFER_ALLOC_C + +/** + * \def MBEDTLS_NET_C + * + * Enable the TCP and UDP over IPv6/IPv4 networking routines. + * + * \note This module only works on POSIX/Unix (including Linux, BSD and OS X) + * and Windows. For other platforms, you'll want to disable it, and write your + * own networking callbacks to be passed to \c mbedtls_ssl_set_bio(). + * + * \note See also our Knowledge Base article about porting to a new + * environment: + * https://tls.mbed.org/kb/how-to/how-do-i-port-mbed-tls-to-a-new-environment-OS + * + * Module: library/net_sockets.c + * + * This module provides networking routines. + */ +//#define MBEDTLS_NET_C + +/** + * \def MBEDTLS_OID_C + * + * Enable the OID database. + * + * Module: library/oid.c + * Caller: library/asn1write.c + * library/pkcs5.c + * library/pkparse.c + * library/pkwrite.c + * library/rsa.c + * library/x509.c + * library/x509_create.c + * library/x509_crl.c + * library/x509_crt.c + * library/x509_csr.c + * library/x509write_crt.c + * library/x509write_csr.c + * + * This modules translates between OIDs and internal values. + */ +#define MBEDTLS_OID_C + +/** + * \def MBEDTLS_PADLOCK_C + * + * Enable VIA Padlock support on x86. + * + * Module: library/padlock.c + * Caller: library/aes.c + * + * Requires: MBEDTLS_HAVE_ASM + * + * This modules adds support for the VIA PadLock on x86. + */ +//#define MBEDTLS_PADLOCK_C + +/** + * \def MBEDTLS_PEM_PARSE_C + * + * Enable PEM decoding / parsing. + * + * Module: library/pem.c + * Caller: library/dhm.c + * library/pkparse.c + * library/x509_crl.c + * library/x509_crt.c + * library/x509_csr.c + * + * Requires: MBEDTLS_BASE64_C + * + * This modules adds support for decoding / parsing PEM files. + */ +#define MBEDTLS_PEM_PARSE_C + +/** + * \def MBEDTLS_PEM_WRITE_C + * + * Enable PEM encoding / writing. + * + * Module: library/pem.c + * Caller: library/pkwrite.c + * library/x509write_crt.c + * library/x509write_csr.c + * + * Requires: MBEDTLS_BASE64_C + * + * This modules adds support for encoding / writing PEM files. + */ +#define MBEDTLS_PEM_WRITE_C + +/** + * \def MBEDTLS_PK_C + * + * Enable the generic public (asymetric) key layer. + * + * Module: library/pk.c + * Caller: library/ssl_tls.c + * library/ssl_cli.c + * library/ssl_srv.c + * + * Requires: MBEDTLS_RSA_C or MBEDTLS_ECP_C + * + * Uncomment to enable generic public key wrappers. + */ +#define MBEDTLS_PK_C + +/** + * \def MBEDTLS_PK_PARSE_C + * + * Enable the generic public (asymetric) key parser. + * + * Module: library/pkparse.c + * Caller: library/x509_crt.c + * library/x509_csr.c + * + * Requires: MBEDTLS_PK_C + * + * Uncomment to enable generic public key parse functions. + */ +#define MBEDTLS_PK_PARSE_C + +/** + * \def MBEDTLS_PK_WRITE_C + * + * Enable the generic public (asymetric) key writer. + * + * Module: library/pkwrite.c + * Caller: library/x509write.c + * + * Requires: MBEDTLS_PK_C + * + * Uncomment to enable generic public key write functions. + */ +#define MBEDTLS_PK_WRITE_C + +/** + * \def MBEDTLS_PKCS5_C + * + * Enable PKCS#5 functions. + * + * Module: library/pkcs5.c + * + * Requires: MBEDTLS_MD_C + * + * This module adds support for the PKCS#5 functions. + */ +#define MBEDTLS_PKCS5_C + +/** + * \def MBEDTLS_PKCS11_C + * + * Enable wrapper for PKCS#11 smartcard support via the pkcs11-helper library. + * + * \deprecated This option is deprecated and will be removed in a future + * version of Mbed TLS. + * + * Module: library/pkcs11.c + * Caller: library/pk.c + * + * Requires: MBEDTLS_PK_C + * + * This module enables SSL/TLS PKCS #11 smartcard support. + * Requires the presence of the PKCS#11 helper library (libpkcs11-helper) + */ +//#define MBEDTLS_PKCS11_C + +/** + * \def MBEDTLS_PKCS12_C + * + * Enable PKCS#12 PBE functions. + * Adds algorithms for parsing PKCS#8 encrypted private keys + * + * Module: library/pkcs12.c + * Caller: library/pkparse.c + * + * Requires: MBEDTLS_ASN1_PARSE_C, MBEDTLS_CIPHER_C, MBEDTLS_MD_C + * Can use: MBEDTLS_ARC4_C + * + * This module enables PKCS#12 functions. + */ +//#define MBEDTLS_PKCS12_C + +/** + * \def MBEDTLS_PLATFORM_C + * + * Enable the platform abstraction layer that allows you to re-assign + * functions like calloc(), free(), snprintf(), printf(), fprintf(), exit(). + * + * Enabling MBEDTLS_PLATFORM_C enables to use of MBEDTLS_PLATFORM_XXX_ALT + * or MBEDTLS_PLATFORM_XXX_MACRO directives, allowing the functions mentioned + * above to be specified at runtime or compile time respectively. + * + * \note This abstraction layer must be enabled on Windows (including MSYS2) + * as other module rely on it for a fixed snprintf implementation. + * + * Module: library/platform.c + * Caller: Most other .c files + * + * This module enables abstraction of common (libc) functions. + */ +#define MBEDTLS_PLATFORM_C + +/** + * \def MBEDTLS_POLY1305_C + * + * Enable the Poly1305 MAC algorithm. + * + * Module: library/poly1305.c + * Caller: library/chachapoly.c + */ +//#define MBEDTLS_POLY1305_C + +/** + * \def MBEDTLS_PSA_CRYPTO_C + * + * Enable the Platform Security Architecture cryptography API. + * + * \warning The PSA Crypto API is still beta status. While you're welcome to + * experiment using it, incompatible API changes are still possible, and some + * parts may not have reached the same quality as the rest of Mbed TLS yet. + * + * Module: library/psa_crypto.c + * + * Requires: either MBEDTLS_CTR_DRBG_C and MBEDTLS_ENTROPY_C, + * or MBEDTLS_HMAC_DRBG_C and MBEDTLS_ENTROPY_C, + * or MBEDTLS_PSA_CRYPTO_EXTERNAL_RNG. + * + */ +//#define MBEDTLS_PSA_CRYPTO_C + +/** + * \def MBEDTLS_PSA_CRYPTO_SE_C + * + * Enable secure element support in the Platform Security Architecture + * cryptography API. + * + * \warning This feature is not yet suitable for production. It is provided + * for API evaluation and testing purposes only. + * + * Module: library/psa_crypto_se.c + * + * Requires: MBEDTLS_PSA_CRYPTO_C, MBEDTLS_PSA_CRYPTO_STORAGE_C + * + */ +//#define MBEDTLS_PSA_CRYPTO_SE_C + +/** + * \def MBEDTLS_PSA_CRYPTO_STORAGE_C + * + * Enable the Platform Security Architecture persistent key storage. + * + * Module: library/psa_crypto_storage.c + * + * Requires: MBEDTLS_PSA_CRYPTO_C, + * either MBEDTLS_PSA_ITS_FILE_C or a native implementation of + * the PSA ITS interface + */ +//#define MBEDTLS_PSA_CRYPTO_STORAGE_C + +/** + * \def MBEDTLS_PSA_ITS_FILE_C + * + * Enable the emulation of the Platform Security Architecture + * Internal Trusted Storage (PSA ITS) over files. + * + * Module: library/psa_its_file.c + * + * Requires: MBEDTLS_FS_IO + */ +//#define MBEDTLS_PSA_ITS_FILE_C + +/** + * \def MBEDTLS_RIPEMD160_C + * + * Enable the RIPEMD-160 hash algorithm. + * + * Module: library/ripemd160.c + * Caller: library/md.c + * + */ +//#define MBEDTLS_RIPEMD160_C + +/** + * \def MBEDTLS_RSA_C + * + * Enable the RSA public-key cryptosystem. + * + * Module: library/rsa.c + * library/rsa_internal.c + * Caller: library/ssl_cli.c + * library/ssl_srv.c + * library/ssl_tls.c + * library/x509.c + * + * This module is used by the following key exchanges: + * RSA, DHE-RSA, ECDHE-RSA, RSA-PSK + * + * Requires: MBEDTLS_BIGNUM_C, MBEDTLS_OID_C + */ +#define MBEDTLS_RSA_C + +/** + * \def MBEDTLS_SHA1_C + * + * Enable the SHA1 cryptographic hash algorithm. + * + * Module: library/sha1.c + * Caller: library/md.c + * library/ssl_cli.c + * library/ssl_srv.c + * library/ssl_tls.c + * library/x509write_crt.c + * + * This module is required for SSL/TLS up to version 1.1, for TLS 1.2 + * depending on the handshake parameters, and for SHA1-signed certificates. + * + * \warning SHA-1 is considered a weak message digest and its use constitutes + * a security risk. If possible, we recommend avoiding dependencies + * on it, and considering stronger message digests instead. + * + */ +#define MBEDTLS_SHA1_C + +/** + * \def MBEDTLS_SHA256_C + * + * Enable the SHA-224 and SHA-256 cryptographic hash algorithms. + * + * Module: library/sha256.c + * Caller: library/entropy.c + * library/md.c + * library/ssl_cli.c + * library/ssl_srv.c + * library/ssl_tls.c + * + * This module adds support for SHA-224 and SHA-256. + * This module is required for the SSL/TLS 1.2 PRF function. + */ +#define MBEDTLS_SHA256_C + +/** + * \def MBEDTLS_SHA512_C + * + * Enable the SHA-384 and SHA-512 cryptographic hash algorithms. + * + * Module: library/sha512.c + * Caller: library/entropy.c + * library/md.c + * library/ssl_cli.c + * library/ssl_srv.c + * + * This module adds support for SHA-384 and SHA-512. + */ +//#define MBEDTLS_SHA512_C + +/** + * \def MBEDTLS_SSL_CACHE_C + * + * Enable simple SSL cache implementation. + * + * Module: library/ssl_cache.c + * Caller: + * + * Requires: MBEDTLS_SSL_CACHE_C + */ +//#define MBEDTLS_SSL_CACHE_C + +/** + * \def MBEDTLS_SSL_COOKIE_C + * + * Enable basic implementation of DTLS cookies for hello verification. + * + * Module: library/ssl_cookie.c + * Caller: + */ +//#define MBEDTLS_SSL_COOKIE_C + +/** + * \def MBEDTLS_SSL_TICKET_C + * + * Enable an implementation of TLS server-side callbacks for session tickets. + * + * Module: library/ssl_ticket.c + * Caller: + * + * Requires: MBEDTLS_CIPHER_C + */ +//#define MBEDTLS_SSL_TICKET_C + +/** + * \def MBEDTLS_SSL_CLI_C + * + * Enable the SSL/TLS client code. + * + * Module: library/ssl_cli.c + * Caller: + * + * Requires: MBEDTLS_SSL_TLS_C + * + * This module is required for SSL/TLS client support. + */ +#define MBEDTLS_SSL_CLI_C + +/** + * \def MBEDTLS_SSL_SRV_C + * + * Enable the SSL/TLS server code. + * + * Module: library/ssl_srv.c + * Caller: + * + * Requires: MBEDTLS_SSL_TLS_C + * + * This module is required for SSL/TLS server support. + */ +//#define MBEDTLS_SSL_SRV_C + +/** + * \def MBEDTLS_SSL_TLS_C + * + * Enable the generic SSL/TLS code. + * + * Module: library/ssl_tls.c + * Caller: library/ssl_cli.c + * library/ssl_srv.c + * + * Requires: MBEDTLS_CIPHER_C, MBEDTLS_MD_C + * and at least one of the MBEDTLS_SSL_PROTO_XXX defines + * + * This module is required for SSL/TLS. + */ +#define MBEDTLS_SSL_TLS_C + +/** + * \def MBEDTLS_THREADING_C + * + * Enable the threading abstraction layer. + * By default mbed TLS assumes it is used in a non-threaded environment or that + * contexts are not shared between threads. If you do intend to use contexts + * between threads, you will need to enable this layer to prevent race + * conditions. See also our Knowledge Base article about threading: + * https://tls.mbed.org/kb/development/thread-safety-and-multi-threading + * + * Module: library/threading.c + * + * This allows different threading implementations (self-implemented or + * provided). + * + * You will have to enable either MBEDTLS_THREADING_ALT or + * MBEDTLS_THREADING_PTHREAD. + * + * Enable this layer to allow use of mutexes within mbed TLS + */ +#define MBEDTLS_THREADING_C + +/** + * \def MBEDTLS_TIMING_C + * + * Enable the semi-portable timing interface. + * + * \note The provided implementation only works on POSIX/Unix (including Linux, + * BSD and OS X) and Windows. On other platforms, you can either disable that + * module and provide your own implementations of the callbacks needed by + * \c mbedtls_ssl_set_timer_cb() for DTLS, or leave it enabled and provide + * your own implementation of the whole module by setting + * \c MBEDTLS_TIMING_ALT in the current file. + * + * \note See also our Knowledge Base article about porting to a new + * environment: + * https://tls.mbed.org/kb/how-to/how-do-i-port-mbed-tls-to-a-new-environment-OS + * + * Module: library/timing.c + * Caller: library/havege.c + * + * This module is used by the HAVEGE random number generator. + */ +//#define MBEDTLS_TIMING_C + +/** + * \def MBEDTLS_VERSION_C + * + * Enable run-time version information. + * + * Module: library/version.c + * + * This module provides run-time version information. + */ +//#define MBEDTLS_VERSION_C + +/** + * \def MBEDTLS_X509_USE_C + * + * Enable X.509 core for using certificates. + * + * Module: library/x509.c + * Caller: library/x509_crl.c + * library/x509_crt.c + * library/x509_csr.c + * + * Requires: MBEDTLS_ASN1_PARSE_C, MBEDTLS_BIGNUM_C, MBEDTLS_OID_C, + * MBEDTLS_PK_PARSE_C + * + * This module is required for the X.509 parsing modules. + */ +#define MBEDTLS_X509_USE_C + +/** + * \def MBEDTLS_X509_CRT_PARSE_C + * + * Enable X.509 certificate parsing. + * + * Module: library/x509_crt.c + * Caller: library/ssl_cli.c + * library/ssl_srv.c + * library/ssl_tls.c + * + * Requires: MBEDTLS_X509_USE_C + * + * This module is required for X.509 certificate parsing. + */ +#define MBEDTLS_X509_CRT_PARSE_C + +/** + * \def MBEDTLS_X509_CRL_PARSE_C + * + * Enable X.509 CRL parsing. + * + * Module: library/x509_crl.c + * Caller: library/x509_crt.c + * + * Requires: MBEDTLS_X509_USE_C + * + * This module is required for X.509 CRL parsing. + */ +//#define MBEDTLS_X509_CRL_PARSE_C + +/** + * \def MBEDTLS_X509_CSR_PARSE_C + * + * Enable X.509 Certificate Signing Request (CSR) parsing. + * + * Module: library/x509_csr.c + * Caller: library/x509_crt_write.c + * + * Requires: MBEDTLS_X509_USE_C + * + * This module is used for reading X.509 certificate request. + */ +#define MBEDTLS_X509_CSR_PARSE_C + +/** + * \def MBEDTLS_X509_CREATE_C + * + * Enable X.509 core for creating certificates. + * + * Module: library/x509_create.c + * + * Requires: MBEDTLS_BIGNUM_C, MBEDTLS_OID_C, MBEDTLS_PK_WRITE_C + * + * This module is the basis for creating X.509 certificates and CSRs. + */ +#define MBEDTLS_X509_CREATE_C + +/** + * \def MBEDTLS_X509_CRT_WRITE_C + * + * Enable creating X.509 certificates. + * + * Module: library/x509_crt_write.c + * + * Requires: MBEDTLS_X509_CREATE_C + * + * This module is required for X.509 certificate creation. + */ +//#define MBEDTLS_X509_CRT_WRITE_C + +/** + * \def MBEDTLS_X509_CSR_WRITE_C + * + * Enable creating X.509 Certificate Signing Requests (CSR). + * + * Module: library/x509_csr_write.c + * + * Requires: MBEDTLS_X509_CREATE_C + * + * This module is required for X.509 certificate request writing. + */ +#define MBEDTLS_X509_CSR_WRITE_C + +/** + * \def MBEDTLS_XTEA_C + * + * Enable the XTEA block cipher. + * + * Module: library/xtea.c + * Caller: + */ +//#define MBEDTLS_XTEA_C + +/* \} name SECTION: mbed TLS modules */ + +/** + * \name SECTION: Module configuration options + * + * This section allows for the setting of module specific sizes and + * configuration options. The default values are already present in the + * relevant header files and should suffice for the regular use cases. + * + * Our advice is to enable options and change their values here + * only if you have a good reason and know the consequences. + * + * Please check the respective header file for documentation on these + * parameters (to prevent duplicate documentation). + * \{ + */ + +/* MPI / BIGNUM options */ +//#define MBEDTLS_MPI_WINDOW_SIZE 6 /**< Maximum window size used. */ +//#define MBEDTLS_MPI_MAX_SIZE 1024 /**< Maximum number of bytes for usable MPIs. */ + +/* CTR_DRBG options */ +//#define MBEDTLS_CTR_DRBG_ENTROPY_LEN 48 /**< Amount of entropy used per seed by default (48 with +// SHA-512, 32 with SHA-256) */ #define MBEDTLS_CTR_DRBG_RESEED_INTERVAL 10000 /**< Interval before reseed is +// performed by default */ #define MBEDTLS_CTR_DRBG_MAX_INPUT 256 /**< Maximum number of additional input +// bytes */ #define MBEDTLS_CTR_DRBG_MAX_REQUEST 1024 /**< Maximum number of requested bytes per call */ +//#define MBEDTLS_CTR_DRBG_MAX_SEED_INPUT 384 /**< Maximum size of (re)seed buffer */ + +/* HMAC_DRBG options */ +//#define MBEDTLS_HMAC_DRBG_RESEED_INTERVAL 10000 /**< Interval before reseed is performed by default */ +//#define MBEDTLS_HMAC_DRBG_MAX_INPUT 256 /**< Maximum number of additional input bytes */ +//#define MBEDTLS_HMAC_DRBG_MAX_REQUEST 1024 /**< Maximum number of requested bytes per call */ +//#define MBEDTLS_HMAC_DRBG_MAX_SEED_INPUT 384 /**< Maximum size of (re)seed buffer */ + +/* ECP options */ +//#define MBEDTLS_ECP_MAX_BITS 521 /**< Maximum bit size of groups */ +//#define MBEDTLS_ECP_WINDOW_SIZE 6 /**< Maximum window size used */ +//#define MBEDTLS_ECP_FIXED_POINT_OPTIM 1 /**< Enable fixed-point speed-up */ + +/* Entropy options */ +//#define MBEDTLS_ENTROPY_MAX_SOURCES 20 /**< Maximum number of sources supported */ +//#define MBEDTLS_ENTROPY_MAX_GATHER 128 /**< Maximum amount requested from entropy sources */ +//#define MBEDTLS_ENTROPY_MIN_HARDWARE 32 /**< Default minimum number of bytes required for the hardware +// entropy source mbedtls_hardware_poll() before entropy is released */ + +/* Memory buffer allocator options */ +//#define MBEDTLS_MEMORY_ALIGN_MULTIPLE 4 /**< Align on multiples of this value */ + +/* Platform options */ +//#define MBEDTLS_PLATFORM_STD_MEM_HDR /**< Header to include if MBEDTLS_PLATFORM_NO_STD_FUNCTIONS is +// defined. Don't define if no header is needed. */ #define MBEDTLS_PLATFORM_STD_CALLOC calloc /**< Default +// allocator to use, can be undefined */ #define MBEDTLS_PLATFORM_STD_FREE free /**< Default free to use, can +// be undefined */ #define MBEDTLS_PLATFORM_STD_EXIT exit /**< Default exit to use, can be undefined */ +//#define MBEDTLS_PLATFORM_STD_TIME time /**< Default time to use, can be undefined. MBEDTLS_HAVE_TIME must +// be enabled */ #define MBEDTLS_PLATFORM_STD_FPRINTF fprintf /**< Default fprintf to use, can be undefined */ +//#define MBEDTLS_PLATFORM_STD_PRINTF printf /**< Default printf to use, can be undefined */ +/* Note: your snprintf must correctly zero-terminate the buffer! */ +//#define MBEDTLS_PLATFORM_STD_SNPRINTF snprintf /**< Default snprintf to use, can be undefined */ +//#define MBEDTLS_PLATFORM_STD_EXIT_SUCCESS 0 /**< Default exit value to use, can be undefined */ +//#define MBEDTLS_PLATFORM_STD_EXIT_FAILURE 1 /**< Default exit value to use, can be undefined */ +//#define MBEDTLS_PLATFORM_STD_NV_SEED_READ mbedtls_platform_std_nv_seed_read /**< Default nv_seed_read function to +// use, can be undefined */ #define MBEDTLS_PLATFORM_STD_NV_SEED_WRITE mbedtls_platform_std_nv_seed_write /**< Default +// nv_seed_write function to use, can be undefined */ #define MBEDTLS_PLATFORM_STD_NV_SEED_FILE "seedfile" /**< Seed +// file to read/write with default implementation */ + +/* To Use Function Macros MBEDTLS_PLATFORM_C must be enabled */ +/* MBEDTLS_PLATFORM_XXX_MACRO and MBEDTLS_PLATFORM_XXX_ALT cannot both be defined */ +//#define MBEDTLS_PLATFORM_CALLOC_MACRO calloc /**< Default allocator macro to use, can be undefined */ +//#define MBEDTLS_PLATFORM_FREE_MACRO free /**< Default free macro to use, can be undefined */ +//#define MBEDTLS_PLATFORM_EXIT_MACRO exit /**< Default exit macro to use, can be undefined */ +//#define MBEDTLS_PLATFORM_TIME_MACRO time /**< Default time macro to use, can be undefined. +// MBEDTLS_HAVE_TIME must be enabled */ #define MBEDTLS_PLATFORM_TIME_TYPE_MACRO time_t /**< Default time macro to +// use, can be undefined. MBEDTLS_HAVE_TIME must be enabled */ #define MBEDTLS_PLATFORM_FPRINTF_MACRO fprintf /**< +// Default fprintf macro to use, can be undefined */ #define MBEDTLS_PLATFORM_PRINTF_MACRO printf /**< Default +// printf macro to use, can be undefined */ +/* Note: your snprintf must correctly zero-terminate the buffer! */ +//#define MBEDTLS_PLATFORM_SNPRINTF_MACRO snprintf /**< Default snprintf macro to use, can be undefined */ +//#define MBEDTLS_PLATFORM_VSNPRINTF_MACRO vsnprintf /**< Default vsnprintf macro to use, can be undefined */ +//#define MBEDTLS_PLATFORM_NV_SEED_READ_MACRO mbedtls_platform_std_nv_seed_read /**< Default nv_seed_read function to +// use, can be undefined */ #define MBEDTLS_PLATFORM_NV_SEED_WRITE_MACRO mbedtls_platform_std_nv_seed_write /**< +// Default nv_seed_write function to use, can be undefined */ + +/** + * \brief This macro is invoked by the library when an invalid parameter + * is detected that is only checked with #MBEDTLS_CHECK_PARAMS + * (see the documentation of that option for context). + * + * When you leave this undefined here, the library provides + * a default definition. If the macro #MBEDTLS_CHECK_PARAMS_ASSERT + * is defined, the default definition is `assert(cond)`, + * otherwise the default definition calls a function + * mbedtls_param_failed(). This function is declared in + * `platform_util.h` for the benefit of the library, but + * you need to define in your application. + * + * When you define this here, this replaces the default + * definition in platform_util.h (which no longer declares the + * function mbedtls_param_failed()) and it is your responsibility + * to make sure this macro expands to something suitable (in + * particular, that all the necessary declarations are visible + * from within the library - you can ensure that by providing + * them in this file next to the macro definition). + * If you define this macro to call `assert`, also define + * #MBEDTLS_CHECK_PARAMS_ASSERT so that library source files + * include ``. + * + * Note that you may define this macro to expand to nothing, in + * which case you don't have to worry about declarations or + * definitions. However, you will then be notified about invalid + * parameters only in non-void functions, and void function will + * just silently return early on invalid parameters, which + * partially negates the benefits of enabling + * #MBEDTLS_CHECK_PARAMS in the first place, so is discouraged. + * + * \param cond The expression that should evaluate to true, but doesn't. + */ +//#define MBEDTLS_PARAM_FAILED( cond ) assert( cond ) + +/* PSA options */ +/** + * Use HMAC_DRBG with the specified hash algorithm for HMAC_DRBG for the + * PSA crypto subsystem. + * + * If this option is unset: + * - If CTR_DRBG is available, the PSA subsystem uses it rather than HMAC_DRBG. + * - Otherwise, the PSA subsystem uses HMAC_DRBG with either + * #MBEDTLS_MD_SHA512 or #MBEDTLS_MD_SHA256 based on availability and + * on unspecified heuristics. + */ +//#define MBEDTLS_PSA_HMAC_DRBG_MD_TYPE MBEDTLS_MD_SHA256 + +/** \def MBEDTLS_PSA_KEY_SLOT_COUNT + * Restrict the PSA library to supporting a maximum amount of simultaneously + * loaded keys. A loaded key is a key stored by the PSA Crypto core as a + * volatile key, or a persistent key which is loaded temporarily by the + * library as part of a crypto operation in flight. + * + * If this option is unset, the library will fall back to a default value of + * 32 keys. + */ +//#define MBEDTLS_PSA_KEY_SLOT_COUNT 32 + +/* SSL Cache options */ +//#define MBEDTLS_SSL_CACHE_DEFAULT_TIMEOUT 86400 /**< 1 day */ +//#define MBEDTLS_SSL_CACHE_DEFAULT_MAX_ENTRIES 50 /**< Maximum entries in cache */ + +/* SSL options */ + +/** \def MBEDTLS_SSL_MAX_CONTENT_LEN + * + * Maximum length (in bytes) of incoming and outgoing plaintext fragments. + * + * This determines the size of both the incoming and outgoing TLS I/O buffers + * in such a way that both are capable of holding the specified amount of + * plaintext data, regardless of the protection mechanism used. + * + * To configure incoming and outgoing I/O buffers separately, use + * #MBEDTLS_SSL_IN_CONTENT_LEN and #MBEDTLS_SSL_OUT_CONTENT_LEN, + * which overwrite the value set by this option. + * + * \note When using a value less than the default of 16KB on the client, it is + * recommended to use the Maximum Fragment Length (MFL) extension to + * inform the server about this limitation. On the server, there + * is no supported, standardized way of informing the client about + * restriction on the maximum size of incoming messages, and unless + * the limitation has been communicated by other means, it is recommended + * to only change the outgoing buffer size #MBEDTLS_SSL_OUT_CONTENT_LEN + * while keeping the default value of 16KB for the incoming buffer. + * + * Uncomment to set the maximum plaintext size of both + * incoming and outgoing I/O buffers. + */ +#define MBEDTLS_SSL_MAX_CONTENT_LEN 8192 + +/** \def MBEDTLS_SSL_IN_CONTENT_LEN + * + * Maximum length (in bytes) of incoming plaintext fragments. + * + * This determines the size of the incoming TLS I/O buffer in such a way + * that it is capable of holding the specified amount of plaintext data, + * regardless of the protection mechanism used. + * + * If this option is undefined, it inherits its value from + * #MBEDTLS_SSL_MAX_CONTENT_LEN. + * + * \note When using a value less than the default of 16KB on the client, it is + * recommended to use the Maximum Fragment Length (MFL) extension to + * inform the server about this limitation. On the server, there + * is no supported, standardized way of informing the client about + * restriction on the maximum size of incoming messages, and unless + * the limitation has been communicated by other means, it is recommended + * to only change the outgoing buffer size #MBEDTLS_SSL_OUT_CONTENT_LEN + * while keeping the default value of 16KB for the incoming buffer. + * + * Uncomment to set the maximum plaintext size of the incoming I/O buffer + * independently of the outgoing I/O buffer. + */ +//#define MBEDTLS_SSL_IN_CONTENT_LEN 16384 + +/** \def MBEDTLS_SSL_CID_IN_LEN_MAX + * + * The maximum length of CIDs used for incoming DTLS messages. + * + */ +//#define MBEDTLS_SSL_CID_IN_LEN_MAX 32 + +/** \def MBEDTLS_SSL_CID_OUT_LEN_MAX + * + * The maximum length of CIDs used for outgoing DTLS messages. + * + */ +//#define MBEDTLS_SSL_CID_OUT_LEN_MAX 32 + +/** \def MBEDTLS_SSL_CID_PADDING_GRANULARITY + * + * This option controls the use of record plaintext padding + * when using the Connection ID extension in DTLS 1.2. + * + * The padding will always be chosen so that the length of the + * padded plaintext is a multiple of the value of this option. + * + * Note: A value of \c 1 means that no padding will be used + * for outgoing records. + * + * Note: On systems lacking division instructions, + * a power of two should be preferred. + * + */ +//#define MBEDTLS_SSL_CID_PADDING_GRANULARITY 16 + +/** \def MBEDTLS_SSL_TLS1_3_PADDING_GRANULARITY + * + * This option controls the use of record plaintext padding + * in TLS 1.3. + * + * The padding will always be chosen so that the length of the + * padded plaintext is a multiple of the value of this option. + * + * Note: A value of \c 1 means that no padding will be used + * for outgoing records. + * + * Note: On systems lacking division instructions, + * a power of two should be preferred. + */ +//#define MBEDTLS_SSL_TLS1_3_PADDING_GRANULARITY 1 + +/** \def MBEDTLS_SSL_OUT_CONTENT_LEN + * + * Maximum length (in bytes) of outgoing plaintext fragments. + * + * This determines the size of the outgoing TLS I/O buffer in such a way + * that it is capable of holding the specified amount of plaintext data, + * regardless of the protection mechanism used. + * + * If this option undefined, it inherits its value from + * #MBEDTLS_SSL_MAX_CONTENT_LEN. + * + * It is possible to save RAM by setting a smaller outward buffer, while keeping + * the default inward 16384 byte buffer to conform to the TLS specification. + * + * The minimum required outward buffer size is determined by the handshake + * protocol's usage. Handshaking will fail if the outward buffer is too small. + * The specific size requirement depends on the configured ciphers and any + * certificate data which is sent during the handshake. + * + * Uncomment to set the maximum plaintext size of the outgoing I/O buffer + * independently of the incoming I/O buffer. + */ +//#define MBEDTLS_SSL_OUT_CONTENT_LEN 16384 + +/** \def MBEDTLS_SSL_DTLS_MAX_BUFFERING + * + * Maximum number of heap-allocated bytes for the purpose of + * DTLS handshake message reassembly and future message buffering. + * + * This should be at least 9/8 * MBEDTLSSL_IN_CONTENT_LEN + * to account for a reassembled handshake message of maximum size, + * together with its reassembly bitmap. + * + * A value of 2 * MBEDTLS_SSL_IN_CONTENT_LEN (32768 by default) + * should be sufficient for all practical situations as it allows + * to reassembly a large handshake message (such as a certificate) + * while buffering multiple smaller handshake messages. + * + */ +//#define MBEDTLS_SSL_DTLS_MAX_BUFFERING 32768 + +//#define MBEDTLS_SSL_DEFAULT_TICKET_LIFETIME 86400 /**< Lifetime of session tickets (if enabled) */ +//#define MBEDTLS_PSK_MAX_LEN 32 /**< Max size of TLS pre-shared keys, in bytes (default 256 bits) */ +//#define MBEDTLS_SSL_COOKIE_TIMEOUT 60 /**< Default expiration delay of DTLS cookies, in seconds if HAVE_TIME, +// or in number of cookies issued */ + +/** + * Complete list of ciphersuites to use, in order of preference. + * + * \warning No dependency checking is done on that field! This option can only + * be used to restrict the set of available ciphersuites. It is your + * responsibility to make sure the needed modules are active. + * + * Use this to save a few hundred bytes of ROM (default ordering of all + * available ciphersuites) and a few to a few hundred bytes of RAM. + * + * The value below is only an example, not the default. + */ +//#define MBEDTLS_SSL_CIPHERSUITES +// MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384,MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256 + +/* X509 options */ +//#define MBEDTLS_X509_MAX_INTERMEDIATE_CA 8 /**< Maximum number of intermediate CAs in a verification chain. */ +//#define MBEDTLS_X509_MAX_FILE_PATH_LEN 512 /**< Maximum length of a path/filename string in bytes including the +// null terminator character ('\0'). */ + +/** + * Allow SHA-1 in the default TLS configuration for certificate signing. + * Without this build-time option, SHA-1 support must be activated explicitly + * through mbedtls_ssl_conf_cert_profile. Turning on this option is not + * recommended because of it is possible to generate SHA-1 collisions, however + * this may be safe for legacy infrastructure where additional controls apply. + * + * \warning SHA-1 is considered a weak message digest and its use constitutes + * a security risk. If possible, we recommend avoiding dependencies + * on it, and considering stronger message digests instead. + * + */ +//#define MBEDTLS_TLS_DEFAULT_ALLOW_SHA1_IN_CERTIFICATES + +/** + * Allow SHA-1 in the default TLS configuration for TLS 1.2 handshake + * signature and ciphersuite selection. Without this build-time option, SHA-1 + * support must be activated explicitly through mbedtls_ssl_conf_sig_hashes. + * The use of SHA-1 in TLS <= 1.1 and in HMAC-SHA-1 is always allowed by + * default. At the time of writing, there is no practical attack on the use + * of SHA-1 in handshake signatures, hence this option is turned on by default + * to preserve compatibility with existing peers, but the general + * warning applies nonetheless: + * + * \warning SHA-1 is considered a weak message digest and its use constitutes + * a security risk. If possible, we recommend avoiding dependencies + * on it, and considering stronger message digests instead. + * + */ +//#define MBEDTLS_TLS_DEFAULT_ALLOW_SHA1_IN_KEY_EXCHANGE + +/** + * Uncomment the macro to let mbed TLS use your alternate implementation of + * mbedtls_platform_zeroize(). This replaces the default implementation in + * platform_util.c. + * + * mbedtls_platform_zeroize() is a widely used function across the library to + * zero a block of memory. The implementation is expected to be secure in the + * sense that it has been written to prevent the compiler from removing calls + * to mbedtls_platform_zeroize() as part of redundant code elimination + * optimizations. However, it is difficult to guarantee that calls to + * mbedtls_platform_zeroize() will not be optimized by the compiler as older + * versions of the C language standards do not provide a secure implementation + * of memset(). Therefore, MBEDTLS_PLATFORM_ZEROIZE_ALT enables users to + * configure their own implementation of mbedtls_platform_zeroize(), for + * example by using directives specific to their compiler, features from newer + * C standards (e.g using memset_s() in C11) or calling a secure memset() from + * their system (e.g explicit_bzero() in BSD). + */ +//#define MBEDTLS_PLATFORM_ZEROIZE_ALT + +/** + * Uncomment the macro to let Mbed TLS use your alternate implementation of + * mbedtls_platform_gmtime_r(). This replaces the default implementation in + * platform_util.c. + * + * gmtime() is not a thread-safe function as defined in the C standard. The + * library will try to use safer implementations of this function, such as + * gmtime_r() when available. However, if Mbed TLS cannot identify the target + * system, the implementation of mbedtls_platform_gmtime_r() will default to + * using the standard gmtime(). In this case, calls from the library to + * gmtime() will be guarded by the global mutex mbedtls_threading_gmtime_mutex + * if MBEDTLS_THREADING_C is enabled. We recommend that calls from outside the + * library are also guarded with this mutex to avoid race conditions. However, + * if the macro MBEDTLS_PLATFORM_GMTIME_R_ALT is defined, Mbed TLS will + * unconditionally use the implementation for mbedtls_platform_gmtime_r() + * supplied at compile time. + */ +//#define MBEDTLS_PLATFORM_GMTIME_R_ALT + +/** + * Enable the verified implementations of ECDH primitives from Project Everest + * (currently only Curve25519). This feature changes the layout of ECDH + * contexts and therefore is a compatibility break for applications that access + * fields of a mbedtls_ecdh_context structure directly. See also + * MBEDTLS_ECDH_LEGACY_CONTEXT in include/mbedtls/ecdh.h. + */ +//#define MBEDTLS_ECDH_VARIANT_EVEREST_ENABLED + +#if defined(MBEDTLS_PSA_CRYPTO_CONFIG) +#include "mbedtls/config_psa.h" +#endif + +#include "mbedtls/check_config.h" + +#endif /* MBEDTLS_CONFIG_H */ diff --git a/config/openiotsdk/mbedtls/platform_alt.cpp b/config/openiotsdk/mbedtls/platform_alt.cpp new file mode 100644 index 00000000000000..803b5f50c4adc8 --- /dev/null +++ b/config/openiotsdk/mbedtls/platform_alt.cpp @@ -0,0 +1,72 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * This file provides the Mbedtls platform aternative implementation. + * It contains custom setup() and teardown() functions. + */ + +#include "mbedtls/platform.h" +#include "mbedtls/threading.h" + +#ifdef MBEDTLS_PLATFORM_SETUP_TEARDOWN_ALT + +#include + +#ifdef MBEDTLS_PLATFORM_NV_SEED_ALT +static int mbedtls_platform_nv_seed_read(unsigned char * buf, size_t buf_len) +{ + if (buf == NULL) + { + return (-1); + } + memset(buf, 0xA5, buf_len); + return 0; +} + +static int mbedtls_platform_nv_seed_write(unsigned char * buf, size_t buf_len) +{ + return 0; +} +#endif /* MBEDTLS_PLATFORM_NV_SEED_ALT */ + +int mbedtls_platform_setup(mbedtls_platform_context * ctx) +{ + (void) ctx; + int ret = 0; + +#ifdef MBEDTLS_PLATFORM_NV_SEED_ALT + ret = mbedtls_platform_set_nv_seed(mbedtls_platform_nv_seed_read, mbedtls_platform_nv_seed_write); + if (ret) + { + return ret; + } +#endif /* MBEDTLS_PLATFORM_NV_SEED_ALT */ +#ifdef MBEDTLS_THREADING_ALT + mbedtls_threading_set_cmsis_rtos(); +#endif /* MBEDTLS_THREADING_ALT */ + return ret; +} + +void mbedtls_platform_teardown(mbedtls_platform_context * ctx) +{ + (void) ctx; +} + +#endif /* MBEDTLS_PLATFORM_SETUP_TEARDOWN_ALT */ diff --git a/config/openiotsdk/mbedtls/platform_alt.h b/config/openiotsdk/mbedtls/platform_alt.h new file mode 100644 index 00000000000000..0b7d50bae5b1b7 --- /dev/null +++ b/config/openiotsdk/mbedtls/platform_alt.h @@ -0,0 +1,36 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * This file provides the Mbedtls platform aternative implementation. + * It contains custom setup() and teardown() functions. + */ + +#ifndef MBEDTLS_PLATFORM_ALT +#define MBEDTLS_PLATFORM_ALT + +/** + * \brief The dummy platform context structure. + */ +typedef struct mbedtls_platform_context +{ + char dummy; +} mbedtls_platform_context; + +#endif /* MBEDTLS_PLATFORM_ALT */ diff --git a/config/openiotsdk/mbedtls/threading_alt.h b/config/openiotsdk/mbedtls/threading_alt.h new file mode 100644 index 00000000000000..6d7af567793141 --- /dev/null +++ b/config/openiotsdk/mbedtls/threading_alt.h @@ -0,0 +1,30 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * This file provides the Mbedtls threading aternative implementation. + * It inludes the CMSIS-RTOS threading adaptation. + */ + +#ifndef MBEDTLS_THREADING_ALT_H +#define MBEDTLS_THREADING_ALT_H + +#include "mbedtls_threading_cmsis_rtos.h" + +#endif // ! MBEDTLS_THREADING_ALT_H diff --git a/config/openiotsdk/util.cmake b/config/openiotsdk/util.cmake new file mode 100644 index 00000000000000..23e0aabe662ee3 --- /dev/null +++ b/config/openiotsdk/util.cmake @@ -0,0 +1,152 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# +# @file +# CMake utilities for managing and retrieving build configuration +# + +# Get compilation flags for specific lang +# The flags might contains compile language generator expressions that +# look like this: +# $<$:-fno-exceptions> +# Applying a regex to extract the flag and also to find out if the language matches. +# [Args]: +# input - list of flags to parse +# output - list of flags set to specific language +function(get_flags_for_lang lang input output) + set(tmp_list "") + + list(LENGTH ${input} nb_elem) + set(index 0) + set(is_compile_lang_expression 0) + + while(${index} LESS ${nb_elem}) + list(GET ${input} ${index} value) + if(value MATCHES ":([^>]+)") + string(REGEX REPLACE "^[^:]*:" "" updated_flag ${value}) + list(APPEND tmp_list ${updated_flag}) + if(NOT value MATCHES ">$") + set(is_compile_lang_expression 1) + endif() + elseif(is_compile_lang_expression) + if(value MATCHES ">$") + set(is_compile_lang_expression 0) + endif() + string(REPLACE ">" "" updated_flag ${value}) + list(APPEND tmp_list ${updated_flag}) + endif() + math(EXPR index "${index}+1") + endwhile() + + set(${output} ${tmp_list} PARENT_SCOPE) +endfunction() + +# Get include directory of target build +# Get target property of includes directories +# For each flag add -I prefix and put it in quotation marks +# [Args]: +# target - target name +# output - output variable name +function(get_include_directories target output) + get_property(flags TARGET ${target} PROPERTY INTERFACE_INCLUDE_DIRECTORIES) + list(APPEND CFLAG_LIST) + foreach(flag ${flags}) + list(APPEND CFLAG_LIST "\"-isystem${flag}\"") + endforeach() + set(${output} ${CFLAG_LIST} PARENT_SCOPE) +endfunction() + +# Get compile definitions of target build +# Get target property of compile definitions +# For each flag change format, add -D prefix and put it in quotation marks +# [Args]: +# target - target name +# output - output variable name +function(get_compile_definitions target output) + get_property(flags TARGET ${target} PROPERTY INTERFACE_COMPILE_DEFINITIONS) + + list(APPEND CFLAG_LIST) + foreach(flag ${flags}) + # Replace each quote with a '\"' - format required for the GN arguments + string(REPLACE "\"" "\\\\\"" output_flag ${flag}) + list(APPEND CFLAG_LIST "\"-D${output_flag}\"") + endforeach() + set(${output} ${CFLAG_LIST} PARENT_SCOPE) +endfunction() + +# Get compile options of build for specific language +# Get property of compile options +# [Args]: +# lang - compilation languge (C, C++ or ASM) +# target - target name +# output - output variable name +function(get_compile_options_for_lang lang target output) + get_property(flags TARGET ${target} PROPERTY INTERFACE_COMPILE_OPTIONS) + get_flags_for_lang(${lang} flags output_list) + set(${output} ${output_list} PARENT_SCOPE) +endfunction() + + +# Retrieve common compilation flags specific for target +# [Args]: +# VAR - flags variable name +# TARGET - target name +function(get_target_common_compile_flags VAR TARGET) + get_include_directories(${TARGET} INCLUDES) + get_compile_definitions(${TARGET} DEFINES) + set(${VAR} ${INCLUDES} ${DEFINES} ${${VAR}} PARENT_SCOPE) +endfunction() + +# Retrieve target compiler flags for the specific language (C or CXX) +# [Args]: +# VAR - flags variable name +# TARGET - target name +# LANG - compilation languge (C, C++ or ASM) +function(get_lang_compile_flags VAR TARGET LANG) + get_compile_options_for_lang(${LANG} ${TARGET} FLAGS) + set(${VAR} ${FLAGS} ${${VAR}} PARENT_SCOPE) +endfunction() + +# Convert list of flags to string format +# [Args]: +# ptr_list_of_flags - list fo flags +# string_of_flags - output string +# separator - flags separator +function(convert_list_of_flags_to_string_of_flags ptr_list_of_flags string_of_flags separator) + # Convert the list to a string so we can do string replace + # operations on it and replace the ";" list separators with a + # desirable one so the flags are spaced out + string(REPLACE ";" ${separator} locally_scoped_string_of_flags "${${ptr_list_of_flags}}") + # Removing excess spaces + string(REPLACE " " " " locally_scoped_string_of_flags "${locally_scoped_string_of_flags}") + + # Set the output variable in the parent scope + set(${string_of_flags} ${locally_scoped_string_of_flags} PARENT_SCOPE) +endfunction() + + +function (get_all_cmake_targets out_var current_dir) + get_property(targets DIRECTORY ${current_dir} PROPERTY BUILDSYSTEM_TARGETS) + get_property(subdirs DIRECTORY ${current_dir} PROPERTY SUBDIRECTORIES) + + foreach(subdir ${subdirs}) + get_all_cmake_targets(subdir_targets ${subdir}) + list(APPEND targets ${subdir_targets}) + endforeach() + + set(${out_var} ${targets} PARENT_SCOPE) +endfunction() \ No newline at end of file diff --git a/config/telink/app/enable-gnu-std.cmake b/config/telink/app/enable-gnu-std.cmake index 38bacbea1ef791..e46c87199aad2d 100644 --- a/config/telink/app/enable-gnu-std.cmake +++ b/config/telink/app/enable-gnu-std.cmake @@ -15,5 +15,5 @@ # add_library(gnu17 INTERFACE) -target_compile_options(gnu17 INTERFACE -std=gnu++17 -D_SYS__PTHREADTYPES_H_) +target_compile_options(gnu17 INTERFACE $<$:-std=gnu++17> -D_SYS__PTHREADTYPES_H_) target_link_libraries(app PRIVATE gnu17) \ No newline at end of file diff --git a/config/telink/app/zephyr.conf b/config/telink/app/zephyr.conf index c83f5aeccca9c4..3721da9a8fa052 100644 --- a/config/telink/app/zephyr.conf +++ b/config/telink/app/zephyr.conf @@ -15,7 +15,6 @@ # CONFIG_CHIP=y - CONFIG_STD_CPP14=y # Logging @@ -24,13 +23,31 @@ CONFIG_LOG_MODE_MINIMAL=y CONFIG_PRINTK=y CONFIG_ASSERT=y CONFIG_CBPRINTF_LIBC_SUBSTS=y -CONFIG_MATTER_LOG_LEVEL_DBG=y + +# Setting the INFO log level +CONFIG_LOG_DEFAULT_LEVEL=2 +CONFIG_MATTER_LOG_LEVEL_INF=y +CONFIG_MCUBOOT_UTIL_LOG_LEVEL_INF=y +CONFIG_IEEE802154_DRIVER_LOG_LEVEL_INF=y +CONFIG_NVS_LOG_LEVEL_INF=y +CONFIG_OPENTHREAD_LOG_LEVEL_INFO=y +CONFIG_OPENTHREAD_L2_LOG_LEVEL_INF=y + +# Setting the DEBUG log level (Uncomment for set the log level) +# CONFIG_LOG_DEFAULT_LEVEL=4 +# CONFIG_MATTER_LOG_LEVEL_DBG=y +# CONFIG_MCUBOOT_UTIL_LOG_LEVEL_DBG=y +# CONFIG_IEEE802154_DRIVER_LOG_LEVEL_DBG=y +# CONFIG_NVS_LOG_LEVEL_DBG=y +# CONFIG_OPENTHREAD_LOG_LEVEL_DEBG=y +# CONFIG_OPENTHREAD_L2_LOG_LEVEL_DBG=y # Generic networking options CONFIG_NETWORKING=y CONFIG_NET_CONFIG_SETTINGS=y CONFIG_NET_SOCKETS=y CONFIG_NET_SOCKETS_POSIX_NAMES=n +CONFIG_NET_CONFIG_INIT_TIMEOUT=0 # Disable TCP and IPv4 (TCP disabled to avoid heavy traffic) CONFIG_NET_TCP=n @@ -58,15 +75,22 @@ CONFIG_NET_BUF_RX_COUNT=32 CONFIG_NET_BUF_TX_COUNT=32 # Bluetooth Low Energy configs -CONFIG_BT=n +CONFIG_BT=y +CONFIG_BT_DEBUG_LOG=n +CONFIG_BT_PERIPHERAL=y +CONFIG_BT_MAX_CONN=1 +CONFIG_BT_DEVICE_NAME_DYNAMIC=y +CONFIG_BT_GATT_DYNAMIC_DB=y +# CONFIG_BT_DEVICE_NAME_MAX=15 +CONFIG_BT_L2CAP_TX_MTU=247 +CONFIG_BT_BUF_ACL_RX_SIZE=251 +CONFIG_BT_BUF_ACL_TX_SIZE=251 # L2 OpenThread enabling CONFIG_NET_L2_OPENTHREAD=y CONFIG_OPENTHREAD_DEBUG=y CONFIG_OPENTHREAD_L2_DEBUG=y -CONFIG_OPENTHREAD_L2_LOG_LEVEL_INF=y -CONFIG_NET_CONFIG_IEEE802154_DEV_NAME="IEEE802154_b91" CONFIG_NET_CONFIG_MY_IPV6_ADDR="fdde:ad00:beef::1" CONFIG_NET_CONFIG_PEER_IPV6_ADDR="fdde:ad00:beef::2" @@ -79,7 +103,6 @@ CONFIG_OPENTHREAD_MTD_NETDIAG=y CONFIG_OPENTHREAD_ENABLE_SERVICE=y CONFIG_OPENTHREAD_MANUAL_START=y CONFIG_OPENTHREAD_THREAD_STACK_SIZE=6144 -CONFIG_OPENTHREAD_LOG_LEVEL_DEBG=y # Enable Thread 1.2 features CONFIG_OPENTHREAD_THREAD_VERSION_1_2=y @@ -96,9 +119,6 @@ CONFIG_MBEDTLS_USER_CONFIG_FILE="telink-mbedtls-config.h" CONFIG_MBEDTLS_HEAP_SIZE=0 CONFIG_OPENTHREAD_EXTERNAL_HEAP=y -# Switch on Telink SDK -CONFIG_TELINK_BLE_LIB=y - # Config dynamic interrupts to have posibility to switch between BLE/Thread radio drivers CONFIG_DYNAMIC_INTERRUPTS=y @@ -106,5 +126,9 @@ CONFIG_DYNAMIC_INTERRUPTS=y # nvs_sector_size = flash_page_size * mult = 256 * 8 = 2048 CONFIG_SETTINGS_NVS_SECTOR_SIZE_MULT=8 -# Shall settings -CONFIG_SHELL_BACKEND_SERIAL_RX_RING_BUFFER_SIZE=255 \ No newline at end of file +# Shell settings +CONFIG_SHELL=n +CONFIG_SHELL_BACKEND_SERIAL_RX_RING_BUFFER_SIZE=255 + +# Legacy +CONFIG_LEGACY_INCLUDE_PATH=y diff --git a/config/telink/chip-gn/BUILD.gn b/config/telink/chip-gn/BUILD.gn index 0d95e8a18e88a8..784c4ceab2563b 100644 --- a/config/telink/chip-gn/BUILD.gn +++ b/config/telink/chip-gn/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021 Project CHIP Authors +# Copyright (c) 2022 Project CHIP Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -14,9 +14,8 @@ import("//build_overrides/build.gni") import("//build_overrides/chip.gni") -import("//build_overrides/telink.gni") -import("${build_root}/chip/tests.gni") +import("${chip_root}/build/chip/tests.gni") assert(current_os == "zephyr") @@ -24,15 +23,8 @@ declare_args() { chip_build_example_providers = false } -declare_args() { - chip_build_pw_rpc_lib = false -} - group("telink") { - deps = [ - "${chip_root}/src/lib", - "${telink_sdk_build_root}", - ] + deps = [ "${chip_root}/src/lib" ] if (chip_build_tests) { deps += [ "${chip_root}/src:tests" ] diff --git a/config/telink/chip-gn/args.gni b/config/telink/chip-gn/args.gni index 713a3fd231c159..a84cc321a4bb88 100644 --- a/config/telink/chip-gn/args.gni +++ b/config/telink/chip-gn/args.gni @@ -14,6 +14,8 @@ import("//build_overrides/chip.gni") +import("${chip_root}/src/crypto/crypto.gni") + chip_device_platform = "telink" chip_build_tests = false @@ -22,6 +24,9 @@ chip_project_config_include = "" chip_system_project_config_include = "" chip_ble_project_config_include = "" +chip_crypto = "mbedtls" +chip_external_mbedtls = true + custom_toolchain = "${chip_root}/config/telink/chip-gn/toolchain:zephyr" pw_build_PIP_CONSTRAINTS = [ "${chip_root}/scripts/constraints.txt" ] diff --git a/config/telink/chip-module/CMakeLists.txt b/config/telink/chip-module/CMakeLists.txt index 6ef6ac2c882238..6113325da57f95 100644 --- a/config/telink/chip-module/CMakeLists.txt +++ b/config/telink/chip-module/CMakeLists.txt @@ -91,6 +91,7 @@ macro(chip_gn_arg ARG VALUE) string(APPEND CHIP_GN_ARGS "--arg\n${ARG}\n${VALUE}\n") endmacro() + # ============================================================================== # Prepare CHIP configuration based on the project Kconfig configuration # ============================================================================== @@ -128,14 +129,6 @@ if (CONFIG_CHIP_LIB_SHELL) list(APPEND CHIP_LIBRARIES -lCHIPShell) endif() -if (CONFIG_CHIP_PW_RPC) - list(APPEND CHIP_LIBRARIES -lPwRpc) -endif() - -if (CONFIG_TELINK_BLE_LIB) - list(APPEND CHIP_LIBRARIES -lB91_ble_lib) -endif() - # Set up CHIP project configuration file if (CONFIG_CHIP_PROJECT_CONFIG) @@ -200,6 +193,7 @@ chip_gn_arg_string("zephyr_cxx" ${CMAKE_CXX_COMPILER chip_gn_arg_bool ("is_debug" CONFIG_DEBUG) chip_gn_arg_bool ("chip_enable_openthread" CONFIG_NET_L2_OPENTHREAD) chip_gn_arg_bool ("chip_openthread_ftd" CONFIG_OPENTHREAD_FTD) +chip_gn_arg_bool ("chip_config_network_layer_ble" CONFIG_BT) chip_gn_arg_bool ("chip_inet_config_enable_ipv4" CONFIG_NET_IPV4) chip_gn_arg_bool ("chip_enable_ota_requestor" CONFIG_CHIP_OTA_REQUESTOR) chip_gn_arg_bool ("chip_build_tests" CONFIG_CHIP_BUILD_TESTS) @@ -226,6 +220,14 @@ if (CHIP_PROJECT_CONFIG) chip_gn_arg_string("chip_project_config_include" ${CHIP_PROJECT_CONFIG}) chip_gn_arg_string("chip_system_project_config_include" ${CHIP_PROJECT_CONFIG}) endif() + +if (CONFIG_CHIP_PW_RPC) + set(PIGWEED_DIR "//third_party/pigweed/repo") + chip_gn_arg_string("pw_assert_BACKEND" ${PIGWEED_DIR}/pw_assert_log:check_backend) + chip_gn_arg_string("pw_log_BACKEND" ${PIGWEED_DIR}/pw_log_basic) + chip_gn_arg("pw_build_LINK_DEPS" [\"${PIGWEED_DIR}/pw_assert:impl\",\ \"${PIGWEED_DIR}/pw_log:impl\"]) +endif() + if (CONFIG_CHIP_EXAMPLE_DEVICE_INFO_PROVIDER) chip_gn_arg_bool("chip_build_example_providers" "true") list(APPEND CHIP_LIBRARIES -lMatterDeviceInfoProviderExample) @@ -271,7 +273,8 @@ target_include_directories(chip INTERFACE ${CHIP_ROOT}/src/include ${CHIP_ROOT}/src/lib ${CHIP_ROOT}/third_party/nlassert/repo/include - ${CHIP_ROOT}/third_party/telink_sdk + ${CHIP_ROOT}/third_party/nlio/repo/include + ${CHIP_ROOT}/zzz_generated/app-common ${CMAKE_CURRENT_BINARY_DIR}/gen/include ) target_link_directories(chip INTERFACE ${CMAKE_CURRENT_BINARY_DIR}/lib) @@ -283,10 +286,6 @@ if (CONFIG_CHIP_EXAMPLE_DEVICE_INFO_PROVIDER) target_include_directories(chip INTERFACE ${CHIP_ROOT}/examples/providers) endif() -if (CONFIG_TELINK_BLE_LIB) - target_link_directories(chip INTERFACE ${CHIP_ROOT}/third_party/telink_sdk/repo/eagle_ble_sdk/proj_lib) -endif() - target_link_libraries(chip INTERFACE -Wl,--start-group ${CHIP_LIBRARIES} -Wl,--end-group) add_dependencies(chip chip-gn) @@ -304,13 +303,15 @@ if (CONFIG_CHIP_OTA_IMAGE_BUILD) add_custom_target(west_sign ALL COMMAND west sign -t imgtool -p ${ZEPHYR_BASE}/../bootloader/mcuboot/scripts/imgtool.py -d ${PROJECT_BINARY_DIR}/.. -- --key ${ZEPHYR_BASE}/../bootloader/mcuboot/root-rsa-2048.pem + BYPRODUCTS + ${PROJECT_BINARY_DIR}/zephyr.signed.bin ) add_custom_target(merge_mcuboot ALL COMMAND dd if=${PROJECT_BINARY_DIR}/../modules/chip-module/build_mcuboot/zephyr/zephyr.bin of=${PROJECT_BINARY_DIR}/zephyr.bin COMMAND - dd if=${PROJECT_BINARY_DIR}/zephyr.signed.bin of=${PROJECT_BINARY_DIR}/zephyr.bin bs=1024 seek=64 + dd if=${PROJECT_BINARY_DIR}/zephyr.signed.bin of=${PROJECT_BINARY_DIR}/zephyr.bin bs=1024 seek=96 ) chip_ota_image(chip-ota-image @@ -326,7 +327,7 @@ endif() if (CONFIG_CHIP_FACTORY_DATA_MERGE_WITH_FIRMWARE) add_custom_target(merge_factory_data ALL COMMAND - dd if=${PROJECT_BINARY_DIR}/factory_data.bin of=${PROJECT_BINARY_DIR}/zephyr.bin bs=1024 seek=976 + dd if=${PROJECT_BINARY_DIR}/factory_data.bin of=${PROJECT_BINARY_DIR}/zephyr.bin bs=1024 seek=2000 ) if (CONFIG_CHIP_OTA_IMAGE_BUILD) add_dependencies(merge_factory_data merge_mcuboot) diff --git a/config/telink/chip-module/Kconfig b/config/telink/chip-module/Kconfig index f216280df7e583..db442126a2c14e 100644 --- a/config/telink/chip-module/Kconfig +++ b/config/telink/chip-module/Kconfig @@ -16,12 +16,6 @@ rsource "../../zephyr/Kconfig" -config TELINK_BLE_LIB - bool "Include third party Telink BLE SDK" - default n - help - Include third party Telink BLE SDK - # See config/zephyr/Kconfig for full definition config CHIP_OTA_REQUESTOR bool diff --git a/config/telink/chip-module/generate_factory_data.cmake b/config/telink/chip-module/generate_factory_data.cmake index 72d99e450bbf2c..a1c9f0ef9780a0 100644 --- a/config/telink/chip-module/generate_factory_data.cmake +++ b/config/telink/chip-module/generate_factory_data.cmake @@ -140,7 +140,7 @@ function(telink_create_factory_data_hex_file factory_data_hex_target factory_dat set(cbor_script_args "-i ${output_path}/${factory_data_target}.json\n") string(APPEND cbor_script_args "-o ${output_path}/${factory_data_target}\n") # get partition address and offset from partition manager during compilation -string(APPEND cbor_script_args "--offset 0xf4000\n") +string(APPEND cbor_script_args "--offset 0x1f4000\n") string(APPEND cbor_script_args "--size 0x1000\n") string(APPEND cbor_script_args "-r\n") diff --git a/config/zephyr/chip-gn/args.gni b/config/zephyr/chip-gn/args.gni index e5d5aedf5bc17d..1421e79aa80edd 100644 --- a/config/zephyr/chip-gn/args.gni +++ b/config/zephyr/chip-gn/args.gni @@ -14,6 +14,8 @@ import("//build_overrides/chip.gni") +import("${chip_root}/src/crypto/crypto.gni") + chip_device_platform = "zephyr" chip_build_tests = false @@ -22,6 +24,9 @@ chip_project_config_include = "" chip_system_project_config_include = "" chip_ble_project_config_include = "" +chip_crypto = "mbedtls" +chip_external_mbedtls = true + custom_toolchain = "${chip_root}/config/zephyr/chip-gn/toolchain:zephyr" pw_build_PIP_CONSTRAINTS = [ "${chip_root}/scripts/constraints.txt" ] diff --git a/config/zephyr/ota-image.cmake b/config/zephyr/ota-image.cmake index 568cbd19faa9f6..bd7735648f8302 100644 --- a/config/zephyr/ota-image.cmake +++ b/config/zephyr/ota-image.cmake @@ -18,9 +18,10 @@ find_package(Python3 REQUIRED) # # Create CMake target for building Matter OTA (Over-the-air update) image. +# # Required arguments: -# INPUT_FILES file1, [file2...] - binary files which Matter OTA image will be composed of -# OUTPUT_FILE file - where to store newly created Matter OTA image +# INPUT_FILES file1[, file2...] Binary files to be included in Matter OTA image +# OUTPUT_FILE file Location of generated Matter OTA image # function(chip_ota_image TARGET_NAME) cmake_parse_arguments(ARG "" "OUTPUT_FILE" "INPUT_FILES" ${ARGN}) @@ -58,7 +59,12 @@ function(chip_ota_image TARGET_NAME) CONTENT ${OTA_ARGS} ) - add_custom_target(${TARGET_NAME} ALL + add_custom_command(OUTPUT ${ARG_OUTPUT_FILE} COMMAND ${Python3_EXECUTABLE} ${CHIP_ROOT}/src/app/ota_image_tool.py create @${ARG_OUTPUT_FILE}.args + DEPENDS ${ARG_INPUT_FILES} ${CHIP_ROOT}/src/app/ota_image_tool.py + ) + + add_custom_target(${TARGET_NAME} ALL + DEPENDS ${ARG_OUTPUT_FILE} ) endfunction() diff --git a/config/zephyr/zephyr-util.cmake b/config/zephyr/zephyr-util.cmake index bab824dc0529d5..0d634914ee73fb 100644 --- a/config/zephyr/zephyr-util.cmake +++ b/config/zephyr/zephyr-util.cmake @@ -19,13 +19,16 @@ # CMake utilities for managing and retrieving Zephyr build configuration # -# Retrieve Zephyr compiler flags for the given language (C or CXX) +# +# Retrieve Zephyr compiler flags for the given language. +# +# Arguments: +# VAR Name of list variable in the parent scope to be appended with the result +# LANG Programming language: C or CXX +# function(zephyr_get_compile_flags VAR LANG) - # We want to treat all zephyr-provided headers as system headers, so - # warnings in them don't trigger -Werror. That means that for the headers - # zephyr returns as "non-system" headers (the ones from - # zephyr_get_include_directories_for_lang) we need to manually replace "-I" - # with "-isystem". + # Replace "-I" with "-isystem" to treat all Zephyr headers as system headers + # that do not trigger -Werror. zephyr_get_include_directories_for_lang_as_string(${LANG} INCLUDES) string(REGEX REPLACE "(^| )-I" "\\1-isystem" INCLUDES ${INCLUDES}) zephyr_get_system_include_directories_for_lang_as_string(${LANG} SYSTEM_INCLUDES) @@ -34,14 +37,12 @@ function(zephyr_get_compile_flags VAR LANG) set(${VAR} ${INCLUDES} ${SYSTEM_INCLUDES} ${DEFINES} ${FLAGS} ${${VAR}} PARENT_SCOPE) endfunction() -# Add include directories to the zephyr interface target. -# It works like zephyr_include_directories(), doesn't prepend the directories with -# the current directory. Hence it works correctly with generator expressions, too. -function(zephyr_include_directories_raw) - target_include_directories(zephyr_interface INTERFACE ${ARGN}) -endfunction() - -# Select gnu++ standard based on Kconfig configuration +# +# Select gnu++ standard matching C++ standard configured via Kconfig. +# +# Arguments: +# VAR Name of list variable to be appended with the selected "-std=gnu++" flag +# macro(zephyr_get_gnu_cpp_standard VAR) if (CONFIG_STD_CPP11) list(APPEND ${VAR} -std=gnu++11) @@ -67,11 +68,16 @@ function(zephyr_set_openthread_config_impl OT_DIR CONFIG_FILE) set_property(DIRECTORY ${OT_DIR} PROPERTY COMPILE_DEFINITIONS ${DEFINES}) foreach(SUBDIR ${SUBDIRS}) - zephyr_set_openthread_config_impl(${SUBDIR} ${CONFIG_FILE}) + zephyr_set_openthread_config_impl(${SUBDIR} ${CONFIG_FILE}) endforeach() endfunction() -# Replace Zephyr-supplied configuration file with a custom one +# +# Replace Zephyr-supplied configuration file with a custom one. +# +# Arguments: +# CONFIG_PATH Path to OpenThread configuration file +# function(zephyr_set_openthread_config CONFIG_PATH) get_filename_component(CONFIG_DIR ${CONFIG_PATH} DIRECTORY) get_filename_component(CONFIG_FILE ${CONFIG_PATH} NAME) diff --git a/docs/code_generation.md b/docs/code_generation.md index 51a615f9872a9e..7deed7ba05fb1a 100644 --- a/docs/code_generation.md +++ b/docs/code_generation.md @@ -170,18 +170,39 @@ Additionally, individual code regeneration can be done using `./scripts/tools/zap/generate.py`: ```bash -/scripts/tools/zap/generate.py examples/bridge-app/bridge-common/bridge-app.zap -o zzz_generated/bridge-app/zap-g -enerated +/scripts/tools/zap/generate.py \ + examples/bridge-app/bridge-common/bridge-app.zap \ + -o zzz_generated/bridge-app/zap-generated ``` ### `*.matter` code generation -Currently `*.matter` code generation is done at compile time. +`*.matter` code generation can be done either at compile time or it can use +pre-generated output. Rules for how `codegen.py` is invoked and how includes/sources are set are defined at: - `src/app/chip_data_model.cmake` -- `build/chip/esp32/esp32_codegen.cmake` (support for 2-pass cmake builds used - by the Espressif `idf.py` build system) - `src/app/chip_data_model.gni` + +Additionally, `build/chip/esp32/esp32_codegen.cmake` adds processing support for +the 2-pass cmake builds used by the Espressif `idf.py` build system. + +## Pre-generation + +Code pre-generation can be used: + +- when compile-time code generation is not desirable. This may be for + importing into build systems that do not have the pre-requisites to run code + generation at build time or to save the code generation time at the expense + of running code generation for every possible zap/generation type +- To check changes in generated code across versions, beyond the comparisons + of golden image tests in `scripts/idl/tests` + +The script to trigger code pre-generation is `scripts/code_pregenerate.py` and +requires the pre-generation output directory as an argument + +```bash +scripts/code_pregenerate.py ${OUTPUT_DIRECTORY:-./zzz_pregenerated/} +``` diff --git a/docs/examples/openiotsdk_examples.md b/docs/examples/openiotsdk_examples.md new file mode 100644 index 00000000000000..41e8c88152b7e8 --- /dev/null +++ b/docs/examples/openiotsdk_examples.md @@ -0,0 +1,258 @@ +# Matter Open IoT SDK Example Application + +These examples are built using +[Open IoT SDK](https://gitlab.arm.com/iot/open-iot-sdk) and runs inside an +emulated target through the +[Arm FVP model for the Corstone-300 MPS3](https://developer.arm.com/downloads/-/arm-ecosystem-fvps). + +You can use these example as a reference for creating your own applications. + +## Environment setup + +Before building the examples, check out the Matter repository and sync +submodules using the following command: + +``` +$ git submodule update --init +``` + +The VSCode devcontainer has all dependencies pre-installed. Using the VSCode +devcontainer is the recommended way to interact with Open IoT SDK port of the +Matter Project. Please read this +[README.md](../../..//docs/VSCODE_DEVELOPMENT.md) for more information. + +### Networking setup + +Running ARM Fast Model with TAP/TUN device networking mode requires setup proper +network interfaces. Special scripts were designed to make setup easy. In +`scripts/setup/openiotsdk` directory you can find: + +- **network_setup.sh** - script to create the specific network namespace and + Virtual Ethernet interface to connect with host network. Both host and + namespace sides have linked IP addresses. Inside the network namespace the + TAP device interface is created and bridged with Virtual Ethernet peer. + There is also option to enable Internet connection in namespace by + forwarding traffic to host default interface. + + To enable Open IoT SDK networking environment: + + ``` + ${MATTER_ROOT}/scripts/setup/openiotsdk/network_setup.sh up + ``` + + To disable Open IoT SDK networking environment: + + ``` + ${MATTER_ROOT}/scripts/setup/openiotsdk/network_setup.sh down + ``` + + Use `--help` to get more information about the script options. + +- **connect_if.sh** - script that connects specified network interfaces with + the default route interface. It creates a bridge and links all interfaces to + it. The bridge becomes the default interface. + + Example: + + ``` + ${MATTER_ROOT}/scripts/setup/openiotsdk/connect_if.sh ARMhveth + ``` + + Use `--help` to get more information about the script options. + +Open IoT SDK network setup scripts contain commands that require root +permissions. Use `sudo` to run the scripts in user account with root privileges. + +After setting up the Open IoT SDK network environment the user will be able to +run Matter examples on `FVP` in an isolated network namespace in TAP device +mode. + +To execute a command in a specific network namespace use the helper script +`scripts/run_in_ns.sh`. + +Example: + +``` +${MATTER_ROOT}/scripts/run_in_ns.sh ARMns +``` + +Use `--help` to get more information about the script options. + +**NOTE** + +For Docker environment users it's recommended to use the +[default bridge network](https://docs.docker.com/network/bridge/#use-the-default-bridge-network) +for a running container. This guarantees full isolation of the Open IoT SDK +network from host settings. + +### Debugging setup + +Debugging Matter application running on `FVP` model requires GDB Remote +Connection Plugin for Fast Model. More details +[GDBRemoteConnection](https://developer.arm.com/documentation/100964/1116/Plug-ins-for-Fast-Models/GDBRemoteConnection). + +The Third-Party IP add-on package can be downloaded from ARM developer website +[Fast models](https://developer.arm.com/downloads/-/fast-models). Currently +required version is `11.16`. + +To install Fast Model Third-Party IP package: + +- unpack the installation package in a temporary location +- execute the command `./setup.bin` (Linux) or `Setup.exe` (Windows), and + follow the installation instructions. + +After installation the GDB Remote Connection Plugin should be visible in +`FastModelsPortfolio_11.16/plugins` directory. + +Then add the GDB plugin to your development environment: + +- host environment - add GDB plugin path to environment variable as + FAST_MODEL_PLUGINS_PATH. + + Example + + ``` + export FAST_MODEL_PLUGINS_PATH=/opt/FastModelsPortfolio_11.16/plugins/Linux64_GCC-9.3 + ``` + +- Docker container environment - mount the Fast Model Third-Party IP directory + into the `/opt/FastModelsPortfolio_11.16` directory in container. + + The Vscode devcontainer users should add a volume bound to this directory + [Add local file mount](https://code.visualstudio.com/remote/advancedcontainers/add-local-file-mount). + + You can edit the `.devcontainer/devcontainer.json` file, for example: + + ``` + ... + "mounts": [ + ... + "source=/opt/FastModelsPortfolio_11.16,target=/opt/FastModelsPortfolio_11.16,type=bind,consistency=cached" + ... + ], + ... + ``` + + In this case, the FAST MODEL PLUGINS PATH environment variable is already + created. + + If you launch the Docker container directly from CLI, use the above + arguments with `docker run` command. Remember add GDB plugin path to + environment variable as FAST_MODEL_PLUGINS_PATH inside container. + +## Building + +You build using a vscode task or call the script directly from the command line. + +### Building using vscode task + +``` +Command Palette (F1) => Run Task... => Build Open IoT SDK example => (debug on/off) => +``` + +This will call the scripts with the selected parameters. + +### Building using CLI + +You can call the script directly yourself. + +``` +${MATTER_ROOT}/scripts/examples/openiotsdk_example.sh +``` + +Use `--help` to get more information about the script options. + +## Running + +The application runs in the background and opens a telnet session. The script +will open telnet for you and connect to the port used by the `FVP`. When the +telnet process is terminated it will also terminate the `FVP` instance. + +You can run the application script from a vscode task or call the script +directly. + +### Running using vscode task + +``` +Command Palette (F1) => Run Task... => Run Open IoT SDK example => (network namespace) => (network interface) => +``` + +This will call the scripts with the selected example name. + +### Running using CLI + +You can call the script directly yourself. + +``` +${MATTER_ROOT}/scripts/examples/openiotsdk_example.sh -C run +``` + +Run example in specific network namespace with TAP device mode: + +``` +${MATTER_ROOT}/scripts/run_in_ns.sh ARMns ${MATTER_ROOT}/scripts/examples/openiotsdk_example.sh -C run -n ARMtap +``` + +### Commissioning + +Once booted the application can be commissioned, please refer to +[docs/guides/openiotsdk_commissioning.md](/../guides/openiotsdk_commissioning.md) +for further instructions. + +## Testing + +Run the Pytest integration test for specific application. + +The test result can be found in +`src/test_driver/openiotsdk/integration-tests//test_report.json` +file. + +You run testing using a vscode task or call the script directly from the command +line. + +### Testing using vscode task + +``` +Command Palette (F1) => Run Task... => Test Open IoT SDK example => (network namespace) => (network interface) => +``` + +This will call the scripts with the selected example name. + +### Testing using CLI + +You can call the script directly yourself. + +``` +${MATTER_ROOT}/scripts/examples/openiotsdk_example.sh -C test +``` + +Test example in specific network namespace with TAP device mode: + +``` +${MATTER_ROOT}/scripts/run_in_ns.sh ARMns ${MATTER_ROOT}/scripts/examples/openiotsdk_example.sh -C test -n ARMtap +``` + +## Debugging + +Debugging can be started using a VS code launch task: + +``` +Run and Debug (Ctrl+Shift+D) => Debug Open IoT SDK example application => Start +Debugging (F5) => => (GDB target address) => (network namespace) => (network interface) => +``` + +For debugging remote targets (i.e. run in other network namespaces) you need to +pass hostname/IP address of external GDB target that you want to connect to +(_GDB target address_). In case of using the +[Open IoT SDK network environment](#networking-setup) the GDB server runs inside +a namespace and has the same IP address as bridge interface. + +``` +${MATTER_ROOT}/scripts/run_in_ns.sh ifconfig +``` + +**NOTE** + +As you can see above, you will need to select the name of the example twice. +This is because the debug task needs to launch the run task and currently VS +code has no way of passing parameters between tasks. diff --git a/docs/guides/nrfconnect_factory_data_configuration.md b/docs/guides/nrfconnect_factory_data_configuration.md index 071fc69ed9a02e..c05b5a61ebaa16 100644 --- a/docs/guides/nrfconnect_factory_data_configuration.md +++ b/docs/guides/nrfconnect_factory_data_configuration.md @@ -386,9 +386,27 @@ window indicates the validation status. #### Option 3: Using the nRF Connect Python script You can have the JSON file checked automatically by the Python script during the -file generation. For this to happen, provide the path to the JSON schema file as -an additional argument, which should replace the __ variable in -the following command: +file generation. For this to happen, you must install the `jsonschema` Python +module in your Python environment and provide the path to the JSON schema file +as an additional argument. To do this, complete the following steps: + +1. Install the `jsonschema` Python module by invoking one of the following + commands from the Matter root directory: + + - Install only the `jsonschema` module: + + ``` + $ python -m pip install jsonschema + ``` + + - Install the `jsonschema` module together with all dependencies for Matter: + + ``` + $ python -m pip install -r ./scripts/requirements.nrfconnect.txt + ``` + +2. Run the following command (remember to replace the __ + variable): ``` $ python generate_nrfconnect_chip_factory_data.py --schema diff --git a/docs/guides/openiotsdk_commissioning.md b/docs/guides/openiotsdk_commissioning.md new file mode 100644 index 00000000000000..596184fd27a961 --- /dev/null +++ b/docs/guides/openiotsdk_commissioning.md @@ -0,0 +1,47 @@ +# Commissioning Open IoT SDK devices + +Matter devices based on Open IoT SDK reset into a ready for commissioning state. +This allows a controller to connect to them and set configuration options before +the device becomes available on the Matter network. + +Open IoT SDK Matter devices, due to the connectivity setup, start already +connected to the IP network and do not require credentials provisioning. + +## Building and installing the Python Device Controller + +To make provisioning possible and to control the Matter device with a Python +application, you can build and run the Python controller application. Please +read the guide +[Python Device Controller guide](python_chip_controller_building.md) for further +instructions. + +## Device commissioning + +Run chip-device-ctrl and use the interactive prompt to commission the device. + +After the device boots, it's in ready for commissioning mode and starts the mDNS +advertisement. This can be discovered by the controller using: + +``` +discover -all +``` + +This will list the devices and their addresses. To commission the device use: + +``` +connect -ip
[] +``` + +The setup pin code is printed in the log of the device. The `` can be +chosen by the user, if left blank it will be automatically picked. + +## Sending ZCL commands + +If the commissioning process was successful, it is possible to send a ZCL +command to the device which initiates a certain action. + +`zcl [arguments]` + +Example: + + chip-device-ctrl > zcl LevelControl MoveWithOnOff 12344321 1 0 moveMode=1 rate=2 diff --git a/docs/guides/openiotsdk_platform_overview.md b/docs/guides/openiotsdk_platform_overview.md new file mode 100644 index 00000000000000..2c4d04754dcc4a --- /dev/null +++ b/docs/guides/openiotsdk_platform_overview.md @@ -0,0 +1,95 @@ +# Open IoT SDK platform port + +This platform is based on +[Open IoT SDK](https://gitlab.arm.com/iot/open-iot-sdk). Open IoT SDK is a +reference implementation of [Open-CMSIS-CDI](https://www.open-cmsis-cdi.org/) +which defines a common device interface for microcontroller-based devices used +in the Internet of Things. It is delivered as a framework of software components +with a set of feature-rich example applications. + +## Building + +Open IoT SDK uses CMake as its build system. To integrate with Matter's GN build +system our top level CMakeLists.txt generates GN configuration files that pass +on the required configs required by the GN build. + +## Targets + +Supported targets are the ones supported by the Open IoT SDK. Currently it ships +with support for +[Corstone-300](https://developer.arm.com/Processors/Corstone-300) and +[Corstone-310](https://developer.arm.com/Processors/Corstone-310). This platform +makes no assumption on the target and will support any targets added to Open IoT +SDK. + +## Fast model network + +The fast models of supported platforms have two network modes: + +- user mode networking - emulates a built-in IP router and DHCP server, and + routes TCP and UDP traffic between the guest and host. It uses the user mode + socket layer of the host to communicate with other hosts. See more details: + [User mode networking](https://developer.arm.com/documentation/100964/1116/Introduction-to-the-Fast-Models-Reference-Manual/User-mode-networking) + +- TAP/TUN networking mode - set fast model to host bridge component which acts + as a networking gateway to exchange Ethernet packets with the TAP device on + the host, and to forward packets to model. See more details + [TAP/TUN networking mode](https://developer.arm.com/documentation/100964/1116/Introduction-to-the-Fast-Models-Reference-Manual/TAP-TUN-networking) + +Due the user mode limitations, the **TAP/TUN networking mode** is preferred for +implementing IP communication for a Matter project. + +## RTOS + +Open IoT SDK uses +[CMSIS-RTOS2 API](https://www.keil.com/pack/doc/cmsis/RTOS2/html/group__CMSIS__RTOS.html) +as its RTOS API. It offers the choice of implementation between FreeRTOS or +CMSIS RTX but this is hidden below the API so your choice has no bearing on this +port and indeed your application may provide your own implementation entirely. + +## Connectivity + +The platform currently only offers connectivity through the Ethernet interface. +This is limited by current support for network interfaces in Open IoT SDK. + +This means that commissioning is simplified since no provisioning is required to +provide the device with network credentials. + +LWIP is used in the implementation of endpoints as the IP stack. LWIP library is +provided through the Open IoT SDK. + +## Mbed TLS + +Mbed TLS is provided through the Open IoT SDK, the Matter version is not used. +Configuration of Mbed TLS is in +[config/openiotsdk/mbedtls](../../config/openiotsdk/mbedtls). + +## Storage + +Storage in Open IoT SDK is provided by +[TDBStore](https://gitlab.arm.com/iot/open-iot-sdk/storage) which is a simple +Key-Value Storage over a block device. + +--- + +**NOTE** + +On the Corstone targets this currently is implemented as a RAM memory region +emulating a Flash device. This does not offer persistence between launches. + +--- + +## Clocks + +Open IoT SDK does not currently offer an RTC. Matter configuration has been set +accordingly and real time cannot be read from the system. + +Monotonic clocks are available and are based on system tick count. They are +limited by the target configuration. The current targets set the tick to 1 ms. +This becomes the lower bound for timers. + +## Drivers + +Drivers are provided by +[Reference MCU-Driver-HAL driver implementation for Arm platforms](https://gitlab.arm.com/iot/open-iot-sdk/mcu-driver-hal/mcu-driver-reference-platforms-for-arm) +which is provided by Open IoT SDK. diff --git a/docs/style/coding/CODING_STYLE_GUIDE.adoc b/docs/style/coding/CODING_STYLE_GUIDE.adoc index c04f22c8d1ac01..d6436523d657a6 100644 --- a/docs/style/coding/CODING_STYLE_GUIDE.adoc +++ b/docs/style/coding/CODING_STYLE_GUIDE.adoc @@ -154,7 +154,7 @@ leveraged through toolchain-compatibility preprocessor macros. CHIP strives to use the latest C++ functionality as long as existing compilers support such standards. -C{plusplus}14 is considered pervasive enough to be used. As compilers start +C{plusplus}14 is considered pervasive enough to be used. As compilers start supporting standards such as C{plusplus}17, C{plusplus}20 and beyond, CHIP may follow suit. @@ -354,7 +354,7 @@ static chipDEFINE_ALIGNED_VAR(sThreadAttributes, sizeof (pthread_attr_t), uint64 #endif // USE_STRUCT_STORAGE -int foobar(void) +int foobar() { int retval; int status; @@ -427,10 +427,10 @@ destructed after deinitialization. class ThreadAttributes { public: - ThreadAttributes(void) {}; - ~ThreadAttributes(void) {}; + ThreadAttributes() {}; + ~ThreadAttributes() {}; - operator pthread_attr_t *(void) { return &mAttributes; } + operator pthread_attr_t *() { return &mAttributes; } private: pthread_attr_t mAttributes; @@ -444,7 +444,7 @@ extern void * foobar_entry(void *aArgument); static chipDEFINE_ALIGNED_VAR(sThreadAttributes, sizeof (ThreadAttributes), uint64_t); -int foobar(void) +int foobar() { int retval = -1; int status; @@ -530,9 +530,9 @@ storage of objects from a static array of storage. class Foo { public: - Foo(void); + Foo(); Foo(const Foo &inFoo); - ~Foo(void); + ~Foo(); }; // Global Variables @@ -554,7 +554,7 @@ static void CreateFooAllocator(void *inStorage, inDestroy); } -static StaticAllocatorBitmap &GetFooAllocator(void) +static StaticAllocatorBitmap &GetFooAllocator() { return *sFooAllocator; } @@ -571,7 +571,7 @@ static void FooDestroy(AllocatorBase &inAllocator, void *inObject) return; } -int Init(void) +int Init() { static const size_t sFooCount = CHIP_FOO_COUNT; static chipAllocatorStaticBitmapStorageDefine(sFooStorage, Foo, sFooCount, uint32_t, sizeof (void *)); @@ -586,7 +586,7 @@ int Init(void) return retval; } -Foo * FooAllocate(void) +Foo * FooAllocate() { Foo *foo; 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 4f87fd2c122da9..7de2619f5f25d7 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 @@ -1514,7 +1514,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -3880,7 +3880,7 @@ server cluster FaultInjection = 4294048774 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Identify { @@ -4207,7 +4207,7 @@ endpoint 0 { } } endpoint 1 { - device type onofflight = 256; + device type onofflight = 256, version 1; server cluster Identify { ram attribute identifyTime; @@ -4797,7 +4797,7 @@ endpoint 1 { } } endpoint 2 { - device type onofflight = 256; + device type onofflight = 256, version 1; server cluster Groups { ram attribute nameSupport; @@ -4844,7 +4844,7 @@ endpoint 2 { } } endpoint 65534 { - device type anonymousEndpointType = 61442; + device type anonymousEndpointType = 61442, version 1; server cluster NetworkCommissioning { callback attribute maxNetworks; 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 186bc91f1c688e..ed35bec1d79b9d 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 @@ -1,5 +1,5 @@ { - "featureLevel": 81, + "featureLevel": 87, "creator": "zap", "keyValuePairs": [ { @@ -16,12 +16,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", @@ -29,6 +23,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": [ @@ -8058,7 +8058,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "client", "enabled": 0, "commands": [ @@ -8110,7 +8110,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "server", "enabled": 0, "commands": [ @@ -9709,7 +9709,7 @@ "code": 15, "mfgCode": null, "side": "server", - "type": "bitmap8", + "type": "LevelControlOptions", "included": 1, "storageOption": "RAM", "singleton": 0, @@ -19162,7 +19162,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "client", "enabled": 0, "commands": [ @@ -19334,7 +19334,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "server", "enabled": 1, "commands": [ @@ -24740,5 +24740,6 @@ "endpointVersion": 1, "deviceIdentifier": 61442 } - ] + ], + "log": [] } \ No newline at end of file diff --git a/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp b/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp index ff5a7a771e4923..93e93c25a653dd 100644 --- a/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp +++ b/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp @@ -96,7 +96,7 @@ CHIP_ERROR ActionsAttrAccess::Read(const ConcreteReadAttributePath & aPath, Attr } } // anonymous namespace -void MatterActionsPluginServerInitCallback(void) +void MatterActionsPluginServerInitCallback() { registerAttributeAccessOverride(&gAttrAccess); } diff --git a/examples/all-clusters-app/ameba/main/DeviceCallbacks.cpp b/examples/all-clusters-app/ameba/main/DeviceCallbacks.cpp index 028dc7ca2a6370..4817cfb5f99e03 100644 --- a/examples/all-clusters-app/ameba/main/DeviceCallbacks.cpp +++ b/examples/all-clusters-app/ameba/main/DeviceCallbacks.cpp @@ -26,7 +26,7 @@ #include "DeviceCallbacks.h" #include "CHIPDeviceManager.h" #include -#include +#include #include #include #include @@ -91,11 +91,11 @@ void DeviceCallbacks::PostAttributeChangeCallback(EndpointId endpointId, Cluster { switch (clusterId) { - case ZCL_ON_OFF_CLUSTER_ID: + case app::Clusters::OnOff::Id: OnOnOffPostAttributeChangeCallback(endpointId, attributeId, value); break; - case ZCL_IDENTIFY_CLUSTER_ID: + case app::Clusters::Identify::Id: OnIdentifyPostAttributeChangeCallback(endpointId, attributeId, value); break; diff --git a/examples/all-clusters-app/cc13x2x7_26x2x7/main/ClusterManager.cpp b/examples/all-clusters-app/cc13x2x7_26x2x7/main/ClusterManager.cpp index 40661af8cd7c7d..1a07e18c72c3de 100644 --- a/examples/all-clusters-app/cc13x2x7_26x2x7/main/ClusterManager.cpp +++ b/examples/all-clusters-app/cc13x2x7_26x2x7/main/ClusterManager.cpp @@ -21,7 +21,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/all-clusters-app/cc13x2x7_26x2x7/main/ZclCallbacks.cpp b/examples/all-clusters-app/cc13x2x7_26x2x7/main/ZclCallbacks.cpp index 0524dc7578fd23..4d14d56f8f0d6f 100644 --- a/examples/all-clusters-app/cc13x2x7_26x2x7/main/ZclCallbacks.cpp +++ b/examples/all-clusters-app/cc13x2x7_26x2x7/main/ZclCallbacks.cpp @@ -28,7 +28,6 @@ #include "ClusterManager.h" #include -#include #include #include #include diff --git a/examples/all-clusters-app/esp32/CMakeLists.txt b/examples/all-clusters-app/esp32/CMakeLists.txt index 171db2102b0836..0a8752ca6bcc27 100644 --- a/examples/all-clusters-app/esp32/CMakeLists.txt +++ b/examples/all-clusters-app/esp32/CMakeLists.txt @@ -53,6 +53,10 @@ flashing_script() if (CONFIG_ENABLE_PW_RPC) get_filename_component(CHIP_ROOT ./third_party/connectedhomeip REALPATH) include(third_party/connectedhomeip/third_party/pigweed/repo/pw_build/pigweed.cmake) +include($ENV{PW_ROOT}/pw_assert/backend.cmake) +include($ENV{PW_ROOT}/pw_log/backend.cmake) +include($ENV{PW_ROOT}/pw_sys_io/backend.cmake) +include($ENV{PW_ROOT}/pw_trace/backend.cmake) pw_set_module_config(pw_rpc_CONFIG pw_rpc.disable_global_mutex_config) diff --git a/examples/all-clusters-app/esp32/main/CMakeLists.txt b/examples/all-clusters-app/esp32/main/CMakeLists.txt index 1af642f45e4935..3293a8334d5e20 100644 --- a/examples/all-clusters-app/esp32/main/CMakeLists.txt +++ b/examples/all-clusters-app/esp32/main/CMakeLists.txt @@ -252,6 +252,7 @@ target_link_libraries(${COMPONENT_LIB} PUBLIC pw_log pw_rpc.server pw_sys_io + pw_trace pw_trace_tokenized pw_trace_tokenized.trace_buffer pw_trace_tokenized.rpc_service diff --git a/examples/all-clusters-app/esp32/main/DeviceCallbacks.cpp b/examples/all-clusters-app/esp32/main/DeviceCallbacks.cpp index 52d632f7fa5afa..82917c28ef26b5 100644 --- a/examples/all-clusters-app/esp32/main/DeviceCallbacks.cpp +++ b/examples/all-clusters-app/esp32/main/DeviceCallbacks.cpp @@ -37,7 +37,7 @@ #include #if CONFIG_DEVICE_TYPE_ESP32_C3_DEVKITM -#include +#include #endif static const char * TAG = "app-devicecallbacks"; @@ -165,13 +165,13 @@ void AppDeviceCallbacks::OnColorControlAttributeChangeCallback(EndpointId endpoi if (attributeId == ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID) { hue = *value; - emberAfReadServerAttribute(endpointId, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, + emberAfReadServerAttribute(endpointId, Clusters::ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, &saturation, sizeof(uint8_t)); } else { saturation = *value; - emberAfReadServerAttribute(endpointId, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID, &hue, + emberAfReadServerAttribute(endpointId, Clusters::ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID, &hue, sizeof(uint8_t)); } statusLED1.SetColor(hue, saturation); diff --git a/examples/all-clusters-app/esp32/main/DeviceWithDisplay.cpp b/examples/all-clusters-app/esp32/main/DeviceWithDisplay.cpp index d413072f671db1..967431efa8fc5f 100644 --- a/examples/all-clusters-app/esp32/main/DeviceWithDisplay.cpp +++ b/examples/all-clusters-app/esp32/main/DeviceWithDisplay.cpp @@ -18,6 +18,7 @@ #include "DeviceWithDisplay.h" #include +#include #include #if CONFIG_HAVE_DISPLAY @@ -322,7 +323,7 @@ class EditAttributeListModel : public TouchesMatterStackModel { value = (value == "On") ? "Off" : "On"; uint8_t attributeValue = (value == "On") ? 1 : 0; - emberAfWriteServerAttribute(endpointIndex + 1, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, + emberAfWriteServerAttribute(endpointIndex + 1, app::Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &attributeValue, ZCL_BOOLEAN_ATTRIBUTE_TYPE); } diff --git a/examples/all-clusters-app/esp32/main/include/DeviceWithDisplay.h b/examples/all-clusters-app/esp32/main/include/DeviceWithDisplay.h index 99e53e9be9dc4f..7a283fe7546ef5 100644 --- a/examples/all-clusters-app/esp32/main/include/DeviceWithDisplay.h +++ b/examples/all-clusters-app/esp32/main/include/DeviceWithDisplay.h @@ -37,7 +37,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/all-clusters-app/infineon/psoc6/src/AppTask.cpp b/examples/all-clusters-app/infineon/psoc6/src/AppTask.cpp index 54cc0a74a29635..4c871b546bacd5 100644 --- a/examples/all-clusters-app/infineon/psoc6/src/AppTask.cpp +++ b/examples/all-clusters-app/infineon/psoc6/src/AppTask.cpp @@ -26,7 +26,7 @@ #include #include #include -#include +#include #include #include #include @@ -409,7 +409,7 @@ void AppTask::OnOffUpdateClusterState(intptr_t context) // write the new on/off value EmberAfStatus status = - emberAfWriteServerAttribute(2, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, &onoff, ZCL_BOOLEAN_ATTRIBUTE_TYPE); + emberAfWriteServerAttribute(2, app::Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, &onoff, ZCL_BOOLEAN_ATTRIBUTE_TYPE); if (status != EMBER_ZCL_STATUS_SUCCESS) { diff --git a/examples/all-clusters-app/infineon/psoc6/src/ClusterManager.cpp b/examples/all-clusters-app/infineon/psoc6/src/ClusterManager.cpp index 4d550f8c4fdaf8..a3ae6a44190c75 100644 --- a/examples/all-clusters-app/infineon/psoc6/src/ClusterManager.cpp +++ b/examples/all-clusters-app/infineon/psoc6/src/ClusterManager.cpp @@ -26,7 +26,6 @@ #include "LEDWidget.h" #include #include -#include #include #include #include diff --git a/examples/all-clusters-app/infineon/psoc6/src/ZclCallbacks.cpp b/examples/all-clusters-app/infineon/psoc6/src/ZclCallbacks.cpp index 32ba951b52cfc6..f3fd7cf6689a70 100644 --- a/examples/all-clusters-app/infineon/psoc6/src/ZclCallbacks.cpp +++ b/examples/all-clusters-app/infineon/psoc6/src/ZclCallbacks.cpp @@ -27,7 +27,6 @@ #include "ClusterManager.h" #include -#include #include #include #include diff --git a/examples/all-clusters-app/nrfconnect/main/AppTask.cpp b/examples/all-clusters-app/nrfconnect/main/AppTask.cpp index f8646a19f7bd94..b42b7b41ccd8ad 100644 --- a/examples/all-clusters-app/nrfconnect/main/AppTask.cpp +++ b/examples/all-clusters-app/nrfconnect/main/AppTask.cpp @@ -28,7 +28,6 @@ #include #include -#include #include #include #include diff --git a/examples/all-clusters-app/nxp/mw320/main.cpp b/examples/all-clusters-app/nxp/mw320/main.cpp index 6f865b9c4fb75e..a7f6478b1af9f7 100644 --- a/examples/all-clusters-app/nxp/mw320/main.cpp +++ b/examples/all-clusters-app/nxp/mw320/main.cpp @@ -30,7 +30,7 @@ //#include //==> rm from TE7.5 #include -#include +#include #include #include #include @@ -288,7 +288,7 @@ EmberAfStatus emberAfExternalAttributeReadCallback(EndpointId endpoint, ClusterI { PRINTF("====> emberAfExternalAttributeReadCallback\r\n"); - if(clusterId == ZCL_SWITCH_CLUSTER_ID) { + if(clusterId == Clusters::Switch::Id) { *buffer = g_ButtonPress; } return EMBER_ZCL_STATUS_SUCCESS; @@ -1144,12 +1144,12 @@ void task_test_main(void * param) value = (uint16_t) is_on; // sync-up the switch attribute: PRINTF("--> update ZCL_CURRENT_POSITION_ATTRIBUTE_ID [%d] \r\n", value); - emAfWriteAttribute(1, ZCL_SWITCH_CLUSTER_ID, ZCL_CURRENT_POSITION_ATTRIBUTE_ID, (uint8_t *) &value, sizeof(value), true, + emAfWriteAttribute(1, Clusters::Switch::Id, ZCL_CURRENT_POSITION_ATTRIBUTE_ID, (uint8_t *) &value, sizeof(value), true, false); #ifdef SUPPORT_MANUAL_CTRL // sync-up the Light attribute (for test event, OO.M.ManuallyControlled) - PRINTF("--> update [ZCL_ON_OFF_CLUSTER_ID]: ZCL_ON_OFF_ATTRIBUTE_ID [%d] \r\n", value); - emAfWriteAttribute(1, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &value, sizeof(value), true, false); + PRINTF("--> update [Clusters::Switch::Id]: ZCL_ON_OFF_ATTRIBUTE_ID [%d] \r\n", value); + emAfWriteAttribute(1, Clusters::Switch::Id, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &value, sizeof(value), true, false); #endif // SUPPORT_MANUAL_CTRL need2sync_sw_attr = false; @@ -1529,7 +1529,7 @@ static void OnSwitchAttributeChangeCallback(EndpointId endpointId, AttributeId a } } if (do_sendrpt == true) { - ConcreteEventPath event_path(endpointId, ZCL_SWITCH_CLUSTER_ID, 0); + ConcreteEventPath event_path(endpointId, Clusters::Switch::Id, 0); pimEngine->GetReportingEngine().ScheduleEventDelivery(event_path, chip::app::EventOptions::Type::kUrgent, sizeof(uint16_t)); } @@ -1554,7 +1554,7 @@ void IdentifyTimerHandler(System::Layer * systemLayer, void * appState) if (pidt->identifyTimerCount) { pidt->identifyTimerCount--; - emAfWriteAttribute(pidt->ep, ZCL_IDENTIFY_CLUSTER_ID, ZCL_IDENTIFY_TIME_ATTRIBUTE_ID, (uint8_t *) &pidt->identifyTimerCount, + emAfWriteAttribute(pidt->ep, Clusters::Identify::Id, ZCL_IDENTIFY_TIME_ATTRIBUTE_ID, (uint8_t *) &pidt->identifyTimerCount, sizeof(identifyTimerCount), true, false); DeviceLayer::SystemLayer().StartTimer(System::Clock::Seconds16(1), IdentifyTimerHandler, pidt); } @@ -1587,16 +1587,16 @@ void MatterPostAttributeChangeCallback(const chip::app::ConcreteAttributePath & // path.mEndpointId, path.mClusterId, path.mAttributeId, mask, type, size, value switch (path.mClusterId) { - case ZCL_ON_OFF_CLUSTER_ID: + case Clusters::OnOff::Id: OnOnOffPostAttributeChangeCallback(path.mEndpointId, path.mAttributeId, value); break; - case ZCL_SWITCH_CLUSTER_ID: + case Clusters::Switch::Id: OnSwitchAttributeChangeCallback(path.mEndpointId, path.mAttributeId, value); // SwitchToggleOnOff(); // Trigger to send on/off/toggle command to the bound devices chip::BindingManager::GetInstance().NotifyBoundClusterChanged(1, chip::app::Clusters::OnOff::Id, nullptr); break; - case ZCL_IDENTIFY_CLUSTER_ID: + case Clusters::Identify::Id: OnIdentifyPostAttributeChangeCallback(path.mEndpointId, path.mAttributeId, value); break; default: diff --git a/examples/all-clusters-app/telink/CMakeLists.txt b/examples/all-clusters-app/telink/CMakeLists.txt index 553dcc8113bb53..6e9dd95f0e84ec 100644 --- a/examples/all-clusters-app/telink/CMakeLists.txt +++ b/examples/all-clusters-app/telink/CMakeLists.txt @@ -18,7 +18,6 @@ cmake_minimum_required(VERSION 3.13.1) set(BOARD tlsr9518adk80d) get_filename_component(CHIP_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/third_party/connectedhomeip REALPATH) -get_filename_component(NLIO_ROOT ${CHIP_ROOT}/third_party/nlio/repo/include REALPATH) get_filename_component(TELINK_COMMON ${CHIP_ROOT}/examples/platform/telink REALPATH) get_filename_component(GEN_DIR ${CHIP_ROOT}/zzz_generated/ REALPATH) get_filename_component(ALL_CLUSTERS_COMMON_DIR ${CHIP_ROOT}/examples/all-clusters-app/all-clusters-common REALPATH) @@ -41,7 +40,6 @@ target_include_directories(app PRIVATE ${ALL_CLUSTERS_COMMON_DIR}/include ${GEN_DIR}/app-common ${GEN_DIR}/all-clusters-app - ${NLIO_ROOT} ${TELINK_COMMON}/util/include) add_definitions( diff --git a/examples/all-clusters-app/telink/include/CHIPProjectConfig.h b/examples/all-clusters-app/telink/include/CHIPProjectConfig.h index 9cfa65977d1717..2fda70c57da9dc 100644 --- a/examples/all-clusters-app/telink/include/CHIPProjectConfig.h +++ b/examples/all-clusters-app/telink/include/CHIPProjectConfig.h @@ -31,18 +31,9 @@ #define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE 20202021 #define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR 0xF00 -/** - * CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE - * - * Enable support for Chip-over-BLE (CHIPoBLE). - */ -#define CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE 1 - /** * CHIP_SYSTEM_CONFIG_PACKETBUFFER_POOL_SIZE * * Reduce packet buffer pool size to 8 (default 15) to reduce ram consumption */ #define CHIP_SYSTEM_CONFIG_PACKETBUFFER_POOL_SIZE 8 - -#define CHIP_DEVICE_CONFIG_ENABLE_EXTENDED_DISCOVERY 1 diff --git a/examples/all-clusters-app/telink/prj.conf b/examples/all-clusters-app/telink/prj.conf index 01b93d52feba2c..6c7821f2c87ec7 100644 --- a/examples/all-clusters-app/telink/prj.conf +++ b/examples/all-clusters-app/telink/prj.conf @@ -30,7 +30,6 @@ CONFIG_OPENTHREAD_PANID=4660 CONFIG_OPENTHREAD_CHANNEL=15 CONFIG_OPENTHREAD_NETWORK_NAME="OpenThreadDemo" CONFIG_OPENTHREAD_XPANID="11:11:11:11:22:22:22:22" -CONFIG_NET_CONFIG_IEEE802154_DEV_NAME="IEEE802154_b91" # Disable Matter OTA DFU CONFIG_CHIP_OTA_REQUESTOR=n diff --git a/examples/all-clusters-app/telink/src/AppTask.cpp b/examples/all-clusters-app/telink/src/AppTask.cpp index f0daf281889d5f..f00236e08ff707 100644 --- a/examples/all-clusters-app/telink/src/AppTask.cpp +++ b/examples/all-clusters-app/telink/src/AppTask.cpp @@ -32,7 +32,6 @@ #include #include -#include #include #include diff --git a/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.matter b/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.matter index 65d9b42461d81b..225bc9b5fd6dcb 100644 --- a/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.matter +++ b/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.matter @@ -1365,7 +1365,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -3270,7 +3270,7 @@ server cluster UnitTesting = 4294048773 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Identify { @@ -3510,7 +3510,7 @@ endpoint 0 { } } endpoint 1 { - device type onofflight = 256; + device type onofflight = 256, version 1; server cluster Identify { ram attribute identifyTime; @@ -3892,7 +3892,7 @@ endpoint 1 { } } endpoint 2 { - device type onofflight = 256; + device type onofflight = 256, version 1; server cluster Groups { ram attribute nameSupport; @@ -3932,7 +3932,7 @@ endpoint 2 { } } endpoint 65534 { - device type anonymousEndpointType = 61442; + device type anonymousEndpointType = 61442, version 1; server cluster NetworkCommissioning { callback attribute maxNetworks; diff --git a/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.zap b/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.zap index b15e878d9821c7..c79516f63b4df4 100644 --- a/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.zap +++ b/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.zap @@ -1,5 +1,5 @@ { - "featureLevel": 81, + "featureLevel": 87, "creator": "zap", "keyValuePairs": [ { @@ -16,6 +16,12 @@ } ], "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.json", @@ -23,12 +29,6 @@ "category": "matter", "version": 1, "description": "Matter SDK ZCL data" - }, - { - "pathRelativity": "relativeToZap", - "path": "../../../src/app/zap-templates/app-templates.json", - "type": "gen-templates-json", - "version": "chip-v1" } ], "endpointTypes": [ @@ -8058,7 +8058,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "client", "enabled": 0, "commands": [ @@ -8110,7 +8110,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "server", "enabled": 0, "commands": [ @@ -9559,7 +9559,7 @@ "code": 15, "mfgCode": null, "side": "server", - "type": "bitmap8", + "type": "LevelControlOptions", "included": 1, "storageOption": "RAM", "singleton": 0, @@ -18954,7 +18954,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "client", "enabled": 0, "commands": [ @@ -19126,7 +19126,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "server", "enabled": 1, "commands": [ @@ -24516,5 +24516,6 @@ "endpointVersion": 1, "deviceIdentifier": 61442 } - ] + ], + "log": [] } \ No newline at end of file diff --git a/examples/all-clusters-minimal-app/ameba/main/DeviceCallbacks.cpp b/examples/all-clusters-minimal-app/ameba/main/DeviceCallbacks.cpp index 502057c88ae215..f4a7ab2d076c2f 100644 --- a/examples/all-clusters-minimal-app/ameba/main/DeviceCallbacks.cpp +++ b/examples/all-clusters-minimal-app/ameba/main/DeviceCallbacks.cpp @@ -26,7 +26,7 @@ #include "CHIPDeviceManager.h" #include -#include +#include #include #include #include @@ -79,11 +79,11 @@ void DeviceCallbacks::PostAttributeChangeCallback(EndpointId endpointId, Cluster { switch (clusterId) { - case ZCL_ON_OFF_CLUSTER_ID: + case app::Clusters::OnOff::Id: OnOnOffPostAttributeChangeCallback(endpointId, attributeId, value); break; - case ZCL_IDENTIFY_CLUSTER_ID: + case app::Clusters::Identify::Id: OnIdentifyPostAttributeChangeCallback(endpointId, attributeId, value); break; diff --git a/examples/all-clusters-minimal-app/cc13x2x7_26x2x7/main/ClusterManager.cpp b/examples/all-clusters-minimal-app/cc13x2x7_26x2x7/main/ClusterManager.cpp index 40661af8cd7c7d..1a07e18c72c3de 100644 --- a/examples/all-clusters-minimal-app/cc13x2x7_26x2x7/main/ClusterManager.cpp +++ b/examples/all-clusters-minimal-app/cc13x2x7_26x2x7/main/ClusterManager.cpp @@ -21,7 +21,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/all-clusters-minimal-app/cc13x2x7_26x2x7/main/ZclCallbacks.cpp b/examples/all-clusters-minimal-app/cc13x2x7_26x2x7/main/ZclCallbacks.cpp index 0524dc7578fd23..4d14d56f8f0d6f 100644 --- a/examples/all-clusters-minimal-app/cc13x2x7_26x2x7/main/ZclCallbacks.cpp +++ b/examples/all-clusters-minimal-app/cc13x2x7_26x2x7/main/ZclCallbacks.cpp @@ -28,7 +28,6 @@ #include "ClusterManager.h" #include -#include #include #include #include diff --git a/examples/all-clusters-minimal-app/esp32/CMakeLists.txt b/examples/all-clusters-minimal-app/esp32/CMakeLists.txt index 7bcb39178e6bee..c53fd3c05c92af 100644 --- a/examples/all-clusters-minimal-app/esp32/CMakeLists.txt +++ b/examples/all-clusters-minimal-app/esp32/CMakeLists.txt @@ -53,6 +53,11 @@ flashing_script() if (CONFIG_ENABLE_PW_RPC) get_filename_component(CHIP_ROOT ./third_party/connectedhomeip REALPATH) include(third_party/connectedhomeip/third_party/pigweed/repo/pw_build/pigweed.cmake) +include($ENV{PW_ROOT}/pw_assert/backend.cmake) +include($ENV{PW_ROOT}/pw_log/backend.cmake) +include($ENV{PW_ROOT}/pw_sys_io/backend.cmake) +include($ENV{PW_ROOT}/pw_trace/backend.cmake) + pw_set_module_config(pw_rpc_CONFIG pw_rpc.disable_global_mutex_config) pw_set_backend(pw_log pw_log_basic) pw_set_backend(pw_assert.check pw_assert_log.check_backend) diff --git a/examples/all-clusters-minimal-app/esp32/main/CMakeLists.txt b/examples/all-clusters-minimal-app/esp32/main/CMakeLists.txt index 31be1f41050a74..6b0dc3f6f0d6ca 100644 --- a/examples/all-clusters-minimal-app/esp32/main/CMakeLists.txt +++ b/examples/all-clusters-minimal-app/esp32/main/CMakeLists.txt @@ -243,6 +243,7 @@ target_link_libraries(${COMPONENT_LIB} PUBLIC pw_log pw_rpc.server pw_sys_io + pw_trace pw_trace_tokenized pw_trace_tokenized.trace_buffer pw_trace_tokenized.rpc_service diff --git a/examples/all-clusters-minimal-app/esp32/main/DeviceCallbacks.cpp b/examples/all-clusters-minimal-app/esp32/main/DeviceCallbacks.cpp index 52d632f7fa5afa..82917c28ef26b5 100644 --- a/examples/all-clusters-minimal-app/esp32/main/DeviceCallbacks.cpp +++ b/examples/all-clusters-minimal-app/esp32/main/DeviceCallbacks.cpp @@ -37,7 +37,7 @@ #include #if CONFIG_DEVICE_TYPE_ESP32_C3_DEVKITM -#include +#include #endif static const char * TAG = "app-devicecallbacks"; @@ -165,13 +165,13 @@ void AppDeviceCallbacks::OnColorControlAttributeChangeCallback(EndpointId endpoi if (attributeId == ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID) { hue = *value; - emberAfReadServerAttribute(endpointId, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, + emberAfReadServerAttribute(endpointId, Clusters::ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, &saturation, sizeof(uint8_t)); } else { saturation = *value; - emberAfReadServerAttribute(endpointId, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID, &hue, + emberAfReadServerAttribute(endpointId, Clusters::ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID, &hue, sizeof(uint8_t)); } statusLED1.SetColor(hue, saturation); diff --git a/examples/all-clusters-minimal-app/esp32/main/DeviceWithDisplay.cpp b/examples/all-clusters-minimal-app/esp32/main/DeviceWithDisplay.cpp index 9557c97851d08e..9146fe465e12e9 100644 --- a/examples/all-clusters-minimal-app/esp32/main/DeviceWithDisplay.cpp +++ b/examples/all-clusters-minimal-app/esp32/main/DeviceWithDisplay.cpp @@ -17,6 +17,7 @@ */ #include "DeviceWithDisplay.h" +#include #include #if CONFIG_HAVE_DISPLAY @@ -232,7 +233,7 @@ class EditAttributeListModel : public TouchesMatterStackModel { value = (value == "On") ? "Off" : "On"; uint8_t attributeValue = (value == "On") ? 1 : 0; - emberAfWriteServerAttribute(endpointIndex + 1, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, + emberAfWriteServerAttribute(endpointIndex + 1, app::Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &attributeValue, ZCL_BOOLEAN_ATTRIBUTE_TYPE); } diff --git a/examples/all-clusters-minimal-app/esp32/main/include/DeviceWithDisplay.h b/examples/all-clusters-minimal-app/esp32/main/include/DeviceWithDisplay.h index 99e53e9be9dc4f..7a283fe7546ef5 100644 --- a/examples/all-clusters-minimal-app/esp32/main/include/DeviceWithDisplay.h +++ b/examples/all-clusters-minimal-app/esp32/main/include/DeviceWithDisplay.h @@ -37,7 +37,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/all-clusters-minimal-app/infineon/psoc6/src/AppTask.cpp b/examples/all-clusters-minimal-app/infineon/psoc6/src/AppTask.cpp index a6d17539331230..35af6870006185 100644 --- a/examples/all-clusters-minimal-app/infineon/psoc6/src/AppTask.cpp +++ b/examples/all-clusters-minimal-app/infineon/psoc6/src/AppTask.cpp @@ -26,7 +26,7 @@ #include #include #include -#include +#include #include #include #include @@ -409,7 +409,7 @@ void AppTask::OnOffUpdateClusterState(intptr_t context) // write the new on/off value EmberAfStatus status = - emberAfWriteServerAttribute(2, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, &onoff, ZCL_BOOLEAN_ATTRIBUTE_TYPE); + emberAfWriteServerAttribute(2, app::Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, &onoff, ZCL_BOOLEAN_ATTRIBUTE_TYPE); if (status != EMBER_ZCL_STATUS_SUCCESS) { diff --git a/examples/all-clusters-minimal-app/infineon/psoc6/src/ClusterManager.cpp b/examples/all-clusters-minimal-app/infineon/psoc6/src/ClusterManager.cpp index 4d550f8c4fdaf8..a3ae6a44190c75 100644 --- a/examples/all-clusters-minimal-app/infineon/psoc6/src/ClusterManager.cpp +++ b/examples/all-clusters-minimal-app/infineon/psoc6/src/ClusterManager.cpp @@ -26,7 +26,6 @@ #include "LEDWidget.h" #include #include -#include #include #include #include diff --git a/examples/all-clusters-minimal-app/infineon/psoc6/src/ZclCallbacks.cpp b/examples/all-clusters-minimal-app/infineon/psoc6/src/ZclCallbacks.cpp index 32ba951b52cfc6..f3fd7cf6689a70 100644 --- a/examples/all-clusters-minimal-app/infineon/psoc6/src/ZclCallbacks.cpp +++ b/examples/all-clusters-minimal-app/infineon/psoc6/src/ZclCallbacks.cpp @@ -27,7 +27,6 @@ #include "ClusterManager.h" #include -#include #include #include #include diff --git a/examples/all-clusters-minimal-app/nrfconnect/main/AppTask.cpp b/examples/all-clusters-minimal-app/nrfconnect/main/AppTask.cpp index 25c4190544a18a..a2a149a9e01d50 100644 --- a/examples/all-clusters-minimal-app/nrfconnect/main/AppTask.cpp +++ b/examples/all-clusters-minimal-app/nrfconnect/main/AppTask.cpp @@ -26,7 +26,6 @@ #include #include -#include #include #include diff --git a/examples/all-clusters-minimal-app/telink/CMakeLists.txt b/examples/all-clusters-minimal-app/telink/CMakeLists.txt index ecf0efd6aff84a..9f0c60f81af439 100644 --- a/examples/all-clusters-minimal-app/telink/CMakeLists.txt +++ b/examples/all-clusters-minimal-app/telink/CMakeLists.txt @@ -18,7 +18,6 @@ cmake_minimum_required(VERSION 3.13.1) set(BOARD tlsr9518adk80d) get_filename_component(CHIP_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/third_party/connectedhomeip REALPATH) -get_filename_component(NLIO_ROOT ${CHIP_ROOT}/third_party/nlio/repo/include REALPATH) get_filename_component(TELINK_COMMON ${CHIP_ROOT}/examples/platform/telink REALPATH) get_filename_component(GEN_DIR ${CHIP_ROOT}/zzz_generated/ REALPATH) get_filename_component(ALL_CLUSTERS_COMMON_DIR ${CHIP_ROOT}/examples/all-clusters-app/all-clusters-common REALPATH) @@ -41,7 +40,6 @@ target_include_directories(app PRIVATE ${ALL_CLUSTERS_COMMON_DIR}/include ${GEN_DIR}/app-common ${GEN_DIR}/all-clusters-minimal-app - ${NLIO_ROOT} ${TELINK_COMMON}/util/include) add_definitions( diff --git a/examples/all-clusters-minimal-app/telink/include/CHIPProjectConfig.h b/examples/all-clusters-minimal-app/telink/include/CHIPProjectConfig.h index 9cfa65977d1717..2fda70c57da9dc 100644 --- a/examples/all-clusters-minimal-app/telink/include/CHIPProjectConfig.h +++ b/examples/all-clusters-minimal-app/telink/include/CHIPProjectConfig.h @@ -31,18 +31,9 @@ #define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE 20202021 #define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR 0xF00 -/** - * CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE - * - * Enable support for Chip-over-BLE (CHIPoBLE). - */ -#define CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE 1 - /** * CHIP_SYSTEM_CONFIG_PACKETBUFFER_POOL_SIZE * * Reduce packet buffer pool size to 8 (default 15) to reduce ram consumption */ #define CHIP_SYSTEM_CONFIG_PACKETBUFFER_POOL_SIZE 8 - -#define CHIP_DEVICE_CONFIG_ENABLE_EXTENDED_DISCOVERY 1 diff --git a/examples/all-clusters-minimal-app/telink/prj.conf b/examples/all-clusters-minimal-app/telink/prj.conf index 791807a463a9e0..0d56373b56dffe 100644 --- a/examples/all-clusters-minimal-app/telink/prj.conf +++ b/examples/all-clusters-minimal-app/telink/prj.conf @@ -30,7 +30,6 @@ CONFIG_OPENTHREAD_PANID=4660 CONFIG_OPENTHREAD_CHANNEL=15 CONFIG_OPENTHREAD_NETWORK_NAME="OpenThreadDemo" CONFIG_OPENTHREAD_XPANID="11:11:11:11:22:22:22:22" -CONFIG_NET_CONFIG_IEEE802154_DEV_NAME="IEEE802154_b91" # Disable Matter OTA DFU CONFIG_CHIP_OTA_REQUESTOR=n diff --git a/examples/all-clusters-minimal-app/telink/src/AppTask.cpp b/examples/all-clusters-minimal-app/telink/src/AppTask.cpp index a08d81bf5b1a39..e6c684c5ff85b1 100644 --- a/examples/all-clusters-minimal-app/telink/src/AppTask.cpp +++ b/examples/all-clusters-minimal-app/telink/src/AppTask.cpp @@ -30,7 +30,6 @@ #include #include -#include #include #include diff --git a/examples/bridge-app/bridge-common/bridge-app.matter b/examples/bridge-app/bridge-common/bridge-app.matter index 935c1c8077c50b..1d162d6635192c 100644 --- a/examples/bridge-app/bridge-common/bridge-app.matter +++ b/examples/bridge-app/bridge-common/bridge-app.matter @@ -1201,7 +1201,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1453,7 +1453,7 @@ server cluster TemperatureMeasurement = 1026 { } endpoint 0 { - device type bridge = 22; + device type bridge = 22, version 1; binding cluster AccessControl; server cluster Descriptor { @@ -1743,7 +1743,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 14; + device type anonymousEndpointType = 14, version 1; binding cluster Binding; server cluster Identify { @@ -1780,7 +1780,7 @@ endpoint 1 { } } endpoint 2 { - device type dimmablelight = 257; + device type dimmablelight = 257, version 1; server cluster OnOff { ram attribute onOff; diff --git a/examples/bridge-app/esp32/main/main.cpp b/examples/bridge-app/esp32/main/main.cpp index fe3cb2e9da11fc..dd06b095a17cf7 100644 --- a/examples/bridge-app/esp32/main/main.cpp +++ b/examples/bridge-app/esp32/main/main.cpp @@ -21,7 +21,7 @@ #include "nvs_flash.h" #include #include -#include +#include #include #include #include @@ -136,10 +136,9 @@ constexpr CommandId onOffIncomingCommands[] = { }; DECLARE_DYNAMIC_CLUSTER_LIST_BEGIN(bridgedLightClusters) -DECLARE_DYNAMIC_CLUSTER(ZCL_ON_OFF_CLUSTER_ID, onOffAttrs, onOffIncomingCommands, nullptr), - DECLARE_DYNAMIC_CLUSTER(ZCL_DESCRIPTOR_CLUSTER_ID, descriptorAttrs, nullptr, nullptr), - DECLARE_DYNAMIC_CLUSTER(ZCL_BRIDGED_DEVICE_BASIC_CLUSTER_ID, bridgedDeviceBasicAttrs, nullptr, - nullptr) DECLARE_DYNAMIC_CLUSTER_LIST_END; +DECLARE_DYNAMIC_CLUSTER(OnOff::Id, onOffAttrs, onOffIncomingCommands, nullptr), + DECLARE_DYNAMIC_CLUSTER(Descriptor::Id, descriptorAttrs, nullptr, nullptr), + DECLARE_DYNAMIC_CLUSTER(BridgedDeviceBasic::Id, bridgedDeviceBasicAttrs, nullptr, nullptr) DECLARE_DYNAMIC_CLUSTER_LIST_END; // Declare Bridged Light endpoint DECLARE_DYNAMIC_ENDPOINT(bridgedLightEndpoint, bridgedLightClusters); @@ -278,11 +277,11 @@ EmberAfStatus emberAfExternalAttributeReadCallback(EndpointId endpoint, ClusterI { Device * dev = gDevices[endpointIndex]; - if (clusterId == ZCL_BRIDGED_DEVICE_BASIC_CLUSTER_ID) + if (clusterId == BridgedDeviceBasic::Id) { return HandleReadBridgedDeviceBasicAttribute(dev, attributeMetadata->attributeId, buffer, maxReadLength); } - else if (clusterId == ZCL_ON_OFF_CLUSTER_ID) + else if (clusterId == OnOff::Id) { return HandleReadOnOffAttribute(dev, attributeMetadata->attributeId, buffer, maxReadLength); } @@ -300,7 +299,7 @@ EmberAfStatus emberAfExternalAttributeWriteCallback(EndpointId endpoint, Cluster { Device * dev = gDevices[endpointIndex]; - if ((dev->IsReachable()) && (clusterId == ZCL_ON_OFF_CLUSTER_ID)) + if ((dev->IsReachable()) && (clusterId == OnOff::Id)) { return HandleWriteOnOffAttribute(dev, attributeMetadata->attributeId, buffer); } diff --git a/examples/bridge-app/linux/bridged-actions-stub.cpp b/examples/bridge-app/linux/bridged-actions-stub.cpp index 9f7173e3564421..aa28a3712e0f17 100644 --- a/examples/bridge-app/linux/bridged-actions-stub.cpp +++ b/examples/bridge-app/linux/bridged-actions-stub.cpp @@ -131,7 +131,7 @@ CHIP_ERROR ActionsAttrAccess::Read(const ConcreteReadAttributePath & aPath, Attr } } // anonymous namespace -void MatterActionsPluginServerInitCallback(void) +void MatterActionsPluginServerInitCallback() { registerAttributeAccessOverride(&gAttrAccess); } diff --git a/examples/bridge-app/linux/main.cpp b/examples/bridge-app/linux/main.cpp index a1b54c5101f73f..22dbeb1ac9f522 100644 --- a/examples/bridge-app/linux/main.cpp +++ b/examples/bridge-app/linux/main.cpp @@ -23,7 +23,7 @@ #include #include -#include +#include #include #include #include @@ -142,10 +142,9 @@ constexpr CommandId onOffIncomingCommands[] = { }; DECLARE_DYNAMIC_CLUSTER_LIST_BEGIN(bridgedLightClusters) -DECLARE_DYNAMIC_CLUSTER(ZCL_ON_OFF_CLUSTER_ID, onOffAttrs, onOffIncomingCommands, nullptr), - DECLARE_DYNAMIC_CLUSTER(ZCL_DESCRIPTOR_CLUSTER_ID, descriptorAttrs, nullptr, nullptr), - DECLARE_DYNAMIC_CLUSTER(ZCL_BRIDGED_DEVICE_BASIC_CLUSTER_ID, bridgedDeviceBasicAttrs, nullptr, - nullptr) DECLARE_DYNAMIC_CLUSTER_LIST_END; +DECLARE_DYNAMIC_CLUSTER(OnOff::Id, onOffAttrs, onOffIncomingCommands, nullptr), + DECLARE_DYNAMIC_CLUSTER(Descriptor::Id, descriptorAttrs, nullptr, nullptr), + DECLARE_DYNAMIC_CLUSTER(BridgedDeviceBasic::Id, bridgedDeviceBasicAttrs, nullptr, nullptr) DECLARE_DYNAMIC_CLUSTER_LIST_END; // Declare Bridged Light endpoint DECLARE_DYNAMIC_ENDPOINT(bridgedLightEndpoint, bridgedLightClusters); @@ -196,9 +195,9 @@ DECLARE_DYNAMIC_ATTRIBUTE(ZCL_POWER_SOURCE_BAT_CHARGE_LEVEL_ATTRIBUTE_ID, ENUM8, DECLARE_DYNAMIC_ATTRIBUTE(ZCL_POWER_SOURCE_DESCRIPTION_ATTRIBUTE_ID, CHAR_STRING, 32, 0), DECLARE_DYNAMIC_ATTRIBUTE_LIST_END(); DECLARE_DYNAMIC_CLUSTER_LIST_BEGIN(bridgedPowerSourceClusters) -DECLARE_DYNAMIC_CLUSTER(ZCL_DESCRIPTOR_CLUSTER_ID, descriptorAttrs, nullptr, nullptr), - DECLARE_DYNAMIC_CLUSTER(ZCL_BRIDGED_DEVICE_BASIC_CLUSTER_ID, bridgedDeviceBasicAttrs, nullptr, nullptr), - DECLARE_DYNAMIC_CLUSTER(ZCL_POWER_SOURCE_CLUSTER_ID, powerSourceAttrs, nullptr, nullptr), DECLARE_DYNAMIC_CLUSTER_LIST_END; +DECLARE_DYNAMIC_CLUSTER(Descriptor::Id, descriptorAttrs, nullptr, nullptr), + DECLARE_DYNAMIC_CLUSTER(BridgedDeviceBasic::Id, bridgedDeviceBasicAttrs, nullptr, nullptr), + DECLARE_DYNAMIC_CLUSTER(PowerSource::Id, powerSourceAttrs, nullptr, nullptr), DECLARE_DYNAMIC_CLUSTER_LIST_END; DECLARE_DYNAMIC_ENDPOINT(bridgedPowerSourceEndpoint, bridgedPowerSourceClusters); @@ -216,10 +215,9 @@ DECLARE_DYNAMIC_ATTRIBUTE(ZCL_TEMP_MEASURED_VALUE_ATTRIBUTE_ID, INT16S, 2, 0), // - Descriptor // - Bridged Device Basic DECLARE_DYNAMIC_CLUSTER_LIST_BEGIN(bridgedTempSensorClusters) -DECLARE_DYNAMIC_CLUSTER(ZCL_TEMPERATURE_MEASUREMENT_CLUSTER_ID, tempSensorAttrs, nullptr, nullptr), - DECLARE_DYNAMIC_CLUSTER(ZCL_DESCRIPTOR_CLUSTER_ID, descriptorAttrs, nullptr, nullptr), - DECLARE_DYNAMIC_CLUSTER(ZCL_BRIDGED_DEVICE_BASIC_CLUSTER_ID, bridgedDeviceBasicAttrs, nullptr, nullptr), - DECLARE_DYNAMIC_CLUSTER_LIST_END; +DECLARE_DYNAMIC_CLUSTER(TemperatureMeasurement::Id, tempSensorAttrs, nullptr, nullptr), + DECLARE_DYNAMIC_CLUSTER(Descriptor::Id, descriptorAttrs, nullptr, nullptr), + DECLARE_DYNAMIC_CLUSTER(BridgedDeviceBasic::Id, bridgedDeviceBasicAttrs, nullptr, nullptr), DECLARE_DYNAMIC_CLUSTER_LIST_END; // Declare Bridged Light endpoint DECLARE_DYNAMIC_ENDPOINT(bridgedTempSensorEndpoint, bridgedTempSensorClusters); @@ -234,9 +232,8 @@ DataVersion gTempSensor2DataVersions[ArraySize(bridgedTempSensorClusters)]; // Composed Device Configuration DECLARE_DYNAMIC_CLUSTER_LIST_BEGIN(bridgedComposedDeviceClusters) -DECLARE_DYNAMIC_CLUSTER(ZCL_DESCRIPTOR_CLUSTER_ID, descriptorAttrs, nullptr, nullptr), - DECLARE_DYNAMIC_CLUSTER(ZCL_BRIDGED_DEVICE_BASIC_CLUSTER_ID, bridgedDeviceBasicAttrs, nullptr, nullptr), - DECLARE_DYNAMIC_CLUSTER_LIST_END; +DECLARE_DYNAMIC_CLUSTER(Descriptor::Id, descriptorAttrs, nullptr, nullptr), + DECLARE_DYNAMIC_CLUSTER(BridgedDeviceBasic::Id, bridgedDeviceBasicAttrs, nullptr, nullptr), DECLARE_DYNAMIC_CLUSTER_LIST_END; DECLARE_DYNAMIC_ENDPOINT(bridgedComposedDeviceEndpoint, bridgedComposedDeviceClusters); DataVersion gComposedDeviceDataVersions[ArraySize(bridgedComposedDeviceClusters)]; @@ -602,11 +599,11 @@ EmberAfStatus emberAfExternalAttributeReadCallback(EndpointId endpoint, ClusterI { Device * dev = gDevices[endpointIndex]; - if (clusterId == ZCL_BRIDGED_DEVICE_BASIC_CLUSTER_ID) + if (clusterId == BridgedDeviceBasic::Id) { ret = HandleReadBridgedDeviceBasicAttribute(dev, attributeMetadata->attributeId, buffer, maxReadLength); } - else if (clusterId == ZCL_ON_OFF_CLUSTER_ID) + else if (clusterId == OnOff::Id) { ret = HandleReadOnOffAttribute(static_cast(dev), attributeMetadata->attributeId, buffer, maxReadLength); } @@ -638,7 +635,7 @@ EmberAfStatus emberAfExternalAttributeWriteCallback(EndpointId endpoint, Cluster { Device * dev = gDevices[endpointIndex]; - if ((dev->IsReachable()) && (clusterId == ZCL_ON_OFF_CLUSTER_ID)) + if ((dev->IsReachable()) && (clusterId == OnOff::Id)) { ret = HandleWriteOnOffAttribute(static_cast(dev), attributeMetadata->attributeId, buffer); } diff --git a/examples/build_overrides/bouffalolab_iot_sdk.gni b/examples/build_overrides/bouffalolab_iot_sdk.gni index c11bd8fa0507f7..1eb018a7ef2c85 100644 --- a/examples/build_overrides/bouffalolab_iot_sdk.gni +++ b/examples/build_overrides/bouffalolab_iot_sdk.gni @@ -21,6 +21,5 @@ declare_args() { bl702_sdk_build_root = "//third_party/connectedhomeip/third_party/bouffalolab/bl702" - # Root directory of toolchain of Bouffalolab chips - bouffalolab_toolchain = "/third_party/bouffalolab/repo/toolchain/riscv" + bouffalolab_sdk_root = "/opt/bouffalolab_sdk" } diff --git a/examples/chef/ameba/main/DeviceCallbacks.cpp b/examples/chef/ameba/main/DeviceCallbacks.cpp index 259ff3d726f529..8e6b1192b96dd8 100644 --- a/examples/chef/ameba/main/DeviceCallbacks.cpp +++ b/examples/chef/ameba/main/DeviceCallbacks.cpp @@ -26,7 +26,7 @@ #include "CHIPDeviceManager.h" #include -#include +#include #include #include #include @@ -90,11 +90,11 @@ void DeviceCallbacks::PostAttributeChangeCallback(EndpointId endpointId, Cluster { switch (clusterId) { - case ZCL_ON_OFF_CLUSTER_ID: + case app::Clusters::OnOff::Id: OnOnOffPostAttributeChangeCallback(endpointId, attributeId, value); break; - case ZCL_IDENTIFY_CLUSTER_ID: + case app::Clusters::Identify::Id: OnIdentifyPostAttributeChangeCallback(endpointId, attributeId, value); break; diff --git a/examples/chef/common/stubs.cpp b/examples/chef/common/stubs.cpp index 7672a41ea9904d..f170d306ff9ff3 100644 --- a/examples/chef/common/stubs.cpp +++ b/examples/chef/common/stubs.cpp @@ -2,7 +2,6 @@ #include #include #include -#include #include // Include door lock callbacks only when the server is enabled diff --git a/examples/chef/devices/noip_rootnode_dimmablelight_bCwGYSDpoe.matter b/examples/chef/devices/noip_rootnode_dimmablelight_bCwGYSDpoe.matter index e7583f96de6237..8d429ea93bbef5 100644 --- a/examples/chef/devices/noip_rootnode_dimmablelight_bCwGYSDpoe.matter +++ b/examples/chef/devices/noip_rootnode_dimmablelight_bCwGYSDpoe.matter @@ -1059,7 +1059,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1298,7 +1298,7 @@ client cluster OccupancySensing = 1030 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1548,7 +1548,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 257; + device type anonymousEndpointType = 257, version 1; binding cluster Binding; binding cluster OccupancySensing; diff --git a/examples/chef/devices/rootnode_colortemperaturelight_hbUnzYVeyn.matter b/examples/chef/devices/rootnode_colortemperaturelight_hbUnzYVeyn.matter index 691f043df048b1..574d43954ab3a5 100644 --- a/examples/chef/devices/rootnode_colortemperaturelight_hbUnzYVeyn.matter +++ b/examples/chef/devices/rootnode_colortemperaturelight_hbUnzYVeyn.matter @@ -1371,7 +1371,7 @@ server cluster ColorControl = 768 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1514,7 +1514,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 268; + device type anonymousEndpointType = 268, version 1; server cluster Identify { ram attribute identifyTime; diff --git a/examples/chef/devices/rootnode_contactsensor_lFAGG1bfRO.matter b/examples/chef/devices/rootnode_contactsensor_lFAGG1bfRO.matter index 0177e33ad28d52..855cea4c4b1e68 100644 --- a/examples/chef/devices/rootnode_contactsensor_lFAGG1bfRO.matter +++ b/examples/chef/devices/rootnode_contactsensor_lFAGG1bfRO.matter @@ -794,7 +794,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1036,7 +1036,7 @@ server cluster BooleanState = 69 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1199,7 +1199,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 21; + device type anonymousEndpointType = 21, version 1; binding cluster Binding; server cluster Identify { diff --git a/examples/chef/devices/rootnode_dimmablelight_bCwGYSDpoe.matter b/examples/chef/devices/rootnode_dimmablelight_bCwGYSDpoe.matter index 4ef2b98da6868e..3a49ba744dcbf5 100644 --- a/examples/chef/devices/rootnode_dimmablelight_bCwGYSDpoe.matter +++ b/examples/chef/devices/rootnode_dimmablelight_bCwGYSDpoe.matter @@ -943,7 +943,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1182,7 +1182,7 @@ client cluster OccupancySensing = 1030 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1345,7 +1345,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 257; + device type anonymousEndpointType = 257, version 1; binding cluster Binding; binding cluster OccupancySensing; diff --git a/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.matter b/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.matter index 13f3a469c1a044..a7215a34d2cd00 100644 --- a/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.matter +++ b/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.matter @@ -794,7 +794,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1421,7 +1421,7 @@ server cluster DoorLock = 257 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1584,7 +1584,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 10; + device type anonymousEndpointType = 10, version 1; binding cluster Binding; server cluster Identify { @@ -1631,11 +1631,11 @@ endpoint 1 { ram attribute wrongCodeEntryLimit default = 3; ram attribute userCodeTemporaryDisableTime default = 10; ram attribute sendPINOverTheAir; - ram attribute requirePINforRemoteOperation; + ram attribute requirePINforRemoteOperation default = 1; callback attribute generatedCommandList; callback attribute acceptedCommandList; callback attribute attributeList; - ram attribute featureMap default = 0x0001; + ram attribute featureMap default = 0x0081; ram attribute clusterRevision default = 6; } } diff --git a/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.zap b/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.zap index 5d17b610e136c5..688b51add16475 100644 --- a/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.zap +++ b/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.zap @@ -7552,7 +7552,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0", + "defaultValue": "1", "reportable": 1, "minInterval": 1, "maxInterval": 65534, @@ -7632,7 +7632,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0081", "reportable": 1, "minInterval": 1, "maxInterval": 65534, diff --git a/examples/chef/devices/rootnode_extendedcolorlight_8lcaaYJVAa.matter b/examples/chef/devices/rootnode_extendedcolorlight_8lcaaYJVAa.matter index 6266fa4f203f19..0c2da0d4114024 100644 --- a/examples/chef/devices/rootnode_extendedcolorlight_8lcaaYJVAa.matter +++ b/examples/chef/devices/rootnode_extendedcolorlight_8lcaaYJVAa.matter @@ -943,7 +943,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1437,7 +1437,7 @@ server cluster ColorControl = 768 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1600,7 +1600,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 269; + device type anonymousEndpointType = 269, version 1; binding cluster Binding; server cluster Identify { diff --git a/examples/chef/devices/rootnode_fan_7N2TobIlOX.matter b/examples/chef/devices/rootnode_fan_7N2TobIlOX.matter index e750f57faebfe3..b0157731cf14ff 100644 --- a/examples/chef/devices/rootnode_fan_7N2TobIlOX.matter +++ b/examples/chef/devices/rootnode_fan_7N2TobIlOX.matter @@ -796,7 +796,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1088,7 +1088,7 @@ server cluster FanControl = 514 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1260,7 +1260,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 43; + device type anonymousEndpointType = 43, version 1; server cluster Identify { ram attribute identifyTime; diff --git a/examples/chef/devices/rootnode_flowsensor_1zVxHedlaV.matter b/examples/chef/devices/rootnode_flowsensor_1zVxHedlaV.matter index c3fbdafce95b94..71251a9891b3b8 100644 --- a/examples/chef/devices/rootnode_flowsensor_1zVxHedlaV.matter +++ b/examples/chef/devices/rootnode_flowsensor_1zVxHedlaV.matter @@ -807,7 +807,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1048,7 +1048,7 @@ server cluster FlowMeasurement = 1028 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1211,7 +1211,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 774; + device type anonymousEndpointType = 774, version 1; binding cluster Groups; binding cluster Binding; diff --git a/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.matter b/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.matter index e8b10818ad1ac0..c2f732cf5a4fff 100644 --- a/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.matter +++ b/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.matter @@ -936,7 +936,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1290,7 +1290,7 @@ server cluster FanControl = 514 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1453,7 +1453,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 768; + device type anonymousEndpointType = 768, version 1; binding cluster Binding; binding cluster Thermostat; diff --git a/examples/chef/devices/rootnode_humiditysensor_Xyj4gda6Hb.matter b/examples/chef/devices/rootnode_humiditysensor_Xyj4gda6Hb.matter index e1227bc1b88212..2465a587d3bc2f 100644 --- a/examples/chef/devices/rootnode_humiditysensor_Xyj4gda6Hb.matter +++ b/examples/chef/devices/rootnode_humiditysensor_Xyj4gda6Hb.matter @@ -807,7 +807,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1048,7 +1048,7 @@ server cluster RelativeHumidityMeasurement = 1029 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1211,7 +1211,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 775; + device type anonymousEndpointType = 775, version 1; binding cluster Groups; binding cluster Binding; diff --git a/examples/chef/devices/rootnode_lightsensor_lZQycTFcJK.matter b/examples/chef/devices/rootnode_lightsensor_lZQycTFcJK.matter index d74341ccf30956..6dbbbc8c29704c 100644 --- a/examples/chef/devices/rootnode_lightsensor_lZQycTFcJK.matter +++ b/examples/chef/devices/rootnode_lightsensor_lZQycTFcJK.matter @@ -807,7 +807,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1052,7 +1052,7 @@ server cluster IlluminanceMeasurement = 1024 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1215,7 +1215,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 262; + device type anonymousEndpointType = 262, version 1; binding cluster Groups; binding cluster Binding; diff --git a/examples/chef/devices/rootnode_occupancysensor_iHyVgifZuo.matter b/examples/chef/devices/rootnode_occupancysensor_iHyVgifZuo.matter index d266a0ecc47132..43f0dc420e138b 100644 --- a/examples/chef/devices/rootnode_occupancysensor_iHyVgifZuo.matter +++ b/examples/chef/devices/rootnode_occupancysensor_iHyVgifZuo.matter @@ -807,7 +807,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1047,7 +1047,7 @@ server cluster OccupancySensing = 1030 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1210,7 +1210,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 263; + device type anonymousEndpointType = 263, version 1; binding cluster Groups; binding cluster Binding; diff --git a/examples/chef/devices/rootnode_onofflight_bbs1b7IaOV.matter b/examples/chef/devices/rootnode_onofflight_bbs1b7IaOV.matter index de8ed09da7a047..0cb0145e16d660 100644 --- a/examples/chef/devices/rootnode_onofflight_bbs1b7IaOV.matter +++ b/examples/chef/devices/rootnode_onofflight_bbs1b7IaOV.matter @@ -943,7 +943,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1172,7 +1172,7 @@ server cluster FixedLabel = 64 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1335,7 +1335,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 256; + device type anonymousEndpointType = 256, version 1; binding cluster Binding; server cluster Identify { diff --git a/examples/chef/devices/rootnode_onofflightswitch_FsPlMr090Q.matter b/examples/chef/devices/rootnode_onofflightswitch_FsPlMr090Q.matter index 156646c74843f9..d82e6d9dbbd2ad 100644 --- a/examples/chef/devices/rootnode_onofflightswitch_FsPlMr090Q.matter +++ b/examples/chef/devices/rootnode_onofflightswitch_FsPlMr090Q.matter @@ -886,7 +886,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1115,7 +1115,7 @@ server cluster FixedLabel = 64 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1278,7 +1278,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 259; + device type anonymousEndpointType = 259, version 1; binding cluster OnOff; binding cluster Binding; diff --git a/examples/chef/devices/rootnode_onoffpluginunit_Wtf8ss5EBY.matter b/examples/chef/devices/rootnode_onoffpluginunit_Wtf8ss5EBY.matter index 1575d818cff0f3..90161aa0fc018a 100644 --- a/examples/chef/devices/rootnode_onoffpluginunit_Wtf8ss5EBY.matter +++ b/examples/chef/devices/rootnode_onoffpluginunit_Wtf8ss5EBY.matter @@ -844,7 +844,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1073,7 +1073,7 @@ server cluster FixedLabel = 64 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1236,7 +1236,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 266; + device type anonymousEndpointType = 266, version 1; binding cluster Binding; server cluster Identify { diff --git a/examples/chef/devices/rootnode_pressuresensor_s0qC9wLH4k.matter b/examples/chef/devices/rootnode_pressuresensor_s0qC9wLH4k.matter index 593a08e39257aa..8d42299065c622 100644 --- a/examples/chef/devices/rootnode_pressuresensor_s0qC9wLH4k.matter +++ b/examples/chef/devices/rootnode_pressuresensor_s0qC9wLH4k.matter @@ -812,7 +812,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1057,7 +1057,7 @@ server cluster PressureMeasurement = 1027 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1226,7 +1226,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 773; + device type anonymousEndpointType = 773, version 1; binding cluster Groups; binding cluster Binding; diff --git a/examples/chef/devices/rootnode_speaker_RpzeXdimqA.matter b/examples/chef/devices/rootnode_speaker_RpzeXdimqA.matter index acc8ff44a996c7..4bd96a0b65173f 100644 --- a/examples/chef/devices/rootnode_speaker_RpzeXdimqA.matter +++ b/examples/chef/devices/rootnode_speaker_RpzeXdimqA.matter @@ -934,7 +934,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1163,7 +1163,7 @@ server cluster FixedLabel = 64 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1326,7 +1326,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 34; + device type anonymousEndpointType = 34, version 1; binding cluster Binding; server cluster Identify { diff --git a/examples/chef/devices/rootnode_temperaturesensor_Qy1zkNW7c3.matter b/examples/chef/devices/rootnode_temperaturesensor_Qy1zkNW7c3.matter index 30796b5c778f38..01536ea35bdc79 100644 --- a/examples/chef/devices/rootnode_temperaturesensor_Qy1zkNW7c3.matter +++ b/examples/chef/devices/rootnode_temperaturesensor_Qy1zkNW7c3.matter @@ -807,7 +807,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1047,7 +1047,7 @@ server cluster TemperatureMeasurement = 1026 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1210,7 +1210,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 770; + device type anonymousEndpointType = 770, version 1; binding cluster Groups; binding cluster Binding; diff --git a/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.matter b/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.matter index 4f58b0042df551..dcec5623cb7e77 100644 --- a/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.matter +++ b/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.matter @@ -794,7 +794,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1185,7 +1185,7 @@ client cluster OccupancySensing = 1030 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1348,7 +1348,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 769; + device type anonymousEndpointType = 769, version 1; binding cluster Binding; binding cluster FanControl; binding cluster TemperatureMeasurement; diff --git a/examples/chef/devices/rootnode_windowcovering_RLCxaGi9Yx.matter b/examples/chef/devices/rootnode_windowcovering_RLCxaGi9Yx.matter index 602e899a5534c4..f61138c0f9f943 100644 --- a/examples/chef/devices/rootnode_windowcovering_RLCxaGi9Yx.matter +++ b/examples/chef/devices/rootnode_windowcovering_RLCxaGi9Yx.matter @@ -794,7 +794,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1165,7 +1165,7 @@ server cluster WindowCovering = 258 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1328,7 +1328,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 514; + device type anonymousEndpointType = 514, version 1; binding cluster Binding; server cluster Identify { diff --git a/examples/chef/efr32/src/AppTask.cpp b/examples/chef/efr32/src/AppTask.cpp index 0eb2b9ec492268..3de9bff17a49f9 100644 --- a/examples/chef/efr32/src/AppTask.cpp +++ b/examples/chef/efr32/src/AppTask.cpp @@ -35,7 +35,6 @@ #include #include -#include #include #include #include diff --git a/examples/chef/esp32/main/CMakeLists.txt b/examples/chef/esp32/main/CMakeLists.txt index 777c891486b380..00a46722388cc9 100644 --- a/examples/chef/esp32/main/CMakeLists.txt +++ b/examples/chef/esp32/main/CMakeLists.txt @@ -194,6 +194,7 @@ target_link_libraries(${COMPONENT_LIB} PUBLIC pw_log pw_rpc.server pw_sys_io + pw_trace pw_trace_tokenized pw_trace_tokenized.trace_buffer pw_trace_tokenized.rpc_service diff --git a/examples/chef/esp32/main/main.cpp b/examples/chef/esp32/main/main.cpp index e5db9238832af0..225815f8043b70 100644 --- a/examples/chef/esp32/main/main.cpp +++ b/examples/chef/esp32/main/main.cpp @@ -41,7 +41,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/chip-tool/BUILD.gn b/examples/chip-tool/BUILD.gn index a4e87b7bacfc1c..d870c1d5cf92f2 100644 --- a/examples/chip-tool/BUILD.gn +++ b/examples/chip-tool/BUILD.gn @@ -120,7 +120,10 @@ static_library("chip-tool-utils") { executable("chip-tool") { sources = [ "main.cpp" ] - deps = [ ":chip-tool-utils" ] + deps = [ + ":chip-tool-utils", + "${chip_root}/src/platform/logging:force_stdio", + ] output_dir = root_out_dir } diff --git a/examples/chip-tool/README.md b/examples/chip-tool/README.md index 3385e7c7c36cdc..2f14c1b2a8c989 100644 --- a/examples/chip-tool/README.md +++ b/examples/chip-tool/README.md @@ -156,14 +156,7 @@ The client will send a single command packet and then exit. 1. Commission and pair device with nodeId 1234 -2. Add Group to device - -``` -chip-tool groups add-group GroupId GroupName node-id endpoint-id -chip-tool groups add-group 0x4141 Light 1234 1 -``` - -3. Add group Keyset to device +2. Add group Keyset to device ``` chip-tool groupkeymanagement key-set-write GroupKeySet node-id endpoint-id @@ -174,13 +167,20 @@ chip-tool groupkeymanagement key-set-write '{"groupKeySetID": 42, \ "d2d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime2": 2220002 }' 1234 0 ``` -4. Bind Key to group +3. Bind Key to group ``` chip-tool groupkeymanagement write group-key-map attr-value node-id endpoint-id chip-tool groupkeymanagement write group-key-map '[{"groupId": 16705, "groupKeySetID": 42}]' 1234 0 ``` +4. Add Group to device + +``` +chip-tool groups add-group GroupId GroupName node-id endpoint-id +chip-tool groups add-group 0x4141 Light 1234 1 +``` + ## Configuring the client for Group Commands Prior to sending a Group command, both the end device and the Client (Chip-tool) @@ -222,8 +222,10 @@ chip-tool groupsettings bind-keyset 0x4141 0xAAAA To use the Client to send Matter commands, run the built executable and pass it the target cluster name, the target command name, the Group Id in Node Id form -(`0xffffffffffffXXXX`) and an unused endpoint Id. Take note that Only commands -and attributes write can be send with Group Id. +(`0xffffffffffffXXXX`) and an used endpoint Id. Take note that Only commands and +attributes write can be send with Group Id. Also note that a group ACL needs to +be installed before a command sent to the group will be accepted. See +[the access control guide](../../docs/guides/access-control-guide.md#installing-a-group-acl) E.G. sending to group Id 0x4141 diff --git a/examples/chip-tool/commands/clusters/ClusterCommand.h b/examples/chip-tool/commands/clusters/ClusterCommand.h index 4b8325074a8716..33320760dd9d9a 100644 --- a/examples/chip-tool/commands/clusters/ClusterCommand.h +++ b/examples/chip-tool/commands/clusters/ClusterCommand.h @@ -30,16 +30,14 @@ class ClusterCommand : public InteractionModelCommands, public ModelCommand, pub InteractionModelCommands(this), ModelCommand("command-by-id", credsIssuerConfig) { AddArgument("cluster-id", 0, UINT32_MAX, &mClusterId); - AddArgument("command-id", 0, UINT32_MAX, &mCommandId); - AddArgument("payload", &mPayload); + AddByIdArguments(); AddArguments(); } ClusterCommand(chip::ClusterId clusterId, CredentialIssuerCommands * credsIssuerConfig) : InteractionModelCommands(this), ModelCommand("command-by-id", credsIssuerConfig), mClusterId(clusterId) { - AddArgument("command-id", 0, UINT32_MAX, &mCommandId); - AddArgument("payload", &mPayload); + AddByIdArguments(); AddArguments(); } @@ -137,6 +135,41 @@ class ClusterCommand : public InteractionModelCommands, public ModelCommand, pub // Subclasses are responsible for calling AddArguments. } + void AddByIdArguments() + { + AddArgument("command-id", 0, UINT32_MAX, &mCommandId); + AddArgument("payload", &mPayload, + "The command payload. This should be a JSON-encoded object, with string representations of field ids as keys. " + " The values for the keys are represented as follows, depending on the type:\n" + " * struct: a JSON-encoded object, with field ids as keys.\n" + " * list: a JSON-encoded array of values.\n" + " * null: A literal null.\n" + " * boolean: A literal true or false.\n" + " * unsigned integer: One of:\n" + " a) The number directly, as decimal.\n" + " b) A string starting with \"u:\" followed by decimal digits\n" + " * signed integer: One of:\n" + " a) The number directly, if it's negative.\n" + " b) A string starting with \"s:\" followed by decimal digits\n" + " * single-precision float: A string starting with \"f:\" followed by the number.\n" + " * double-precision float: One of:\n" + " a) The number directly, if it's not an integer.\n" + " b) A string starting with \"d:\" followed by the number.\n" + " * octet string: A string starting with \"hex:\" followed by the hex encoding of the bytes.\n" + " * string: A string with the characters.\n" + "\n" + " An example payload may look like this: '{ \"0x0\": { \"0\": null, \"1\": false }, \"1\": [17, \"u:17\"], " + "\"0x2\": [ -17, \"s:17\", \"s:-17\" ], \"0x3\": \"f:2\", \"0x4\": [ \"d:3\", 4.5 ], \"0x5\": \"hex:ab12\", " + "\"0x6\": \"ab12\" }' and represents:\n" + " Field 0: a struct with two fields, one with value null and one with value false.\n" + " Field 1: A list of unsigned integers.\n" + " Field 2: A list of signed integers.\n" + " Field 3: A single-precision float.\n" + " Field 4: A list of double-precision floats.\n" + " Field 5: A 2-byte octet string.\n" + " Field 6: A 4-char character string."); + } + void AddArguments() { AddArgument("timedInteractionTimeoutMs", 0, UINT16_MAX, &mTimedInteractionTimeoutMs, diff --git a/examples/chip-tool/commands/clusters/ComplexArgument.h b/examples/chip-tool/commands/clusters/ComplexArgument.h index 8684116893cd12..8cb23a0b661797 100644 --- a/examples/chip-tool/commands/clusters/ComplexArgument.h +++ b/examples/chip-tool/commands/clusters/ComplexArgument.h @@ -29,7 +29,8 @@ #include "JsonParser.h" -constexpr uint8_t kMaxLabelLength = 100; +constexpr uint8_t kMaxLabelLength = 100; +constexpr const char kNullString[] = "null"; class ComplexArgumentParser { @@ -326,7 +327,11 @@ class TypedComplexArgument : public ComplexArgument CHIP_ERROR Parse(const char * label, const char * json) { Json::Value value; - if (!JsonParser::ParseComplexArgument(label, json, value)) + if (strcmp(kNullString, json) == 0) + { + value = Json::nullValue; + } + else if (!JsonParser::ParseComplexArgument(label, json, value)) { return CHIP_ERROR_INVALID_ARGUMENT; } diff --git a/examples/chip-tool/commands/clusters/WriteAttributeCommand.h b/examples/chip-tool/commands/clusters/WriteAttributeCommand.h index ac9f6233a65ff4..d220468d622260 100644 --- a/examples/chip-tool/commands/clusters/WriteAttributeCommand.h +++ b/examples/chip-tool/commands/clusters/WriteAttributeCommand.h @@ -179,22 +179,50 @@ class WriteAttribute : public InteractionModelWriter, public ModelCommand, publi AddArgument("attribute-name", attributeName, "The attribute name to write."); } - template - void AddArgumentAttributeValues(minType minValue, maxType maxValue) + template >::value, int> = 0> + static const char * GetAttributeValuesDescription() { - AddArgument("attribute-values", minValue, maxValue, &mAttributeValues, - "Comma-separated list of attribute values to write."); + return "Comma-separated list of attribute values to write. Each value is represented as follows, depending on the type:\n" + " * struct: a JSON-encoded object, with field ids as keys.\n" + " * list: a JSON-encoded array of values.\n" + " * null: A literal null.\n" + " * boolean: A literal true or false.\n" + " * unsigned integer: One of:\n" + " a) The number directly, as decimal.\n" + " b) The number directly, as 0x followed by hex digits. (Only for the toplevel value, not inside structs or " + "lists.)\n" + " c) A string starting with \"u:\" followed by decimal digits\n" + " * signed integer: One of:\n" + " a) The number directly, if it's negative.\n" + " c) A string starting with \"s:\" followed by decimal digits\n" + " * single-precision float: A string starting with \"f:\" followed by the number.\n" + " * double-precision float: One of:\n" + " a) The number directly, if it's not an integer.\n" + " b) A string starting with \"d:\" followed by the number.\n" + " * octet string: A string starting with \"hex:\" followed by the hex encoding of the bytes.\n" + " * string: A string with the characters."; } - void AddArgumentAttributeValues() + static const char * GetTypedAttributeValuesDescription() { return "Comma-separated list of attribute values to write."; } + + template >::value, int> = 0> + static const char * GetAttributeValuesDescription() { - AddArgument("attribute-values", &mAttributeValues, "Comma-separated list of attribute values to write."); + return GetTypedAttributeValuesDescription(); } + template + void AddArgumentAttributeValues(minType minValue, maxType maxValue) + { + AddArgument("attribute-values", minValue, maxValue, &mAttributeValues, GetTypedAttributeValuesDescription()); + } + + void AddArgumentAttributeValues() { AddArgument("attribute-values", &mAttributeValues, GetAttributeValuesDescription()); } + void AddArgumentAttributeValues(TypedComplexArgument & attributeParser) { attributeParser.SetArgument(&mAttributeValues); - AddArgument("attribute-values", &attributeParser, "Comma-separated list of attribute values to write."); + AddArgument("attribute-values", &attributeParser, GetTypedAttributeValuesDescription()); } void AddArguments() diff --git a/examples/chip-tool/commands/common/Command.cpp b/examples/chip-tool/commands/common/Command.cpp index 59d678158ed073..0c5777e825df3b 100644 --- a/examples/chip-tool/commands/common/Command.cpp +++ b/examples/chip-tool/commands/common/Command.cpp @@ -17,13 +17,15 @@ */ #include "Command.h" -#include "platform/PlatformManager.h" +#include #include #include #include #include +#include // For INFINITY + #include #include #include @@ -541,6 +543,18 @@ bool Command::InitArgument(size_t argIndex, char * argValue) case ArgumentType::Float: { isValidArgument = HandleNullableOptional(arg, argValue, [&](auto * value) { + if (strcmp(argValue, "Infinity") == 0) + { + *value = INFINITY; + return true; + } + + if (strcmp(argValue, "-Infinity") == 0) + { + *value = -INFINITY; + return true; + } + std::stringstream ss; ss << argValue; ss >> *value; @@ -551,6 +565,18 @@ bool Command::InitArgument(size_t argIndex, char * argValue) case ArgumentType::Double: { isValidArgument = HandleNullableOptional(arg, argValue, [&](auto * value) { + if (strcmp(argValue, "Infinity") == 0) + { + *value = INFINITY; + return true; + } + + if (strcmp(argValue, "-Infinity") == 0) + { + *value = -INFINITY; + return true; + } + std::stringstream ss; ss << argValue; ss >> *value; @@ -803,7 +829,7 @@ const char * Command::GetArgumentDescription(size_t index) const return nullptr; } -const char * Command::GetAttribute(void) const +const char * Command::GetAttribute() const { size_t argsCount = mArgs.size(); for (size_t i = 0; i < argsCount; i++) @@ -818,7 +844,7 @@ const char * Command::GetAttribute(void) const return nullptr; } -const char * Command::GetEvent(void) const +const char * Command::GetEvent() const { size_t argsCount = mArgs.size(); for (size_t i = 0; i < argsCount; i++) diff --git a/examples/chip-tool/commands/common/Command.h b/examples/chip-tool/commands/common/Command.h index 96de49477621d8..265bf1af3c5925 100644 --- a/examples/chip-tool/commands/common/Command.h +++ b/examples/chip-tool/commands/common/Command.h @@ -21,7 +21,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/chip-tool/commands/common/CredentialIssuerCommands.h b/examples/chip-tool/commands/common/CredentialIssuerCommands.h index 2a5df5a42abe63..1ea712ffa9593f 100644 --- a/examples/chip-tool/commands/common/CredentialIssuerCommands.h +++ b/examples/chip-tool/commands/common/CredentialIssuerCommands.h @@ -19,12 +19,18 @@ #pragma once #include -#include #include #include #include #include +namespace chip { +namespace Controller { +struct SetupParams; +class OperationalCredentialsDelegate; +} // namespace Controller +} // namespace chip + class CredentialIssuerCommands { public: diff --git a/examples/chip-tool/commands/discover/DiscoverCommissionersCommand.cpp b/examples/chip-tool/commands/discover/DiscoverCommissionersCommand.cpp index b2fe353931328a..0d1c9a032de02c 100644 --- a/examples/chip-tool/commands/discover/DiscoverCommissionersCommand.cpp +++ b/examples/chip-tool/commands/discover/DiscoverCommissionersCommand.cpp @@ -18,6 +18,7 @@ #include "DiscoverCommissionersCommand.h" #include +#include using namespace ::chip; diff --git a/examples/chip-tool/commands/example/ExampleCredentialIssuerCommands.h b/examples/chip-tool/commands/example/ExampleCredentialIssuerCommands.h index da4716e957e921..e06466ca4ab67d 100644 --- a/examples/chip-tool/commands/example/ExampleCredentialIssuerCommands.h +++ b/examples/chip-tool/commands/example/ExampleCredentialIssuerCommands.h @@ -19,6 +19,7 @@ #pragma once #include +#include #include #include #include diff --git a/examples/chip-tool/commands/interactive/InteractiveCommands.cpp b/examples/chip-tool/commands/interactive/InteractiveCommands.cpp index 380a6e34c6ab6c..de82f205803070 100644 --- a/examples/chip-tool/commands/interactive/InteractiveCommands.cpp +++ b/examples/chip-tool/commands/interactive/InteractiveCommands.cpp @@ -18,6 +18,8 @@ #include "InteractiveCommands.h" +#include + #include #include #include diff --git a/examples/chip-tool/commands/pairing/PairingCommand.cpp b/examples/chip-tool/commands/pairing/PairingCommand.cpp index 9f827004d087f4..adc560a812fe11 100644 --- a/examples/chip-tool/commands/pairing/PairingCommand.cpp +++ b/examples/chip-tool/commands/pairing/PairingCommand.cpp @@ -70,17 +70,23 @@ CHIP_ERROR PairingCommand::RunInternal(NodeId remoteId) CommissioningParameters PairingCommand::GetCommissioningParameters() { + auto params = CommissioningParameters(); + params.SetSkipCommissioningComplete(mSkipCommissioningComplete.ValueOr(false)); + switch (mNetworkType) { case PairingNetworkType::WiFi: - return CommissioningParameters().SetWiFiCredentials(Controller::WiFiCredentials(mSSID, mPassword)); + params.SetWiFiCredentials(Controller::WiFiCredentials(mSSID, mPassword)); + break; case PairingNetworkType::Thread: - return CommissioningParameters().SetThreadOperationalDataset(mOperationalDataset); + params.SetThreadOperationalDataset(mOperationalDataset); + break; case PairingNetworkType::Ethernet: case PairingNetworkType::None: - return CommissioningParameters(); + break; } - return CommissioningParameters(); + + return params; } CHIP_ERROR PairingCommand::PaseWithCode(NodeId remoteId) diff --git a/examples/chip-tool/commands/pairing/PairingCommand.h b/examples/chip-tool/commands/pairing/PairingCommand.h index 61c7440ad9963e..3edd1cfd9e3f4e 100644 --- a/examples/chip-tool/commands/pairing/PairingCommand.h +++ b/examples/chip-tool/commands/pairing/PairingCommand.h @@ -78,20 +78,24 @@ class PairingCommand : public CHIPCommand, case PairingMode::None: break; case PairingMode::Code: + AddArgument("skip-commissioning-complete", 0, 1, &mSkipCommissioningComplete); case PairingMode::CodePaseOnly: AddArgument("payload", &mOnboardingPayload); AddArgument("discover-once", 0, 1, &mDiscoverOnce); AddArgument("use-only-onnetwork-discovery", 0, 1, &mUseOnlyOnNetworkDiscovery); break; case PairingMode::Ble: + AddArgument("skip-commissioning-complete", 0, 1, &mSkipCommissioningComplete); AddArgument("setup-pin-code", 0, 134217727, &mSetupPINCode); AddArgument("discriminator", 0, 4096, &mDiscriminator); break; case PairingMode::OnNetwork: + AddArgument("skip-commissioning-complete", 0, 1, &mSkipCommissioningComplete); AddArgument("setup-pin-code", 0, 134217727, &mSetupPINCode); AddArgument("pase-only", 0, 1, &mPaseOnly); break; case PairingMode::SoftAP: + AddArgument("skip-commissioning-complete", 0, 1, &mSkipCommissioningComplete); AddArgument("setup-pin-code", 0, 134217727, &mSetupPINCode); AddArgument("discriminator", 0, 4096, &mDiscriminator); AddArgument("device-remote-ip", &mRemoteAddr); @@ -99,6 +103,7 @@ class PairingCommand : public CHIPCommand, AddArgument("pase-only", 0, 1, &mPaseOnly); break; case PairingMode::Ethernet: + AddArgument("skip-commissioning-complete", 0, 1, &mSkipCommissioningComplete); AddArgument("setup-pin-code", 0, 134217727, &mSetupPINCode); AddArgument("discriminator", 0, 4096, &mDiscriminator); AddArgument("device-remote-ip", &mRemoteAddr); @@ -169,6 +174,7 @@ class PairingCommand : public CHIPCommand, chip::Optional mDiscoverOnce; chip::Optional mUseOnlyOnNetworkDiscovery; chip::Optional mPaseOnly; + chip::Optional mSkipCommissioningComplete; uint16_t mRemotePort; uint16_t mDiscriminator; uint32_t mSetupPINCode; diff --git a/examples/common/pigweed/rpc_services/Attributes.h b/examples/common/pigweed/rpc_services/Attributes.h index 298df264a682ec..abc9dd1268b6fa 100644 --- a/examples/common/pigweed/rpc_services/Attributes.h +++ b/examples/common/pigweed/rpc_services/Attributes.h @@ -23,7 +23,6 @@ #include "pigweed/rpc_services/internal/StatusUtils.h" #include #include -#include #include #include #include diff --git a/examples/common/pigweed/rpc_services/Lighting.h b/examples/common/pigweed/rpc_services/Lighting.h index e8a96c6f4bdec3..533267a54c59bd 100644 --- a/examples/common/pigweed/rpc_services/Lighting.h +++ b/examples/common/pigweed/rpc_services/Lighting.h @@ -23,7 +23,7 @@ #include "pigweed/rpc_services/internal/StatusUtils.h" #include #include -#include +#include #include namespace chip { @@ -42,12 +42,12 @@ class Lighting : public pw_rpc::nanopb::Lighting::Service uint8_t on = request.on; RETURN_STATUS_IF_NOT_OK( - emberAfWriteServerAttribute(1, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, &on, ZCL_BOOLEAN_ATTRIBUTE_ID)); + emberAfWriteServerAttribute(1, app::Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, &on, ZCL_BOOLEAN_ATTRIBUTE_ID)); if (mSupportLevel && request.has_level) { // Clip level to max uint8_t level = std::min(request.level, static_cast(std::numeric_limits::max())); - RETURN_STATUS_IF_NOT_OK(emberAfWriteServerAttribute(kEndpoint, ZCL_LEVEL_CONTROL_CLUSTER_ID, + RETURN_STATUS_IF_NOT_OK(emberAfWriteServerAttribute(kEndpoint, app::Clusters::LevelControl::Id, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, &level, ZCL_INT8U_ATTRIBUTE_TYPE)); } @@ -58,8 +58,8 @@ class Lighting : public pw_rpc::nanopb::Lighting::Service uint8_t hue = std::min(request.color.hue, kColorMax); uint8_t saturation = std::min(request.color.saturation, kColorMax); RETURN_STATUS_IF_NOT_OK(emberAfWriteServerAttribute( - 1, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID, &hue, ZCL_INT8U_ATTRIBUTE_TYPE)); - RETURN_STATUS_IF_NOT_OK(emberAfWriteServerAttribute(kEndpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, + 1, app::Clusters::ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID, &hue, ZCL_INT8U_ATTRIBUTE_TYPE)); + RETURN_STATUS_IF_NOT_OK(emberAfWriteServerAttribute(kEndpoint, app::Clusters::ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, &saturation, ZCL_INT8U_ATTRIBUTE_TYPE)); } @@ -74,22 +74,22 @@ class Lighting : public pw_rpc::nanopb::Lighting::Service uint8_t level; uint8_t hue; uint8_t saturation; - RETURN_STATUS_IF_NOT_OK(emberAfReadServerAttribute(1, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, &on, sizeof(on))); + RETURN_STATUS_IF_NOT_OK(emberAfReadServerAttribute(1, app::Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, &on, sizeof(on))); response.on = on; if (mSupportLevel) { - RETURN_STATUS_IF_NOT_OK( - emberAfReadServerAttribute(1, ZCL_LEVEL_CONTROL_CLUSTER_ID, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, &level, sizeof(level))); + RETURN_STATUS_IF_NOT_OK(emberAfReadServerAttribute(1, app::Clusters::LevelControl::Id, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, + &level, sizeof(level))); response.level = level; response.has_level = true; } if (mSupportColor) { - RETURN_STATUS_IF_NOT_OK(emberAfReadServerAttribute(kEndpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, + RETURN_STATUS_IF_NOT_OK(emberAfReadServerAttribute(kEndpoint, app::Clusters::ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID, &hue, sizeof(hue))); - RETURN_STATUS_IF_NOT_OK(emberAfReadServerAttribute(kEndpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, + RETURN_STATUS_IF_NOT_OK(emberAfReadServerAttribute(kEndpoint, app::Clusters::ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, &saturation, sizeof(saturation))); response.color.hue = hue; diff --git a/examples/common/pigweed/rpc_services/internal/StatusUtils.h b/examples/common/pigweed/rpc_services/internal/StatusUtils.h index 0eaab65d6706a0..444759f818efa2 100644 --- a/examples/common/pigweed/rpc_services/internal/StatusUtils.h +++ b/examples/common/pigweed/rpc_services/internal/StatusUtils.h @@ -43,7 +43,7 @@ constexpr pw::Status EmberStatusToPwStatus(EmberAfStatus ember_status) return pw::OkStatus(); case EMBER_ZCL_STATUS_NOT_FOUND: return pw::Status::NotFound(); - case EMBER_ZCL_STATUS_NOT_AUTHORIZED: + case EMBER_ZCL_STATUS_UNSUPPORTED_ACCESS: return pw::Status::PermissionDenied(); default: return pw::Status::Unknown(); diff --git a/examples/common/pigweed/telink/PigweedLoggerMutex.cpp b/examples/common/pigweed/telink/PigweedLoggerMutex.cpp new file mode 100644 index 00000000000000..5061d53e768a6d --- /dev/null +++ b/examples/common/pigweed/telink/PigweedLoggerMutex.cpp @@ -0,0 +1,27 @@ +/* + * + * Copyright (c) 2021 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 "PigweedLoggerMutex.h" + +namespace chip { +namespace rpc { + +PigweedLoggerMutex logger_mutex; + +} // namespace rpc +} // namespace chip diff --git a/examples/common/pigweed/telink/PigweedLoggerMutex.h b/examples/common/pigweed/telink/PigweedLoggerMutex.h new file mode 100644 index 00000000000000..9a9b7e57d5dfea --- /dev/null +++ b/examples/common/pigweed/telink/PigweedLoggerMutex.h @@ -0,0 +1,52 @@ +/* + * + * Copyright (c) 2021 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 "PigweedLogger.h" +#include "pigweed/RpcService.h" +#include + +namespace chip { +namespace rpc { +class PigweedLoggerMutex : public ::chip::rpc::Mutex +{ +public: + PigweedLoggerMutex() {} + void Lock() override + { + k_sem * sem = PigweedLogger::GetSemaphore(); + if (sem) + { + k_sem_take(sem, K_FOREVER); + } + } + void Unlock() override + { + k_sem * sem = PigweedLogger::GetSemaphore(); + if (sem) + { + k_sem_give(sem); + } + } +}; + +extern PigweedLoggerMutex logger_mutex; + +} // namespace rpc +} // namespace chip diff --git a/examples/contact-sensor-app/contact-sensor-common/contact-sensor-app.matter b/examples/contact-sensor-app/contact-sensor-common/contact-sensor-app.matter index 5fb1dbfd1cbaaa..10d4a9698fa39d 100644 --- a/examples/contact-sensor-app/contact-sensor-common/contact-sensor-app.matter +++ b/examples/contact-sensor-app/contact-sensor-common/contact-sensor-app.matter @@ -1255,7 +1255,7 @@ server cluster OccupancySensing = 1030 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1525,7 +1525,7 @@ endpoint 0 { } } endpoint 1 { - device type dimmablelight = 21; + device type dimmablelight = 21, version 1; server cluster Identify { ram attribute identifyTime; diff --git a/examples/contact-sensor-app/nxp/k32w/k32w0/main/AppTask.cpp b/examples/contact-sensor-app/nxp/k32w/k32w0/main/AppTask.cpp index 437573fc215cf1..ef070c33c64273 100644 --- a/examples/contact-sensor-app/nxp/k32w/k32w0/main/AppTask.cpp +++ b/examples/contact-sensor-app/nxp/k32w/k32w0/main/AppTask.cpp @@ -32,7 +32,7 @@ #include #include -#include +#include #include /* OTA related includes */ @@ -854,7 +854,7 @@ void AppTask::UpdateClusterStateInternal(intptr_t arg) uint8_t newValue = ContactSensorMgr().IsContactClosed(); // write the new on/off value - EmberAfStatus status = emberAfWriteAttribute(1, ZCL_BOOLEAN_STATE_CLUSTER_ID, ZCL_STATE_VALUE_ATTRIBUTE_ID, + EmberAfStatus status = emberAfWriteAttribute(1, app::Clusters::BooleanState::Id, ZCL_STATE_VALUE_ATTRIBUTE_ID, (uint8_t *) &newValue, ZCL_BOOLEAN_ATTRIBUTE_TYPE); if (status != EMBER_ZCL_STATUS_SUCCESS) { @@ -873,7 +873,8 @@ void AppTask::UpdateDeviceStateInternal(intptr_t arg) bool stateValueAttrValue = 0; /* get onoff attribute value */ - (void) emberAfReadAttribute(1, ZCL_BOOLEAN_STATE_CLUSTER_ID, ZCL_STATE_VALUE_ATTRIBUTE_ID, (uint8_t *) &stateValueAttrValue, 1); + (void) emberAfReadAttribute(1, app::Clusters::BooleanState::Id, ZCL_STATE_VALUE_ATTRIBUTE_ID, (uint8_t *) &stateValueAttrValue, + 1); #if !cPWR_UsePowerDownMode /* set the device state */ sContactSensorLED.Set(stateValueAttrValue); diff --git a/examples/darwin-framework-tool/BUILD.gn b/examples/darwin-framework-tool/BUILD.gn index 5a9fbabfbbe5b2..c11da0692038df 100644 --- a/examples/darwin-framework-tool/BUILD.gn +++ b/examples/darwin-framework-tool/BUILD.gn @@ -27,6 +27,11 @@ assert(chip_build_tools) declare_args() { chip_codesign = current_os == "ios" + + # When config_enable_yaml_tests is false, the Matter SDK options are not available. + if (!config_enable_yaml_tests) { + chip_inet_config_enable_ipv4 = true + } } sdk = "macosx" @@ -68,6 +73,10 @@ action("build-darwin-framework") { ] } + if (defined(chip_inet_config_enable_ipv4) && !chip_inet_config_enable_ipv4) { + args += [ "--no-ipv4" ] + } + output_name = "Matter.framework" outputs = [ "${root_out_dir}/macos_framework_output/Build/Products/${output_sdk_type}/${output_name}", @@ -143,20 +152,6 @@ executable("darwin-framework-tool") { deps = [ ":build-darwin-framework", - "${chip_root}/src/app/tests/suites/commands/delay", - - # IM is needed for MTRError - "${chip_root}/src/app/tests/suites/commands/interaction_model", - - # Log is needed by tests UserPrompt and Log - "${chip_root}/src/app/tests/suites/commands/log", - - # System is needed by tests FactoryReset etc.. - "${chip_root}/src/app/tests/suites/commands/system", - - # pics is needed by tests - "${chip_root}/src/app/tests/suites/pics", - "${chip_root}/third_party/inipp", "${chip_root}/third_party/jsoncpp", ] @@ -175,6 +170,60 @@ executable("darwin-framework-tool") { "Security.framework", ] + # When config_enable_yaml_tests=true the Matter SDK is pulled in as a dependency because the code of the test suite + # uses some helpers from the Matter SDK. As a result, the SDK is built twice. Once because of this dependency and once + # when the Matter.framework is built. + # It may results in different versions of the Matter SDK between the output binary and the linked Matter.framework. + # + # When config_enable_yaml_tests=false the Matter SDK is built once when the Matter.framework is built and the resulting + # libCHIP.a library is linked statically to the output binary. + if (config_enable_yaml_tests) { + deps += [ + "${chip_root}/src/app/tests/suites/commands/delay", + + # IM is needed for MTRError + "${chip_root}/src/app/tests/suites/commands/interaction_model", + + # Log is needed by tests UserPrompt and Log + "${chip_root}/src/app/tests/suites/commands/log", + + # System is needed by tests FactoryReset etc.. + "${chip_root}/src/app/tests/suites/commands/system", + + # pics is needed by tests + "${chip_root}/src/app/tests/suites/pics", + ] + } else { + include_dirs = [ + "${chip_root}/config/standalone/", + "${chip_root}/src/", + "${chip_root}/src/include/", + "${chip_root}/third_party/nlassert/repo/include/", + "${chip_root}/third_party/nlio/repo/include/", + "${chip_root}/zzz_generated/app-common/", + "${root_gen_dir}/include", + "${root_out_dir}/macos_framework_output/Build/Intermediates.noindex/Matter.build/${output_sdk_type}/Matter.build/out/gen/include", + ] + + defines = [ + "CHIP_HAVE_CONFIG_H=1", + "CHIP_SYSTEM_CONFIG_USE_SOCKETS=1", + ] + + frameworks += [ + "CoreFoundation.framework", + "Foundation.framework", + "CoreBluetooth.framework", + "Network.framework", + ] + + # Other SDKs are linked statically to Matter.framework but the macosx SDK is linked dynamically but needs some symbols that are + # not exposed by the dylib. + if (sdk == "macosx") { + libs = [ "${root_out_dir}/macos_framework_output/Build/Intermediates.noindex/Matter.build/${output_sdk_type}/Matter.build/out/lib/libCHIP.a" ] + } + } + public_configs = [ ":config" ] output_dir = root_out_dir diff --git a/examples/darwin-framework-tool/commands/clusters/ModelCommandBridge.h b/examples/darwin-framework-tool/commands/clusters/ModelCommandBridge.h index df6cf196c04569..447d2c2ae5ccf6 100644 --- a/examples/darwin-framework-tool/commands/clusters/ModelCommandBridge.h +++ b/examples/darwin-framework-tool/commands/clusters/ModelCommandBridge.h @@ -24,8 +24,6 @@ class ModelCommand : public CHIPCommandBridge { public: - using ChipDevice = ::chip::OperationalDeviceProxy; - ModelCommand(const char * _Nonnull commandName) : CHIPCommandBridge(commandName) {} void AddArguments() diff --git a/examples/darwin-framework-tool/commands/common/CHIPCommandBridge.h b/examples/darwin-framework-tool/commands/common/CHIPCommandBridge.h index ca11c746e30e09..bf5e7b49fce0fd 100644 --- a/examples/darwin-framework-tool/commands/common/CHIPCommandBridge.h +++ b/examples/darwin-framework-tool/commands/common/CHIPCommandBridge.h @@ -21,6 +21,7 @@ #include #include #include +#include #include #include "../provider/OTAProviderDelegate.h" diff --git a/examples/darwin-framework-tool/commands/common/CHIPCommandBridge.mm b/examples/darwin-framework-tool/commands/common/CHIPCommandBridge.mm index e886eed2c56b0c..613a7737181b52 100644 --- a/examples/darwin-framework-tool/commands/common/CHIPCommandBridge.mm +++ b/examples/darwin-framework-tool/commands/common/CHIPCommandBridge.mm @@ -124,7 +124,7 @@ NSArray * paaCertResults; ReturnLogErrorOnFailure(GetPAACertsFromFolder(&paaCertResults)); if ([paaCertResults count] > 0) { - params.paaCerts = paaCertResults; + params.productAttestationAuthorityCertificates = paaCertResults; } NSError * error; diff --git a/examples/darwin-framework-tool/commands/interactive/InteractiveCommands.mm b/examples/darwin-framework-tool/commands/interactive/InteractiveCommands.mm index 7fe2d7d236d933..a251d517e6b83e 100644 --- a/examples/darwin-framework-tool/commands/interactive/InteractiveCommands.mm +++ b/examples/darwin-framework-tool/commands/interactive/InteractiveCommands.mm @@ -17,7 +17,8 @@ */ #include "InteractiveCommands.h" -#import + +#include #include #include diff --git a/examples/darwin-framework-tool/commands/pairing/OpenCommissioningWindowCommand.h b/examples/darwin-framework-tool/commands/pairing/OpenCommissioningWindowCommand.h index e9fc4ce373b352..68c0d2b7aab6aa 100644 --- a/examples/darwin-framework-tool/commands/pairing/OpenCommissioningWindowCommand.h +++ b/examples/darwin-framework-tool/commands/pairing/OpenCommissioningWindowCommand.h @@ -31,8 +31,8 @@ class OpenCommissioningWindowCommand : public CHIPCommandBridge "1 to use Enhanced Commissioning Method.\n 0 to use Basic Commissioning Method."); AddArgument("window-timeout", 0, UINT16_MAX, &mCommissioningWindowTimeoutMs, "Time, in seconds, before the commissioning window closes."); - AddArgument("iteration", chip::kSpake2p_Min_PBKDF_Iterations, chip::kSpake2p_Max_PBKDF_Iterations, &mIteration, - "Number of PBKDF iterations to use to derive the verifier. Ignored if 'option' is 0."); + AddArgument("iteration", chip::Crypto::kSpake2p_Min_PBKDF_Iterations, chip::Crypto::kSpake2p_Max_PBKDF_Iterations, + &mIteration, "Number of PBKDF iterations to use to derive the verifier. Ignored if 'option' is 0."); AddArgument("discriminator", 0, 4096, &mDiscriminator, "Discriminator to use for advertising. Ignored if 'option' is 0."); AddArgument("timeout", 0, UINT16_MAX, &mTimeout, "Time, in seconds, before this command is considered to have timed out."); } diff --git a/examples/darwin-framework-tool/commands/provider/OTAProviderDelegate.h b/examples/darwin-framework-tool/commands/provider/OTAProviderDelegate.h index f213e064019572..40c02ecbad0eec 100644 --- a/examples/darwin-framework-tool/commands/provider/OTAProviderDelegate.h +++ b/examples/darwin-framework-tool/commands/provider/OTAProviderDelegate.h @@ -24,7 +24,7 @@ typedef NS_ENUM(uint8_t, UserConsentState) { OTAProviderUserUnknown = 0x03, }; -@interface DeviceSoftwareVersionModelData : MTROtaSoftwareUpdateProviderClusterQueryImageParams +@interface DeviceSoftwareVersionModelData : MTROTASoftwareUpdateProviderClusterQueryImageParams @property BOOL softwareVersionValid; @property (strong, nonatomic, nullable) NSNumber * cDVersionNumber; @property (strong, nonatomic, nullable) NSNumber * minApplicableSoftwareVersion; @@ -32,7 +32,7 @@ typedef NS_ENUM(uint8_t, UserConsentState) { @property (strong, nonatomic, nullable) NSString * otaURL; @end -@interface DeviceSoftwareVersionModel : MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams +@interface DeviceSoftwareVersionModel : MTROTASoftwareUpdateProviderClusterQueryImageResponseParams @property (strong, nonatomic, nullable) DeviceSoftwareVersionModelData * deviceModelData; - (NSComparisonResult)CompareSoftwareVersions:(DeviceSoftwareVersionModel * _Nullable)otherObject; @end @@ -40,28 +40,28 @@ typedef NS_ENUM(uint8_t, UserConsentState) { @interface OTAProviderDelegate : NSObject - (void)handleQueryImageForNodeID:(NSNumber * _Nonnull)nodeID controller:(MTRDeviceController * _Nonnull)controller - params:(MTROtaSoftwareUpdateProviderClusterQueryImageParams * _Nonnull)params - completion:(void (^_Nonnull)(MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, + params:(MTROTASoftwareUpdateProviderClusterQueryImageParams * _Nonnull)params + completion:(void (^_Nonnull)(MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error))completion; - (void)handleApplyUpdateRequestForNodeID:(NSNumber * _Nonnull)nodeID controller:(MTRDeviceController * _Nonnull)controller - params:(MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams * _Nonnull)params + params:(MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams * _Nonnull)params completion: - (void (^_Nonnull)(MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, + (void (^_Nonnull)(MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, NSError * _Nullable error))completion; - (void)handleNotifyUpdateAppliedForNodeID:(NSNumber * _Nonnull)nodeID controller:(MTRDeviceController * _Nonnull)controller - params:(MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams * _Nonnull)params + params:(MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams * _Nonnull)params completion:(MTRStatusCompletion _Nonnull)completion; @property (strong, nonatomic, nullable) NSArray * candidates; @property (strong, nonatomic, nullable) DeviceSoftwareVersionModel * selectedCandidate; @property (strong, nonatomic, nullable) NSNumber * nodeID; -@property (nonatomic, readwrite) MTROtaSoftwareUpdateProviderOTAQueryStatus queryImageStatus; +@property (nonatomic, readwrite) MTROTASoftwareUpdateProviderOTAQueryStatus queryImageStatus; @property (nonatomic, readwrite) UserConsentState userConsentState; -@property (nonatomic, readwrite) MTROtaSoftwareUpdateProviderOTAApplyUpdateAction action; +@property (nonatomic, readwrite) MTROTASoftwareUpdateProviderOTAApplyUpdateAction action; @property (nonatomic, readwrite, nullable) NSNumber * delayedActionTime; @property (nonatomic, readwrite, nullable) NSNumber * timedInvokeTimeoutMs; @property (nonatomic, readwrite, nullable) NSNumber * userConsentNeeded; diff --git a/examples/darwin-framework-tool/commands/provider/OTAProviderDelegate.mm b/examples/darwin-framework-tool/commands/provider/OTAProviderDelegate.mm index 50bb9086dc6801..68eef16bfc31fe 100644 --- a/examples/darwin-framework-tool/commands/provider/OTAProviderDelegate.mm +++ b/examples/darwin-framework-tool/commands/provider/OTAProviderDelegate.mm @@ -35,26 +35,26 @@ - (instancetype)init { if (self = [super init]) { _selectedCandidate = [[DeviceSoftwareVersionModel alloc] init]; - _action = MTROtaSoftwareUpdateProviderOTAApplyUpdateActionProceed; + _action = MTROTASoftwareUpdateProviderOTAApplyUpdateActionProceed; _userConsentState = OTAProviderUserUnknown; _delayedActionTime = nil; _timedInvokeTimeoutMs = nil; _userConsentNeeded = nil; - _queryImageStatus = MTROtaSoftwareUpdateProviderOTAQueryStatusNotAvailable; + _queryImageStatus = MTROTASoftwareUpdateProviderOTAQueryStatusNotAvailable; } return self; } - (void)handleQueryImageForNodeID:(NSNumber * _Nonnull)nodeID controller:(MTRDeviceController * _Nonnull)controller - params:(MTROtaSoftwareUpdateProviderClusterQueryImageParams * _Nonnull)params - completion:(void (^_Nonnull)(MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, + params:(MTROTASoftwareUpdateProviderClusterQueryImageParams * _Nonnull)params + completion:(void (^_Nonnull)(MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error))completion { auto isBDXProtocolSupported = - [params.protocolsSupported containsObject:@(MTROtaSoftwareUpdateProviderOTADownloadProtocolBDXSynchronous)]; + [params.protocolsSupported containsObject:@(MTROTASoftwareUpdateProviderOTADownloadProtocolBDXSynchronous)]; if (!isBDXProtocolSupported) { - _selectedCandidate.status = @(MTROtaSoftwareUpdateProviderOTAQueryStatusDownloadProtocolNotSupported); + _selectedCandidate.status = @(MTROTASoftwareUpdateProviderOTAQueryStatusDownloadProtocolNotSupported); completion(_selectedCandidate, nil); return; } @@ -62,7 +62,7 @@ - (void)handleQueryImageForNodeID:(NSNumber * _Nonnull)nodeID auto hasCandidate = [self SelectOTACandidate:params.vendorId rPID:params.productId rSV:params.softwareVersion]; if (!hasCandidate) { NSLog(@"Unable to select OTA Image."); - _selectedCandidate.status = @(MTROtaSoftwareUpdateProviderOTAQueryStatusNotAvailable); + _selectedCandidate.status = @(MTROTASoftwareUpdateProviderOTAQueryStatusNotAvailable); completion(_selectedCandidate, nil); return; } @@ -80,13 +80,13 @@ - (void)handleQueryImageForNodeID:(NSNumber * _Nonnull)nodeID - (void)handleApplyUpdateRequestForNodeID:(NSNumber * _Nonnull)nodeID controller:(MTRDeviceController * _Nonnull)controller - params:(MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams * _Nonnull)params + params:(MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams * _Nonnull)params completion: - (void (^_Nonnull)(MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, + (void (^_Nonnull)(MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, NSError * _Nullable error))completion { - MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * applyUpdateResponseParams = - [[MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams alloc] init]; + MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams * applyUpdateResponseParams = + [[MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams alloc] init]; applyUpdateResponseParams.action = @(_action); if (_delayedActionTime) { applyUpdateResponseParams.delayedActionTime = _delayedActionTime; @@ -100,7 +100,7 @@ - (void)handleApplyUpdateRequestForNodeID:(NSNumber * _Nonnull)nodeID - (void)handleNotifyUpdateAppliedForNodeID:(NSNumber * _Nonnull)nodeID controller:(MTRDeviceController * _Nonnull)controller - params:(MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams * _Nonnull)params + params:(MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams * _Nonnull)params completion:(MTRStatusCompletion _Nonnull)completion { completion(nil); diff --git a/examples/darwin-framework-tool/commands/provider/OTASoftwareUpdateInteractive.mm b/examples/darwin-framework-tool/commands/provider/OTASoftwareUpdateInteractive.mm index ad3966a86b1411..2e6734bea4c38f 100644 --- a/examples/darwin-framework-tool/commands/provider/OTASoftwareUpdateInteractive.mm +++ b/examples/darwin-framework-tool/commands/provider/OTASoftwareUpdateInteractive.mm @@ -161,14 +161,14 @@ static bool ParseJsonFileAndPopulateCandidates( { CHIP_ERROR error = CHIP_NO_ERROR; if (action == 0) { - mOTADelegate.action = MTROtaSoftwareUpdateProviderOTAApplyUpdateActionProceed; - ChipLogDetail(chipTool, "Successfully set action to: MTROtaSoftwareUpdateProviderOTAApplyUpdateActionProceed"); + mOTADelegate.action = MTROTASoftwareUpdateProviderOTAApplyUpdateActionProceed; + ChipLogDetail(chipTool, "Successfully set action to: MTROTASoftwareUpdateProviderOTAApplyUpdateActionProceed"); } else if (action == 1) { - mOTADelegate.action = MTROtaSoftwareUpdateProviderOTAApplyUpdateActionAwaitNextAction; - ChipLogDetail(chipTool, "Successfully set action to: MTROtaSoftwareUpdateProviderOTAApplyUpdateActionAwaitNextAction"); + mOTADelegate.action = MTROTASoftwareUpdateProviderOTAApplyUpdateActionAwaitNextAction; + ChipLogDetail(chipTool, "Successfully set action to: MTROTASoftwareUpdateProviderOTAApplyUpdateActionAwaitNextAction"); } else if (action == 2) { - mOTADelegate.action = MTROtaSoftwareUpdateProviderOTAApplyUpdateActionDiscontinue; - ChipLogDetail(chipTool, "Successfully set action to: MTROtaSoftwareUpdateProviderOTAApplyUpdateActionDiscontinue"); + mOTADelegate.action = MTROTASoftwareUpdateProviderOTAApplyUpdateActionDiscontinue; + ChipLogDetail(chipTool, "Successfully set action to: MTROTASoftwareUpdateProviderOTAApplyUpdateActionDiscontinue"); } else { ChipLogError(chipTool, "Only accepts the following: 0 (Proceed), 1 (Await Next Action), 2 (Discontinue)"); error = CHIP_ERROR_INTERNAL; @@ -179,18 +179,18 @@ static bool ParseJsonFileAndPopulateCandidates( { CHIP_ERROR error = CHIP_NO_ERROR; if (status == 0) { - mOTADelegate.queryImageStatus = MTROtaSoftwareUpdateProviderOTAQueryStatusUpdateAvailable; - ChipLogDetail(chipTool, "Successfully set status to: MTROtaSoftwareUpdateProviderOTAQueryStatusUpdateAvailable"); + mOTADelegate.queryImageStatus = MTROTASoftwareUpdateProviderOTAQueryStatusUpdateAvailable; + ChipLogDetail(chipTool, "Successfully set status to: MTROTASoftwareUpdateProviderOTAQueryStatusUpdateAvailable"); } else if (status == 1) { - mOTADelegate.queryImageStatus = MTROtaSoftwareUpdateProviderOTAQueryStatusBusy; - ChipLogDetail(chipTool, "Successfully set status to: MTROtaSoftwareUpdateProviderOTAQueryStatusBusy"); + mOTADelegate.queryImageStatus = MTROTASoftwareUpdateProviderOTAQueryStatusBusy; + ChipLogDetail(chipTool, "Successfully set status to: MTROTASoftwareUpdateProviderOTAQueryStatusBusy"); } else if (status == 2) { - mOTADelegate.queryImageStatus = MTROtaSoftwareUpdateProviderOTAQueryStatusNotAvailable; - ChipLogDetail(chipTool, "Successfully set status to: MTROtaSoftwareUpdateProviderOTAQueryStatusNotAvailable"); + mOTADelegate.queryImageStatus = MTROTASoftwareUpdateProviderOTAQueryStatusNotAvailable; + ChipLogDetail(chipTool, "Successfully set status to: MTROTASoftwareUpdateProviderOTAQueryStatusNotAvailable"); } else if (status == 4) { - mOTADelegate.queryImageStatus = MTROtaSoftwareUpdateProviderOTAQueryStatusDownloadProtocolNotSupported; + mOTADelegate.queryImageStatus = MTROTASoftwareUpdateProviderOTAQueryStatusDownloadProtocolNotSupported; ChipLogDetail( - chipTool, "Successfully set status to: MTROtaSoftwareUpdateProviderOTAQueryStatusDownloadProtocolNotSupported"); + chipTool, "Successfully set status to: MTROTASoftwareUpdateProviderOTAQueryStatusDownloadProtocolNotSupported"); } else { ChipLogError(chipTool, "Only accepts the following: 0 (Available), 1 (Busy), 2 (Not Available), 3 (Not Supported)"); error = CHIP_ERROR_INTERNAL; diff --git a/examples/darwin-framework-tool/main.mm b/examples/darwin-framework-tool/main.mm index f0aeab45f78342..58a37ebb2ce42b 100644 --- a/examples/darwin-framework-tool/main.mm +++ b/examples/darwin-framework-tool/main.mm @@ -28,9 +28,15 @@ #include #include +#include + int main(int argc, const char * argv[]) { @autoreleasepool { + MTRSetLogCallback(MTRLogTypeDetail, ^(MTRLogType type, NSString * component, NSString * message) { + fprintf(stdout, "CHIP:%s: %s\n", component.UTF8String, message.UTF8String); + }); + Commands commands; registerCommandsPairing(commands); registerCommandsInteractive(commands); diff --git a/examples/darwin-framework-tool/templates/commands.zapt b/examples/darwin-framework-tool/templates/commands.zapt index be91419dcd835b..2d39ca2cd29d7f 100644 --- a/examples/darwin-framework-tool/templates/commands.zapt +++ b/examples/darwin-framework-tool/templates/commands.zapt @@ -46,8 +46,8 @@ public: ChipLogProgress(chipTool, "Sending cluster ({{asHex parent.code 8}}) command ({{asHex code 8}}) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseCluster{{asUpperCamelCase clusterName}} * cluster = [[MTRBaseCluster{{asUpperCamelCase clusterName}} alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - __auto_type * params = [[MTR{{asUpperCamelCase clusterName}}Cluster{{asUpperCamelCase name}}Params alloc] init]; + __auto_type * cluster = [[MTRBaseCluster{{asUpperCamelCase clusterName preserveAcronyms=true}} alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTR{{asUpperCamelCase clusterName preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}Params alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; {{#chip_cluster_command_arguments}} {{>decodable_value target=(concat "params." (asStructPropertyName label)) source=(concat "mRequest." (asLowerCamelCase label)) cluster=parent.clusterName type=type depth=0}} @@ -58,7 +58,7 @@ public: { [cluster {{asLowerCamelCase name}}WithParams:params completion: {{#if hasSpecificResponse}} - ^(MTR{{asUpperCamelCase clusterName}}Cluster{{asUpperCamelCase responseName}}Params * _Nullable values, NSError * _Nullable error) { + ^(MTR{{asUpperCamelCase clusterName preserveAcronyms=true}}Cluster{{asUpperCamelCase responseName}}Params * _Nullable values, NSError * _Nullable error) { NSLog(@"Values: %@", values); {{else}} ^(NSError * _Nullable error) { @@ -90,7 +90,8 @@ private: {{/chip_cluster_commands}} {{#chip_server_cluster_attributes}} -{{#*inline "attribute"}}Attribute{{asUpperCamelCase name}}{{/inline}} +{{#*inline "cluster"}}Cluster{{asUpperCamelCase parent.name preserveAcronyms=true}}{{/inline}} +{{#*inline "attribute"}}Attribute{{asUpperCamelCase name preserveAcronyms=true}}{{/inline}} /* * Attribute {{asUpperCamelCase name}} @@ -111,23 +112,23 @@ public: ChipLogProgress(chipTool, "Sending cluster ({{asHex parent.code 8}}) ReadAttribute ({{asHex code 8}}) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseCluster{{asUpperCamelCase parent.name}} * cluster = [[MTRBaseCluster{{asUpperCamelCase parent.name}} alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBase{{>cluster}} alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; {{#if_is_fabric_scoped_struct type}} - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; if (mFabricFiltered.HasValue()) { params.filterByFabric = mFabricFiltered.Value(); } {{/if_is_fabric_scoped_struct}} - [cluster readAttribute{{asUpperCamelCase name}}With + [cluster read{{>attribute}}With {{~#if_is_fabric_scoped_struct type~}} Params:params completion: {{~else~}} Completion: {{~/if_is_fabric_scoped_struct~}} ^({{asObjectiveCClass type parent.name}} * _Nullable value, NSError * _Nullable error) { - NSLog(@"{{asUpperCamelCase parent.name}}.{{asUpperCamelCase name}} response %@", [value description]); + NSLog(@"{{asUpperCamelCase parent.name preserveAcronyms=true}}.{{asUpperCamelCase name preserveAcronyms=true}} response %@", [value description]); if (error != nil) { - LogNSError("{{asUpperCamelCase parent.name}} {{asUpperCamelCase name}} read Error", error); + LogNSError("{{asUpperCamelCase parent.name preserveAcronyms=true}} {{asUpperCamelCase name preserveAcronyms=true}} read Error", error); } SetCommandExitStatus(error); }]; @@ -163,8 +164,8 @@ public: { ChipLogProgress(chipTool, "Sending cluster ({{asHex parent.code 8}}) WriteAttribute ({{asHex code 8}}) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseCluster{{asUpperCamelCase parent.name}} * cluster = [[MTRBaseCluster{{asUpperCamelCase parent.name}} alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBase{{>cluster}} alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; {{#if_chip_complex}} @@ -178,9 +179,9 @@ public: {{asObjectiveCType type parent.name}} value = [NSNumber numberWith{{asObjectiveCNumberType "" type false}}:mValue]; {{/if_chip_complex}} - [cluster writeAttribute{{asUpperCamelCase name}}WithValue:value params:params completion:^(NSError * _Nullable error) { + [cluster write{{>attribute}}WithValue:value params:params completion:^(NSError * _Nullable error) { if (error != nil) { - LogNSError("{{asUpperCamelCase parent.name}} {{asUpperCamelCase name}} write Error", error); + LogNSError("{{asUpperCamelCase parent.name preserveAcronyms=true}} {{asUpperCamelCase name preserveAcronyms=true}} write Error", error); } SetCommandExitStatus(error); }]; @@ -217,8 +218,8 @@ public: { ChipLogProgress(chipTool, "Sending cluster ({{asHex parent.code 8}}) ReportAttribute ({{asHex code 8}}) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseCluster{{asUpperCamelCase parent.name}} * cluster = [[MTRBaseCluster{{asUpperCamelCase parent.name}} alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBase{{>cluster}} alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -231,7 +232,7 @@ public: [cluster subscribe{{>attribute}}WithParams:params subscriptionEstablished:^(){ mSubscriptionEstablished=YES; } reportHandler:^({{asObjectiveCClass type parent.name}} * _Nullable value, NSError * _Nullable error) { - NSLog(@"{{asUpperCamelCase parent.name}}.{{asUpperCamelCase name}} response %@", [value description]); + NSLog(@"{{asUpperCamelCase parent.name preserveAcronyms=true}}.{{asUpperCamelCase name preserveAcronyms=true}} response %@", [value description]); SetCommandExitStatus(error); }]; diff --git a/examples/darwin-framework-tool/templates/tests/ciTests.json b/examples/darwin-framework-tool/templates/tests/ciTests.json index 50f8ce2e3add50..fa2baf9081e469 100644 --- a/examples/darwin-framework-tool/templates/tests/ciTests.json +++ b/examples/darwin-framework-tool/templates/tests/ciTests.json @@ -6,6 +6,7 @@ "TestEvents", "TestDiscovery", "TestGroupMessaging", + "Test_TC_BRBINFO_2_1", "Test_TC_DGTHREAD_2_1", "Test_TC_DGTHREAD_2_2", "Test_TC_DGTHREAD_2_3", diff --git a/examples/darwin-framework-tool/templates/tests/commands.zapt b/examples/darwin-framework-tool/templates/tests/commands.zapt index adfa4662f7b1c5..4040d94975a8be 100644 --- a/examples/darwin-framework-tool/templates/tests/commands.zapt +++ b/examples/darwin-framework-tool/templates/tests/commands.zapt @@ -4,6 +4,7 @@ #if CONFIG_ENABLE_YAML_TESTS +#include #include #include #include diff --git a/examples/darwin-framework-tool/templates/tests/partials/test_cluster.zapt b/examples/darwin-framework-tool/templates/tests/partials/test_cluster.zapt index b364cc98f6e2a5..64536ad71655f9 100644 --- a/examples/darwin-framework-tool/templates/tests/partials/test_cluster.zapt +++ b/examples/darwin-framework-tool/templates/tests/partials/test_cluster.zapt @@ -126,6 +126,8 @@ class {{filename}}: public TestCommandBridge {{#*inline "testCommand"}}Test{{asUpperCamelCase label}}_{{index}}{{/inline}} CHIP_ERROR {{>testCommand}}() { + {{#*inline "cluster"}}{{asUpperCamelCase cluster preserveAcronyms=true}}{{/inline}} + {{#*inline "attribute"}}{{asUpperCamelCase attribute preserveAcronyms=true}}{{/inline}} {{#if (isTestOnlyCluster cluster)}} {{asEncodableType}} value; {{#chip_tests_item_parameters}} @@ -134,19 +136,19 @@ class {{filename}}: public TestCommandBridge return {{command}}("{{identity}}", value); {{else}} MTRBaseDevice * device = GetDevice("{{identity}}"); - MTRBaseCluster{{asUpperCamelCase cluster}} * cluster = [[MTRBaseCluster{{asUpperCamelCase cluster}} alloc] initWithDevice:device endpointID:@({{endpoint}}) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseCluster{{>cluster}} alloc] initWithDevice:device endpointID:@({{endpoint}}) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); {{#if isCommand}} {{#if commandObject.arguments.length}} - __auto_type * params = [[MTR{{asUpperCamelCase cluster}}Cluster{{asUpperCamelCase command}}Params alloc] init]; + __auto_type * params = [[MTR{{>cluster}}Cluster{{asUpperCamelCase command preserveAcronyms=true}}Params alloc] init]; {{/if}} {{#chip_tests_item_parameters}} {{>test_value target=(concat "params." (asStructPropertyName label)) definedValue=definedValue cluster=parent.cluster depth=0}} {{/chip_tests_item_parameters}} [cluster {{asLowerCamelCase command}}With{{#if commandObject.arguments.length}}Params:params completion{{else}}Completion{{/if}}: {{#if commandObject.hasSpecificResponse}} - ^(MTR{{asUpperCamelCase cluster}}Cluster{{asUpperCamelCase commandObject.responseName}}Params * _Nullable values, NSError * _Nullable err) { + ^(MTR{{>cluster}}Cluster{{asUpperCamelCase commandObject.responseName}}Params * _Nullable values, NSError * _Nullable err) { {{else}} ^(NSError * _Nullable err) { {{/if}} @@ -154,11 +156,11 @@ class {{filename}}: public TestCommandBridge {{#chip_tests_item_parameters}} {{asObjectiveCBasicType type}} {{asLowerCamelCase name}}Argument = {{asTypedLiteral definedValue type}}; {{/chip_tests_item_parameters}} - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) maxInterval:@(maxIntervalArgument)]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) maxInterval:@(maxIntervalArgument)]; params.filterByFabric = {{#if fabricFiltered}}true{{else}}false{{/if}}; params.replaceExistingSubscriptions = {{#if keepSubscriptions}}false{{else}}true{{/if}}; - [cluster subscribeAttribute{{asUpperCamelCase attribute}}WithParams:params - subscriptionEstablished:^{ + [cluster subscribeAttribute{{>attribute}}WithParams:params + subscriptionEstablished:^{ VerifyOrReturn(testSendCluster{{parent.filename}}_{{waitForReport.index}}_{{asUpperCamelCase waitForReport.command}}_Fulfilled, SetCommandExitStatus(CHIP_ERROR_INCORRECT_STATE)); NextTest(); } @@ -167,10 +169,10 @@ class {{filename}}: public TestCommandBridge {{> subscribeDataCallback }} = ^({{asObjectiveCClass attributeObject.type cluster forceList=attributeObject.isArray}} * _Nullable value, NSError * _Nullable err) { {{else if isReadAttribute}} {{#if_is_fabric_scoped_struct attributeObject.type}} - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = {{fabricFiltered}}; {{/if_is_fabric_scoped_struct}} - [cluster readAttribute{{asUpperCamelCase attribute}}With + [cluster readAttribute{{>attribute}}With {{~#if_is_fabric_scoped_struct attributeObject.type~}} Params:params completion: {{~else~}} @@ -182,7 +184,7 @@ class {{filename}}: public TestCommandBridge id {{asLowerCamelCase name}}Argument; {{>test_value target=(concat (asLowerCamelCase name) "Argument") definedValue=definedValue cluster=parent.cluster depth=0}} {{/chip_tests_item_parameters}} - [cluster writeAttribute{{asUpperCamelCase attribute}}WithValue:{{#chip_tests_item_parameters}}{{asLowerCamelCase name}}Argument{{/chip_tests_item_parameters}} completion:^(NSError * _Nullable err) { + [cluster writeAttribute{{>attribute}}WithValue:{{#chip_tests_item_parameters}}{{asLowerCamelCase name}}Argument{{/chip_tests_item_parameters}} completion:^(NSError * _Nullable err) { {{/if}} NSLog(@"{{label}} Error: %@", err); diff --git a/examples/dynamic-bridge-app/bridge-common/bridge-app.matter b/examples/dynamic-bridge-app/bridge-common/bridge-app.matter index 935c1c8077c50b..1d162d6635192c 100644 --- a/examples/dynamic-bridge-app/bridge-common/bridge-app.matter +++ b/examples/dynamic-bridge-app/bridge-common/bridge-app.matter @@ -1201,7 +1201,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1453,7 +1453,7 @@ server cluster TemperatureMeasurement = 1026 { } endpoint 0 { - device type bridge = 22; + device type bridge = 22, version 1; binding cluster AccessControl; server cluster Descriptor { @@ -1743,7 +1743,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 14; + device type anonymousEndpointType = 14, version 1; binding cluster Binding; server cluster Identify { @@ -1780,7 +1780,7 @@ endpoint 1 { } } endpoint 2 { - device type dimmablelight = 257; + device type dimmablelight = 257, version 1; server cluster OnOff { ram attribute onOff; diff --git a/examples/dynamic-bridge-app/linux/DynamicDevice.cpp b/examples/dynamic-bridge-app/linux/DynamicDevice.cpp index 9f0ca3951e8ce0..e9b99c94b0537a 100644 --- a/examples/dynamic-bridge-app/linux/DynamicDevice.cpp +++ b/examples/dynamic-bridge-app/linux/DynamicDevice.cpp @@ -19,7 +19,7 @@ #include #include -#include +#include #include "DynamicDevice.h" @@ -55,7 +55,7 @@ Device DynamicDevice::CreateDevice() // Force a default descriptor cluster to be present. mClusterDecls.emplace_back( - EmberAfCluster DECLARE_DYNAMIC_CLUSTER(ZCL_DESCRIPTOR_CLUSTER_ID, descriptorAttrs, nullptr, nullptr)); + EmberAfCluster DECLARE_DYNAMIC_CLUSTER(chip::app::Clusters::Descriptor::Id, descriptorAttrs, nullptr, nullptr)); return Device(chip::Span(mVersions.data(), mVersions.size()), chip::Span(mClusterDecls.data(), mClusterDecls.size()), diff --git a/examples/dynamic-bridge-app/linux/bridge_service.h b/examples/dynamic-bridge-app/linux/bridge_service.h index d2e05416a0a74f..faa744e7fba228 100644 --- a/examples/dynamic-bridge-app/linux/bridge_service.h +++ b/examples/dynamic-bridge-app/linux/bridge_service.h @@ -23,7 +23,6 @@ #include "pigweed/rpc_services/internal/StatusUtils.h" #include #include -#include #include namespace chip { diff --git a/examples/dynamic-bridge-app/linux/main.cpp b/examples/dynamic-bridge-app/linux/main.cpp index efb339582e3085..1c6ed2300771c7 100644 --- a/examples/dynamic-bridge-app/linux/main.cpp +++ b/examples/dynamic-bridge-app/linux/main.cpp @@ -23,7 +23,6 @@ #include #include -#include #include #include #include diff --git a/examples/java-matter-controller/BUILD.gn b/examples/java-matter-controller/BUILD.gn index 154f75aba19227..9830b360195c1d 100644 --- a/examples/java-matter-controller/BUILD.gn +++ b/examples/java-matter-controller/BUILD.gn @@ -58,9 +58,6 @@ java_binary("java-matter-controller") { "java/src/com/matter/controller/commands/pairing/PairingModeType.java", "java/src/com/matter/controller/commands/pairing/PairingNetworkType.java", "java/src/com/matter/controller/commands/pairing/UnpairCommand.java", - "java/src/com/matter/controller/config/PersistentStorage.java", - "java/src/com/matter/controller/config/PersistentStorageOpCertStore.java", - "java/src/com/matter/controller/config/PersistentStorageOperationalKeystore.java", ] javac_flags = [ "-Xlint:deprecation" ] diff --git a/examples/java-matter-controller/java/src/com/matter/controller/Main.java b/examples/java-matter-controller/java/src/com/matter/controller/Main.java index 5478add7cfea56..8a22143b17a767 100644 --- a/examples/java-matter-controller/java/src/com/matter/controller/Main.java +++ b/examples/java-matter-controller/java/src/com/matter/controller/Main.java @@ -24,8 +24,12 @@ import com.matter.controller.commands.discover.*; import com.matter.controller.commands.pairing.*; import java.util.ArrayList; +import java.util.logging.Level; +import java.util.logging.Logger; public class Main { + private static Logger logger = Logger.getLogger(Main.class.getName()); + private static void registerCommandsDiscover( ChipDeviceController controller, CommandManager commandManager, @@ -109,9 +113,9 @@ public static void main(String[] args) { try { commandManager.run(args); } catch (IllegalArgumentException e) { - System.out.println("Arguments init failed with exception: " + e.getMessage()); + logger.log(Level.INFO, "Arguments init failed with exception: " + e.getMessage()); } catch (Exception e) { - System.out.println("Run command failed with exception: " + e.getMessage()); + logger.log(Level.INFO, "Run command failed with exception: " + e.getMessage()); } controller.shutdownCommissioning(); } diff --git a/examples/java-matter-controller/java/src/com/matter/controller/commands/common/Argument.java b/examples/java-matter-controller/java/src/com/matter/controller/commands/common/Argument.java index 559c244834c231..c9d911bdc7f347 100644 --- a/examples/java-matter-controller/java/src/com/matter/controller/commands/common/Argument.java +++ b/examples/java-matter-controller/java/src/com/matter/controller/commands/common/Argument.java @@ -33,59 +33,78 @@ public final class Argument { private final long mMax; private final Object mValue; private final Optional mDesc; + private final boolean mOptional; - public Argument(String name, IPAddress value) { + boolean isOptional() { + return mOptional; + } + + public Argument(String name, IPAddress value, boolean optional) { this.mName = name; this.mType = ArgumentType.ADDRESS; this.mMin = 0; this.mMax = 0; this.mValue = value; this.mDesc = Optional.empty(); + this.mOptional = optional; } - public Argument(String name, StringBuffer value, @Nullable String desc) { + public Argument(String name, StringBuffer value, @Nullable String desc, boolean optional) { this.mName = name; this.mType = ArgumentType.STRING; this.mMin = 0; this.mMax = 0; this.mValue = value; this.mDesc = Optional.ofNullable(desc); + this.mOptional = optional; } - public Argument(String name, AtomicBoolean value, @Nullable String desc) { + public Argument(String name, AtomicBoolean value, @Nullable String desc, boolean optional) { this.mName = name; this.mType = ArgumentType.BOOL; this.mMin = 0; this.mMax = 0; this.mValue = value; this.mDesc = Optional.ofNullable(desc); + this.mOptional = optional; } - public Argument(String name, short min, short max, AtomicInteger value, @Nullable String desc) { + public Argument( + String name, + short min, + short max, + AtomicInteger value, + @Nullable String desc, + boolean optional) { this.mName = name; this.mType = ArgumentType.NUMBER_INT16; this.mMin = min; this.mMax = max; this.mValue = value; this.mDesc = Optional.ofNullable(desc); + this.mOptional = optional; } - public Argument(String name, int min, int max, AtomicInteger value, @Nullable String desc) { + public Argument( + String name, int min, int max, AtomicInteger value, @Nullable String desc, boolean optional) { this.mName = name; this.mType = ArgumentType.NUMBER_INT32; this.mMin = min; this.mMax = max; this.mValue = value; this.mDesc = Optional.ofNullable(desc); + this.mOptional = optional; } - public Argument(String name, long min, long max, AtomicLong value, @Nullable String desc) { + public Argument( + String name, long min, long max, AtomicLong value, @Nullable String desc, boolean optional) { this.mName = name; this.mType = ArgumentType.NUMBER_INT64; this.mMin = min; this.mMax = max; this.mValue = value; this.mDesc = Optional.ofNullable(desc); + this.mOptional = optional; } public String getName() { diff --git a/examples/java-matter-controller/java/src/com/matter/controller/commands/common/Command.java b/examples/java-matter-controller/java/src/com/matter/controller/commands/common/Command.java index 13ed473f43285f..fe33e2459c2c31 100644 --- a/examples/java-matter-controller/java/src/com/matter/controller/commands/common/Command.java +++ b/examples/java-matter-controller/java/src/com/matter/controller/commands/common/Command.java @@ -32,6 +32,8 @@ * Matter devices from the environment. */ public abstract class Command { + private static final String OPTIONAL_ARGUMENT_PREFIX = "--"; + private static final int OPTIONAL_ARGUMENT_PREFIX_LENGTH = 2; private final String mName; private final ArrayList mArgs = new ArrayList(); private final Optional mHelpText; @@ -74,6 +76,10 @@ public final int getArgumentsCount() { return mArgs.size(); } + public final boolean getArgumentIsOptional(int index) { + return mArgs.get(index).isOptional(); + } + /** * @brief Get argument description if it exists * @return A pointer to an Optional where the argument description will be stored @@ -82,17 +88,35 @@ public final Optional getArgumentDescription(int index) { return mArgs.get(index).getDesc(); } + public final void addArgumentToList(Argument arg, boolean optional) { + if (arg.isOptional() || mArgs.isEmpty()) { + // Safe to just append to the end of a list. + mArgs.add(arg); + return; + } + + // mandatory arg needs to be inserted before the optional arguments. + int index = 0; + while (index < mArgs.size() && !mArgs.get(index).isOptional()) { + index++; + } + + // Insert before the first optional arg. + mArgs.add(index, arg); + } + /** * @brief Add a bool command argument * @param name The name that will be displayed in the command help * @param out A pointer to a MutableInteger where the argv value will be stored * @param desc The description of the argument that will be displayed in the command help + * @param optional Indicate if an optional argument * @return The number of arguments currently added to the command */ - public final int addArgument(String name, AtomicBoolean out, @Nullable String desc) { - Argument arg = new Argument(name, out, desc); - mArgs.add(arg); - return mArgs.size(); + public final void addArgument( + String name, AtomicBoolean out, @Nullable String desc, boolean optional) { + Argument arg = new Argument(name, out, desc, optional); + addArgumentToList(arg, optional); } /** @@ -102,13 +126,18 @@ public final int addArgument(String name, AtomicBoolean out, @Nullable String de * @param max The minimum value of the argv value * @param out A pointer to a MutableInteger where the argv value will be stored * @param desc The description of the argument that will be displayed in the command help + * @param optional Indicate if an optional argument * @return The number of arguments currently added to the command */ - public final int addArgument( - String name, short min, short max, AtomicInteger out, @Nullable String desc) { - Argument arg = new Argument(name, min, max, out, desc); - mArgs.add(arg); - return mArgs.size(); + public final void addArgument( + String name, + short min, + short max, + AtomicInteger out, + @Nullable String desc, + boolean optional) { + Argument arg = new Argument(name, min, max, out, desc, optional); + addArgumentToList(arg, optional); } /** @@ -118,13 +147,13 @@ public final int addArgument( * @param max The minimum value of the argv value * @param out A pointer to a MutableInteger where the argv value will be stored * @param desc The description of the argument that will be displayed in the command help + * @param optional Indicate if an optional argument * @return The number of arguments currently added to the command */ - public final int addArgument( - String name, int min, int max, AtomicInteger out, @Nullable String desc) { - Argument arg = new Argument(name, min, max, out, desc); - mArgs.add(arg); - return mArgs.size(); + public final void addArgument( + String name, int min, int max, AtomicInteger out, @Nullable String desc, boolean optional) { + Argument arg = new Argument(name, min, max, out, desc, optional); + addArgumentToList(arg, optional); } /** @@ -134,25 +163,25 @@ public final int addArgument( * @param max The minimum value of the argv value * @param out A pointer to a MutableInteger where the argv value will be stored * @param desc The description of the argument that will be displayed in the command help + * @param optional Indicate if an optional argument * @return The number of arguments currently added to the command */ - public final int addArgument( - String name, long min, long max, AtomicLong out, @Nullable String desc) { - Argument arg = new Argument(name, min, max, out, desc); - mArgs.add(arg); - return mArgs.size(); + public final void addArgument( + String name, long min, long max, AtomicLong out, @Nullable String desc, boolean optional) { + Argument arg = new Argument(name, min, max, out, desc, optional); + addArgumentToList(arg, optional); } /** * @brief Add an IP address command argument * @param name The name that will be displayed in the command help * @param out A pointer to a IPAddress where the argv value will be stored + * @param optional Indicate if an optional argument * @return The number of arguments currently added to the command */ - public final int addArgument(String name, IPAddress out) { - Argument arg = new Argument(name, out); - mArgs.add(arg); - return mArgs.size(); + public final void addArgument(String name, IPAddress out, boolean optional) { + Argument arg = new Argument(name, out, optional); + addArgumentToList(arg, optional); } /** @@ -160,12 +189,13 @@ public final int addArgument(String name, IPAddress out) { * @param name The name that will be displayed in the command help * @param out A pointer to a StringBuffer where the argv value will be stored * @param desc The description of the argument that will be displayed in the command help + * @param optional Indicate if an optional argument * @return The number of arguments currently added to the command */ - public final int addArgument(String name, StringBuffer out, @Nullable String desc) { - Argument arg = new Argument(name, out, desc); - mArgs.add(arg); - return mArgs.size(); + public final void addArgument( + String name, StringBuffer out, @Nullable String desc, boolean optional) { + Argument arg = new Argument(name, out, desc, optional); + addArgumentToList(arg, optional); } /** @@ -174,15 +204,44 @@ public final int addArgument(String name, StringBuffer out, @Nullable String des * @param args Supplied command-line arguments as an array of String objects. */ public final void initArguments(int argc, String[] args) { - int argsCount = mArgs.size(); + int mandatoryArgsCount = 0; + int currentIndex = 0; - if (argsCount != argc) { + for (Argument arg : mArgs) { + if (!arg.isOptional()) { + mandatoryArgsCount++; + } + } + + if (argc < mandatoryArgsCount) { throw new IllegalArgumentException( - "Wrong arguments number: " + argc + " instead of " + argsCount); + "initArguments: Wrong arguments number: " + argc + " instead of " + mandatoryArgsCount); + } + + // Initialize mandatory arguments + for (int i = 0; i < mandatoryArgsCount; i++) { + initArgument(currentIndex++, args[i]); } - for (int i = 0; i < argsCount; i++) { - initArgument(i, args[i]); + // Initialize optional arguments + // Optional arguments expect a name and a value, so i is increased by 2 on every step. + for (int i = mandatoryArgsCount; i < argc; i += 2) { + // optional arguments starts with OPTIONAL_ARGUMENT_PREFIX + if (args[i].length() <= OPTIONAL_ARGUMENT_PREFIX_LENGTH + && !args[i].startsWith(OPTIONAL_ARGUMENT_PREFIX)) { + throw new IllegalArgumentException("initArguments: Invalid optional argument: " + args[i]); + } + + if (args[i] + .substring(OPTIONAL_ARGUMENT_PREFIX_LENGTH) + .equals(mArgs.get(currentIndex).getName())) { + if (i + 1 >= argc) { + throw new IllegalArgumentException( + "initArguments: Optional argument " + args[i] + " missing value"); + } + + initArgument(currentIndex++, args[i + 1]); + } } } diff --git a/examples/java-matter-controller/java/src/com/matter/controller/commands/common/CommandManager.java b/examples/java-matter-controller/java/src/com/matter/controller/commands/common/CommandManager.java index ad6cd6808ce907..933a1d5b9c1796 100644 --- a/examples/java-matter-controller/java/src/com/matter/controller/commands/common/CommandManager.java +++ b/examples/java-matter-controller/java/src/com/matter/controller/commands/common/CommandManager.java @@ -22,11 +22,15 @@ import java.util.Arrays; import java.util.HashMap; import java.util.Map; +import java.util.Optional; +import java.util.logging.Level; +import java.util.logging.Logger; public final class CommandManager { private final ArrayList mCommandMgr = new ArrayList(); private final Map> mClusters = new HashMap>(); + private static Logger logger = Logger.getLogger(CommandManager.class.getName()); public final void register(String clusterName, ArrayList commandsList) { mClusters.put(clusterName, commandsList); @@ -36,20 +40,20 @@ public final void run(String[] args) { Command command; if (args.length < 1) { - System.out.println("Missing cluster name"); + logger.log(Level.INFO, "Missing cluster name"); showClusters(); return; } ArrayList commands = mClusters.get(args[0]); if (commands == null) { - System.out.println("Unknown cluster: " + args[0]); + logger.log(Level.INFO, "Unknown cluster: " + args[0]); showClusters(); return; } if (args.length < 2) { - System.out.println("Missing command name"); + logger.log(Level.INFO, "Missing command name"); showCluster(args[0], commands); return; } @@ -63,27 +67,27 @@ public final void run(String[] args) { } } else if (isEventCommand(args[1])) { if (args.length < 3) { - System.out.println("Missing event name"); + logger.log(Level.INFO, "Missing event name"); showClusterEvents(args[0], args[1], commands); throw new IllegalArgumentException(); } command = getGlobalCommand(commands, args[1], args[2]); if (command == null) { - System.out.println("Unknown event: " + args[2]); + logger.log(Level.INFO, "Unknown event: " + args[2]); showClusterEvents(args[0], args[1], commands); throw new IllegalArgumentException(); } } else { if (args.length < 3) { - System.out.println("Missing attribute name"); + logger.log(Level.INFO, "Missing attribute name"); showClusterAttributes(args[0], args[1], commands); throw new IllegalArgumentException(); } command = getGlobalCommand(commands, args[1], args[2]); if (command == null) { - System.out.println("Unknown attribute: " + args[2]); + logger.log(Level.INFO, "Unknown attribute: " + args[2]); showClusterAttributes(args[0], args[1], commands); throw new IllegalArgumentException(); } @@ -96,9 +100,10 @@ public final void run(String[] args) { command.initArguments(temp.length, temp); command.run(); } catch (IllegalArgumentException e) { - System.out.println("Arguments init failed with exception: " + e.getMessage()); - } catch (Exception e) { System.out.println("Run command failed with exception: " + e.getMessage()); + showCommand(args[0], command); + } catch (Exception e) { + logger.log(Level.INFO, "Run command failed with exception: " + e.getMessage()); } } @@ -138,34 +143,43 @@ private Command getGlobalCommand( } private void showClusters() { - System.out.println("Usage:"); - System.out.println(" java-matter-controller cluster_name command_name [param1 param2 ...]"); - System.out.println("\n"); - System.out.println( + logger.log(Level.INFO, "Usage:"); + logger.log( + Level.INFO, " java-matter-controller cluster_name command_name [param1 param2 ...]"); + logger.log(Level.INFO, "\n"); + logger.log( + Level.INFO, " +-------------------------------------------------------------------------------------+"); - System.out.println( + logger.log( + Level.INFO, " | Clusters: |"); - System.out.println( + logger.log( + Level.INFO, " +-------------------------------------------------------------------------------------+"); for (String key : mClusters.keySet()) { System.out.printf(" | * %-82s|\n", key.toLowerCase()); } - System.out.println( + logger.log( + Level.INFO, " +-------------------------------------------------------------------------------------+"); } private void showCluster(String clusterName, ArrayList commands) { - System.out.println("Usage:"); - System.out.println( + logger.log(Level.INFO, "Usage:"); + logger.log( + Level.INFO, " java-matter-controller " + clusterName + " command_name [param1 param2 ...]"); - System.out.println("\n"); - System.out.println( + logger.log(Level.INFO, "\n"); + logger.log( + Level.INFO, " +-------------------------------------------------------------------------------------+"); - System.out.println( + logger.log( + Level.INFO, " | Commands: |"); - System.out.println( + logger.log( + Level.INFO, " +-------------------------------------------------------------------------------------+"); boolean readCommand = false; boolean writeCommand = false; @@ -196,44 +210,52 @@ private void showCluster(String clusterName, ArrayList commands) { System.out.printf(" | * %-82s|\n", cmdName); } } - System.out.println( + logger.log( + Level.INFO, " +-------------------------------------------------------------------------------------+\n"); } private void showClusterAttributes( String clusterName, String commandName, ArrayList commands) { - System.out.println("Usage:"); + logger.log(Level.INFO, "Usage:"); System.out.printf( " java-matter-controller %s %s attribute-name [param1 param2 ...]\n", clusterName, commandName); - System.out.println("\n"); - System.out.println( + logger.log(Level.INFO, "\n"); + logger.log( + Level.INFO, " +-------------------------------------------------------------------------------------+"); - System.out.println( + logger.log( + Level.INFO, " | Attributes: |"); - System.out.println( + logger.log( + Level.INFO, " +-------------------------------------------------------------------------------------+"); for (Command command : commands) { if (commandName.equals(command.getName())) { System.out.printf(" | * %-82s|\n", command.getAttribute().get()); } } - System.out.println( + logger.log( + Level.INFO, " +-------------------------------------------------------------------------------------+"); } private void showClusterEvents( String clusterName, String commandName, ArrayList commands) { - System.out.println("Usage:"); + logger.log(Level.INFO, "Usage:"); System.out.printf( " java-matter-controller %s %s event-name [param1 param2 ...]\n", clusterName, commandName); - System.out.println("\n"); - System.out.println( + logger.log(Level.INFO, "\n"); + logger.log( + Level.INFO, " +-------------------------------------------------------------------------------------+"); - System.out.println( + logger.log( + Level.INFO, " | Events: |"); - System.out.println( + logger.log( + Level.INFO, " +-------------------------------------------------------------------------------------+"); for (Command command : commands) { @@ -241,7 +263,49 @@ private void showClusterEvents( System.out.printf(" | * %-82s|\n", command.getAttribute().get()); } } - System.out.println( + logger.log( + Level.INFO, " +-------------------------------------------------------------------------------------+"); } + + private void showCommand(String clusterName, Command command) { + logger.log(Level.INFO, "Usage:"); + + String arguments = command.getName(); + String description = ""; + + int argumentsCount = command.getArgumentsCount(); + for (int i = 0; i < argumentsCount; i++) { + String arg = ""; + boolean isOptional = command.getArgumentIsOptional(i); + if (isOptional) { + arg += "[--"; + } + arg += command.getArgumentName(i); + if (isOptional) { + arg += "]"; + } + arguments += " "; + arguments += arg; + + Optional argDescription = command.getArgumentDescription(i); + if (argDescription.isPresent()) { + description += "\n"; + description += arg; + description += ":\n "; + description += argDescription.get(); + description += "\n"; + } + } + System.out.format(" java-matter-controller %s %s\n", clusterName, arguments); + + Optional helpText = command.getHelpText(); + if (helpText.isPresent()) { + System.out.format("\n%s\n", helpText.get()); + } + + if (!description.isEmpty()) { + logger.log(Level.INFO, description); + } + } } diff --git a/examples/java-matter-controller/java/src/com/matter/controller/commands/common/MatterCommand.java b/examples/java-matter-controller/java/src/com/matter/controller/commands/common/MatterCommand.java index 9aefec5d81b63a..b892c0bf678282 100644 --- a/examples/java-matter-controller/java/src/com/matter/controller/commands/common/MatterCommand.java +++ b/examples/java-matter-controller/java/src/com/matter/controller/commands/common/MatterCommand.java @@ -19,21 +19,12 @@ package com.matter.controller.commands.common; import chip.devicecontroller.ChipDeviceController; -import com.matter.controller.config.PersistentStorage; -import com.matter.controller.config.PersistentStorageOpCertStore; -import com.matter.controller.config.PersistentStorageOperationalKeystore; import java.util.Optional; import java.util.concurrent.atomic.AtomicBoolean; import java.util.concurrent.atomic.AtomicLong; public abstract class MatterCommand extends Command { private final ChipDeviceController mChipDeviceController; - private final PersistentStorage mDefaultStorage = new PersistentStorage(); - private final PersistentStorage mCommissionerStorage = new PersistentStorage(); - private final PersistentStorageOperationalKeystore mOperationalKeystore = - new PersistentStorageOperationalKeystore(); - private final PersistentStorageOpCertStore mOpCertStore = new PersistentStorageOpCertStore(); - private final Optional mCredIssuerCmds; private final StringBuffer mCommissionerName = new StringBuffer(); private final StringBuffer mPaaTrustStorePath = new StringBuffer(); @@ -57,40 +48,43 @@ public MatterCommand( this.mCredIssuerCmds = Optional.ofNullable(credIssuerCmds); this.mChipDeviceController = controller; - // TODO: Add support to enable the below optional arguments - /* addArgument( "paa-trust-store-path", mPaaTrustStorePath, "Path to directory holding PAA certificate information. Can be absolute or relative to the current working " - + "directory."); + + "directory.", + true); addArgument( "cd-trust-store-path", mCDTrustStorePath, "Path to directory holding CD certificate information. Can be absolute or relative to the current working " - + "directory."); + + "directory.", + true); addArgument( "commissioner-name", mCommissionerName, "Name of fabric to use. Valid values are \"alpha\", \"beta\", \"gamma\", and integers greater than or equal to " - + "4. The default if not specified is \"alpha\"."); + + "4. The default if not specified is \"alpha\".", + true); addArgument( "commissioner-nodeid", 0, Long.MAX_VALUE, mCommissionerNodeId, - "The node id to use for chip-tool. If not provided, kTestControllerNodeId (112233, 0x1B669) will be used."); + "The node id to use for java-matter-controller. If not provided, kTestControllerNodeId (112233, 0x1B669) will be used.", + true); addArgument( "use-max-sized-certs", mUseMaxSizedCerts, "Maximize the size of operational certificates. If not provided or 0 (\"false\"), normally sized operational " - + "certificates are generated."); + + "certificates are generated.", + true); addArgument( "only-allow-trusted-cd-keys", mOnlyAllowTrustedCdKeys, "Only allow trusted CD verifying keys (disallow test keys). If not provided or 0 (\"false\"), untrusted CD " - + "verifying keys are allowed. If 1 (\"true\"), test keys are disallowed."); - */ + + "verifying keys are allowed. If 1 (\"true\"), test keys are disallowed.", + true); } // This method returns the commissioner instance to be used for running the command. @@ -101,24 +95,11 @@ public ChipDeviceController currentCommissioner() { /////////// Command Interface ///////// @Override public void run() throws Exception { - // TODO: setup chip storage from Java, currently it is using example one from chip-tool - // maybeSetUpStack(); runCommand(); - // maybeTearDownStack(); } protected abstract void runCommand(); - private void maybeSetUpStack() throws Exception { - mDefaultStorage.init(); - mOperationalKeystore.init(mDefaultStorage); - mOpCertStore.init(mDefaultStorage); - } - - private void maybeTearDownStack() { - // ToDo:We need to call DeviceController::Shutdown() - } - public void setTestResult(String result) { mTestResult = Optional.of(result); } diff --git a/examples/java-matter-controller/java/src/com/matter/controller/commands/discover/DiscoverCommand.java b/examples/java-matter-controller/java/src/com/matter/controller/commands/discover/DiscoverCommand.java index 3d0bf2518e9098..988e97bb23c3b8 100644 --- a/examples/java-matter-controller/java/src/com/matter/controller/commands/discover/DiscoverCommand.java +++ b/examples/java-matter-controller/java/src/com/matter/controller/commands/discover/DiscoverCommand.java @@ -29,8 +29,8 @@ public final class DiscoverCommand extends MatterCommand { public DiscoverCommand(ChipDeviceController controller, CredentialsIssuer credsIssuer) { super(controller, "resolve", credsIssuer); - addArgument("nodeid", 0, Long.MAX_VALUE, mNodeId, null); - addArgument("fabricid", 0, Long.MAX_VALUE, mFabricId, null); + addArgument("nodeid", 0, Long.MAX_VALUE, mNodeId, null, false); + addArgument("fabricid", 0, Long.MAX_VALUE, mFabricId, null, false); } @Override diff --git a/examples/java-matter-controller/java/src/com/matter/controller/commands/pairing/CloseSessionCommand.java b/examples/java-matter-controller/java/src/com/matter/controller/commands/pairing/CloseSessionCommand.java index ce3e263665866a..f8b911217594ec 100644 --- a/examples/java-matter-controller/java/src/com/matter/controller/commands/pairing/CloseSessionCommand.java +++ b/examples/java-matter-controller/java/src/com/matter/controller/commands/pairing/CloseSessionCommand.java @@ -30,13 +30,14 @@ public final class CloseSessionCommand extends MatterCommand { public CloseSessionCommand(ChipDeviceController controller, CredentialsIssuer credsIssuer) { super(controller, "close-session", credsIssuer); - addArgument("destination-id", 0, Long.MAX_VALUE, mDestinationId, null); + addArgument("destination-id", 0, Long.MAX_VALUE, mDestinationId, null, false); addArgument( "timeout", (short) 0, Short.MAX_VALUE, mTimeoutSecs, - "Time, in seconds, before this command is considered to have timed out."); + "Time, in seconds, before this command is considered to have timed out.", + false); } @Override diff --git a/examples/java-matter-controller/java/src/com/matter/controller/commands/pairing/PairingCommand.java b/examples/java-matter-controller/java/src/com/matter/controller/commands/pairing/PairingCommand.java index 323c3bd2cb12fa..c6e209095bfca8 100644 --- a/examples/java-matter-controller/java/src/com/matter/controller/commands/pairing/PairingCommand.java +++ b/examples/java-matter-controller/java/src/com/matter/controller/commands/pairing/PairingCommand.java @@ -27,6 +27,8 @@ import java.util.concurrent.atomic.AtomicBoolean; import java.util.concurrent.atomic.AtomicInteger; import java.util.concurrent.atomic.AtomicLong; +import java.util.logging.Level; +import java.util.logging.Logger; public abstract class PairingCommand extends MatterCommand implements ChipDeviceController.CompletionListener { @@ -48,6 +50,8 @@ public abstract class PairingCommand extends MatterCommand private final StringBuffer mOnboardingPayload = new StringBuffer(); private final StringBuffer mDiscoveryFilterInstanceName = new StringBuffer(); + private static Logger logger = Logger.getLogger(PairingCommand.class.getName()); + public long getNodeId() { return mNodeId.get(); } @@ -66,17 +70,17 @@ public long getTimeoutMillis() { @Override public void onConnectDeviceComplete() { - System.out.println("onConnectDeviceComplete"); + logger.log(Level.INFO, "onConnectDeviceComplete"); } @Override public void onStatusUpdate(int status) { - System.out.println("onStatusUpdate with status: " + status); + logger.log(Level.INFO, "onStatusUpdate with status: " + status); } @Override public void onPairingComplete(int errorCode) { - System.out.println("onPairingComplete with error code: " + errorCode); + logger.log(Level.INFO, "onPairingComplete with error code: " + errorCode); if (errorCode != 0) { setTestResult("Failure"); } @@ -84,12 +88,12 @@ public void onPairingComplete(int errorCode) { @Override public void onPairingDeleted(int errorCode) { - System.out.println("onPairingDeleted with error code: " + errorCode); + logger.log(Level.INFO, "onPairingDeleted with error code: " + errorCode); } @Override public void onCommissioningComplete(long nodeId, int errorCode) { - System.out.println("onCommissioningComplete with error code: " + errorCode); + logger.log(Level.INFO, "onCommissioningComplete with error code: " + errorCode); if (errorCode == 0) { setTestResult("Success"); } else { @@ -100,33 +104,33 @@ public void onCommissioningComplete(long nodeId, int errorCode) { @Override public void onReadCommissioningInfo( int vendorId, int productId, int wifiEndpointId, int threadEndpointId) { - System.out.println("onReadCommissioningInfo"); + logger.log(Level.INFO, "onReadCommissioningInfo"); } @Override public void onCommissioningStatusUpdate(long nodeId, String stage, int errorCode) { - System.out.println("onCommissioningStatusUpdate"); + logger.log(Level.INFO, "onCommissioningStatusUpdate"); } @Override public void onNotifyChipConnectionClosed() { - System.out.println("onNotifyChipConnectionClosed"); + logger.log(Level.INFO, "onNotifyChipConnectionClosed"); } @Override public void onCloseBleComplete() { - System.out.println("onCloseBleComplete"); + logger.log(Level.INFO, "onCloseBleComplete"); } @Override public void onError(Throwable error) { setTestResult(error.toString()); - System.out.println("onError with error: " + error.toString()); + logger.log(Level.INFO, "onError with error: " + error.toString()); } @Override public void onOpCSRGenerationComplete(byte[] csr) { - System.out.println("onOpCSRGenerationComplete"); + logger.log(Level.INFO, "onOpCSRGenerationComplete"); for (int i = 0; i < csr.length; i++) { System.out.print(csr[i] + " "); } @@ -163,18 +167,18 @@ public PairingCommand( throw new RuntimeException(e); } - addArgument("node-id", 0, Long.MAX_VALUE, mNodeId, null); + addArgument("node-id", 0, Long.MAX_VALUE, mNodeId, null, false); switch (networkType) { case NONE: case ETHERNET: break; case WIFI: - addArgument("ssid", mSSID, null); - addArgument("password", mPassword, null); + addArgument("ssid", mSSID, null, false); + addArgument("password", mPassword, null, false); break; case THREAD: - addArgument("operationalDataset", mOperationalDataset, null); + addArgument("operationalDataset", mOperationalDataset, null, false); break; } @@ -184,29 +188,29 @@ public PairingCommand( case CODE: case CODE_PASE_ONLY: Only: - addArgument("payload", mOnboardingPayload, null); - addArgument("discover-once", mDiscoverOnce, null); - addArgument("use-only-onnetwork-discovery", mUseOnlyOnNetworkDiscovery, null); + addArgument("payload", mOnboardingPayload, null, false); + addArgument("discover-once", mDiscoverOnce, null, false); + addArgument("use-only-onnetwork-discovery", mUseOnlyOnNetworkDiscovery, null, false); break; case BLE: - addArgument("setup-pin-code", 0, 134217727, mSetupPINCode, null); - addArgument("discriminator", (short) 0, (short) 4096, mDiscriminator, null); + addArgument("setup-pin-code", 0, 134217727, mSetupPINCode, null, false); + addArgument("discriminator", (short) 0, (short) 4096, mDiscriminator, null, false); break; case ON_NETWORK: - addArgument("setup-pin-code", 0, 134217727, mSetupPINCode, null); + addArgument("setup-pin-code", 0, 134217727, mSetupPINCode, null, false); break; case SOFT_AP: AP: - addArgument("setup-pin-code", 0, 134217727, mSetupPINCode, null); - addArgument("discriminator", (short) 0, (short) 4096, mDiscriminator, null); - addArgument("device-remote-ip", mRemoteAddr); - addArgument("device-remote-port", (short) 0, Short.MAX_VALUE, mRemotePort, null); + addArgument("setup-pin-code", 0, 134217727, mSetupPINCode, null, false); + addArgument("discriminator", (short) 0, (short) 4096, mDiscriminator, null, false); + addArgument("device-remote-ip", mRemoteAddr, false); + addArgument("device-remote-port", (short) 0, Short.MAX_VALUE, mRemotePort, null, false); break; case ETHERNET: - addArgument("setup-pin-code", 0, 134217727, mSetupPINCode, null); - addArgument("discriminator", (short) 0, (short) 4096, mDiscriminator, null); - addArgument("device-remote-ip", mRemoteAddr); - addArgument("device-remote-port", (short) 0, Short.MAX_VALUE, mRemotePort, null); + addArgument("setup-pin-code", 0, 134217727, mSetupPINCode, null, false); + addArgument("discriminator", (short) 0, (short) 4096, mDiscriminator, null, false); + addArgument("device-remote-ip", mRemoteAddr, false); + addArgument("device-remote-port", (short) 0, Short.MAX_VALUE, mRemotePort, null, false); break; } @@ -214,28 +218,28 @@ public PairingCommand( case NONE: break; case SHORT_DISCRIMINATOR: - addArgument("discriminator", (short) 0, (short) 4096, mDiscriminator, null); + addArgument("discriminator", (short) 0, (short) 4096, mDiscriminator, null, false); break; case LONG_DISCRIMINATOR: - addArgument("discriminator", (short) 0, (short) 4096, mDiscriminator, null); + addArgument("discriminator", (short) 0, (short) 4096, mDiscriminator, null, false); break; case VENDOR_ID: - addArgument("vendor-id", (short) 0, Short.MAX_VALUE, mDiscoveryFilterCode, null); + addArgument("vendor-id", (short) 0, Short.MAX_VALUE, mDiscoveryFilterCode, null, false); break; case COMPRESSED_FABRIC_ID: - addArgument("fabric-id", 0, Long.MAX_VALUE, mDiscoveryFilterCode, null); + addArgument("fabric-id", 0, Long.MAX_VALUE, mDiscoveryFilterCode, null, false); break; case COMMISSIONING_MODE: case COMMISSIONER: break; case DEVICE_TYPE: - addArgument("device-type", (short) 0, Short.MAX_VALUE, mDiscoveryFilterCode, null); + addArgument("device-type", (short) 0, Short.MAX_VALUE, mDiscoveryFilterCode, null, false); break; case INSTANCE_NAME: - addArgument("name", mDiscoveryFilterInstanceName, null); + addArgument("name", mDiscoveryFilterInstanceName, null, false); break; } - addArgument("timeout", (long) 0, Long.MAX_VALUE, mTimeoutMillis, null); + addArgument("timeout", (long) 0, Long.MAX_VALUE, mTimeoutMillis, null, false); } } diff --git a/examples/java-matter-controller/java/src/com/matter/controller/config/PersistentStorage.java b/examples/java-matter-controller/java/src/com/matter/controller/config/PersistentStorage.java deleted file mode 100644 index eea19943ddf83c..00000000000000 --- a/examples/java-matter-controller/java/src/com/matter/controller/config/PersistentStorage.java +++ /dev/null @@ -1,25 +0,0 @@ -/* - * Copyright (c) 2022 Project CHIP Authors - * All rights reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -package com.matter.controller.config; - -public class PersistentStorage { - public void init() throws Exception { - throw new Exception("Failed to initialize PersistentStorage"); - } -} diff --git a/examples/java-matter-controller/java/src/com/matter/controller/config/PersistentStorageOpCertStore.java b/examples/java-matter-controller/java/src/com/matter/controller/config/PersistentStorageOpCertStore.java deleted file mode 100644 index 04b5617e799c39..00000000000000 --- a/examples/java-matter-controller/java/src/com/matter/controller/config/PersistentStorageOpCertStore.java +++ /dev/null @@ -1,25 +0,0 @@ -/* - * Copyright (c) 2022 Project CHIP Authors - * All rights reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -package com.matter.controller.config; - -public class PersistentStorageOpCertStore { - public int init(PersistentStorage storage) throws Exception { - throw new Exception("Failed to initialize PersistentStorageOpCertStore"); - } -} diff --git a/examples/java-matter-controller/java/src/com/matter/controller/config/PersistentStorageOperationalKeystore.java b/examples/java-matter-controller/java/src/com/matter/controller/config/PersistentStorageOperationalKeystore.java deleted file mode 100644 index 819a129af27448..00000000000000 --- a/examples/java-matter-controller/java/src/com/matter/controller/config/PersistentStorageOperationalKeystore.java +++ /dev/null @@ -1,25 +0,0 @@ -/* - * Copyright (c) 2022 Project CHIP Authors - * All rights reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -package com.matter.controller.config; - -public class PersistentStorageOperationalKeystore { - public int init(PersistentStorage storage) throws Exception { - throw new Exception("Failed to initialize PersistentStorageOperationalKeystore"); - } -} diff --git a/examples/light-switch-app/ameba/main/DeviceCallbacks.cpp b/examples/light-switch-app/ameba/main/DeviceCallbacks.cpp index f1776a46a71426..679faf925f5873 100644 --- a/examples/light-switch-app/ameba/main/DeviceCallbacks.cpp +++ b/examples/light-switch-app/ameba/main/DeviceCallbacks.cpp @@ -26,7 +26,6 @@ #include "CHIPDeviceManager.h" #include -#include #include #include #include diff --git a/examples/light-switch-app/efr32/BUILD.gn b/examples/light-switch-app/efr32/BUILD.gn index 83704a8fa6cc1b..5c03b769dc964c 100644 --- a/examples/light-switch-app/efr32/BUILD.gn +++ b/examples/light-switch-app/efr32/BUILD.gn @@ -181,6 +181,7 @@ efr32_sdk("sdk") { efr32_executable("light_switch_app") { output_name = "chip-efr32-light-switch-example.out" + public_configs = [ "${efr32_sdk_build_root}:silabs_config" ] include_dirs = [ "include" ] defines = [] diff --git a/examples/light-switch-app/efr32/include/CHIPProjectConfig.h b/examples/light-switch-app/efr32/include/CHIPProjectConfig.h index 94c82dcbb0281d..1b74c802fd4f09 100644 --- a/examples/light-switch-app/efr32/include/CHIPProjectConfig.h +++ b/examples/light-switch-app/efr32/include/CHIPProjectConfig.h @@ -69,17 +69,6 @@ */ #define CHIP_DEVICE_CONFIG_DEVICE_HARDWARE_VERSION 1 -/** - * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING - * - * A string identifying the software version running on the device. - * CHIP service currently expects the software version to be in the format - * {MAJOR_VERSION}.0d{MINOR_VERSION} - */ -#ifndef CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING -#define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING "0.1ALPHA" -#endif - /** * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION * diff --git a/examples/light-switch-app/efr32/src/AppTask.cpp b/examples/light-switch-app/efr32/src/AppTask.cpp index 3a3b2434b416dd..e1bbc8d782c888 100644 --- a/examples/light-switch-app/efr32/src/AppTask.cpp +++ b/examples/light-switch-app/efr32/src/AppTask.cpp @@ -40,7 +40,6 @@ #include #include -#include #include #include #include diff --git a/examples/light-switch-app/genio/src/AppTask.cpp b/examples/light-switch-app/genio/src/AppTask.cpp index 9f12f221846739..4fd88497239959 100644 --- a/examples/light-switch-app/genio/src/AppTask.cpp +++ b/examples/light-switch-app/genio/src/AppTask.cpp @@ -27,7 +27,6 @@ #include #include -#include #include #include #include diff --git a/examples/light-switch-app/light-switch-common/light-switch-app.matter b/examples/light-switch-app/light-switch-common/light-switch-app.matter index 16ed6bc10db317..176bb914c61dea 100644 --- a/examples/light-switch-app/light-switch-common/light-switch-app.matter +++ b/examples/light-switch-app/light-switch-common/light-switch-app.matter @@ -1249,7 +1249,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1719,7 +1719,7 @@ client cluster ColorControl = 768 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Descriptor { @@ -1989,7 +1989,7 @@ endpoint 0 { } } endpoint 1 { - device type onofflightswitch = 259; + device type onofflightswitch = 259, version 1; binding cluster Identify; binding cluster Scenes; binding cluster OnOff; @@ -2026,7 +2026,7 @@ endpoint 1 { } } endpoint 2 { - device type genericswitch = 15; + device type genericswitch = 15, version 1; server cluster Identify { ram attribute identifyTime; diff --git a/examples/light-switch-app/nrfconnect/main/include/AppTask.h b/examples/light-switch-app/nrfconnect/main/include/AppTask.h index 6d464638f11e7a..9bd5ac4f5d98c0 100644 --- a/examples/light-switch-app/nrfconnect/main/include/AppTask.h +++ b/examples/light-switch-app/nrfconnect/main/include/AppTask.h @@ -21,7 +21,6 @@ #include "AppEvent.h" #include "LEDWidget.h" -#include #include #if CONFIG_CHIP_FACTORY_DATA diff --git a/examples/light-switch-app/telink/CMakeLists.txt b/examples/light-switch-app/telink/CMakeLists.txt index 892190ddf4b59f..40b9490510d47a 100755 --- a/examples/light-switch-app/telink/CMakeLists.txt +++ b/examples/light-switch-app/telink/CMakeLists.txt @@ -18,7 +18,6 @@ cmake_minimum_required(VERSION 3.13.1) set(BOARD tlsr9518adk80d) get_filename_component(CHIP_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/third_party/connectedhomeip REALPATH) -get_filename_component(NLIO_ROOT ${CHIP_ROOT}/third_party/nlio/repo/include REALPATH) get_filename_component(TELINK_COMMON ${CHIP_ROOT}/examples/platform/telink REALPATH) get_filename_component(GEN_DIR ${CHIP_ROOT}/zzz_generated/ REALPATH) @@ -39,7 +38,6 @@ target_include_directories(app PRIVATE include ${GEN_DIR}/app-common ${GEN_DIR}/light-switch-app - ${NLIO_ROOT} ${TELINK_COMMON}/util/include ${TELINK_COMMON}/app/include) diff --git a/examples/light-switch-app/telink/include/CHIPProjectConfig.h b/examples/light-switch-app/telink/include/CHIPProjectConfig.h index ade0219ab5da91..2fda70c57da9dc 100755 --- a/examples/light-switch-app/telink/include/CHIPProjectConfig.h +++ b/examples/light-switch-app/telink/include/CHIPProjectConfig.h @@ -31,13 +31,6 @@ #define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE 20202021 #define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR 0xF00 -/** - * CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE - * - * Enable support for Chip-over-BLE (CHIPoBLE). - */ -#define CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE 1 - /** * CHIP_SYSTEM_CONFIG_PACKETBUFFER_POOL_SIZE * diff --git a/examples/light-switch-app/telink/prj.conf b/examples/light-switch-app/telink/prj.conf index 1366c5f0e952fb..757920cafb7165 100755 --- a/examples/light-switch-app/telink/prj.conf +++ b/examples/light-switch-app/telink/prj.conf @@ -33,7 +33,6 @@ CONFIG_OPENTHREAD_PANID=4660 CONFIG_OPENTHREAD_CHANNEL=15 CONFIG_OPENTHREAD_NETWORK_NAME="OpenThreadDemo" CONFIG_OPENTHREAD_XPANID="11:11:11:11:22:22:22:22" -CONFIG_NET_CONFIG_IEEE802154_DEV_NAME="IEEE802154_b91" # Disable Matter OTA DFU CONFIG_CHIP_OTA_REQUESTOR=n @@ -58,4 +57,5 @@ CONFIG_CHIP_LIB_SHELL=n # Disable factory data support. CONFIG_CHIP_FACTORY_DATA=n -CONFIG_CHIP_FACTORY_DATA_BUILD=n \ No newline at end of file +CONFIG_CHIP_FACTORY_DATA_BUILD=n +CONFIG_CHIP_FACTORY_DATA_MERGE_WITH_FIRMWARE=n \ No newline at end of file diff --git a/examples/light-switch-app/telink/src/AppTask.cpp b/examples/light-switch-app/telink/src/AppTask.cpp index 7e1c792018b885..2bbd510217b7c3 100644 --- a/examples/light-switch-app/telink/src/AppTask.cpp +++ b/examples/light-switch-app/telink/src/AppTask.cpp @@ -29,7 +29,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/lighting-app/ameba/main/CHIPDeviceManager.cpp b/examples/lighting-app/ameba/main/CHIPDeviceManager.cpp index c164e20609c497..951b4033e33077 100644 --- a/examples/lighting-app/ameba/main/CHIPDeviceManager.cpp +++ b/examples/lighting-app/ameba/main/CHIPDeviceManager.cpp @@ -35,8 +35,8 @@ #include #include -#include #include +#include #include #include #include @@ -96,7 +96,7 @@ void MatterPostAttributeChangeCallback(const chip::app::ConcreteAttributePath & ClusterId clusterId = attributePath.mClusterId; AttributeId attributeId = attributePath.mAttributeId; - if (clusterId == ZCL_ON_OFF_CLUSTER_ID) + if (clusterId == app::Clusters::OnOff::Id) { if (attributeId != ZCL_ON_OFF_ATTRIBUTE_ID) { @@ -106,7 +106,7 @@ void MatterPostAttributeChangeCallback(const chip::app::ConcreteAttributePath & statusLED1.Set(*value); } - else if (clusterId == ZCL_LEVEL_CONTROL_CLUSTER_ID) + else if (clusterId == app::Clusters::LevelControl::Id) { if (attributeId != ZCL_CURRENT_LEVEL_ATTRIBUTE_ID) { @@ -122,7 +122,7 @@ void MatterPostAttributeChangeCallback(const chip::app::ConcreteAttributePath & ChipLogError(Zcl, "wrong length for level: %d\n", size); } } - else if (clusterId == ZCL_COLOR_CONTROL_CLUSTER_ID) + else if (clusterId == app::Clusters::ColorControl::Id) { uint8_t hue, saturation; @@ -136,18 +136,18 @@ void MatterPostAttributeChangeCallback(const chip::app::ConcreteAttributePath & if (attributeId == ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID) { hue = *value; - emberAfReadServerAttribute(endpointId, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, - &saturation, sizeof(uint8_t)); + emberAfReadServerAttribute(endpointId, app::Clusters::ColorControl::Id, + ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, &saturation, sizeof(uint8_t)); } if (attributeId == ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID) { saturation = *value; - emberAfReadServerAttribute(endpointId, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID, &hue, - sizeof(uint8_t)); + emberAfReadServerAttribute(endpointId, app::Clusters::ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID, + &hue, sizeof(uint8_t)); } ChipLogProgress(Zcl, "New hue: %d, New saturation: %d ", hue, saturation); } - else if (clusterId == ZCL_IDENTIFY_CLUSTER_ID) + else if (clusterId == app::Clusters::Identify::Id) { if (attributeId == ZCL_IDENTIFY_TIME_ATTRIBUTE_ID) { diff --git a/examples/lighting-app/ameba/main/DeviceCallbacks.cpp b/examples/lighting-app/ameba/main/DeviceCallbacks.cpp index 5cf63d6ba41faa..d2f99168e97515 100644 --- a/examples/lighting-app/ameba/main/DeviceCallbacks.cpp +++ b/examples/lighting-app/ameba/main/DeviceCallbacks.cpp @@ -26,7 +26,7 @@ #include "CHIPDeviceManager.h" #include -#include +#include #include #include #include @@ -123,7 +123,7 @@ void DeviceCallbacks::PostAttributeChangeCallback(EndpointId endpointId, Cluster { switch (clusterId) { - case ZCL_IDENTIFY_CLUSTER_ID: + case app::Clusters::Identify::Id: OnIdentifyPostAttributeChangeCallback(endpointId, attributeId, value); break; diff --git a/examples/lighting-app/beken/main/DeviceCallbacks.cpp b/examples/lighting-app/beken/main/DeviceCallbacks.cpp index ff9362486a08c0..52da67d1253ecf 100644 --- a/examples/lighting-app/beken/main/DeviceCallbacks.cpp +++ b/examples/lighting-app/beken/main/DeviceCallbacks.cpp @@ -28,7 +28,7 @@ #include #include -#include +#include #include #include #include @@ -56,11 +56,11 @@ void AppDeviceCallbacks::PostAttributeChangeCallback(EndpointId endpointId, Clus { switch (clusterId) { - case ZCL_ON_OFF_CLUSTER_ID: + case app::Clusters::OnOff::Id: OnOnOffPostAttributeChangeCallback(endpointId, attributeId, value); break; - case ZCL_IDENTIFY_CLUSTER_ID: + case app::Clusters::Identify::Id: OnIdentifyPostAttributeChangeCallback(endpointId, attributeId, value); break; diff --git a/examples/lighting-app/bouffalolab/README.md b/examples/lighting-app/bouffalolab/README.md index efa22fe1aee11c..49dd7fb8236452 100644 --- a/examples/lighting-app/bouffalolab/README.md +++ b/examples/lighting-app/bouffalolab/README.md @@ -53,6 +53,22 @@ Mac OS. > under this environment. If not, please try `scripts/bootstrap.sh` for > matter environment update. +- Setup build environment for `Bouffalo Lab` SoC + + Run `setup.sh` to install `Bouffalo Lab` SDK to /opt/bouffalolab_sdk + + ``` + cd third_party/bouffalolab/repo + sudo bash scripts/setup.sh + ``` + + Please execute following command export `BOUFFALOLAB_SDK_ROOT` before + building. + + ``` + export BOUFFALOLAB_SDK_ROOT=/opt/bouffalolab_sdk + ``` + ## Build CHIP Lighting App example The following steps take examples for BL602 develop board `BL602-IoT-Matter-V1` diff --git a/examples/lighting-app/bouffalolab/bl602/BUILD.gn b/examples/lighting-app/bouffalolab/bl602/BUILD.gn index b9511c8d4408e9..369b732b02f49b 100644 --- a/examples/lighting-app/bouffalolab/bl602/BUILD.gn +++ b/examples/lighting-app/bouffalolab/bl602/BUILD.gn @@ -38,17 +38,16 @@ declare_args() { # Dump memory usage at link time. chip_print_memory_usage = true - # PIN code for PASE session establishment. - setupPinCode = 20202021 + # OTA periodic query timeout in seconds + ota_periodic_query_timeout = 86400 - # Monitor & log memory usage at runtime. enable_heap_monitoring = false - # OTA periodic query timeout in seconds - ota_periodic_query_timeout = 86400 + setupPinCode = 20202021 + setupDiscriminator = 3840 board = "BL602-IoT-Matter-V1" - + module_type = "BL602" baudrate = 2000000 } @@ -196,7 +195,6 @@ bl602_executable("lighting_app") { sources += [ "${examples_plat_common_dir}/plat/OTAConfig.cpp" ] } - print(defines) ldscript = "${examples_plat_dir}/ldscripts/flash_rom.ld" ldflags = [ "-T" + rebase_path(ldscript, root_build_dir) ] diff --git a/examples/lighting-app/bouffalolab/bl702/BUILD.gn b/examples/lighting-app/bouffalolab/bl702/BUILD.gn index 2863fae45dd08c..5872505775bd15 100644 --- a/examples/lighting-app/bouffalolab/bl702/BUILD.gn +++ b/examples/lighting-app/bouffalolab/bl702/BUILD.gn @@ -38,21 +38,20 @@ declare_args() { # Dump memory usage at link time. chip_print_memory_usage = true + # OTA periodic query timeout in seconds + ota_periodic_query_timeout = 86400 + config_cache_size = 8192 - # Monitor & log memory usage at runtime. enable_heap_monitoring = false - # OTA periodic query timeout in seconds - ota_periodic_query_timeout = 86400 + setupPinCode = 20202021 + setupDiscriminator = 3840 board = "XT-ZB6-DevKit" module_type = "BL706C-22" enable_psram = true baudrate = 2000000 - - setupPinCode = 20202021 - setupDiscriminator = 3840 } bl702_sdk("sdk") { diff --git a/examples/lighting-app/bouffalolab/common/AppTask.cpp b/examples/lighting-app/bouffalolab/common/AppTask.cpp index d0e2e582c187ba..cae6be58e7dd75 100644 --- a/examples/lighting-app/bouffalolab/common/AppTask.cpp +++ b/examples/lighting-app/bouffalolab/common/AppTask.cpp @@ -23,7 +23,7 @@ #include #include #include -#include +#include #include #include @@ -469,26 +469,25 @@ void AppTask::LightingUpdate(app_event_t event) do { if (EMBER_ZCL_STATUS_SUCCESS != - emberAfReadAttribute(endpoint, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, &onoff, sizeof(onoff))) + emberAfReadAttribute(endpoint, Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, &onoff, sizeof(onoff))) { break; } if (EMBER_ZCL_STATUS_SUCCESS != - emberAfReadAttribute(endpoint, ZCL_LEVEL_CONTROL_CLUSTER_ID, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, &v, sizeof(v))) + emberAfReadAttribute(endpoint, Clusters::LevelControl::Id, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, &v, sizeof(v))) { break; } if (EMBER_ZCL_STATUS_SUCCESS != - emberAfReadAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID, &hue, - sizeof(v))) + emberAfReadAttribute(endpoint, Clusters::ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID, &hue, sizeof(v))) { break; } if (EMBER_ZCL_STATUS_SUCCESS != - emberAfReadAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, &sat, + emberAfReadAttribute(endpoint, Clusters::ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, &sat, sizeof(v))) { break; @@ -516,10 +515,10 @@ void AppTask::LightingSetOnoff(uint8_t bonoff) EndpointId endpoint = GetAppTask().GetEndpointId(); // write the new on/off value - emberAfWriteAttribute(endpoint, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &newValue, + emberAfWriteAttribute(endpoint, Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &newValue, ZCL_BOOLEAN_ATTRIBUTE_TYPE); newValue = 254; - emberAfWriteAttribute(endpoint, ZCL_LEVEL_CONTROL_CLUSTER_ID, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, (uint8_t *) &newValue, + emberAfWriteAttribute(endpoint, Clusters::LevelControl::Id, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, (uint8_t *) &newValue, ZCL_INT8U_ATTRIBUTE_TYPE); } @@ -531,20 +530,20 @@ void AppTask::LightingSetStatus(app_event_t status) if (APP_EVENT_SYS_LIGHT_TOGGLE == status) { - emberAfReadAttribute(endpoint, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &onoff, + emberAfReadAttribute(endpoint, Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &onoff, ZCL_BOOLEAN_ATTRIBUTE_TYPE); onoff = 1 - onoff; } else if (APP_EVENT_SYS_BLE_ADV == status) { hue = 35; - emberAfWriteAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID, (uint8_t *) &hue, + emberAfWriteAttribute(endpoint, Clusters::ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_HUE_ATTRIBUTE_ID, (uint8_t *) &hue, ZCL_INT8U_ATTRIBUTE_TYPE); sat = 254; - emberAfWriteAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, + emberAfWriteAttribute(endpoint, Clusters::ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, (uint8_t *) &sat, ZCL_INT8U_ATTRIBUTE_TYPE); level = 254; - emberAfWriteAttribute(endpoint, ZCL_LEVEL_CONTROL_CLUSTER_ID, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, (uint8_t *) &level, + emberAfWriteAttribute(endpoint, Clusters::LevelControl::Id, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, (uint8_t *) &level, ZCL_INT8U_ATTRIBUTE_TYPE); isProvisioned = false; @@ -557,14 +556,14 @@ void AppTask::LightingSetStatus(app_event_t status) } isProvisioned = true; sat = 0; - emberAfWriteAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, + emberAfWriteAttribute(endpoint, Clusters::ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, (uint8_t *) &sat, ZCL_INT8U_ATTRIBUTE_TYPE); level = 254; - emberAfWriteAttribute(endpoint, ZCL_LEVEL_CONTROL_CLUSTER_ID, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, (uint8_t *) &level, + emberAfWriteAttribute(endpoint, Clusters::LevelControl::Id, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, (uint8_t *) &level, ZCL_INT8U_ATTRIBUTE_TYPE); } - emberAfWriteAttribute(endpoint, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &onoff, ZCL_BOOLEAN_ATTRIBUTE_TYPE); + emberAfWriteAttribute(endpoint, Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &onoff, ZCL_BOOLEAN_ATTRIBUTE_TYPE); } bool AppTask::StartTimer(void) diff --git a/examples/lighting-app/esp32/CMakeLists.txt b/examples/lighting-app/esp32/CMakeLists.txt index b865807ad8e076..746f70379ef1c1 100644 --- a/examples/lighting-app/esp32/CMakeLists.txt +++ b/examples/lighting-app/esp32/CMakeLists.txt @@ -53,6 +53,10 @@ flashing_script() if (CONFIG_ENABLE_PW_RPC) get_filename_component(CHIP_ROOT ./third_party/connectedhomeip REALPATH) include(third_party/connectedhomeip/third_party/pigweed/repo/pw_build/pigweed.cmake) +include($ENV{PW_ROOT}/pw_assert/backend.cmake) +include($ENV{PW_ROOT}/pw_log/backend.cmake) +include($ENV{PW_ROOT}/pw_sys_io/backend.cmake) +include($ENV{PW_ROOT}/pw_trace/backend.cmake) pw_set_module_config(pw_rpc_CONFIG pw_rpc.disable_global_mutex_config) diff --git a/examples/lighting-app/esp32/main/AppTask.cpp b/examples/lighting-app/esp32/main/AppTask.cpp index 1af833792d0f71..434d98396efc64 100644 --- a/examples/lighting-app/esp32/main/AppTask.cpp +++ b/examples/lighting-app/esp32/main/AppTask.cpp @@ -23,7 +23,6 @@ #include #include #include -#include #define APP_TASK_NAME "APP" #define APP_EVENT_QUEUE_SIZE 10 diff --git a/examples/lighting-app/esp32/main/CMakeLists.txt b/examples/lighting-app/esp32/main/CMakeLists.txt index f7517c62295e8a..1e25058d3cb3d5 100644 --- a/examples/lighting-app/esp32/main/CMakeLists.txt +++ b/examples/lighting-app/esp32/main/CMakeLists.txt @@ -208,6 +208,7 @@ target_link_libraries(${COMPONENT_LIB} PUBLIC pw_log pw_rpc.server pw_sys_io + pw_trace pw_trace_tokenized pw_trace_tokenized.trace_buffer pw_trace_tokenized.rpc_service diff --git a/examples/lighting-app/genio/src/AppTask.cpp b/examples/lighting-app/genio/src/AppTask.cpp index e681d28a22169a..3542e1adca1381 100644 --- a/examples/lighting-app/genio/src/AppTask.cpp +++ b/examples/lighting-app/genio/src/AppTask.cpp @@ -28,7 +28,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/lighting-app/infineon/cyw30739/src/LightingManager.cpp b/examples/lighting-app/infineon/cyw30739/src/LightingManager.cpp index dc11429fc65cd0..f8719aa64850ec 100644 --- a/examples/lighting-app/infineon/cyw30739/src/LightingManager.cpp +++ b/examples/lighting-app/infineon/cyw30739/src/LightingManager.cpp @@ -22,7 +22,6 @@ #include #include #include -#include #include #include diff --git a/examples/lighting-app/infineon/psoc6/src/AppTask.cpp b/examples/lighting-app/infineon/psoc6/src/AppTask.cpp index 89605fc8a9c6e6..6bbc62708117cf 100644 --- a/examples/lighting-app/infineon/psoc6/src/AppTask.cpp +++ b/examples/lighting-app/infineon/psoc6/src/AppTask.cpp @@ -24,7 +24,7 @@ #include "LEDWidget.h" #include #include -#include +#include #include #include #include @@ -554,8 +554,8 @@ void AppTask::UpdateClusterState(intptr_t context) uint8_t newValue = LightMgr().IsLightOn(); // write the new on/off value - EmberAfStatus status = - emberAfWriteAttribute(1, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &newValue, ZCL_BOOLEAN_ATTRIBUTE_TYPE); + EmberAfStatus status = emberAfWriteAttribute(1, app::Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &newValue, + ZCL_BOOLEAN_ATTRIBUTE_TYPE); if (status != EMBER_ZCL_STATUS_SUCCESS) { P6_LOG("ERR: updating on/off %x", status); diff --git a/examples/lighting-app/lighting-common/lighting-app.matter b/examples/lighting-app/lighting-common/lighting-app.matter index 68d7564439425b..c8349802e7da65 100644 --- a/examples/lighting-app/lighting-common/lighting-app.matter +++ b/examples/lighting-app/lighting-common/lighting-app.matter @@ -1205,7 +1205,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1706,7 +1706,7 @@ server cluster OccupancySensing = 1030 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1981,7 +1981,7 @@ endpoint 0 { } } endpoint 1 { - device type dimmablelight = 257; + device type dimmablelight = 257, version 1; server cluster Identify { ram attribute identifyTime; diff --git a/examples/lighting-app/mbed/main/AppTask.cpp b/examples/lighting-app/mbed/main/AppTask.cpp index 78ec859903b205..3cdf03a03edcec 100644 --- a/examples/lighting-app/mbed/main/AppTask.cpp +++ b/examples/lighting-app/mbed/main/AppTask.cpp @@ -35,7 +35,7 @@ // ZAP -- ZCL Advanced Platform #include #include -#include +#include #include #ifdef CAPSENSE_ENABLED @@ -464,7 +464,7 @@ void AppTask::UpdateClusterState() // write the new on/off value EmberAfStatus status = - emberAfWriteServerAttribute(1, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, &onoff, ZCL_BOOLEAN_ATTRIBUTE_TYPE); + emberAfWriteServerAttribute(1, app::Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, &onoff, ZCL_BOOLEAN_ATTRIBUTE_TYPE); if (status != EMBER_ZCL_STATUS_SUCCESS) { ChipLogError(NotSpecified, "Updating on/off cluster failed: %x", status); @@ -472,7 +472,7 @@ void AppTask::UpdateClusterState() uint8_t level = LightingMgr().GetLevel(); - status = emberAfWriteServerAttribute(1, ZCL_LEVEL_CONTROL_CLUSTER_ID, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, &level, + status = emberAfWriteServerAttribute(1, app::Clusters::LevelControl::Id, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, &level, ZCL_INT8U_ATTRIBUTE_TYPE); if (status != EMBER_ZCL_STATUS_SUCCESS) diff --git a/examples/lighting-app/nrfconnect/main/AppTask.cpp b/examples/lighting-app/nrfconnect/main/AppTask.cpp index 15ab885139e20b..26a90b858eaf64 100644 --- a/examples/lighting-app/nrfconnect/main/AppTask.cpp +++ b/examples/lighting-app/nrfconnect/main/AppTask.cpp @@ -27,7 +27,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/lighting-app/nxp/k32w/k32w0/main/AppTask.cpp b/examples/lighting-app/nxp/k32w/k32w0/main/AppTask.cpp index ab05f79d417c4e..4e45106161348e 100644 --- a/examples/lighting-app/nxp/k32w/k32w0/main/AppTask.cpp +++ b/examples/lighting-app/nxp/k32w/k32w0/main/AppTask.cpp @@ -32,7 +32,7 @@ #include #include -#include +#include #include #include @@ -922,8 +922,8 @@ void AppTask::UpdateClusterStateInternal(intptr_t arg) uint8_t newValue = !LightingMgr().IsTurnedOff(); // write the new on/off value - EmberAfStatus status = - emberAfWriteAttribute(1, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &newValue, ZCL_BOOLEAN_ATTRIBUTE_TYPE); + EmberAfStatus status = emberAfWriteAttribute(1, app::Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &newValue, + ZCL_BOOLEAN_ATTRIBUTE_TYPE); if (status != EMBER_ZCL_STATUS_SUCCESS) { ChipLogError(NotSpecified, "ERR: updating on/off %x", status); @@ -940,7 +940,7 @@ void AppTask::UpdateDeviceStateInternal(intptr_t arg) bool onoffAttrValue = 0; /* get onoff attribute value */ - (void) emberAfReadAttribute(1, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &onoffAttrValue, 1); + (void) emberAfReadAttribute(1, app::Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &onoffAttrValue, 1); /* set the device state */ sLightLED.Set(onoffAttrValue); diff --git a/examples/lighting-app/nxp/zap/lighting-on-off.matter b/examples/lighting-app/nxp/zap/lighting-on-off.matter index 5a4d2825990eaf..a26c5db83cdee2 100644 --- a/examples/lighting-app/nxp/zap/lighting-on-off.matter +++ b/examples/lighting-app/nxp/zap/lighting-on-off.matter @@ -1189,7 +1189,7 @@ server cluster GroupKeyManagement = 63 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Descriptor { @@ -1371,7 +1371,7 @@ endpoint 0 { } } endpoint 1 { - device type dimmablelight = 256; + device type dimmablelight = 256, version 1; server cluster Identify { ram attribute identifyTime; diff --git a/examples/lighting-app/qpg/src/AppTask.cpp b/examples/lighting-app/qpg/src/AppTask.cpp index d7dd3c282791f6..145bee65d6c6be 100644 --- a/examples/lighting-app/qpg/src/AppTask.cpp +++ b/examples/lighting-app/qpg/src/AppTask.cpp @@ -28,7 +28,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/lighting-app/silabs/SiWx917/.gn b/examples/lighting-app/silabs/SiWx917/.gn new file mode 100644 index 00000000000000..4c078f6acefdcc --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/.gn @@ -0,0 +1,29 @@ +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/build.gni") + +# The location of the build configuration file. +buildconfig = "${build_root}/config/BUILDCONFIG.gn" + +# CHIP uses angle bracket includes. +check_system_includes = true + +default_args = { + target_cpu = "arm" + target_os = "freertos" + chip_openthread_ftd = true + + import("//args.gni") +} diff --git a/examples/lighting-app/silabs/SiWx917/BUILD.gn b/examples/lighting-app/silabs/SiWx917/BUILD.gn new file mode 100644 index 00000000000000..dbedc37a233b5c --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/BUILD.gn @@ -0,0 +1,395 @@ +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/build.gni") +import("//build_overrides/chip.gni") +import("//build_overrides/efr32_sdk.gni") +import("//build_overrides/pigweed.gni") + +import("${build_root}/config/defaults.gni") +import("${efr32_sdk_build_root}/SiWx917_sdk.gni") +import("${efr32_sdk_build_root}/efr32_executable.gni") + +import("${chip_root}/examples/common/pigweed/pigweed_rpcs.gni") +import("${chip_root}/src/platform/device.gni") + +if (chip_enable_pw_rpc) { + import("//build_overrides/pigweed.gni") + import("$dir_pw_build/target_types.gni") +} + +assert(current_os == "freertos") + +efr32_project_dir = "${chip_root}/examples/lighting-app/silabs/SiWx917" +examples_plat_dir = "${chip_root}/examples/platform/silabs/SiWx917" +examples_common_plat_dir = "${chip_root}/examples/platform/silabs" + +declare_args() { + # Dump memory usage at link time. + chip_print_memory_usage = false + + # Monitor & log memory usage at runtime. + enable_heap_monitoring = false + + # Enable Sleepy end device + enable_sleepy_device = false + + # OTA timeout in seconds + OTA_periodic_query_timeout = 86400 + + # Wifi related stuff - they are overridden by gn -args="use_wf200=true" + use_wf200 = false + use_rs911x = false + use_rs911x_sockets = false + sl_wfx_config_softap = false + sl_wfx_config_scan = true + + # Disable LCD on supported devices + disable_lcd = true + + # Argument to Disable IPv4 for wifi(rs911) + chip_enable_wifi_ipv4 = false + + # Argument to force enable WPA3 security on rs91x + rs91x_wpa3_only = false + + #default WiFi SSID + ssid = "" + + #default Wifi Password + psk = "" +} + +declare_args() { + # Enables LCD Qr Code on supported devices + show_qr_code = !disable_lcd +} + +# qr code cannot be true if lcd is disabled +assert(!(disable_lcd && show_qr_code)) + +# Sanity check +assert(!(chip_enable_wifi && chip_enable_openthread)) +assert(!(use_rs911x && chip_enable_openthread)) +assert(!(use_wf200 && chip_enable_openthread)) +if (chip_enable_wifi) { + assert(use_rs911x || use_wf200) + enable_openthread_cli = false + import("${chip_root}/src/platform/silabs/SiWx917/wifi_args.gni") +} + +# ThunderBoards, Explorer Kit and MGM240L do not support LCD (No LCD) +if (silabs_board == "BRD4166A" || silabs_board == "BRD2601B" || + silabs_board == "BRD2703A" || silabs_board == "BRD4319A") { + show_qr_code = false + disable_lcd = true +} + +defines = [] + +# WiFi settings +if (chip_enable_wifi) { + # disabling LCD for MG24 for wifi + if (silabs_board == "BRD4186A" || silabs_board == "BRD4187A") { + show_qr_code = false + disable_lcd = true + } + + if (ssid != "") { + defines += [ + "CHIP_ONNETWORK_PAIRING = 1", + "CHIP_WIFI_SSID = $ssid", + ] + } + if (psk != "") { + assert(ssid != "", "ssid can't be null if psk is provided") + defines += [ "CHIP_WIFI_PSK = $psk" ] + } + + wifi_sdk_dir = "${chip_root}/src/platform/silabs/SiWx917/wifi" + efr32_lwip_defs = [ "LWIP_NETIF_API=1" ] + if (lwip_ipv4) { + efr32_lwip_defs += [ + "LWIP_IPV4=1", + + # adds following options to provide + # them to .cpp source files + # flags ported from lwipopts file + # TODO: move lwipopts to one location + "LWIP_ARP=1", + "LWIP_ICMP=1", + "LWIP_IGMP=1", + "LWIP_DHCP=1", + "LWIP_DNS=0", + ] + } else { + efr32_lwip_defs += [ "LWIP_IPV4=0" ] + } + if (lwip_ipv6) { + efr32_lwip_defs += [ "LWIP_IPV6=1" ] + } else { + efr32_lwip_defs += [ "LWIP_IPV6=0" ] + } + + wiseconnect_sdk_root = "${chip_root}/third_party/silabs/wisemcu-wifi-bt-sdk" + import("${examples_plat_dir}/SiWx917/rs911x.gni") +} + +efr32_sdk("sdk") { + sources = [ + "${efr32_project_dir}/include/CHIPProjectConfig.h", + "${examples_plat_dir}/FreeRTOSConfig.h", + ] + + include_dirs = [ + "${chip_root}/src/platform/silabs/SiWx917", + "${efr32_project_dir}/include", + "${examples_plat_dir}", + "${chip_root}/src/lib", + "${examples_common_plat_dir}", + ] + + defines += [ + "BOARD_ID=${silabs_board}", + "OTA_PERIODIC_TIMEOUT=${OTA_periodic_query_timeout}", + ] + + if (chip_enable_pw_rpc) { + defines += [ + "HAL_VCOM_ENABLE=1", + "PW_RPC_ENABLED", + ] + } + + # WiFi Settings + if (chip_enable_wifi) { + if (use_rs911x) { + defines += rs911x_defs + include_dirs += rs911x_plat_incs + } else if (use_wf200) { + defines += wf200_defs + include_dirs += wf200_plat_incs + } + + if (use_rs911x_sockets) { + include_dirs += [ "${examples_plat_dir}/wifi/rsi-sockets" ] + defines += rs911x_sock_defs + } else { + # Using LWIP instead of the native TCP/IP stack + defines += efr32_lwip_defs + } + + if (sl_wfx_config_softap) { + defines += [ "SL_WFX_CONFIG_SOFTAP" ] + } + if (sl_wfx_config_scan) { + defines += [ "SL_WFX_CONFIG_SCAN" ] + } + } +} + +efr32_executable("lighting_app") { + output_name = "chip-efr32-lighting-example.out" + public_configs = [ "${efr32_sdk_build_root}:silabs_config" ] + include_dirs = [ "include" ] + defines = [] + + sources = [ + "${examples_common_plat_dir}/heap_4_silabs.c", + "${examples_plat_dir}/BaseApplication.cpp", + "${examples_plat_dir}/init_ccpPlatform.cpp", + "${examples_plat_dir}/matter_config.cpp", + "${examples_plat_dir}/siwx917_utils.cpp", + "src/AppTask.cpp", + "src/LightingManager.cpp", + "src/ZclCallbacks.cpp", + "src/main.cpp", + ] + + if (use_wstk_leds) { + # TODO: Commentting for CCP till the bring up of this is done + #sources += [ "${examples_plat_dir}/LEDWidget.cpp" ] + } + + if (chip_enable_pw_rpc || chip_build_libshell || use_rs911x) { + # TODO: Commentting for CCP till the bring up of this is done + #sources += [ "${examples_plat_dir}/uart.cpp" ] + } + + deps = [ + ":sdk", + "${chip_root}/examples/lighting-app/lighting-common", + "${chip_root}/examples/providers:device_info_provider", + "${chip_root}/src/lib", + "${chip_root}/src/setup_payload", + ] + + # OpenThread Settings + if (chip_enable_openthread) { + deps += [ + "${chip_root}/third_party/openthread:openthread", + "${chip_root}/third_party/openthread:openthread-platform", + "${examples_plat_dir}:efr-matter-shell", + ] + } + + #TODO: OTA should be added + + # WiFi Settings + if (chip_enable_wifi) { + if (use_rs911x) { + sources += rs911x_src_plat + + # All the stuff from wiseconnect + sources += rs911x_src_sapi + + # Apparently - the rsi library needs this (though we may not use use it) + sources += rs911x_src_sock + include_dirs += rs911x_inc_plat + + if (use_rs911x_sockets) { + # + # Using native sockets inside RS911x + # + include_dirs += rs911x_sock_inc + } else { + # + # We use LWIP - not built-in sockets + # + sources += rs911x_src_lwip + } + } else if (use_wf200) { + sources += wf200_plat_src + include_dirs += wf200_plat_incs + } + + if (chip_enable_wifi_ipv4) { + defines += [ "CHIP_DEVICE_CONFIG_ENABLE_IPV4" ] + } + + if (rs91x_wpa3_only) { + # TODO: Change this macro once WF200 support is provided + defines += [ "WIFI_ENABLE_SECURITY_WPA3=1" ] + } + } + + if (!disable_lcd) { + sources += [ + "${examples_plat_dir}/display/demo-ui.c", + "${examples_plat_dir}/display/lcd.cpp", + ] + + include_dirs += [ "${examples_plat_dir}/display" ] + defines += [ + "DISPLAY_ENABLED", + "IS_DEMO_LIGHT=1", + ] + if (show_qr_code) { + defines += [ "QR_CODE_ENABLED" ] + + deps += [ "${chip_root}/examples/common/QRCode" ] + } + } + + if (chip_enable_pw_rpc) { + defines += [ + "PW_RPC_ENABLED", + "PW_RPC_ATTRIBUTE_SERVICE=1", + "PW_RPC_BUTTON_SERVICE=1", + "PW_RPC_DESCRIPTOR_SERVICE=1", + "PW_RPC_DEVICE_SERVICE=1", + "PW_RPC_LIGHTING_SERVICE=1", + "PW_RPC_OTCLI_SERVICE=1", + "PW_RPC_THREAD_SERVICE=1", + "PW_RPC_TRACING_SERVICE=1", + ] + + sources += [ + "${chip_root}/examples/common/pigweed/RpcService.cpp", + "${chip_root}/examples/common/pigweed/efr32/PigweedLoggerMutex.cpp", + "${examples_common_plat_dir}/PigweedLogger.cpp", + "${examples_common_plat_dir}/Rpc.cpp", + ] + + deps += [ + "$dir_pw_hdlc:rpc_channel_output", + "$dir_pw_stream:sys_io_stream", + "$dir_pw_trace", + "$dir_pw_trace_tokenized", + "$dir_pw_trace_tokenized:trace_rpc_service", + "${chip_root}/config/efr32/lib/pw_rpc:pw_rpc", + "${chip_root}/examples/common/pigweed:attributes_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", + "${chip_root}/examples/common/pigweed:lighting_service.nanopb_rpc", + "${chip_root}/examples/common/pigweed:ot_cli_service.nanopb_rpc", + "${chip_root}/examples/common/pigweed:thread_service.nanopb_rpc", + "${examples_plat_dir}/pw_sys_io:pw_sys_io_siwx917", + ] + + deps += pw_build_LINK_DEPS + + include_dirs += [ + "${chip_root}/examples/common", + "${chip_root}/examples/common/pigweed/efr32", + ] + } + + if (enable_heap_monitoring) { + sources += [ "${examples_common_plat_dir}/MemMonitoring.cpp" ] + defines += [ "HEAP_MONITORING" ] + } + + ldscript = "${examples_plat_dir}/ldscripts/${silabs_family}.ld" + + inputs = [ ldscript ] + + ldflags = [ "-T" + rebase_path(ldscript, root_build_dir) ] + + if (chip_print_memory_usage) { + ldflags += [ + "-Wl,--print-memory-usage", + "-fstack-usage", + ] + } + + # WiFi Settings + if (chip_enable_wifi) { + ldflags += [ + "-Wl,--defsym", + "-Wl,SILABS_WIFI=1", + ] + } + + # Attestation Credentials + if (chip_build_platform_attestation_credentials_provider) { + deps += [ "${examples_plat_dir}:siwx917-attestation-credentials" ] + } + + # Factory Data Provider + if (use_efr32_factory_data_provider) { + deps += [ "${examples_plat_dir}:efr32-factory-data-provider" ] + } + + output_dir = root_out_dir +} + +group("efr32") { + deps = [ ":lighting_app" ] +} + +group("default") { + deps = [ ":efr32" ] +} diff --git a/examples/lighting-app/silabs/SiWx917/README.md b/examples/lighting-app/silabs/SiWx917/README.md new file mode 100644 index 00000000000000..ae7565f492c620 --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/README.md @@ -0,0 +1,424 @@ +# Matter EFR32 Lighting Example + +An example showing the use of CHIP on the Silicon Labs EFR32 MG12 and MG24. + +
+ +- [Matter EFR32 Lighting Example](#matter-efr32-lighting-example) + - [Introduction](#introduction) + - [Building](#building) + - [Flashing the Application](#flashing-the-application) + - [Viewing Logging Output](#viewing-logging-output) + - [Running the Complete Example](#running-the-complete-example) + - [Notes](#notes) + - [Running RPC console](#running-rpc-console) + - [Device Tracing](#device-tracing) + - [Memory settings](#memory-settings) + - [OTA Software Update](#ota-software-update) + - [Group Communication (Multicast)](#group-communication-multicast) + - [Building options](#building-options) + - [Disabling logging](#disabling-logging) + - [Debug build / release build](#debug-build--release-build) + - [Disabling LCD](#disabling-lcd) + - [KVS maximum entry count](#kvs-maximum-entry-count) + +
+ +> **NOTE:** Silicon Laboratories now maintains a public matter GitHub repo with +> frequent releases thoroughly tested and validated. Developers looking to +> develop matter products with silabs hardware are encouraged to use our latest +> release with added tools and documentation. +> [Silabs Matter Github](https://github.com/SiliconLabs/matter/releases) + + + +## Introduction + +The EFR32 lighting example provides a baseline demonstration of a Light control +device, built using Matter and the Silicon Labs gecko SDK. It can be controlled +by a Chip controller over an Openthread or Wifi network.. + +The EFR32 device can be commissioned over Bluetooth Low Energy where the device +and the Chip controller will exchange security information with the Rendez-vous +procedure. If using Thread, Thread Network credentials are then provided to the +EFR32 device which will then join the Thread network. + +If the LCD is enabled, the LCD on the Silabs WSTK shows a QR Code containing the +needed commissioning information for the BLE connection and starting the +Rendez-vous procedure. + +The lighting example is intended to serve both as a means to explore the +workings of Matter as well as a template for creating real products based on the +Silicon Labs platform. + + + +## Building + +- Download the + [Simplicity Commander](https://www.silabs.com/mcu/programming-options) + command line tool, and ensure that `commander` is your shell search path. + (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) + +- Install some additional tools (likely already present for CHIP developers): + + - Linux: `sudo apt-get install git ninja-build` + + - Mac OS X: `brew install ninja` + +- Supported hardware: + + - > For the latest supported hardware please refer to the + > [Hardware Requirements](https://github.com/SiliconLabs/matter/blob/latest/docs/silabs/general/HARDWARE_REQUIREMENTS.md) + > in the Silicon Labs Matter Github Repo + + MG12 boards: + + - BRD4161A / SLWSTK6000B / Wireless Starter Kit / 2.4GHz@19dBm + - BRD4162A / SLWSTK6000B / Wireless Starter Kit / 2.4GHz@10dBm + - BRD4163A / SLWSTK6000B / Wireless Starter Kit / 2.4GHz@10dBm, + 868MHz@19dBm + - BRD4164A / SLWSTK6000B / Wireless Starter Kit / 2.4GHz@19dBm + - BRD4166A / SLTB004A / Thunderboard Sense 2 / 2.4GHz@10dBm + - BRD4170A / SLWSTK6000B / Multiband Wireless Starter Kit / 2.4GHz@19dBm, + 915MHz@19dBm + - BRD4304A / SLWSTK6000B / MGM12P Module / 2.4GHz@19dBm + + MG21 boards: Currently not supported due to RAM limitation. + + - BRD4180A / SLWSTK6006A / Wireless Starter Kit / 2.4GHz@20dBm + + MG24 boards : + + - BRD2601B / SLWSTK6000B / Wireless Starter Kit / 2.4GHz@10dBm + - BRD2703A / SLWSTK6000B / Wireless Starter Kit / 2.4GHz@10dBm + - BRD4186A / SLWSTK6006A / Wireless Starter Kit / 2.4GHz@10dBm + - BRD4186C / SLWSTK6006A / Wireless Starter Kit / 2.4GHz@10dBm + - BRD4187A / SLWSTK6006A / Wireless Starter Kit / 2.4GHz@20dBm + - BRD4187C / SLWSTK6006A / Wireless Starter Kit / 2.4GHz@20dBm + + MG12 boards: + + - BRD4161A / SLWSTK6000B / Wireless Starter Kit / 2.4GHz@19dBm + - BRD4162A / SLWSTK6000B / Wireless Starter Kit / 2.4GHz@10dBm + - BRD4163A / SLWSTK6000B / Wireless Starter Kit / 2.4GHz@10dBm, + 868MHz@19dBm + - BRD4164A / SLWSTK6000B / Wireless Starter Kit / 2.4GHz@19dBm + - BRD4166A / SLTB004A / Thunderboard Sense 2 / 2.4GHz@10dBm + - BRD4170A / SLWSTK6000B / Multiband Wireless Starter Kit / 2.4GHz@19dBm, + 915MHz@19dBm + - BRD4304A / SLWSTK6000B / MGM12P Module / 2.4GHz@19dBm + + MG21 boards: Currently not supported due to RAM limitation. + + - BRD4180A / SLWSTK6006A / Wireless Starter Kit / 2.4GHz@20dBm + + MG24 boards : + + - BRD2601B / SLWSTK6000B / Wireless Starter Kit / 2.4GHz@10dBm + - BRD2703A / SLWSTK6000B / Wireless Starter Kit / 2.4GHz@10dBm + - BRD4186A / SLWSTK6006A / Wireless Starter Kit / 2.4GHz@10dBm + - BRD4186C / SLWSTK6006A / Wireless Starter Kit / 2.4GHz@10dBm + - BRD4187A / SLWSTK6006A / Wireless Starter Kit / 2.4GHz@20dBm + - BRD4187C / SLWSTK6006A / Wireless Starter Kit / 2.4GHz@20dBm + +* Build the example application: + + cd ~/connectedhomeip + ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/efr32/ ./out/lighting-app BRD4161A + +- To delete generated executable, libraries and object files use: + + $ cd ~/connectedhomeip + $ rm -rf ./out/ + + OR use GN/Ninja directly + + $ cd ~/connectedhomeip/examples/lighting-app/efr32 + $ git submodule update --init + $ source third_party/connectedhomeip/scripts/activate.sh + $ export EFR32_BOARD=BRD4161A + $ gn gen out/debug + $ ninja -C out/debug + +- To delete generated executable, libraries and object files use: + + $ cd ~/connectedhomeip/examples/lighting-app/efr32 + $ rm -rf out/ + +* Build the example as Sleepy End Device (SED) + + $ ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/efr32/ ./out/lighting-app_SED BRD4161A --sed + + or use gn as previously mentioned but adding the following arguments: + + $ gn gen out/debug '--args=silabs_board="BRD4161A" enable_sleepy_device=true chip_openthread_ftd=false' + +* Build the example with pigweed RPC + + $ ./scripts/examples/gn_efr32_example.sh examples/lighting-app/efr32/ out/lighting_app_rpc BRD4161A 'import("//with_pw_rpc.gni")' + + or use GN/Ninja Directly + + $ cd ~/connectedhomeip/examples/lighting-app/efr32 + $ git submodule update --init + $ source third_party/connectedhomeip/scripts/activate.sh + $ export EFR32_BOARD=BRD4161A + $ gn gen out/debug --args='import("//with_pw_rpc.gni")' + $ ninja -C out/debug + + [Running Pigweed RPC console](#running-pigweed-rpc-console) + +For more build options, help is provided when running the build script without +arguments + + ./scripts/examples/gn_efr32_example.sh + + + +## Flashing the Application + +- On the command line: + + $ cd ~/connectedhomeip/examples/lighting-app/efr32 + $ python3 out/debug/chip-efr32-lighting-example.flash.py + +- Or with the Ozone debugger, just load the .out file. + + + +## Viewing Logging Output + +The example application is built to use the SEGGER Real Time Transfer (RTT) +facility for log output. RTT is a feature built-in to the J-Link Interface MCU +on the WSTK development board. It allows bi-directional communication with an +embedded application without the need for a dedicated UART. + +Using the RTT facility requires downloading and installing the _SEGGER J-Link +Software and Documentation Pack_ +([web site](https://www.segger.com/downloads/jlink#J-LinkSoftwareAndDocumentationPack)). + +Alternatively, SEGGER Ozone J-Link debugger can be used to view RTT logs too +after flashing the .out file. + +- Download the J-Link installer by navigating to the appropriate URL and + agreeing to the license agreement. + +- [JLink_Linux_x86_64.deb](https://www.segger.com/downloads/jlink/JLink_Linux_x86_64.deb) +- [JLink_MacOSX.pkg](https://www.segger.com/downloads/jlink/JLink_MacOSX.pkg) + +* Install the J-Link software + + $ cd ~/Downloads + $ sudo dpkg -i JLink_Linux_V*_x86_64.deb + +* In Linux, grant the logged in user the ability to talk to the development + hardware via the linux tty device (/dev/ttyACMx) by adding them to the + dialout group. + + $ sudo usermod -a -G dialout ${USER} + +Once the above is complete, log output can be viewed using the JLinkExe tool in +combination with JLinkRTTClient as follows: + +- Run the JLinkExe tool with arguments to autoconnect to the WSTK board: + + For MG12 use: + + $ JLinkExe -device EFR32MG12PXXXF1024 -if JTAG -speed 4000 -autoconnect 1 + + For MG21 use: + + $ JLinkExe -device EFR32MG21AXXXF1024 -if SWD -speed 4000 -autoconnect 1 + +- In a second terminal, run the JLinkRTTClient to view logs: + + $ JLinkRTTClient + + + +## Running the Complete Example + +- It is assumed here that you already have an OpenThread border router + configured and running. If not see the following guide + [Openthread_border_router](https://github.com/project-chip/connectedhomeip/blob/master/docs/guides/openthread_border_router_pi.md) + for more information on how to setup a border router on a raspberryPi. + + Take note that the RCP code is available directly through + [Simplicity Studio 5](https://www.silabs.com/products/development-tools/software/simplicity-studio/simplicity-studio-5) + under File->New->Project Wizard->Examples->Thread : ot-rcp + +- User interface : **LCD** The LCD on Silabs WSTK shows a QR Code. This QR + Code is be scanned by the CHIP Tool app For the Rendez-vous procedure over + BLE + + * On devices that do not have or support the LCD Display like the BRD4166A Thunderboard Sense 2, + a URL can be found in the RTT logs. + + [SVR] Copy/paste the below URL in a browser to see the QR Code: + [SVR] https://project-chip.github.io/connectedhomeip/qrcode.html?data=CH%3AI34NM%20-00%200C9SS0 + + **LED 0** shows the overall state of the device and its connectivity. The + following states are possible: + + - _Short Flash On (50 ms on/950 ms off)_ ; The device is in the + unprovisioned (unpaired) state and is waiting for a commissioning + application to connect. + + - _Rapid Even Flashing_ ; (100 ms on/100 ms off)_ — The device is in the + unprovisioned state and a commissioning application is connected through + Bluetooth LE. + + - _Short Flash Off_ ; (950ms on/50ms off)_ — The device is fully + provisioned, but does not yet have full Thread network or service + connectivity. + + - _Solid On_ ; The device is fully provisioned and has full Thread + network and service connectivity. + + **LED 1** Simulates the Light The following states are possible: + + - _Solid On_ ; Light is on + - _Off_ ; Light is off + + **Push Button 0** + + - _Press and Release_ : Start, or restart, BLE advertisement in fast mode. It will advertise in this mode + for 30 seconds. The device will then switch to a slower interval advertisement. + After 15 minutes, the advertisement stops. + + - _Pressed and hold for 6 s_ : Initiates the factory reset of the device. + Releasing the button within the 6-second window cancels the factory reset + procedure. **LEDs** blink in unison when the factory reset procedure is + initiated. + + **Push Button 1** Toggles the light state On/Off + +* You can provision and control the Chip device using the python controller, + Chip tool standalone, Android or iOS app + +* You can provision and control the Chip device using the python controller, + Chip tool standalone, Android or iOS app + + [CHIPTool](https://github.com/project-chip/connectedhomeip/blob/master/examples/chip-tool/README.md) + + Here is an example with the CHIPTool: + + chip-tool pairing ble-thread 1 hex: 20202021 3840 + + chip-tool onoff on 1 1 + +### Notes + +- Depending on your network settings your router might not provide native ipv6 + addresses to your devices (Border router / PC). If this is the case, you + need to add a static ipv6 addresses on both device and then an ipv6 route to + the border router on your PC + + - On Border Router: `sudo ip addr add dev 2002::2/64` + + - On PC(Linux): `sudo ip addr add dev 2002::1/64` + + - Add Ipv6 route on PC(Linux) + `sudo ip route add /64 via 2002::2` + + + +## Running RPC console + +- As part of building the example with RPCs enabled the chip_rpc python + interactive console is installed into your venv. The python wheel files are + also created in the output folder: out/debug/chip_rpc_console_wheels. To + install the wheel files without rebuilding: + `pip3 install out/debug/chip_rpc_console_wheels/*.whl` + +- To use the chip-rpc console after it has been installed run: + `chip-console --device /dev/tty. -b 115200 -o //pw_log.out` + +- Then you can simulate a button press or release using the following command + where : idx = 0 or 1 for Button PB0 or PB1 action = 0 for PRESSED, 1 for + RELEASE Test toggling the LED with + `rpcs.chip.rpc.Button.Event(idx=1, pushed=True)` + +- You can also Get and Set the light directly using the RPCs: + `rpcs.chip.rpc.Lighting.Get()` + + `rpcs.chip.rpc.Lighting.Set(on=True, level=128, color=protos.chip.rpc.LightingColor(hue=5, saturation=5))` + +## Device Tracing + +Device tracing is available to analyze the device performance. To turn on +tracing, build with RPC enabled. See Build the example with pigweed RPC. + +Obtain tracing json file. + + $ ./{PIGWEED_REPO}/pw_trace_tokenized/py/pw_trace_tokenized/get_trace.py -d {PORT} -o {OUTPUT_FILE} \ + -t {ELF_FILE} {PIGWEED_REPO}/pw_trace_tokenized/pw_trace_protos/trace_rpc.proto + +## Memory settings + +While most of the RAM usage in CHIP is static, allowing easier debugging and +optimization with symbols analysis, we still need some HEAP for the crypto and +OpenThread. Size of the HEAP can be modified by changing the value of the +`configTOTAL_HEAP_SIZE` define inside of the FreeRTOSConfig.h file of this +example. Please take note that a HEAP size smaller than 13k can and will cause a +Mbedtls failure during the BLE rendez-vous or CASE session + +To track memory usage you can set `enable_heap_monitoring = true` either in the +BUILD.gn file or pass it as a build argument to gn. This will print on the RTT +console the RAM usage of each individual task and the number of Memory +allocation and Free. While this is not extensive monitoring you're welcome to +modify `examples/platform/efr32/MemMonitoring.cpp` to add your own memory +tracking code inside the `trackAlloc` and `trackFree` function + +## OTA Software Update + +For the description of Software Update process with EFR32 example applications +see +[EFR32 OTA Software Update](../../../docs/guides/silabs_efr32_software_update.md) + +## Group Communication (Multicast) + +With this lighting example you can also use group communication to send Lighting +commands to multiples devices at once. Please refer to the +[chip-tool documentation](../../chip-tool/README.md) _Configuring the server +side for Group Commands_ and _Using the Client to Send Group (Multicast) Matter +Commands_ + +## Building options + +All of Silabs's examples within the Matter repo have all the features enabled by +default, as to provide the best end user experience. However some of those +features can easily be toggled on or off. Here is a short list of options to be +passed to the build scripts. + +### Disabling logging + +`chip_progress_logging, chip_detail_logging, chip_automation_logging` + + $ ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/efr32 ./out/lighting-app BRD4164A "chip_detail_logging=false chip_automation_logging=false chip_progress_logging=false" + +### Debug build / release build + +`is_debug` + + $ ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/efr32 ./out/lighting-app BRD4164A "is_debug=false" + +### Disabling LCD + +`show_qr_code` + + $ ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/efr32 ./out/lighting-app BRD4164A "show_qr_code=false" + +### KVS maximum entry count + +`kvs_max_entries` + + Set the maximum Kvs entries that can be stored in NVM (Default 75) + Thresholds: 30 <= kvs_max_entries <= 255 + + $ ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/efr32 ./out/lighting-app BRD4164A kvs_max_entries=50 diff --git a/examples/lighting-app/silabs/SiWx917/args.gni b/examples/lighting-app/silabs/SiWx917/args.gni new file mode 100644 index 00000000000000..8b382c4520b390 --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/args.gni @@ -0,0 +1,30 @@ +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/chip.gni") +import("//build_overrides/pigweed.gni") +import("${chip_root}/config/standalone/args.gni") +import("${chip_root}/src/platform/silabs/SiWx917/args.gni") + +efr32_sdk_target = get_label_info(":sdk", "label_no_toolchain") + +chip_enable_ota_requestor = true + +pw_log_BACKEND = "${chip_root}/src/lib/support/pw_log_chip" +pw_assert_BACKEND = "$dir_pw_assert_log:check_backend" +chip_enable_openthread = true +pw_rpc_CONFIG = "$dir_pw_rpc:disable_global_mutex" + +openthread_external_platform = + "${chip_root}/third_party/openthread/platforms/efr32:libopenthread-efr32" diff --git a/examples/lighting-app/silabs/SiWx917/build_for_wifi_args.gni b/examples/lighting-app/silabs/SiWx917/build_for_wifi_args.gni new file mode 100644 index 00000000000000..8a0192cd5e9c3f --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/build_for_wifi_args.gni @@ -0,0 +1,25 @@ +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +import("//build_overrides/chip.gni") +import("//build_overrides/pigweed.gni") +import("${chip_root}/config/standalone/args.gni") + +efr32_sdk_target = get_label_info(":sdk", "label_no_toolchain") +chip_enable_openthread = false +import("${chip_root}/src/platform/silabs/SiWx917/wifi_args.gni") + +chip_enable_ota_requestor = true + +pw_log_BACKEND = "${chip_root}/src/lib/support/pw_log_chip" +pw_assert_BACKEND = "$dir_pw_assert_log:check_backend" diff --git a/examples/lighting-app/silabs/SiWx917/build_for_wifi_gnfile.gn b/examples/lighting-app/silabs/SiWx917/build_for_wifi_gnfile.gn new file mode 100644 index 00000000000000..d391814190d09f --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/build_for_wifi_gnfile.gn @@ -0,0 +1,28 @@ +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/build.gni") + +# The location of the build configuration file. +buildconfig = "${build_root}/config/BUILDCONFIG.gn" + +# CHIP uses angle bracket includes. +check_system_includes = true + +default_args = { + target_cpu = "arm" + target_os = "freertos" + chip_enable_wifi = true + import("//build_for_wifi_args.gni") +} diff --git a/examples/lighting-app/silabs/SiWx917/build_overrides b/examples/lighting-app/silabs/SiWx917/build_overrides new file mode 120000 index 00000000000000..995884e6163eb5 --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/build_overrides @@ -0,0 +1 @@ +../../../build_overrides \ No newline at end of file diff --git a/examples/lighting-app/silabs/SiWx917/include/AppConfig.h b/examples/lighting-app/silabs/SiWx917/include/AppConfig.h new file mode 100644 index 00000000000000..b86af8b22c2213 --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/include/AppConfig.h @@ -0,0 +1,30 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2019 Google LLC. + * 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 "siwx917_utils.h" + +// ---- Lighting Example App Config ---- + +#define APP_TASK_NAME "Lit" + +// Time it takes in ms for the simulated actuator to move from one +// state to another. +#define ACTUATOR_MOVEMENT_PERIOS_MS 10 diff --git a/examples/lighting-app/silabs/SiWx917/include/AppEvent.h b/examples/lighting-app/silabs/SiWx917/include/AppEvent.h new file mode 100644 index 00000000000000..7a19b719edad25 --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/include/AppEvent.h @@ -0,0 +1,55 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2018 Nest Labs, Inc. + * 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 + +struct AppEvent; +typedef void (*EventHandler)(AppEvent *); + +struct AppEvent +{ + enum AppEventTypes + { + kEventType_Button = 0, + kEventType_Timer, + kEventType_Light, + kEventType_Install, + }; + + uint16_t Type; + + union + { + struct + { + uint8_t Action; + } ButtonEvent; + struct + { + void * Context; + } TimerEvent; + struct + { + uint8_t Action; + int32_t Actor; + } LightEvent; + }; + + EventHandler Handler; +}; diff --git a/examples/lighting-app/silabs/SiWx917/include/AppTask.h b/examples/lighting-app/silabs/SiWx917/include/AppTask.h new file mode 100644 index 00000000000000..225b726f732b13 --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/include/AppTask.h @@ -0,0 +1,120 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2019 Google LLC. + * 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 + +/********************************************************** + * Includes + *********************************************************/ + +#include +#include + +#include "AppEvent.h" +#include "BaseApplication.h" +#include "FreeRTOS.h" +#include "LightingManager.h" +#include "timers.h" // provides FreeRTOS timer support +#include +#include +#include +#include + +/********************************************************** + * Defines + *********************************************************/ + +// Application-defined error codes in the CHIP_ERROR space. +#define APP_ERROR_EVENT_QUEUE_FAILED CHIP_APPLICATION_ERROR(0x01) +#define APP_ERROR_CREATE_TASK_FAILED CHIP_APPLICATION_ERROR(0x02) +#define APP_ERROR_UNHANDLED_EVENT CHIP_APPLICATION_ERROR(0x03) +#define APP_ERROR_CREATE_TIMER_FAILED CHIP_APPLICATION_ERROR(0x04) +#define APP_ERROR_START_TIMER_FAILED CHIP_APPLICATION_ERROR(0x05) +#define APP_ERROR_STOP_TIMER_FAILED CHIP_APPLICATION_ERROR(0x06) + +/********************************************************** + * AppTask Declaration + *********************************************************/ + +class AppTask : public BaseApplication +{ + +public: + AppTask() = default; + + static AppTask & GetAppTask() { return sAppTask; } + + /** + * @brief AppTask task main loop function + * + * @param pvParameter FreeRTOS task parameter + */ + static void AppTaskMain(void * pvParameter); + + CHIP_ERROR StartAppTask(); + + /** + * @brief Callback called by the identify-server when an identify command is received + * + * @param identify identify structure the command applies on + */ + static void OnIdentifyStart(Identify * identify); + + /** + * @brief Callback called by the identify-server when an identify command is stopped or finished + * + * @param identify identify structure the command applies on + */ + static void OnIdentifyStop(Identify * identify); + + void PostLightActionRequest(int32_t aActor, LightingManager::Action_t aAction); + +private: + static AppTask sAppTask; + + static void ActionInitiated(LightingManager::Action_t aAction, int32_t aActor); + static void ActionCompleted(LightingManager::Action_t aAction); + static void LightActionEventHandler(AppEvent * aEvent); + + static void UpdateClusterState(intptr_t context); + + /** + * @brief AppTask initialisation function + * + * @return CHIP_ERROR + */ + CHIP_ERROR Init(); + + /** + * @brief PB0 Button event processing function + * Press and hold will trigger a factory reset timer start + * Press and release will restart BLEAdvertising if not commisionned + * + * @param aEvent button event being processed + */ + static void ButtonHandler(AppEvent * aEvent); + + /** + * @brief PB1 Button event processing function + * Function triggers a switch action sent to the CHIP task + * + * @param aEvent button event being processed + */ + static void SwitchActionEventHandler(AppEvent * aEvent); +}; diff --git a/examples/lighting-app/silabs/SiWx917/include/CHIPProjectConfig.h b/examples/lighting-app/silabs/SiWx917/include/CHIPProjectConfig.h new file mode 100644 index 00000000000000..4b3d8f571c9057 --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/include/CHIPProjectConfig.h @@ -0,0 +1,135 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2019 Google LLC. + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Example project configuration file for CHIP. + * + * This is a place to put application or project-specific overrides + * to the default configuration values for general CHIP features. + * + */ + +#pragma once + +// Use a default pairing code if one hasn't been provisioned in flash. +#ifndef CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE +#define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE 20202021 +#endif + +#ifndef CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR +#define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR 0xF00 +#endif + +// For convenience, Chip Security Test Mode can be enabled and the +// requirement for authentication in various protocols can be disabled. +// +// WARNING: These options make it possible to circumvent basic Chip security functionality, +// including message encryption. Because of this they MUST NEVER BE ENABLED IN PRODUCTION BUILDS. +// +#define CHIP_CONFIG_SECURITY_TEST_MODE 0 + +/** + * CHIP_DEVICE_CONFIG_DEVICE_VENDOR_ID + * + * 0xFFF1: Test vendor + */ +#define CHIP_DEVICE_CONFIG_DEVICE_VENDOR_ID 0xFFF1 + +/** + * CHIP_DEVICE_CONFIG_DEVICE_PRODUCT_ID + * + * 0x8005: example lighting app + */ +#define CHIP_DEVICE_CONFIG_DEVICE_PRODUCT_ID 0x8005 + +/** + * CHIP_DEVICE_CONFIG_DEVICE_HARDWARE_VERSION + * + * The hardware version number assigned to device or product by the device vendor. This + * number is scoped to the device product id, and typically corresponds to a revision of the + * physical device, a change to its packaging, and/or a change to its marketing presentation. + * This value is generally *not* incremented for device software versions. + */ +#define CHIP_DEVICE_CONFIG_DEVICE_HARDWARE_VERSION 1 + +/** + * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING + * + * A string identifying the software version running on the device. + * CHIP service currently expects the software version to be in the format + * {MAJOR_VERSION}.0d{MINOR_VERSION} + */ +#ifndef CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING +#define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING "0.1ALPHA" +#endif + +/** + * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION + * + * A uint32_t identifying the software version running on the device. + */ +/* The SoftwareVersion attribute of the Basic cluster. */ +#ifndef CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION +#define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION 0x0001 +#endif + +/** + * CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE + * + * Enable support for Chip-over-BLE (CHIPoBLE). + */ +#define CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE 1 + +/** + * CHIP_DEVICE_CONFIG_TEST_SERIAL_NUMBER + * + * Enables the use of a hard-coded default serial number if none + * is found in Chip NV storage. + */ +#define CHIP_DEVICE_CONFIG_TEST_SERIAL_NUMBER "TEST_SN" + +/** + * CHIP_CONFIG_EVENT_LOGGING_UTC_TIMESTAMPS + * + * Enable recording UTC timestamps. + */ +#define CHIP_CONFIG_EVENT_LOGGING_UTC_TIMESTAMPS 1 + +/** + * CHIP_DEVICE_CONFIG_EVENT_LOGGING_DEBUG_BUFFER_SIZE + * + * A size, in bytes, of the individual debug event logging buffer. + */ +#define CHIP_DEVICE_CONFIG_EVENT_LOGGING_DEBUG_BUFFER_SIZE (512) + +/** + * @def CHIP_CONFIG_MRP_LOCAL_ACTIVE_RETRY_INTERVAL + * + * @brief + * Active retransmit interval, or time to wait before retransmission after + * subsequent failures in milliseconds. + * + * This is the default value, that might be adjusted by end device depending on its + * needs (e.g. sleeping period) using Service Discovery TXT record CRA key. + * + */ +#define CHIP_CONFIG_MRP_LOCAL_ACTIVE_RETRY_INTERVAL (2000_ms32) + +#define CHIP_DEVICE_CONFIG_ENABLE_EXTENDED_DISCOVERY 1 diff --git a/examples/lighting-app/silabs/SiWx917/include/LightingManager.h b/examples/lighting-app/silabs/SiWx917/include/LightingManager.h new file mode 100644 index 00000000000000..6d286faa30ef96 --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/include/LightingManager.h @@ -0,0 +1,90 @@ +/* + * + * Copyright (c) 2019 Google LLC. + * 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 +#include + +#include "AppEvent.h" + +#include "FreeRTOS.h" +#include "timers.h" // provides FreeRTOS timer support +#include + +#include + +class LightingManager +{ +public: + enum Action_t + { + ON_ACTION = 0, + OFF_ACTION, + + INVALID_ACTION + } Action; + + enum State_t + { + kState_OffInitiated = 0, + kState_OffCompleted, + kState_OnInitiated, + kState_OnCompleted, + } State; + + CHIP_ERROR Init(); + bool IsLightOn(); + void EnableAutoTurnOff(bool aOn); + void SetAutoTurnOffDuration(uint32_t aDurationInSecs); + bool IsActionInProgress(); + bool InitiateAction(int32_t aActor, Action_t aAction); + + typedef void (*Callback_fn_initiated)(Action_t, int32_t aActor); + typedef void (*Callback_fn_completed)(Action_t); + void SetCallbacks(Callback_fn_initiated aActionInitiated_CB, Callback_fn_completed aActionCompleted_CB); + + static void OnTriggerOffWithEffect(OnOffEffect * effect); + +private: + friend LightingManager & LightMgr(void); + State_t mState; + + Callback_fn_initiated mActionInitiated_CB; + Callback_fn_completed mActionCompleted_CB; + + bool mAutoTurnOff; + uint32_t mAutoTurnOffDuration; + bool mAutoTurnOffTimerArmed; + bool mOffEffectArmed; + + void CancelTimer(void); + void StartTimer(uint32_t aTimeoutMs); + + static void TimerEventHandler(TimerHandle_t xTimer); + static void AutoTurnOffTimerEventHandler(AppEvent * aEvent); + static void ActuatorMovementTimerEventHandler(AppEvent * aEvent); + static void OffEffectTimerEventHandler(AppEvent * aEvent); + + static LightingManager sLight; +}; + +inline LightingManager & LightMgr(void) +{ + return LightingManager::sLight; +} diff --git a/examples/lighting-app/silabs/SiWx917/src/AppTask.cpp b/examples/lighting-app/silabs/SiWx917/src/AppTask.cpp new file mode 100644 index 00000000000000..22cab2f3ed1e5f --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/src/AppTask.cpp @@ -0,0 +1,288 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2019 Google LLC. + * 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 "AppTask.h" +#include "AppConfig.h" +#include "AppEvent.h" + +#include +#include +#include +#include +#include +#include +#include + +#include + +#include +#include + +#include + +#include + +#define APP_FUNCTION_BUTTON &sl_button_btn0 +#define APP_LIGHT_SWITCH &sl_button_btn1 + +using namespace chip; +using namespace ::chip::DeviceLayer; + +namespace { + +EmberAfIdentifyEffectIdentifier sIdentifyEffect = EMBER_ZCL_IDENTIFY_EFFECT_IDENTIFIER_STOP_EFFECT; + +/********************************************************** + * Identify Callbacks + *********************************************************/ + +namespace { +void OnTriggerIdentifyEffectCompleted(chip::System::Layer * systemLayer, void * appState) +{ + ChipLogProgress(Zcl, "Trigger Identify Complete"); + sIdentifyEffect = EMBER_ZCL_IDENTIFY_EFFECT_IDENTIFIER_STOP_EFFECT; + +#if CHIP_DEVICE_CONFIG_ENABLE_SED == 1 + AppTask::GetAppTask().StopStatusLEDTimer(); +#endif +} +} // namespace + +void OnTriggerIdentifyEffect(Identify * identify) +{ + sIdentifyEffect = identify->mCurrentEffectIdentifier; + + if (identify->mCurrentEffectIdentifier == EMBER_ZCL_IDENTIFY_EFFECT_IDENTIFIER_CHANNEL_CHANGE) + { + ChipLogProgress(Zcl, "IDENTIFY_EFFECT_IDENTIFIER_CHANNEL_CHANGE - Not supported, use effect varriant %d", + identify->mEffectVariant); + sIdentifyEffect = static_cast(identify->mEffectVariant); + } + +#if CHIP_DEVICE_CONFIG_ENABLE_SED == 1 + AppTask::GetAppTask().StartStatusLEDTimer(); +#endif + + switch (sIdentifyEffect) + { + case EMBER_ZCL_IDENTIFY_EFFECT_IDENTIFIER_BLINK: + case EMBER_ZCL_IDENTIFY_EFFECT_IDENTIFIER_BREATHE: + case EMBER_ZCL_IDENTIFY_EFFECT_IDENTIFIER_OKAY: + (void) chip::DeviceLayer::SystemLayer().StartTimer(chip::System::Clock::Seconds16(5), OnTriggerIdentifyEffectCompleted, + identify); + break; + case EMBER_ZCL_IDENTIFY_EFFECT_IDENTIFIER_FINISH_EFFECT: + (void) chip::DeviceLayer::SystemLayer().CancelTimer(OnTriggerIdentifyEffectCompleted, identify); + (void) chip::DeviceLayer::SystemLayer().StartTimer(chip::System::Clock::Seconds16(1), OnTriggerIdentifyEffectCompleted, + identify); + break; + case EMBER_ZCL_IDENTIFY_EFFECT_IDENTIFIER_STOP_EFFECT: + (void) chip::DeviceLayer::SystemLayer().CancelTimer(OnTriggerIdentifyEffectCompleted, identify); + sIdentifyEffect = EMBER_ZCL_IDENTIFY_EFFECT_IDENTIFIER_STOP_EFFECT; + break; + default: + ChipLogProgress(Zcl, "No identifier effect"); + } +} + +Identify gIdentify = { + chip::EndpointId{ 1 }, + AppTask::GetAppTask().OnIdentifyStart, + AppTask::GetAppTask().OnIdentifyStop, + EMBER_ZCL_IDENTIFY_IDENTIFY_TYPE_VISIBLE_LED, + OnTriggerIdentifyEffect, +}; + +} // namespace + +using namespace chip::TLV; +using namespace ::chip::DeviceLayer; + +AppTask AppTask::sAppTask; + +CHIP_ERROR AppTask::Init() +{ + CHIP_ERROR err = CHIP_NO_ERROR; +#ifdef DISPLAY_ENABLED + GetLCD().Init((uint8_t *) "Lighting-App"); +#endif + + err = BaseApplication::Init(&gIdentify); + if (err != CHIP_NO_ERROR) + { + SILABS_LOG("BaseApplication::Init() failed"); + appError(err); + } + + /* TODO + err = LightMgr().Init(); + if (err != CHIP_NO_ERROR) + { + SILABS_LOG("LightMgr::Init() failed"); + appError(err); + } + + LightMgr().SetCallbacks(ActionInitiated, ActionCompleted); + */ + + return err; +} + +CHIP_ERROR AppTask::StartAppTask() +{ + return BaseApplication::StartAppTask(AppTaskMain); +} + +void AppTask::AppTaskMain(void * pvParameter) +{ + AppEvent event; + QueueHandle_t sAppEventQueue = *(static_cast(pvParameter)); + + CHIP_ERROR err = sAppTask.Init(); + if (err != CHIP_NO_ERROR) + { + SILABS_LOG("AppTask.Init() failed"); + appError(err); + } + +#if !(defined(CHIP_DEVICE_CONFIG_ENABLE_SED) && CHIP_DEVICE_CONFIG_ENABLE_SED) + sAppTask.StartStatusLEDTimer(); +#endif + + SILABS_LOG("App Task started"); + + while (true) + { + BaseType_t eventReceived = xQueueReceive(sAppEventQueue, &event, pdMS_TO_TICKS(10)); + while (eventReceived == pdTRUE) + { + sAppTask.DispatchEvent(&event); + eventReceived = xQueueReceive(sAppEventQueue, &event, 0); + } + } +} + +void AppTask::OnIdentifyStart(Identify * identify) +{ + ChipLogProgress(Zcl, "onIdentifyStart"); + +#if CHIP_DEVICE_CONFIG_ENABLE_SED == 1 + sAppTask.StartStatusLEDTimer(); +#endif +} + +void AppTask::OnIdentifyStop(Identify * identify) +{ + ChipLogProgress(Zcl, "onIdentifyStop"); + +#if CHIP_DEVICE_CONFIG_ENABLE_SED == 1 + sAppTask.StopStatusLEDTimer(); +#endif +} + +void AppTask::LightActionEventHandler(AppEvent * aEvent) +{ + bool initiated = false; + LightingManager::Action_t action; + int32_t actor; + CHIP_ERROR err = CHIP_NO_ERROR; + + if (aEvent->Type == AppEvent::kEventType_Light) + { + action = static_cast(aEvent->LightEvent.Action); + actor = aEvent->LightEvent.Actor; + } + else if (aEvent->Type == AppEvent::kEventType_Button) + { + action = (LightMgr().IsLightOn()) ? LightingManager::OFF_ACTION : LightingManager::ON_ACTION; + actor = AppEvent::kEventType_Button; + } + else + { + err = APP_ERROR_UNHANDLED_EVENT; + } + + if (err == CHIP_NO_ERROR) + { + initiated = LightMgr().InitiateAction(actor, action); + + if (!initiated) + { + SILABS_LOG("Action is already in progress or active."); + } + } +} + +void AppTask::ActionInitiated(LightingManager::Action_t aAction, int32_t aActor) +{ + // Action initiated, update the light led + bool lightOn = aAction == LightingManager::ON_ACTION; + SILABS_LOG("Turning light %s", (lightOn) ? "On" : "Off") + +#ifdef DISPLAY_ENABLED + sAppTask.GetLCD().WriteDemoUI(lightOn); +#endif + + if (aActor == AppEvent::kEventType_Button) + { + sAppTask.mSyncClusterToButtonAction = true; + } +} + +void AppTask::ActionCompleted(LightingManager::Action_t aAction) +{ + // action has been completed bon the light + if (aAction == LightingManager::ON_ACTION) + { + SILABS_LOG("Light ON") + } + else if (aAction == LightingManager::OFF_ACTION) + { + SILABS_LOG("Light OFF") + } + + if (sAppTask.mSyncClusterToButtonAction) + { + chip::DeviceLayer::PlatformMgr().ScheduleWork(UpdateClusterState, reinterpret_cast(nullptr)); + sAppTask.mSyncClusterToButtonAction = false; + } +} + +void AppTask::PostLightActionRequest(int32_t aActor, LightingManager::Action_t aAction) +{ + AppEvent event; + event.Type = AppEvent::kEventType_Light; + event.LightEvent.Actor = aActor; + event.LightEvent.Action = aAction; + event.Handler = LightActionEventHandler; + PostEvent(&event); +} + +void AppTask::UpdateClusterState(intptr_t context) +{ + uint8_t newValue = LightMgr().IsLightOn(); + + // write the new on/off value + EmberAfStatus status = OnOffServer::Instance().setOnOffValue(1, newValue, false); + + if (status != EMBER_ZCL_STATUS_SUCCESS) + { + SILABS_LOG("ERR: updating on/off %x", status); + } +} diff --git a/examples/lighting-app/silabs/SiWx917/src/LightingManager.cpp b/examples/lighting-app/silabs/SiWx917/src/LightingManager.cpp new file mode 100644 index 00000000000000..31a4ca0ba91e7c --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/src/LightingManager.cpp @@ -0,0 +1,322 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2019 Google LLC. + * 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 "LightingManager.h" + +#include "AppConfig.h" +#include "AppTask.h" +#include + +using namespace chip; +using namespace ::chip::DeviceLayer; + +LightingManager LightingManager::sLight; + +TimerHandle_t sLightTimer; + +namespace { + +/********************************************************** + * OffWithEffect Callbacks + *********************************************************/ + +OnOffEffect gEffect = { + chip::EndpointId{ 1 }, + LightMgr().OnTriggerOffWithEffect, + EMBER_ZCL_ON_OFF_EFFECT_IDENTIFIER_DELAYED_ALL_OFF, + static_cast(EMBER_ZCL_ON_OFF_DELAYED_ALL_OFF_EFFECT_VARIANT_FADE_TO_OFF_IN_0P8_SECONDS), +}; + +} // namespace + +CHIP_ERROR LightingManager::Init() +{ + // Create FreeRTOS sw timer for light timer. + sLightTimer = xTimerCreate("lightTmr", // Just a text name, not used by the RTOS kernel + 1, // == default timer period (mS) + false, // no timer reload (==one-shot) + (void *) this, // init timer id = light obj context + TimerEventHandler // timer callback handler + ); + + if (sLightTimer == NULL) + { + SILABS_LOG("sLightTimer timer create failed"); + return APP_ERROR_CREATE_TIMER_FAILED; + } + + bool currentLedState; + // read current on/off value on endpoint one. + chip::DeviceLayer::PlatformMgr().LockChipStack(); + OnOffServer::Instance().getOnOffValue(1, ¤tLedState); + chip::DeviceLayer::PlatformMgr().UnlockChipStack(); + + mState = currentLedState ? kState_OnCompleted : kState_OffCompleted; + mAutoTurnOffTimerArmed = false; + mAutoTurnOff = false; + mAutoTurnOffDuration = 0; + mOffEffectArmed = false; + + return CHIP_NO_ERROR; +} + +void LightingManager::SetCallbacks(Callback_fn_initiated aActionInitiated_CB, Callback_fn_completed aActionCompleted_CB) +{ + mActionInitiated_CB = aActionInitiated_CB; + mActionCompleted_CB = aActionCompleted_CB; +} + +bool LightingManager::IsActionInProgress() +{ + return (mState == kState_OffInitiated || mState == kState_OnInitiated); +} + +bool LightingManager::IsLightOn() +{ + return (mState == kState_OnCompleted); +} + +void LightingManager::EnableAutoTurnOff(bool aOn) +{ + mAutoTurnOff = aOn; +} + +void LightingManager::SetAutoTurnOffDuration(uint32_t aDurationInSecs) +{ + mAutoTurnOffDuration = aDurationInSecs; +} + +bool LightingManager::InitiateAction(int32_t aActor, Action_t aAction) +{ + bool action_initiated = false; + State_t new_state; + + // Initiate Turn On/Off Action only when the previous one is complete. + if (((mState == kState_OffCompleted) || mOffEffectArmed) && aAction == ON_ACTION) + { + action_initiated = true; + + new_state = kState_OnInitiated; + } + else if (mState == kState_OnCompleted && aAction == OFF_ACTION && mOffEffectArmed == false) + { + action_initiated = true; + + new_state = kState_OffInitiated; + } + + if (action_initiated) + { + if (mAutoTurnOffTimerArmed && new_state == kState_OffInitiated) + { + // If auto turn off timer has been armed and someone initiates turning off, + // cancel the timer and continue as normal. + mAutoTurnOffTimerArmed = false; + + CancelTimer(); + } + + if (mOffEffectArmed && new_state == kState_OnInitiated) + { + CancelTimer(); + mOffEffectArmed = false; + } + + StartTimer(ACTUATOR_MOVEMENT_PERIOS_MS); + + // Since the timer started successfully, update the state and trigger callback + mState = new_state; + + if (mActionInitiated_CB) + { + mActionInitiated_CB(aAction, aActor); + } + } + + return action_initiated; +} + +void LightingManager::StartTimer(uint32_t aTimeoutMs) +{ + if (xTimerIsTimerActive(sLightTimer)) + { + SILABS_LOG("app timer already started!"); + CancelTimer(); + } + + // timer is not active, change its period to required value (== restart). + // FreeRTOS- Block for a maximum of 100 ticks if the change period command + // cannot immediately be sent to the timer command queue. + if (xTimerChangePeriod(sLightTimer, (aTimeoutMs / portTICK_PERIOD_MS), 100) != pdPASS) + { + SILABS_LOG("sLightTimer timer start() failed"); + appError(APP_ERROR_START_TIMER_FAILED); + } +} + +void LightingManager::CancelTimer(void) +{ + if (xTimerStop(sLightTimer, 0) == pdFAIL) + { + SILABS_LOG("sLightTimer stop() failed"); + appError(APP_ERROR_STOP_TIMER_FAILED); + } +} + +void LightingManager::TimerEventHandler(TimerHandle_t xTimer) +{ + // Get light obj context from timer id. + LightingManager * light = static_cast(pvTimerGetTimerID(xTimer)); + + // The timer event handler will be called in the context of the timer task + // once sLightTimer expires. Post an event to apptask queue with the actual handler + // so that the event can be handled in the context of the apptask. + AppEvent event; + event.Type = AppEvent::kEventType_Timer; + event.TimerEvent.Context = light; + if (light->mAutoTurnOffTimerArmed) + { + event.Handler = AutoTurnOffTimerEventHandler; + } + else if (light->mOffEffectArmed) + { + event.Handler = OffEffectTimerEventHandler; + } + else + { + event.Handler = ActuatorMovementTimerEventHandler; + } + AppTask::GetAppTask().PostEvent(&event); +} + +void LightingManager::AutoTurnOffTimerEventHandler(AppEvent * aEvent) +{ + LightingManager * light = static_cast(aEvent->TimerEvent.Context); + int32_t actor = AppEvent::kEventType_Timer; + + // Make sure auto turn off timer is still armed. + if (!light->mAutoTurnOffTimerArmed) + { + return; + } + + light->mAutoTurnOffTimerArmed = false; + + SILABS_LOG("Auto Turn Off has been triggered!"); + + light->InitiateAction(actor, OFF_ACTION); +} + +void LightingManager::OffEffectTimerEventHandler(AppEvent * aEvent) +{ + LightingManager * light = static_cast(aEvent->TimerEvent.Context); + int32_t actor = AppEvent::kEventType_Timer; + + // Make sure auto turn off timer is still armed. + if (!light->mOffEffectArmed) + { + return; + } + + light->mOffEffectArmed = false; + + SILABS_LOG("OffEffect completed"); + + light->InitiateAction(actor, OFF_ACTION); +} + +void LightingManager::ActuatorMovementTimerEventHandler(AppEvent * aEvent) +{ + Action_t actionCompleted = INVALID_ACTION; + + LightingManager * light = static_cast(aEvent->TimerEvent.Context); + + if (light->mState == kState_OffInitiated) + { + light->mState = kState_OffCompleted; + actionCompleted = OFF_ACTION; + } + else if (light->mState == kState_OnInitiated) + { + light->mState = kState_OnCompleted; + actionCompleted = ON_ACTION; + } + + if (actionCompleted != INVALID_ACTION) + { + if (light->mActionCompleted_CB) + { + light->mActionCompleted_CB(actionCompleted); + } + + if (light->mAutoTurnOff && actionCompleted == ON_ACTION) + { + // Start the timer for auto turn off + light->StartTimer(light->mAutoTurnOffDuration * 1000); + + light->mAutoTurnOffTimerArmed = true; + + SILABS_LOG("Auto Turn off enabled. Will be triggered in %u seconds", light->mAutoTurnOffDuration); + } + } +} + +void LightingManager::OnTriggerOffWithEffect(OnOffEffect * effect) +{ + chip::app::Clusters::OnOff::OnOffEffectIdentifier effectId = effect->mEffectIdentifier; + uint8_t effectVariant = effect->mEffectVariant; + uint32_t offEffectDuration = 0; + + // Temporary print outs and delay to test OffEffect behaviour + // Until dimming is supported for dev boards. + if (effectId == EMBER_ZCL_ON_OFF_EFFECT_IDENTIFIER_DELAYED_ALL_OFF) + { + if (effectVariant == EMBER_ZCL_ON_OFF_DELAYED_ALL_OFF_EFFECT_VARIANT_FADE_TO_OFF_IN_0P8_SECONDS) + { + offEffectDuration = 800; + ChipLogProgress(Zcl, "EMBER_ZCL_ON_OFF_DELAYED_ALL_OFF_EFFECT_VARIANT_FADE_TO_OFF_IN_0P8_SECONDS"); + } + else if (effectVariant == EMBER_ZCL_ON_OFF_DELAYED_ALL_OFF_EFFECT_VARIANT_NO_FADE) + { + offEffectDuration = 800; + ChipLogProgress(Zcl, "EMBER_ZCL_ON_OFF_DELAYED_ALL_OFF_EFFECT_VARIANT_NO_FADE"); + } + else if (effectVariant == + EMBER_ZCL_ON_OFF_DELAYED_ALL_OFF_EFFECT_VARIANT_50_PERCENT_DIM_DOWN_IN_0P8_SECONDS_THEN_FADE_TO_OFF_IN_12_SECONDS) + { + offEffectDuration = 12800; + ChipLogProgress(Zcl, + "EMBER_ZCL_ON_OFF_DELAYED_ALL_OFF_EFFECT_VARIANT_50_PERCENT_DIM_DOWN_IN_0P8_SECONDS_THEN_FADE_TO_OFF_" + "IN_12_SECONDS"); + } + } + else if (effectId == EMBER_ZCL_ON_OFF_EFFECT_IDENTIFIER_DYING_LIGHT) + { + if (effectVariant == + EMBER_ZCL_ON_OFF_DYING_LIGHT_EFFECT_VARIANT_20_PERCENTER_DIM_UP_IN_0P5_SECONDS_THEN_FADE_TO_OFF_IN_1_SECOND) + { + offEffectDuration = 1500; + ChipLogProgress( + Zcl, "EMBER_ZCL_ON_OFF_DYING_LIGHT_EFFECT_VARIANT_20_PERCENTER_DIM_UP_IN_0P5_SECONDS_THEN_FADE_TO_OFF_IN_1_SECOND"); + } + } + + LightMgr().mOffEffectArmed = true; + LightMgr().StartTimer(offEffectDuration); +} diff --git a/examples/lighting-app/silabs/SiWx917/src/ZclCallbacks.cpp b/examples/lighting-app/silabs/SiWx917/src/ZclCallbacks.cpp new file mode 100644 index 00000000000000..cfbcbc8a191411 --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/src/ZclCallbacks.cpp @@ -0,0 +1,91 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * This file implements the handler for data model messages. + */ + +#include "AppConfig.h" +#include "LightingManager.h" + +#include +#include +#include +#include + +using namespace ::chip; +using namespace ::chip::app::Clusters; + +void MatterPostAttributeChangeCallback(const chip::app::ConcreteAttributePath & attributePath, uint8_t type, uint16_t size, + uint8_t * value) +{ + ClusterId clusterId = attributePath.mClusterId; + AttributeId attributeId = attributePath.mAttributeId; + ChipLogProgress(Zcl, "Cluster callback: " ChipLogFormatMEI, ChipLogValueMEI(clusterId)); + + if (clusterId == OnOff::Id && attributeId == OnOff::Attributes::OnOff::Id) + { + LightMgr().InitiateAction(AppEvent::kEventType_Light, *value ? LightingManager::ON_ACTION : LightingManager::OFF_ACTION); + } + else if (clusterId == LevelControl::Id) + { + ChipLogProgress(Zcl, "Level Control attribute ID: " ChipLogFormatMEI " Type: %u Value: %u, length %u", + ChipLogValueMEI(attributeId), type, *value, size); + + // WIP Apply attribute change to Light + } + else if (clusterId == ColorControl::Id) + { + ChipLogProgress(Zcl, "Color Control attribute ID: " ChipLogFormatMEI " Type: %u Value: %u, length %u", + ChipLogValueMEI(attributeId), type, *value, size); + + // WIP Apply attribute change to Light + } + else if (clusterId == OnOffSwitchConfiguration::Id) + { + ChipLogProgress(Zcl, "OnOff Switch Configuration attribute ID: " ChipLogFormatMEI " Type: %u Value: %u, length %u", + ChipLogValueMEI(attributeId), type, *value, size); + + // WIP Apply attribute change to Light + } + else if (clusterId == Identify::Id) + { + ChipLogProgress(Zcl, "Identify attribute ID: " ChipLogFormatMEI " Type: %u Value: %u, length %u", + ChipLogValueMEI(attributeId), type, *value, size); + } +} + +/** @brief OnOff Cluster Init + * + * This function is called when a specific cluster is initialized. It gives the + * application an opportunity to take care of cluster initialization procedures. + * It is called exactly once for each endpoint where cluster is present. + * + * @param endpoint Ver.: always + * + * TODO Issue #3841 + * emberAfOnOffClusterInitCallback happens before the stack initialize the cluster + * attributes to the default value. + * The logic here expects something similar to the deprecated Plugins callback + * emberAfPluginOnOffClusterServerPostInitCallback. + * + */ +void emberAfOnOffClusterInitCallback(EndpointId endpoint) +{ + // TODO: implement any additional Cluster Server init actions +} diff --git a/examples/lighting-app/silabs/SiWx917/src/main.cpp b/examples/lighting-app/silabs/SiWx917/src/main.cpp new file mode 100644 index 00000000000000..e3ed2a9c8490a8 --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/src/main.cpp @@ -0,0 +1,82 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2019 Google LLC. + * 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 + +#include "AppConfig.h" +#include "init_ccpPlatform.h" + +#include +#include +#include +#include +#ifdef SI917_ATTESTATION_CREDENTIALS +#include +#else +#include +#endif + +#define BLE_DEV_NAME "SiLabs-Light" +using namespace ::chip; +using namespace ::chip::Inet; +using namespace ::chip::DeviceLayer; +using namespace ::chip::Credentials; + +#define UNUSED_PARAMETER(a) (a = a) + +volatile int apperror_cnt; +static chip::DeviceLayer::DeviceInfoProviderImpl gExampleDeviceInfoProvider; + +// ================================================================================ +// Main Code +// ================================================================================ +int main(void) +{ + init_ccpPlatform(); + if (SI917MatterConfig::InitMatter(BLE_DEV_NAME) != CHIP_NO_ERROR) + { + appError(CHIP_ERROR_INTERNAL); + } + + gExampleDeviceInfoProvider.SetStorageDelegate(&chip::Server::GetInstance().GetPersistentStorage()); + chip::DeviceLayer::SetDeviceInfoProvider(&gExampleDeviceInfoProvider); + + chip::DeviceLayer::PlatformMgr().LockChipStack(); + // Initialize device attestation config +#ifdef SI917_ATTESTATION_CREDENTIALS + SetDeviceAttestationCredentialsProvider(Silabs::GetSilabsDacProvider()); +#else + SetDeviceAttestationCredentialsProvider(Examples::GetExampleDACProvider()); +#endif + chip::DeviceLayer::PlatformMgr().UnlockChipStack(); + + SILABS_LOG("Starting App Task"); + if (AppTask::GetAppTask().StartAppTask() != CHIP_NO_ERROR) + { + appError(CHIP_ERROR_INTERNAL); + } + + SILABS_LOG("Starting FreeRTOS scheduler"); + vTaskStartScheduler(); + + // Should never get here. + chip::Platform::MemoryShutdown(); + SILABS_LOG("vTaskStartScheduler() failed"); + appError(CHIP_ERROR_INTERNAL); +} diff --git a/examples/lighting-app/silabs/SiWx917/third_party/connectedhomeip b/examples/lighting-app/silabs/SiWx917/third_party/connectedhomeip new file mode 120000 index 00000000000000..59307833b4fee9 --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/third_party/connectedhomeip @@ -0,0 +1 @@ +../../../../.. \ No newline at end of file diff --git a/examples/lighting-app/silabs/SiWx917/with_pw_rpc.gni b/examples/lighting-app/silabs/SiWx917/with_pw_rpc.gni new file mode 100644 index 00000000000000..3e2b6e54411c6c --- /dev/null +++ b/examples/lighting-app/silabs/SiWx917/with_pw_rpc.gni @@ -0,0 +1,31 @@ +# Copyright (c) 2021 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# add this gni as import in your build args to use pigweed in the example +# 'import("//with_pw_rpc.gni")' + +import("//build_overrides/chip.gni") +import("${chip_root}/config/efr32/lib/pw_rpc/pw_rpc.gni") +import("${chip_root}/examples/platform/silabs/SiWx917/args.gni") + +efr32_sdk_target = get_label_info(":sdk", "label_no_toolchain") + +chip_enable_pw_rpc = true +chip_enable_openthread = true +chip_build_pw_trace_lib = true + +cpp_standard = "gnu++17" + +# Light app on EFR enables tracing server +pw_trace_BACKEND = "$dir_pw_trace_tokenized" diff --git a/examples/lighting-app/silabs/efr32/BUILD.gn b/examples/lighting-app/silabs/efr32/BUILD.gn index 3a812b966d3361..d2f68f8b44541e 100644 --- a/examples/lighting-app/silabs/efr32/BUILD.gn +++ b/examples/lighting-app/silabs/efr32/BUILD.gn @@ -190,6 +190,7 @@ efr32_sdk("sdk") { efr32_executable("lighting_app") { output_name = "chip-efr32-lighting-example.out" + public_configs = [ "${efr32_sdk_build_root}:silabs_config" ] include_dirs = [ "include" ] defines = [] diff --git a/examples/lighting-app/silabs/efr32/README.md b/examples/lighting-app/silabs/efr32/README.md index ae7565f492c620..c7edd84f746eea 100644 --- a/examples/lighting-app/silabs/efr32/README.md +++ b/examples/lighting-app/silabs/efr32/README.md @@ -129,7 +129,7 @@ Silicon Labs platform. * Build the example application: cd ~/connectedhomeip - ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/efr32/ ./out/lighting-app BRD4161A + ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/silabs/efr32/ ./out/lighting-app BRD4161A - To delete generated executable, libraries and object files use: @@ -152,7 +152,7 @@ Silicon Labs platform. * Build the example as Sleepy End Device (SED) - $ ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/efr32/ ./out/lighting-app_SED BRD4161A --sed + $ ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/silabs/efr32/ ./out/lighting-app_SED BRD4161A --sed or use gn as previously mentioned but adding the following arguments: @@ -400,19 +400,19 @@ passed to the build scripts. `chip_progress_logging, chip_detail_logging, chip_automation_logging` - $ ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/efr32 ./out/lighting-app BRD4164A "chip_detail_logging=false chip_automation_logging=false chip_progress_logging=false" + $ ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/silabs/efr32 ./out/lighting-app BRD4164A "chip_detail_logging=false chip_automation_logging=false chip_progress_logging=false" ### Debug build / release build `is_debug` - $ ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/efr32 ./out/lighting-app BRD4164A "is_debug=false" + $ ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/silabs/efr32 ./out/lighting-app BRD4164A "is_debug=false" ### Disabling LCD `show_qr_code` - $ ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/efr32 ./out/lighting-app BRD4164A "show_qr_code=false" + $ ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/silabs/efr32 ./out/lighting-app BRD4164A "show_qr_code=false" ### KVS maximum entry count @@ -421,4 +421,4 @@ passed to the build scripts. Set the maximum Kvs entries that can be stored in NVM (Default 75) Thresholds: 30 <= kvs_max_entries <= 255 - $ ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/efr32 ./out/lighting-app BRD4164A kvs_max_entries=50 + $ ./scripts/examples/gn_efr32_example.sh ./examples/lighting-app/silabs/efr32 ./out/lighting-app BRD4164A kvs_max_entries=50 diff --git a/examples/lighting-app/silabs/efr32/include/CHIPProjectConfig.h b/examples/lighting-app/silabs/efr32/include/CHIPProjectConfig.h index 4b3d8f571c9057..1d3fefcce8232e 100644 --- a/examples/lighting-app/silabs/efr32/include/CHIPProjectConfig.h +++ b/examples/lighting-app/silabs/efr32/include/CHIPProjectConfig.h @@ -69,17 +69,6 @@ */ #define CHIP_DEVICE_CONFIG_DEVICE_HARDWARE_VERSION 1 -/** - * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING - * - * A string identifying the software version running on the device. - * CHIP service currently expects the software version to be in the format - * {MAJOR_VERSION}.0d{MINOR_VERSION} - */ -#ifndef CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING -#define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING "0.1ALPHA" -#endif - /** * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION * diff --git a/examples/lighting-app/silabs/efr32/src/AppTask.cpp b/examples/lighting-app/silabs/efr32/src/AppTask.cpp index 850649df25e27d..ccd77060e755d1 100644 --- a/examples/lighting-app/silabs/efr32/src/AppTask.cpp +++ b/examples/lighting-app/silabs/efr32/src/AppTask.cpp @@ -28,7 +28,6 @@ #include #include -#include #include #include #include @@ -187,7 +186,7 @@ void AppTask::AppTaskMain(void * pvParameter) while (true) { - BaseType_t eventReceived = xQueueReceive(sAppEventQueue, &event, pdMS_TO_TICKS(10)); + BaseType_t eventReceived = xQueueReceive(sAppEventQueue, &event, portMAX_DELAY); while (eventReceived == pdTRUE) { sAppTask.DispatchEvent(&event); diff --git a/examples/lighting-app/telink/CMakeLists.txt b/examples/lighting-app/telink/CMakeLists.txt index c4af6cb598b8c9..5beea781359c18 100644 --- a/examples/lighting-app/telink/CMakeLists.txt +++ b/examples/lighting-app/telink/CMakeLists.txt @@ -18,7 +18,6 @@ cmake_minimum_required(VERSION 3.13.1) set(BOARD tlsr9518adk80d) get_filename_component(CHIP_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/third_party/connectedhomeip REALPATH) -get_filename_component(NLIO_ROOT ${CHIP_ROOT}/third_party/nlio/repo/include REALPATH) get_filename_component(TELINK_COMMON ${CHIP_ROOT}/examples/platform/telink REALPATH) get_filename_component(GEN_DIR ${CHIP_ROOT}/zzz_generated/ REALPATH) @@ -39,7 +38,6 @@ target_include_directories(app PRIVATE include ${GEN_DIR}/app-common ${GEN_DIR}/lighting-app - ${NLIO_ROOT} ${TELINK_COMMON}/util/include ${TELINK_COMMON}/app/include) @@ -66,3 +64,162 @@ chip_configure_data_model(app if(CONFIG_CHIP_OTA_REQUESTOR) target_sources(app PRIVATE ${TELINK_COMMON}/util/src/OTAUtil.cpp) endif() + +# Fix for unused swap parameter in: zephyr/include/zephyr/arch/riscv/irq.h:70 +add_compile_options(-Wno-error=unused-parameter) + +if (CONFIG_CHIP_PW_RPC) + +# Make all targets created below depend on zephyr_interface to inherit MCU-related compilation flags +link_libraries($) + +set(PIGWEED_ROOT "${CHIP_ROOT}/third_party/pigweed/repo") +include(${PIGWEED_ROOT}/pw_build/pigweed.cmake) +include(${PIGWEED_ROOT}/pw_protobuf_compiler/proto.cmake) + +pw_set_module_config(pw_rpc_CONFIG pw_rpc.disable_global_mutex_config) +pw_set_backend(pw_log pw_log_basic) +pw_set_backend(pw_assert.check pw_assert_log.check_backend) +pw_set_backend(pw_assert.assert pw_assert.assert_compatibility_backend) +pw_set_backend(pw_sys_io pw_sys_io.telink) +pw_set_backend(pw_trace pw_trace_tokenized) +set(dir_pw_third_party_nanopb "${CHIP_ROOT}/third_party/nanopb/repo" CACHE STRING "" FORCE) + +add_subdirectory(third_party/connectedhomeip/third_party/pigweed/repo) +add_subdirectory(third_party/connectedhomeip/third_party/nanopb/repo) +add_subdirectory(third_party/connectedhomeip/examples/platform/telink/pw_sys_io) + +pw_proto_library(attributes_service + SOURCES + ${CHIP_ROOT}/examples/common/pigweed/protos/attributes_service.proto + INPUTS + ${CHIP_ROOT}/examples/common/pigweed/protos/attributes_service.options + PREFIX + attributes_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 + PREFIX + button_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 + PREFIX + descriptor_service + STRIP_PREFIX + ${CHIP_ROOT}/examples/common/pigweed/protos + DEPS + pw_protobuf.common_proto +) + +pw_proto_library(device_service + SOURCES + ${CHIP_ROOT}/examples/common/pigweed/protos/device_service.proto + INPUTS + ${CHIP_ROOT}/examples/common/pigweed/protos/device_service.options + PREFIX + device_service + STRIP_PREFIX + ${CHIP_ROOT}/examples/common/pigweed/protos + DEPS + pw_protobuf.common_proto +) + +pw_proto_library(lighting_service + SOURCES + ${CHIP_ROOT}/examples/common/pigweed/protos/lighting_service.proto + STRIP_PREFIX + ${CHIP_ROOT}/examples/common/pigweed/protos + PREFIX + lighting_service + DEPS + pw_protobuf.common_proto +) + +pw_proto_library(ot_cli_service + SOURCES + ${CHIP_ROOT}/examples/common/pigweed/protos/ot_cli_service.proto + INPUTS + ${CHIP_ROOT}/examples/common/pigweed/protos/ot_cli_service.options + STRIP_PREFIX + ${CHIP_ROOT}/examples/common/pigweed/protos + PREFIX + ot_cli_service + DEPS + pw_protobuf.common_proto +) + +pw_proto_library(thread_service + SOURCES + ${CHIP_ROOT}/examples/common/pigweed/protos/thread_service.proto + INPUTS + ${CHIP_ROOT}/examples/common/pigweed/protos/thread_service.options + STRIP_PREFIX + ${CHIP_ROOT}/examples/common/pigweed/protos + PREFIX + thread_service + DEPS + pw_protobuf.common_proto +) + +target_sources(app PRIVATE + ../../common/pigweed/RpcService.cpp + ../../common/pigweed/telink/PigweedLoggerMutex.cpp + ${TELINK_COMMON}/Rpc.cpp + ${TELINK_COMMON}/util/src/PigweedLogger.cpp +) + +target_include_directories(app PRIVATE + ${PIGWEED_ROOT}/pw_sys_io/public + ${CHIP_ROOT}/src/lib/support + ${CHIP_ROOT}/src/system + ${TELINK_COMMON} + ../../common + ../../common/pigweed + ../../common/pigweed/telink) + +target_compile_options(app PRIVATE + "-DPW_RPC_ATTRIBUTE_SERVICE=1" + "-DPW_RPC_BUTTON_SERVICE=1" + "-DPW_RPC_DESCRIPTOR_SERVICE=1" + "-DPW_RPC_DEVICE_SERVICE=1" + "-DPW_RPC_LIGHTING_SERVICE=1" + "-DPW_RPC_THREAD_SERVICE=1" + "-DPW_RPC_TRACING_SERVICE=1" + "-DPW_TRACE_BACKEND_SET=1") + +target_link_libraries(app PRIVATE + attributes_service.nanopb_rpc + button_service.nanopb_rpc + descriptor_service.nanopb_rpc + device_service.nanopb_rpc + lighting_service.nanopb_rpc + thread_service.nanopb_rpc + pw_checksum + pw_hdlc + pw_log + pw_rpc.server + pw_trace_tokenized + pw_trace_tokenized.trace_buffer + pw_trace_tokenized.rpc_service + pw_trace_tokenized.protos.nanopb_rpc +) + +target_link_options(app + PUBLIC + "-T${PIGWEED_ROOT}/pw_tokenizer/pw_tokenizer_linker_sections.ld" +) + +endif(CONFIG_CHIP_PW_RPC) diff --git a/examples/lighting-app/telink/Readme.md b/examples/lighting-app/telink/Readme.md index 018fdd386dc898..d6ace813c0df75 100644 --- a/examples/lighting-app/telink/Readme.md +++ b/examples/lighting-app/telink/Readme.md @@ -223,3 +223,15 @@ Usage of OTA: Once the transfer is complete, OTA requestor sends ApplyUpdateRequest command to OTA provider for applying the image. Device will restart on successful application of OTA image. + +### Building with Pigweed RPCs + +The RPCs in `lighting-common/lighting_service/lighting_service.proto` can be +used to control various functionalities of the lighting app from a USB-connected +host computer. To build the example with the RPC server, run the following +command with _build-target_ replaced with the build target name of the Nordic +Semiconductor's kit you own: + + ``` + $ west build -b tlsr9518adk80d -- -DOVERLAY_CONFIG=rpc.overlay + ``` diff --git a/examples/lighting-app/telink/include/AppTask.h b/examples/lighting-app/telink/include/AppTask.h index 0b1b588654aa13..09ba6ef240f26c 100644 --- a/examples/lighting-app/telink/include/AppTask.h +++ b/examples/lighting-app/telink/include/AppTask.h @@ -27,6 +27,10 @@ #include #endif +#ifdef CONFIG_CHIP_PW_RPC +#include "Rpc.h" +#endif + #include struct k_timer; @@ -40,7 +44,18 @@ class AppTask void PostEvent(AppEvent * event); void UpdateClusterState(); + enum ButtonId_t + { + kButtonId_LightingAction = 1, + kButtonId_FactoryReset, + kButtonId_StartThread, + kButtonId_StartBleAdv + } ButtonId; + private: +#ifdef CONFIG_CHIP_PW_RPC + friend class chip::rpc::TelinkButton; +#endif friend AppTask & GetAppTask(void); CHIP_ERROR Init(); @@ -62,6 +77,7 @@ class AppTask static void LightingActionEventHandler(AppEvent * aEvent); static void StartBleAdvHandler(AppEvent * aEvent); + static void ButtonEventHandler(ButtonId_t btnId, bool btnPressed); static void InitButtons(void); static void ThreadProvisioningHandler(const chip::DeviceLayer::ChipDeviceEvent * event, intptr_t arg); diff --git a/examples/lighting-app/telink/include/CHIPProjectConfig.h b/examples/lighting-app/telink/include/CHIPProjectConfig.h index 43adb45f85f50b..76d4372a80703f 100644 --- a/examples/lighting-app/telink/include/CHIPProjectConfig.h +++ b/examples/lighting-app/telink/include/CHIPProjectConfig.h @@ -31,12 +31,10 @@ #define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE 20202021 #define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR 0xF00 -/** - * CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE - * - * Enable support for Chip-over-BLE (CHIPoBLE). - */ -#define CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE 1 +// Switching from Thread child to router may cause a few second packet stall. +// Until this is improved in OpenThread we need to increase the retransmission +// interval to survive the stall. +#define CHIP_CONFIG_MRP_LOCAL_ACTIVE_RETRY_INTERVAL (1000_ms32) /** * CHIP_SYSTEM_CONFIG_PACKETBUFFER_POOL_SIZE @@ -44,5 +42,3 @@ * Reduce packet buffer pool size to 8 (default 15) to reduce ram consumption */ #define CHIP_SYSTEM_CONFIG_PACKETBUFFER_POOL_SIZE 8 - -#define CHIP_DEVICE_CONFIG_ENABLE_EXTENDED_DISCOVERY 1 diff --git a/examples/lighting-app/telink/prj.conf b/examples/lighting-app/telink/prj.conf index 3de670dd34bf07..f05cfc94f7cdce 100644 --- a/examples/lighting-app/telink/prj.conf +++ b/examples/lighting-app/telink/prj.conf @@ -33,7 +33,6 @@ CONFIG_OPENTHREAD_PANID=4660 CONFIG_OPENTHREAD_CHANNEL=15 CONFIG_OPENTHREAD_NETWORK_NAME="OpenThreadDemo" CONFIG_OPENTHREAD_XPANID="11:11:11:11:22:22:22:22" -CONFIG_NET_CONFIG_IEEE802154_DEV_NAME="IEEE802154_b91" # Disable Matter OTA DFU CONFIG_CHIP_OTA_REQUESTOR=n @@ -58,4 +57,5 @@ CONFIG_CHIP_LIB_SHELL=n # Disable factory data support. CONFIG_CHIP_FACTORY_DATA=n -CONFIG_CHIP_FACTORY_DATA_BUILD=n \ No newline at end of file +CONFIG_CHIP_FACTORY_DATA_BUILD=n +CONFIG_CHIP_FACTORY_DATA_MERGE_WITH_FIRMWARE=n \ No newline at end of file diff --git a/examples/lighting-app/telink/rpc.overlay b/examples/lighting-app/telink/rpc.overlay new file mode 100644 index 00000000000000..a97621181efc75 --- /dev/null +++ b/examples/lighting-app/telink/rpc.overlay @@ -0,0 +1,47 @@ +# +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# This file should be used as a configuration overlay to build Pigweed RPCs to +# lighting-app. + +# Enable Pigweed RPC +CONFIG_CHIP_PW_RPC=y + +# Add support for C++17 to build Pigweed components +CONFIG_STD_CPP14=n +CONFIG_STD_CPP17=y + +# Add support for Zephyr console component to use it for Pigweed console purposes +CONFIG_CONSOLE_SUBSYS=y +CONFIG_CONSOLE_GETCHAR=y +CONFIG_CONSOLE_PUTCHAR_BUFSIZE=256 + +# Disable features which may interfere with Pigweed HDLC transport +CONFIG_SHELL=n +CONFIG_OPENTHREAD_SHELL=n +CONFIG_BOOT_BANNER=n + +# Configure Zephyr logger with defaults backends disabled as the app provides its own, +# based on Pigweed HDLC. +CONFIG_LOG=y +CONFIG_LOG_MODE_MINIMAL=n +CONFIG_LOG_MODE_IMMEDIATE=y +CONFIG_LOG_BACKEND_UART=n +CONFIG_LOG_BACKEND_RTT=n +CONFIG_LOG_OUTPUT=y + +# Increase zephyr tty rx buffer +CONFIG_CONSOLE_GETCHAR_BUFSIZE=128 diff --git a/examples/lighting-app/telink/src/AppTask.cpp b/examples/lighting-app/telink/src/AppTask.cpp index 00db77cd01c89a..a90dc1f89a3156 100644 --- a/examples/lighting-app/telink/src/AppTask.cpp +++ b/examples/lighting-app/telink/src/AppTask.cpp @@ -30,7 +30,6 @@ #include #include #include -#include #include #include #include @@ -457,6 +456,30 @@ void AppTask::UpdateClusterState() } } +void AppTask::ButtonEventHandler(ButtonId_t btnId, bool btnPressed) +{ + if (!btnPressed) + { + return; + } + + switch (btnId) + { + case kButtonId_LightingAction: + LightingActionButtonEventHandler(); + break; + case kButtonId_FactoryReset: + FactoryResetButtonEventHandler(); + break; + case kButtonId_StartThread: + StartThreadButtonEventHandler(); + break; + case kButtonId_StartBleAdv: + StartBleAdvButtonEventHandler(); + break; + } +} + void AppTask::InitButtons(void) { sFactoryResetButton.Configure(BUTTON_PORT, BUTTON_PIN_3, BUTTON_PIN_1, FactoryResetButtonEventHandler); diff --git a/examples/lighting-app/telink/src/LightingManager.cpp b/examples/lighting-app/telink/src/LightingManager.cpp index 3aad922a3516af..1c0cea74bb5cce 100644 --- a/examples/lighting-app/telink/src/LightingManager.cpp +++ b/examples/lighting-app/telink/src/LightingManager.cpp @@ -132,5 +132,5 @@ void LightingManager::UpdateLight() const uint8_t maxEffectiveLevel = mMaxLevel - mMinLevel; const uint8_t effectiveLevel = mState == kState_On ? chip::min(mLevel - mMinLevel, maxEffectiveLevel) : 0; - pwm_pin_set_usec(mPwmDevice, mPwmChannel, kPwmWidthUs, kPwmWidthUs * effectiveLevel / maxEffectiveLevel, 0); + pwm_set(mPwmDevice, mPwmChannel, PWM_USEC(kPwmWidthUs), PWM_USEC(kPwmWidthUs * effectiveLevel / maxEffectiveLevel), 0); } diff --git a/examples/lighting-app/telink/src/main.cpp b/examples/lighting-app/telink/src/main.cpp index 4ea2a51acd6b2e..55e75804eec945 100644 --- a/examples/lighting-app/telink/src/main.cpp +++ b/examples/lighting-app/telink/src/main.cpp @@ -23,6 +23,10 @@ #include +#ifdef CONFIG_CHIP_PW_RPC +#include "Rpc.h" +#endif + LOG_MODULE_REGISTER(app); using namespace ::chip; @@ -33,6 +37,10 @@ int main(void) { CHIP_ERROR err = CHIP_NO_ERROR; +#ifdef CONFIG_CHIP_PW_RPC + rpc::Init(); +#endif + err = chip::Platform::MemoryInit(); if (err != CHIP_NO_ERROR) { diff --git a/examples/lock-app/cc32xx/main/AppTask.cpp b/examples/lock-app/cc32xx/main/AppTask.cpp index 79da0749349665..cff1e73bf8d0cf 100644 --- a/examples/lock-app/cc32xx/main/AppTask.cpp +++ b/examples/lock-app/cc32xx/main/AppTask.cpp @@ -21,7 +21,7 @@ #include "AppConfig.h" #include "AppEvent.h" #include -#include +#include #include #include @@ -263,7 +263,7 @@ void AppTask::ActionCompleted(BoltLockManager::Action_t aAction) LED_setOff(gLedRedHandle); state = 0; } - emberAfWriteAttribute(1, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, &state, ZCL_BOOLEAN_ATTRIBUTE_TYPE); + emberAfWriteAttribute(1, app::Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, &state, ZCL_BOOLEAN_ATTRIBUTE_TYPE); } void AppTask::DispatchEvent(AppEvent * aEvent) diff --git a/examples/lock-app/efr32/BUILD.gn b/examples/lock-app/efr32/BUILD.gn index 8e22a6add4864e..88983a2f058284 100644 --- a/examples/lock-app/efr32/BUILD.gn +++ b/examples/lock-app/efr32/BUILD.gn @@ -180,6 +180,7 @@ efr32_sdk("sdk") { efr32_executable("lock_app") { output_name = "chip-efr32-lock-example.out" + public_configs = [ "${efr32_sdk_build_root}:silabs_config" ] include_dirs = [ "include" ] defines = [] diff --git a/examples/lock-app/efr32/include/CHIPProjectConfig.h b/examples/lock-app/efr32/include/CHIPProjectConfig.h index 6e8342dc0f7a99..9793e98ac9bc0a 100644 --- a/examples/lock-app/efr32/include/CHIPProjectConfig.h +++ b/examples/lock-app/efr32/include/CHIPProjectConfig.h @@ -70,17 +70,6 @@ */ #define CHIP_DEVICE_CONFIG_DEVICE_HARDWARE_VERSION 1 -/** - * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING - * - * A string identifying the software version running on the device. - * CHIP service currently expects the software version to be in the format - * {MAJOR_VERSION}.0d{MINOR_VERSION} - */ -#ifndef CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING -#define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING "0.1ALPHA" -#endif - /** * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION * diff --git a/examples/lock-app/efr32/src/AppTask.cpp b/examples/lock-app/efr32/src/AppTask.cpp index 55003936dc515e..8cd16f2a5a52cd 100644 --- a/examples/lock-app/efr32/src/AppTask.cpp +++ b/examples/lock-app/efr32/src/AppTask.cpp @@ -40,7 +40,6 @@ #include #include #include -#include #include #include @@ -288,7 +287,7 @@ void AppTask::AppTaskMain(void * pvParameter) while (true) { - BaseType_t eventReceived = xQueueReceive(sAppEventQueue, &event, pdMS_TO_TICKS(10)); + BaseType_t eventReceived = xQueueReceive(sAppEventQueue, &event, portMAX_DELAY); while (eventReceived == pdTRUE) { sAppTask.DispatchEvent(&event); diff --git a/examples/lock-app/esp32/CMakeLists.txt b/examples/lock-app/esp32/CMakeLists.txt index 9cc498c3c6863a..24110deb8352c2 100644 --- a/examples/lock-app/esp32/CMakeLists.txt +++ b/examples/lock-app/esp32/CMakeLists.txt @@ -46,6 +46,10 @@ idf_build_set_property(COMPILE_OPTIONS "-Wno-error=maybe-uninitialized" APPEND) if (CONFIG_ENABLE_PW_RPC) get_filename_component(CHIP_ROOT ./third_party/connectedhomeip REALPATH) include(third_party/connectedhomeip/third_party/pigweed/repo/pw_build/pigweed.cmake) +include($ENV{PW_ROOT}/pw_assert/backend.cmake) +include($ENV{PW_ROOT}/pw_log/backend.cmake) +include($ENV{PW_ROOT}/pw_sys_io/backend.cmake) +include($ENV{PW_ROOT}/pw_trace/backend.cmake) pw_set_module_config(pw_rpc_CONFIG pw_rpc.disable_global_mutex_config) pw_set_backend(pw_log pw_log_basic) diff --git a/examples/lock-app/esp32/main/AppTask.cpp b/examples/lock-app/esp32/main/AppTask.cpp index bedaf75b6946e2..c7ebacf0f334f5 100644 --- a/examples/lock-app/esp32/main/AppTask.cpp +++ b/examples/lock-app/esp32/main/AppTask.cpp @@ -23,7 +23,7 @@ #include "esp_log.h" #include #include -#include +#include #include #include #include @@ -467,8 +467,8 @@ void AppTask::UpdateClusterState(chip::System::Layer *, void * context) uint8_t newValue = !BoltLockMgr().IsUnlocked(); // write the new on/off value - EmberAfStatus status = - emberAfWriteAttribute(1, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &newValue, ZCL_BOOLEAN_ATTRIBUTE_TYPE); + EmberAfStatus status = emberAfWriteAttribute(1, chip::app::Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &newValue, + ZCL_BOOLEAN_ATTRIBUTE_TYPE); if (status != EMBER_ZCL_STATUS_SUCCESS) { ESP_LOGI(TAG, "ERR: updating on/off %x", status); diff --git a/examples/lock-app/esp32/main/DeviceCallbacks.cpp b/examples/lock-app/esp32/main/DeviceCallbacks.cpp index a7e12754e7cb4d..7a073be32e1e53 100644 --- a/examples/lock-app/esp32/main/DeviceCallbacks.cpp +++ b/examples/lock-app/esp32/main/DeviceCallbacks.cpp @@ -28,7 +28,7 @@ #include "BoltLockManager.h" #include -#include +#include static const char * TAG = "lock-devicecallbacks"; @@ -45,7 +45,7 @@ void AppDeviceCallbacks::PostAttributeChangeCallback(EndpointId endpointId, Clus switch (clusterId) { - case ZCL_ON_OFF_CLUSTER_ID: + case app::Clusters::OnOff::Id: OnOnOffPostAttributeChangeCallback(endpointId, attributeId, value); break; diff --git a/examples/lock-app/genio/src/AppTask.cpp b/examples/lock-app/genio/src/AppTask.cpp index 6c3e284991a9f2..05455f579ad1d3 100644 --- a/examples/lock-app/genio/src/AppTask.cpp +++ b/examples/lock-app/genio/src/AppTask.cpp @@ -27,7 +27,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/lock-app/infineon/cyw30739/include/LockManager.h b/examples/lock-app/infineon/cyw30739/include/LockManager.h index 4bf738182d47b9..8f4cdf658d7375 100644 --- a/examples/lock-app/infineon/cyw30739/include/LockManager.h +++ b/examples/lock-app/infineon/cyw30739/include/LockManager.h @@ -119,6 +119,7 @@ class LockManager { LOCK_ACTION = 0, UNLOCK_ACTION, + LOCK_JAMMED, INVALID_ACTION } Action; diff --git a/examples/lock-app/infineon/cyw30739/src/ButtonHandler.cpp b/examples/lock-app/infineon/cyw30739/src/ButtonHandler.cpp index 51279a8c80c104..40233323890c96 100644 --- a/examples/lock-app/infineon/cyw30739/src/ButtonHandler.cpp +++ b/examples/lock-app/infineon/cyw30739/src/ButtonHandler.cpp @@ -56,14 +56,14 @@ wiced_result_t app_button_init(void) memset(app_buttons, 0, (sizeof(button_manager_button_t) * APP_MAX_BUTTON_DEF)); app_button_configurations[ON_OFF_BUTTON].button = PLATFORM_BUTTON_1; - app_button_configurations[ON_OFF_BUTTON].button_event_mask = BUTTON_CLICK_EVENT; + app_button_configurations[ON_OFF_BUTTON].button_event_mask = (BUTTON_CLICK_EVENT | BUTTON_LONG_DURATION_EVENT); app_buttons[ON_OFF_BUTTON].configuration = &app_button_configurations[ON_OFF_BUTTON]; result = wiced_button_manager_init(&app_button_manager, &app_button_manager_configuration, app_buttons, 1); if (result != WICED_SUCCESS) { - printf("button_manager_init failed (%d)\n", result); + ChipLogProgress(Zcl, "button_manager_init failed (%d)\n", result); } return result; } @@ -71,33 +71,38 @@ wiced_result_t app_button_init(void) void app_button_event_handler(const button_manager_button_t * button_mgr, button_manager_event_t event, button_manager_button_state_t state) { - // printf("app_button_event_handler. button=%d, event=%d, state=%d\n", button_mgr[ON_OFF_BUTTON].configuration->button, event, - // state); bool initiated = false; LockManager::Action_t action; - CHIP_ERROR err = CHIP_NO_ERROR; - if (button_mgr[0].configuration->button == PLATFORM_BUTTON_1 && event == BUTTON_CLICK_EVENT && state == BUTTON_STATE_RELEASED) + + ChipLogProgress(Zcl, "app_button_event_handler. button=%d, event=%d, state=%d\n", + button_mgr[ON_OFF_BUTTON].configuration->button, event, state); + + /* This app is interested in PLATFORM_BUTTON_1 only */ + if (button_mgr[0].configuration->button != PLATFORM_BUTTON_1) + return; + + /* This callback is invoked both for held and released state, we want to process on the released event to avoid duplication */ + if (state != BUTTON_STATE_RELEASED) + return; + + /* single click to Lock/Unlock + long press to generate Jammed event */ + if (event == BUTTON_CLICK_EVENT) { - if (LockMgr().NextState() == true) - { - action = LockManager::LOCK_ACTION; - } - else - { - action = LockManager::UNLOCK_ACTION; - } + action = (LockMgr().NextState() == true) ? LockManager::LOCK_ACTION : LockManager::UNLOCK_ACTION; } - else + else if (event == BUTTON_LONG_DURATION_EVENT) { - err = CHIP_ERROR_UNEXPECTED_EVENT; + action = LockManager::LOCK_JAMMED; } - if (err == CHIP_NO_ERROR) + else { - initiated = LockMgr().InitiateAction(AppEvent::kEventType_Button, action); + return; + } - if (!initiated) - { - printf("Action is already in progress or active."); - } + initiated = LockMgr().InitiateAction(AppEvent::kEventType_Button, action); + if (!initiated) + { + ChipLogProgress(Zcl, "Action is already in progress or active."); } } diff --git a/examples/lock-app/infineon/cyw30739/src/LockManager.cpp b/examples/lock-app/infineon/cyw30739/src/LockManager.cpp index d434e94924c3a4..598e454f2e4d1a 100644 --- a/examples/lock-app/infineon/cyw30739/src/LockManager.cpp +++ b/examples/lock-app/infineon/cyw30739/src/LockManager.cpp @@ -181,6 +181,15 @@ bool LockManager::InitiateAction(int32_t aActor, Action_t aAction) bool action_initiated = false; State_t new_state; + if (aAction == LOCK_JAMMED) + { + ChipLogProgress(Zcl, "Sending a lock jammed event"); + + /* Generating Door Lock Jammed event */ + DoorLockServer::Instance().SendLockAlarmEvent(1, DlAlarmCode::kLockJammed); + return true; + } + // Initiate Lock/Unlock Action only when the previous one is complete. if (mState == kState_LockCompleted && aAction == UNLOCK_ACTION) { @@ -197,7 +206,6 @@ bool LockManager::InitiateAction(int32_t aActor, Action_t aAction) if (action_initiated) { - StartTimer(ACTUATOR_MOVEMENT_PERIOS_MS); // Since the timer started successfully, update the state and trigger callback diff --git a/examples/lock-app/infineon/psoc6/include/AppConfig.h b/examples/lock-app/infineon/psoc6/include/AppConfig.h index f20ca007a5a3fc..41ff70e1f94b71 100644 --- a/examples/lock-app/infineon/psoc6/include/AppConfig.h +++ b/examples/lock-app/infineon/psoc6/include/AppConfig.h @@ -31,10 +31,11 @@ #define APP_LOCK_BUTTON CYBSP_USER_BTN1 #define APP_FUNCTION_BUTTON CYBSP_USER_BTN2 -#define APP_BUTTON_MIN_ASSERT_TIME_MS 30 +#define APP_BUTTON_MIN_ASSERT_TIME_MS 500 #define APP_BUTTON_PRESSED 0 #define APP_BUTTON_RELEASED 1 +#define APP_BUTTON_LONG_PRESS 2 #define SYSTEM_STATE_LED CYBSP_USER_LED1 #define LOCK_STATE_LED CYBSP_USER_LED2 diff --git a/examples/lock-app/infineon/psoc6/include/ButtonHandler.h b/examples/lock-app/infineon/psoc6/include/ButtonHandler.h index 3820e162780640..db2f94feb3fc35 100644 --- a/examples/lock-app/infineon/psoc6/include/ButtonHandler.h +++ b/examples/lock-app/infineon/psoc6/include/ButtonHandler.h @@ -33,7 +33,7 @@ class ButtonHandler private: static void GpioInit(void); - static void lock_button_callback(void * handler_arg, cyhal_gpio_event_t event); - static void func_button_callback(void * handler_arg, cyhal_gpio_event_t event); + static void LockButtonCallback(void * handler_arg, cyhal_gpio_event_t event); + static void FuncButtonCallback(void * handler_arg, cyhal_gpio_event_t event); static void TimerCallback(TimerHandle_t xTimer); }; diff --git a/examples/lock-app/infineon/psoc6/include/CHIPProjectConfig.h b/examples/lock-app/infineon/psoc6/include/CHIPProjectConfig.h index f24b7b73241926..b069e13284c07d 100644 --- a/examples/lock-app/infineon/psoc6/include/CHIPProjectConfig.h +++ b/examples/lock-app/infineon/psoc6/include/CHIPProjectConfig.h @@ -89,6 +89,14 @@ */ #define CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE 1 +/** + * CHIP_DEVICE_CONFIG_ENABLE_CHIP_TIME_SERVICE_TIME_SYNC + * + * Enables synchronizing the device's real time clock with a remote Chip Time service + * using the Chip Time Sync protocol. + */ +#define CHIP_DEVICE_CONFIG_ENABLE_CHIP_TIME_SERVICE_TIME_SYNC 0 + /** * CHIP_DEVICE_CONFIG_TEST_SERIAL_NUMBER * diff --git a/examples/lock-app/infineon/psoc6/src/AppTask.cpp b/examples/lock-app/infineon/psoc6/src/AppTask.cpp index d9d46398ee8afa..a06f1ca687dca0 100644 --- a/examples/lock-app/infineon/psoc6/src/AppTask.cpp +++ b/examples/lock-app/infineon/psoc6/src/AppTask.cpp @@ -25,7 +25,6 @@ #include #include #include -#include #include #include @@ -400,16 +399,31 @@ void AppTask::LockActionEventHandler(AppEvent * event) } case AppEvent::kEventType_Button: { - if (LockMgr().NextState() == true) + + P6_LOG("%s [Action: %d]", __FUNCTION__, event->ButtonEvent.Action); + + if (event->ButtonEvent.Action == APP_BUTTON_LONG_PRESS) { - action = LockManager::LOCK_ACTION; + P6_LOG("Sending a lock jammed event"); + + /* Generating Door Lock Jammed event */ + DoorLockServer::Instance().SendLockAlarmEvent(1 /* Endpoint Id */, DlAlarmCode::kLockJammed); + + return; } else { - action = LockManager::UNLOCK_ACTION; - } + if (LockMgr().NextState() == true) + { + action = LockManager::LOCK_ACTION; + } + else + { + action = LockManager::UNLOCK_ACTION; + } - actor = AppEvent::kEventType_Button; + actor = AppEvent::kEventType_Button; + } break; } diff --git a/examples/lock-app/infineon/psoc6/src/ButtonHandler.cpp b/examples/lock-app/infineon/psoc6/src/ButtonHandler.cpp index 2eea4c760a20f9..84aaac16ae3d41 100644 --- a/examples/lock-app/infineon/psoc6/src/ButtonHandler.cpp +++ b/examples/lock-app/infineon/psoc6/src/ButtonHandler.cpp @@ -32,6 +32,7 @@ TimerHandle_t buttonTimers[kButtonCount]; // FreeRTOS timers used for debouncing void ButtonHandler::Init(void) { GpioInit(); + // Create FreeRTOS sw timers for debouncing buttons. for (uint8_t i = 0; i < kButtonCount; i++) { @@ -48,36 +49,42 @@ void ButtonHandler::Init(void) void ButtonHandler::GpioInit(void) { cy_rslt_t result = CY_RSLT_SUCCESS; + static cyhal_gpio_callback_data_t lockButtonCbData; + static cyhal_gpio_callback_data_t funcButtonCbData; + // Set up button GPIOs to input with pullups. result = cyhal_gpio_init(APP_LOCK_BUTTON, CYHAL_GPIO_DIR_INPUT, CYHAL_GPIO_DRIVE_PULLUP, CYBSP_BTN_OFF); if (result != CY_RSLT_SUCCESS) { printf(" cyhal_gpio_init failed for APP_LOCK_BUTTON\r\n"); } + result = cyhal_gpio_init(APP_FUNCTION_BUTTON, CYHAL_GPIO_DIR_INPUT, CYHAL_GPIO_DRIVE_PULLUP, CYBSP_BTN_OFF); if (result != CY_RSLT_SUCCESS) { printf(" cyhal_gpio_init failed for APP_FUNCTION_BUTTON\r\n"); } + /* Configure GPIO interrupt. */ - static cyhal_gpio_callback_data_t lock_button_cbdata; - static cyhal_gpio_callback_data_t func_button_cbdata; - lock_button_cbdata.callback = lock_button_callback; - lock_button_cbdata.callback_arg = NULL; - cyhal_gpio_register_callback(APP_LOCK_BUTTON, &lock_button_cbdata); - func_button_cbdata.callback = func_button_callback; - func_button_cbdata.callback_arg = NULL; - cyhal_gpio_register_callback(APP_FUNCTION_BUTTON, &func_button_cbdata); + lockButtonCbData.callback = LockButtonCallback; + lockButtonCbData.callback_arg = NULL; + cyhal_gpio_register_callback(APP_LOCK_BUTTON, &lockButtonCbData); + + funcButtonCbData.callback = FuncButtonCallback; + funcButtonCbData.callback_arg = NULL; + cyhal_gpio_register_callback(APP_FUNCTION_BUTTON, &funcButtonCbData); + cyhal_gpio_enable_event(APP_LOCK_BUTTON, CYHAL_GPIO_IRQ_FALL, GPIO_INTERRUPT_PRIORITY, true); cyhal_gpio_enable_event(APP_FUNCTION_BUTTON, CYHAL_GPIO_IRQ_FALL, GPIO_INTERRUPT_PRIORITY, true); } -void ButtonHandler::lock_button_callback(void * handler_arg, cyhal_gpio_event_t event) + +void ButtonHandler::LockButtonCallback(void * handler_arg, cyhal_gpio_event_t event) { portBASE_TYPE taskWoken = pdFALSE; xTimerStartFromISR(buttonTimers[APP_LOCK_BUTTON_IDX], &taskWoken); } -void ButtonHandler::func_button_callback(void * handler_arg, cyhal_gpio_event_t event) +void ButtonHandler::FuncButtonCallback(void * handler_arg, cyhal_gpio_event_t event) { portBASE_TYPE taskWoken = pdFALSE; xTimerStartFromISR(buttonTimers[APP_FUNCTION_BUTTON_IDX], &taskWoken); @@ -85,21 +92,29 @@ void ButtonHandler::func_button_callback(void * handler_arg, cyhal_gpio_event_t void ButtonHandler::TimerCallback(TimerHandle_t xTimer) { - // Get the button index of the expired timer and call button event helper. - uint32_t timerId; - uint8_t buttonevent; + uint32_t timerId = 0; + uint8_t buttonevent = 0; + + /* Get the button index of the expired timer and call button event helper. */ timerId = (uint32_t) pvTimerGetTimerID(xTimer); if (timerId) { buttonevent = cyhal_gpio_read(APP_FUNCTION_BUTTON); + if (buttonevent) + { + GetAppTask().ButtonEventHandler(timerId, APP_BUTTON_PRESSED); + } } else { buttonevent = cyhal_gpio_read(APP_LOCK_BUTTON); - } - - if (!buttonevent) - { - GetAppTask().ButtonEventHandler(timerId, APP_BUTTON_PRESSED); + if (!buttonevent) + { + GetAppTask().ButtonEventHandler(timerId, APP_BUTTON_LONG_PRESS); + } + else + { + GetAppTask().ButtonEventHandler(timerId, APP_BUTTON_PRESSED); + } } } diff --git a/examples/lock-app/linux/args.gni b/examples/lock-app/linux/args.gni index 311ddab32d5fe5..703c3576d66c19 100644 --- a/examples/lock-app/linux/args.gni +++ b/examples/lock-app/linux/args.gni @@ -15,3 +15,11 @@ import("//build_overrides/chip.gni") import("${chip_root}/config/standalone/args.gni") + +chip_device_project_config_include = "" +chip_project_config_include = "" +chip_system_project_config_include = "" + +chip_project_config_include_dirs = + [ "${chip_root}/examples/all-clusters-app/linux/include" ] +chip_project_config_include_dirs += [ "${chip_root}/config/standalone" ] diff --git a/examples/lock-app/linux/include/CHIPProjectAppConfig.h b/examples/lock-app/linux/include/CHIPProjectAppConfig.h new file mode 100644 index 00000000000000..b6c15f4c98230e --- /dev/null +++ b/examples/lock-app/linux/include/CHIPProjectAppConfig.h @@ -0,0 +1,34 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Example project configuration file for CHIP. + * + * This is a place to put application or project-specific overrides + * to the default configuration values for general CHIP features. + * + */ + +#pragma once + +// include the CHIPProjectConfig from config/standalone +#include + +// Allows app options (ports) to be configured on launch of app +#define CHIP_DEVICE_ENABLE_PORT_PARAMS 1 diff --git a/examples/lock-app/lock-common/lock-app.matter b/examples/lock-app/lock-common/lock-app.matter index f04c84443ffdf5..dd2071ec6d6f25 100644 --- a/examples/lock-app/lock-common/lock-app.matter +++ b/examples/lock-app/lock-common/lock-app.matter @@ -1868,7 +1868,7 @@ server cluster DoorLock = 257 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Descriptor { @@ -2147,7 +2147,7 @@ endpoint 0 { } } endpoint 1 { - device type doorlock = 10; + device type doorlock = 10, version 1; server cluster Identify { ram attribute identifyTime; diff --git a/examples/lock-app/mbed/main/AppTask.cpp b/examples/lock-app/mbed/main/AppTask.cpp index d9fc7e6dab8a13..8e2b98dac5b3f2 100644 --- a/examples/lock-app/mbed/main/AppTask.cpp +++ b/examples/lock-app/mbed/main/AppTask.cpp @@ -35,7 +35,7 @@ // ZAP -- ZCL Advanced Platform #include #include -#include +#include #include #ifdef CAPSENSE_ENABLED @@ -463,7 +463,7 @@ void AppTask::UpdateClusterState() // write the new on/off value EmberAfStatus status = - emberAfWriteAttribute(1, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, &newValue, ZCL_BOOLEAN_ATTRIBUTE_TYPE); + emberAfWriteAttribute(1, app::Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, &newValue, ZCL_BOOLEAN_ATTRIBUTE_TYPE); if (status != EMBER_ZCL_STATUS_SUCCESS) { ChipLogError(NotSpecified, "ZCL update failed: %lx", status); diff --git a/examples/lock-app/nrfconnect/main/AppTask.cpp b/examples/lock-app/nrfconnect/main/AppTask.cpp index 4f5c18d869a73e..f767e5d52c6615 100644 --- a/examples/lock-app/nrfconnect/main/AppTask.cpp +++ b/examples/lock-app/nrfconnect/main/AppTask.cpp @@ -26,7 +26,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/lock-app/nxp/k32w/k32w0/main/AppTask.cpp b/examples/lock-app/nxp/k32w/k32w0/main/AppTask.cpp index cb78aef83ee0cd..deba6a5c63772d 100644 --- a/examples/lock-app/nxp/k32w/k32w0/main/AppTask.cpp +++ b/examples/lock-app/nxp/k32w/k32w0/main/AppTask.cpp @@ -32,7 +32,7 @@ #include #include -#include +#include #include #include "Keyboard.h" @@ -763,8 +763,8 @@ void AppTask::UpdateClusterStateInternal(intptr_t arg) uint8_t newValue = !BoltLockMgr().IsUnlocked(); // write the new on/off value - EmberAfStatus status = - emberAfWriteAttribute(1, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &newValue, ZCL_BOOLEAN_ATTRIBUTE_TYPE); + EmberAfStatus status = emberAfWriteAttribute(1, chip::app::Clusters::OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, (uint8_t *) &newValue, + ZCL_BOOLEAN_ATTRIBUTE_TYPE); if (status != EMBER_ZCL_STATUS_SUCCESS) { ChipLogError(NotSpecified, "ERR: updating on/off %x", status); diff --git a/examples/lock-app/openiotsdk/.gitignore b/examples/lock-app/openiotsdk/.gitignore new file mode 100644 index 00000000000000..567609b1234a9b --- /dev/null +++ b/examples/lock-app/openiotsdk/.gitignore @@ -0,0 +1 @@ +build/ diff --git a/examples/lock-app/openiotsdk/CMakeLists.txt b/examples/lock-app/openiotsdk/CMakeLists.txt new file mode 100644 index 00000000000000..67308591faa7a0 --- /dev/null +++ b/examples/lock-app/openiotsdk/CMakeLists.txt @@ -0,0 +1,85 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +cmake_minimum_required(VERSION 3.21) + +get_filename_component(CHIP_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/../../.. REALPATH) +get_filename_component(OPEN_IOT_SDK_CONFIG ${CHIP_ROOT}/config/openiotsdk REALPATH) +get_filename_component(OPEN_IOT_SDK_EXAMPLE_COMMON ${CHIP_ROOT}/examples/platform/openiotsdk REALPATH) +get_filename_component(GEN_DIR ${CHIP_ROOT}/zzz_generated/ REALPATH) + +list(APPEND CMAKE_MODULE_PATH ${OPEN_IOT_SDK_CONFIG}/cmake) + +set(APP_TARGET chip-openiotsdk-lock-app-example) + +# Toolchain files need to exist before first call to project +include(toolchain) + +project(${APP_TARGET} LANGUAGES C CXX ASM) + +include(sdk) + +# LwIP configuration +if(TARGET lwip-cmsis-port) + # lwip requires user_lwipopts.h, we use the custom settings + target_include_directories(lwipopts + INTERFACE + ${OPEN_IOT_SDK_CONFIG}/lwip + ) + + if (${CMAKE_BUILD_TYPE} STREQUAL "Debug") + target_compile_definitions(lwipopts + INTERFACE + LWIP_DEBUG + ) + endif() +endif() + +add_executable(${APP_TARGET}) + +# Application CHIP build configuration +include(chip) + +add_subdirectory(${OPEN_IOT_SDK_EXAMPLE_COMMON}/app ./app_build) + +target_include_directories(${APP_TARGET} + PRIVATE + main/include + ${GEN_DIR}/app-common + ${GEN_DIR}/lock-app +) + +target_sources(${APP_TARGET} + PRIVATE + main/main.cpp + main/ZclCallbacks.cpp + main/LockManager.cpp + main/LockEndpoint.cpp + ${GEN_DIR}/lock-app/zap-generated/IMClusterCommandHandler.cpp +) + +target_link_libraries(${APP_TARGET} + openiotsdk-app +) + +include(${CHIP_ROOT}/src/app/chip_data_model.cmake) +chip_configure_data_model(${APP_TARGET} + INCLUDE_SERVER + ZAP_FILE ${CMAKE_CURRENT_SOURCE_DIR}/../lock-common/lock-app.zap +) + +include(linker) +set_target_link(${APP_TARGET}) diff --git a/examples/lock-app/openiotsdk/README.md b/examples/lock-app/openiotsdk/README.md new file mode 100644 index 00000000000000..4ff38ecc3a1445 --- /dev/null +++ b/examples/lock-app/openiotsdk/README.md @@ -0,0 +1,54 @@ +# Matter Open IoT SDK Lock-App Example Application + +The Open IoT SDK Lock Example demonstrates how to remotely control a door lock a +device with one basic bolt. + +The example behaves as a Matter accessory, device that can be paired into an +existing Matter network and can be controlled by it. + +## Build and run + +For information on how to build and run this example and further information +about the platform it is run on see +[Open IoT SDK examples](../../../docs/examples/openiotsdk_examples.md). + +The example name to use in the scripts is `lock-app`. + +## Using the example + +Communication with the application goes through the active telnet session. When +the application runs these lines should be visible: + +``` +[INF] [-] Open IoT SDK lock-app example application start +... +[INF] [-] Open IoT SDK lock-app example application run +``` + +The lock-app application launched correctly and you can follow traces in the +terminal. + +### Commissioning + +Read the +[Open IoT SDK commissioning guide](../../../docs/guides/openiotsdk_commissioning.md) +to see how to use the Matter controller to commission and control the +application. + +### DoorLock cluster usage + +The application fully supports the DoorLock cluster. Use its commands to trigger +actions on the device. You can issue commands through the same Matter controller +you used to perform the commissioning step above. + +Example command: + +``` +zcl DoorLock LockDoor 1234 1 pinCode=str:12345 +``` + +In response the device will output this line to the terminal: + +``` +[INF] [ZC] Lock App: specified PIN code was found in the database, setting door lock state to "Locked" [endpointId=1] +``` diff --git a/examples/lock-app/openiotsdk/cmsis-config/RTE_Components.h b/examples/lock-app/openiotsdk/cmsis-config/RTE_Components.h new file mode 100644 index 00000000000000..3921500daecafb --- /dev/null +++ b/examples/lock-app/openiotsdk/cmsis-config/RTE_Components.h @@ -0,0 +1,24 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef RTE_COMPONENTS_H +#define RTE_COMPONENTS_H + +#define OS_STACK_SIZE (4 * 1024) + +#endif // RTE_COMPONENTS_H diff --git a/examples/lock-app/openiotsdk/freertos-config/FreeRTOSConfig.h b/examples/lock-app/openiotsdk/freertos-config/FreeRTOSConfig.h new file mode 100644 index 00000000000000..c95af61db3c84d --- /dev/null +++ b/examples/lock-app/openiotsdk/freertos-config/FreeRTOSConfig.h @@ -0,0 +1,257 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef FREERTOS_CONFIG_H +#define FREERTOS_CONFIG_H + +/*----------------------------------------------------------- + * Application specific definitions. + * + * These definitions should be adjusted for your particular hardware and + * application requirements. + * + * THESE PARAMETERS ARE DESCRIBED WITHIN THE 'CONFIGURATION' SECTION OF THE + * FreeRTOS API DOCUMENTATION AVAILABLE ON THE FreeRTOS.org WEB SITE. + * + * See http://www.freertos.org/a00110.html + *----------------------------------------------------------*/ + +#if (defined(__ARMCC_VERSION) || defined(__GNUC__) || defined(__ICCARM__)) +#include + +extern uint32_t SystemCoreClock; +#endif + +// Minimal stack size [words] <0-65535> +// Stack for idle task and default task stack in words. +// Default: 4kB +#define configMINIMAL_STACK_SIZE ((uint16_t)(4 * 1024)) + +// Total heap size [bytes] <0-0xFFFFFFFF> +// Heap memory size in bytes. +// Default: 32kB +#define configTOTAL_HEAP_SIZE ((size_t)(32 * 1024)) + +// Kernel tick frequency [Hz] <0-0xFFFFFFFF> +// Kernel tick rate in Hz. +// Default: 1000 +#define configTICK_RATE_HZ ((TickType_t) 1000) + +// Timer task stack depth [words] <0-65535> +// Stack for timer task in words. +// Default: 80 +#define configTIMER_TASK_STACK_DEPTH configMINIMAL_STACK_SIZE + +// Timer task priority <0-56> +// Timer task priority. +// Default: 40 (High) +#define configTIMER_TASK_PRIORITY 40 + +// Timer queue length <0-1024> +// Timer command queue length. +// Default: 5 +#define configTIMER_QUEUE_LENGTH 5 + +// Preemption interrupt priority +// Maximum priority of interrupts that are safe to call FreeRTOS API. +// Default: 16 +#define configMAX_SYSCALL_INTERRUPT_PRIORITY (5 << (8 - configPRIO_BITS)) + +// Use time slicing +// Enable setting to use timeslicing. +// Default: 1 +#define configUSE_TIME_SLICING 1 + +// Idle should yield +// Control Yield behaviour of the idle task. +// Default: 1 +#define configIDLE_SHOULD_YIELD 1 + +// Check for stack overflow +// <0=>Disable <1=>Method one <2=>Method two +// Enable or disable stack overflow checking. +// Callback function vApplicationStackOverflowHook implementation is required when stack checking is enabled. +// Default: 0 +#define configCHECK_FOR_STACK_OVERFLOW 2 + +// Use idle hook +// Enable callback function call on each idle task iteration. +// Callback function vApplicationIdleHook implementation is required when idle hook is enabled. +// Default: 0 +#define configUSE_IDLE_HOOK 0 + +// Use tick hook +// Enable callback function call during each tick interrupt. +// Callback function vApplicationTickHook implementation is required when tick hook is enabled. +// Default: 0 +#define configUSE_TICK_HOOK 0 + +// Use deamon task startup hook +// Enable callback function call when timer service starts. +// Callback function vApplicationDaemonTaskStartupHook implementation is required when deamon task startup hook is +// enabled. Default: 0 +#define configUSE_DAEMON_TASK_STARTUP_HOOK 0 + +// Use malloc failed hook +// Enable callback function call when out of dynamic memory. +// Callback function vApplicationMallocFailedHook implementation is required when malloc failed hook is enabled. +// Default: 0 +#define configUSE_MALLOC_FAILED_HOOK 0 + +// Queue registry size +// Define maximum number of queue objects registered for debug purposes. +// The queue registry is used by kernel aware debuggers to locate queue and semaphore structures and display +// associated text names. Default: 0 +#define configQUEUE_REGISTRY_SIZE 0 + +// Event Recorder configuration +// Initialize and setup Event Recorder level filtering. +// Settings have no effect when Event Recorder is not present. + +// Initialize Event Recorder +// Initialize Event Recorder before FreeRTOS kernel start. +// Default: 1 +#define configEVR_INITIALIZE 1 + +// Setup recording level filter +// Enable configuration of FreeRTOS events recording level +// Default: 1 +#define configEVR_SETUP_LEVEL 1 + +// Tasks functions +// Define event recording level bitmask for events generated from Tasks functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_TASKS 0x05 + +// Queue functions +// Define event recording level bitmask for events generated from Queue functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_QUEUE 0x05 + +// Timer functions +// Define event recording level bitmask for events generated from Timer functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_TIMERS 0x05 + +// Event Groups functions +// Define event recording level bitmask for events generated from Event Groups functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_EVENTGROUPS 0x05 + +// Heap functions +// Define event recording level bitmask for events generated from Heap functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_HEAP 0x05 + +// Stream Buffer functions +// Define event recording level bitmask for events generated from Stream Buffer functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_STREAMBUFFER 0x05 +// +// + +// Port Specific Features +// Enable and configure port specific features. +// Check FreeRTOS documentation for definitions that apply for the used port. + +// Use Floating Point Unit +// Using Floating Point Unit (FPU) affects context handling. +// Enable FPU when application uses floating point operations. +// Default: 1 +#define configENABLE_FPU 1 + +// Use Memory Protection Unit +// Using Memory Protection Unit (MPU) requires detailed memory map definition. +// This setting is only releavant for MPU enabled ports. +// Default: 0 +#define configENABLE_MPU 0 + +// Use TrustZone Secure Side Only +// This settings prevents FreeRTOS contex switch to Non-Secure side. +// Enable this setting when FreeRTOS runs on the Secure side only. +#define configRUN_FREERTOS_SECURE_ONLY 1 + +// Use TrustZone Security Extension +// Using TrustZone affects context handling. +// Enable TrustZone when FreeRTOS runs on the Non-Secure side and calls functions from the Secure side. +// Default: 1 +#define configENABLE_TRUSTZONE 0 + +// Minimal secure stack size [words] <0-65535> +// Stack for idle task Secure side context in words. +// This setting is only relevant when TrustZone extension is enabled. +// Default: 128 +#define configMINIMAL_SECURE_STACK_SIZE ((uint32_t) 128) +// + +#ifdef __NVIC_PRIO_BITS +#define configPRIO_BITS __NVIC_PRIO_BITS +#else +#define configPRIO_BITS 4 +#endif + +//------------- <<< end of configuration section >>> --------------------------- + +/* Defines needed by FreeRTOS to implement CMSIS RTOS2 API. Do not change! */ +#define configCPU_CLOCK_HZ (SystemCoreClock) +#define configSUPPORT_STATIC_ALLOCATION 1 +#define configSUPPORT_DYNAMIC_ALLOCATION 1 +#define configUSE_PREEMPTION 1 +#define configUSE_TIMERS 1 +#define configUSE_MUTEXES 1 +#define configUSE_RECURSIVE_MUTEXES 1 +#define configUSE_COUNTING_SEMAPHORES 1 +#define configUSE_TASK_NOTIFICATIONS 1 +#define configUSE_TRACE_FACILITY 1 +#define configUSE_16_BIT_TICKS 0 +#define configUSE_PORT_OPTIMISED_TASK_SELECTION 0 +#define configMAX_PRIORITIES 56 +#define configKERNEL_INTERRUPT_PRIORITY (0x07 << (8 - configPRIO_BITS)) + +/* Defines that include FreeRTOS functions which implement CMSIS RTOS2 API. Do not change! */ +#define INCLUDE_xEventGroupSetBitsFromISR 1 +#define INCLUDE_xSemaphoreGetMutexHolder 1 +#define INCLUDE_vTaskDelay 1 +#define INCLUDE_xTaskDelayUntil 1 +#define INCLUDE_vTaskDelete 1 +#define INCLUDE_xTaskGetCurrentTaskHandle 1 +#define INCLUDE_xTaskGetSchedulerState 1 +#define INCLUDE_uxTaskGetStackHighWaterMark 1 +#define INCLUDE_uxTaskPriorityGet 1 +#define INCLUDE_vTaskPrioritySet 1 +#define INCLUDE_eTaskGetState 1 +#define INCLUDE_vTaskSuspend 1 +#define INCLUDE_xTimerPendFunctionCall 1 + +/* Map the FreeRTOS port interrupt handlers to their CMSIS standard names. */ +#define xPortPendSVHandler PendSV_Handler +#define vPortSVCHandler SVC_Handler + +/* Ensure Cortex-M port compatibility. */ +#define SysTick_Handler xPortSysTickHandler + +#include "RTE_Components.h" +#include CMSIS_device_header + +#endif /* FREERTOS_CONFIG_H */ diff --git a/examples/lock-app/openiotsdk/main/LockEndpoint.cpp b/examples/lock-app/openiotsdk/main/LockEndpoint.cpp new file mode 100644 index 00000000000000..82e91a53aceb23 --- /dev/null +++ b/examples/lock-app/openiotsdk/main/LockEndpoint.cpp @@ -0,0 +1,348 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include "LockEndpoint.h" +#include + +using chip::to_underlying; + +bool LockEndpoint::Lock(const Optional & pin, DlOperationError & err) +{ + return setLockState(DlLockState::kLocked, pin, err); +} + +bool LockEndpoint::Unlock(const Optional & pin, DlOperationError & err) +{ + return setLockState(DlLockState::kUnlocked, pin, err); +} + +bool LockEndpoint::GetUser(uint16_t userIndex, EmberAfPluginDoorLockUserInfo & user) const +{ + ChipLogDetail(Zcl, "Lock App: LockEndpoint::GetUser [endpoint=%d,userIndex=%hu]", mEndpointId, userIndex); + + auto adjustedUserIndex = static_cast(userIndex - 1); + if (adjustedUserIndex > mLockUsers.size()) + { + ChipLogError(Zcl, "Cannot get user - index out of range [endpoint=%d,index=%hu,adjustedIndex=%d]", mEndpointId, userIndex, + adjustedUserIndex); + return false; + } + + const auto & userInDb = mLockUsers[adjustedUserIndex]; + user.userStatus = userInDb.userStatus; + if (DlUserStatus::kAvailable == user.userStatus) + { + ChipLogDetail(Zcl, "Found unoccupied user [endpoint=%d,adjustedIndex=%hu]", mEndpointId, adjustedUserIndex); + return true; + } + + user.userName = chip::CharSpan(userInDb.userName, strlen(userInDb.userName)); + user.credentials = chip::Span(userInDb.credentials.data(), userInDb.credentials.size()); + user.userUniqueId = userInDb.userUniqueId; + user.userType = userInDb.userType; + user.credentialRule = userInDb.credentialRule; + user.createdBy = userInDb.createdBy; + user.lastModifiedBy = userInDb.lastModifiedBy; + + ChipLogDetail(Zcl, + "Found occupied user " + "[endpoint=%d,adjustedIndex=%hu,name=\"%.*s\",credentialsCount=%u,uniqueId=%x,type=%u,credentialRule=%u," + "createdBy=%d,lastModifiedBy=%d]", + mEndpointId, adjustedUserIndex, static_cast(user.userName.size()), user.userName.data(), + static_cast(user.credentials.size()), user.userUniqueId, to_underlying(user.userType), + to_underlying(user.credentialRule), user.createdBy, user.lastModifiedBy); + + return true; +} + +bool LockEndpoint::SetUser(uint16_t userIndex, chip::FabricIndex creator, chip::FabricIndex modifier, + const chip::CharSpan & userName, uint32_t uniqueId, DlUserStatus userStatus, DlUserType usertype, + DlCredentialRule credentialRule, const DlCredential * credentials, size_t totalCredentials) +{ + ChipLogProgress(Zcl, + "SetUser " + "[endpoint=%d,userIndex=%u,creator=%d,modifier=%d,userName=\"%.*s\",uniqueId=%" PRIx32 + ",userStatus=%u,userType=%u," + "credentialRule=%u,credentials=%p,totalCredentials=%u]", + mEndpointId, userIndex, creator, modifier, static_cast(userName.size()), userName.data(), uniqueId, + to_underlying(userStatus), to_underlying(usertype), to_underlying(credentialRule), credentials, + static_cast(totalCredentials)); + + auto adjustedUserIndex = static_cast(userIndex - 1); + if (adjustedUserIndex > mLockUsers.size()) + { + ChipLogError(Zcl, "Cannot set user - index out of range [endpoint=%d,index=%d,adjustedUserIndex=%u]", mEndpointId, + userIndex, adjustedUserIndex); + return false; + } + + auto & userInStorage = mLockUsers[adjustedUserIndex]; + if (userName.size() > DOOR_LOCK_MAX_USER_NAME_SIZE) + { + ChipLogError(Zcl, "Cannot set user - user name is too long [endpoint=%d,index=%d,adjustedUserIndex=%u]", mEndpointId, + userIndex, adjustedUserIndex); + return false; + } + + if (totalCredentials > userInStorage.credentials.capacity()) + { + ChipLogError(Zcl, + "Cannot set user - total number of credentials is too big [endpoint=%d,index=%d,adjustedUserIndex=%u" + ",totalCredentials=%u,maxNumberOfCredentials=%u]", + mEndpointId, userIndex, adjustedUserIndex, static_cast(totalCredentials), + static_cast(userInStorage.credentials.capacity())); + return false; + } + + chip::Platform::CopyString(userInStorage.userName, userName); + userInStorage.userName[userName.size()] = 0; + userInStorage.userUniqueId = uniqueId; + userInStorage.userStatus = userStatus; + userInStorage.userType = usertype; + userInStorage.credentialRule = credentialRule; + userInStorage.lastModifiedBy = modifier; + userInStorage.createdBy = creator; + + userInStorage.credentials.clear(); + for (size_t i = 0; i < totalCredentials; ++i) + { + userInStorage.credentials.push_back(credentials[i]); + } + + ChipLogProgress(Zcl, "Successfully set the user [mEndpointId=%d,index=%d,adjustedIndex=%d]", mEndpointId, userIndex, + adjustedUserIndex); + + return true; +} + +bool LockEndpoint::GetCredential(uint16_t credentialIndex, DlCredentialType credentialType, + EmberAfPluginDoorLockCredentialInfo & credential) const +{ + ChipLogDetail(Zcl, "GetCredential [endpoint=%d,credentialIndex=%u,credentialType=%u]", mEndpointId, credentialIndex, + to_underlying(credentialType)); + + if (credentialIndex >= mLockCredentials.size() || (0 == credentialIndex && DlCredentialType::kProgrammingPIN != credentialType)) + { + ChipLogError(Zcl, "Cannot get the credential - index out of range [endpoint=%d,index=%d]", mEndpointId, credentialIndex); + return false; + } + + const auto & credentialInStorage = mLockCredentials[credentialIndex]; + + credential.status = credentialInStorage.status; + if (DlCredentialStatus::kAvailable == credential.status) + { + ChipLogDetail(Zcl, "Found unoccupied credential [endpoint=%d,index=%u]", mEndpointId, credentialIndex); + return true; + } + credential.credentialType = credentialInStorage.credentialType; + credential.credentialData = chip::ByteSpan(credentialInStorage.credentialData, credentialInStorage.credentialDataSize); + credential.createdBy = credentialInStorage.createdBy; + credential.lastModifiedBy = credentialInStorage.modifiedBy; + + ChipLogDetail(Zcl, "Found occupied credential [endpoint=%d,index=%u,type=%u,dataSize=%u,createdBy=%u,modifiedBy=%u]", + mEndpointId, credentialIndex, to_underlying(credential.credentialType), + static_cast(credential.credentialData.size()), credential.createdBy, credential.lastModifiedBy); + + return true; +} + +bool LockEndpoint::SetCredential(uint16_t credentialIndex, chip::FabricIndex creator, chip::FabricIndex modifier, + DlCredentialStatus credentialStatus, DlCredentialType credentialType, + const chip::ByteSpan & credentialData) +{ + ChipLogDetail( + Zcl, + "SetCredential " + "[endpoint=%d,credentialIndex=%u,credentialStatus=%u,credentialType=%u,credentialDataSize=%u,creator=%u,modifier=%u]", + mEndpointId, credentialIndex, to_underlying(credentialStatus), to_underlying(credentialType), + static_cast(credentialData.size()), creator, modifier); + + if (credentialIndex >= mLockCredentials.size() || (0 == credentialIndex && DlCredentialType::kProgrammingPIN != credentialType)) + { + ChipLogError(Zcl, "Cannot set the credential - index out of range [endpoint=%d,index=%d]", mEndpointId, credentialIndex); + return false; + } + + auto & credentialInStorage = mLockCredentials[credentialIndex]; + if (credentialData.size() > DOOR_LOCK_CREDENTIAL_INFO_MAX_DATA_SIZE) + { + ChipLogError(Zcl, + "Cannot get the credential - data size exceeds limit " + "[endpoint=%d,index=%d,dataSize=%u,maxDataSize=%u]", + mEndpointId, credentialIndex, static_cast(credentialData.size()), + static_cast(DOOR_LOCK_CREDENTIAL_INFO_MAX_DATA_SIZE)); + return false; + } + credentialInStorage.status = credentialStatus; + credentialInStorage.credentialType = credentialType; + credentialInStorage.createdBy = creator; + credentialInStorage.modifiedBy = modifier; + std::memcpy(credentialInStorage.credentialData, credentialData.data(), credentialData.size()); + credentialInStorage.credentialDataSize = credentialData.size(); + + ChipLogProgress(Zcl, "Successfully set the credential [mEndpointId=%d,index=%d,credentialType=%u,creator=%u,modifier=%u]", + mEndpointId, credentialIndex, to_underlying(credentialType), credentialInStorage.createdBy, + credentialInStorage.modifiedBy); + + return true; +} + +DlStatus LockEndpoint::GetSchedule(uint8_t weekDayIndex, uint16_t userIndex, EmberAfPluginDoorLockWeekDaySchedule & schedule) +{ + if (0 == userIndex || userIndex > mWeekDaySchedules.size()) + { + return DlStatus::kFailure; + } + + if (0 == weekDayIndex || weekDayIndex > mWeekDaySchedules.at(userIndex - 1).size()) + { + return DlStatus::kFailure; + } + + const auto & scheduleInStorage = mWeekDaySchedules.at(userIndex - 1).at(weekDayIndex - 1); + if (DlScheduleStatus::kAvailable == scheduleInStorage.status) + { + return DlStatus::kNotFound; + } + + schedule = scheduleInStorage.schedule; + + return DlStatus::kSuccess; +} + +DlStatus LockEndpoint::SetSchedule(uint8_t weekDayIndex, uint16_t userIndex, DlScheduleStatus status, DlDaysMaskMap daysMask, + uint8_t startHour, uint8_t startMinute, uint8_t endHour, uint8_t endMinute) +{ + if (0 == userIndex || userIndex > mWeekDaySchedules.size()) + { + return DlStatus::kFailure; + } + + if (0 == weekDayIndex || weekDayIndex > mWeekDaySchedules.at(userIndex - 1).size()) + { + return DlStatus::kFailure; + } + + auto & scheduleInStorage = mWeekDaySchedules.at(userIndex - 1).at(weekDayIndex - 1); + + scheduleInStorage.schedule.daysMask = daysMask; + scheduleInStorage.schedule.startHour = startHour; + scheduleInStorage.schedule.startMinute = startMinute; + scheduleInStorage.schedule.endHour = endHour; + scheduleInStorage.schedule.endMinute = endMinute; + scheduleInStorage.status = status; + + return DlStatus::kSuccess; +} + +DlStatus LockEndpoint::GetSchedule(uint8_t yearDayIndex, uint16_t userIndex, EmberAfPluginDoorLockYearDaySchedule & schedule) +{ + if (0 == userIndex || userIndex > mYearDaySchedules.size()) + { + return DlStatus::kFailure; + } + + if (0 == yearDayIndex || yearDayIndex > mYearDaySchedules.at(userIndex - 1).size()) + { + return DlStatus::kFailure; + } + + const auto & scheduleInStorage = mYearDaySchedules.at(userIndex - 1).at(yearDayIndex - 1); + if (DlScheduleStatus::kAvailable == scheduleInStorage.status) + { + return DlStatus::kNotFound; + } + + schedule = scheduleInStorage.schedule; + + return DlStatus::kSuccess; +} + +DlStatus LockEndpoint::SetSchedule(uint8_t yearDayIndex, uint16_t userIndex, DlScheduleStatus status, uint32_t localStartTime, + uint32_t localEndTime) +{ + if (0 == userIndex || userIndex > mYearDaySchedules.size()) + { + return DlStatus::kFailure; + } + + if (0 == yearDayIndex || yearDayIndex > mYearDaySchedules.at(userIndex - 1).size()) + { + return DlStatus::kFailure; + } + + auto & scheduleInStorage = mYearDaySchedules.at(userIndex - 1).at(yearDayIndex - 1); + scheduleInStorage.schedule.localStartTime = localStartTime; + scheduleInStorage.schedule.localEndTime = localEndTime; + scheduleInStorage.status = status; + + return DlStatus::kSuccess; +} + +bool LockEndpoint::setLockState(DlLockState lockState, const Optional & pin, DlOperationError & err) +{ + if (!pin.HasValue()) + { + ChipLogDetail(Zcl, "PIN code is not specified, setting door lock state to \"%s\" [endpointId=%d]", + lockStateToString(lockState), mEndpointId); + mLockState = lockState; + return true; + } + + // Check the PIN code + for (const auto & pinCredential : mLockCredentials) + { + if (pinCredential.credentialType != DlCredentialType::kPin || pinCredential.status == DlCredentialStatus::kAvailable) + { + continue; + } + + chip::ByteSpan credentialData(pinCredential.credentialData, pinCredential.credentialDataSize); + if (credentialData.data_equal(pin.Value())) + { + ChipLogProgress(Zcl, "Setting door lock state to \"%s\" [endpointId=%d]", lockStateToString(lockState), mEndpointId); + + mLockState = lockState; + return true; + } + } + + ChipLogDetail(Zcl, + "Specified PIN code was not found in the database, ignoring command to set lock state to \"%s\" " + "[endpointId=%d]", + lockStateToString(lockState), mEndpointId); + + err = DlOperationError::kInvalidCredential; + return false; +} + +const char * LockEndpoint::lockStateToString(DlLockState lockState) const +{ + switch (lockState) + { + case DlLockState::kNotFullyLocked: + return "Not Fully Locked"; + case DlLockState::kLocked: + return "Locked"; + case DlLockState::kUnlocked: + return "Unlocked"; + } + + return "Unknown"; +} diff --git a/examples/lock-app/openiotsdk/main/LockManager.cpp b/examples/lock-app/openiotsdk/main/LockManager.cpp new file mode 100644 index 00000000000000..33397bbf3113df --- /dev/null +++ b/examples/lock-app/openiotsdk/main/LockManager.cpp @@ -0,0 +1,248 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include "LockManager.h" + +#include + +#include +#include +#include + +using chip::to_underlying; + +LockManager LockManager::instance; + +LockManager & LockManager::Instance() +{ + return instance; +} + +bool LockManager::InitEndpoint(chip::EndpointId endpointId) +{ + uint16_t numberOfSupportedUsers = 0; + if (!DoorLockServer::Instance().GetNumberOfUserSupported(endpointId, numberOfSupportedUsers)) + { + ChipLogError(Zcl, + "Unable to get number of supported users when initializing lock endpoint, defaulting to 10 [endpointId=%d]", + endpointId); + numberOfSupportedUsers = CHIP_LOCK_MANAGER_USER_NUMBER; + } + + uint16_t numberOfSupportedCredentials = 0; + // We're planning to use shared storage for PIN and RFID users so we will have the maximum of both sizes her to simplify logic + uint16_t numberOfPINCredentialsSupported = 0; + uint16_t numberOfRFIDCredentialsSupported = 0; + if (!DoorLockServer::Instance().GetNumberOfPINCredentialsSupported(endpointId, numberOfPINCredentialsSupported) || + !DoorLockServer::Instance().GetNumberOfRFIDCredentialsSupported(endpointId, numberOfRFIDCredentialsSupported)) + { + ChipLogError( + Zcl, "Unable to get number of supported credentials when initializing lock endpoint, defaulting to 10 [endpointId=%d]", + endpointId); + numberOfSupportedCredentials = CHIP_LOCK_MANAGER_CREDENTIALS_NUMBER; + } + else + { + numberOfSupportedCredentials = std::max(numberOfPINCredentialsSupported, numberOfRFIDCredentialsSupported); + } + + uint8_t numberOfCredentialsSupportedPerUser = 0; + if (!DoorLockServer::Instance().GetNumberOfCredentialsSupportedPerUser(endpointId, numberOfCredentialsSupportedPerUser)) + { + ChipLogError(Zcl, + "Unable to get number of credentials supported per user when initializing lock endpoint, defaulting to 5 " + "[endpointId=%d]", + endpointId); + numberOfCredentialsSupportedPerUser = CHIP_LOCK_MANAGER_CREDENTIALS_PER_USER_NUMBER; + } + + uint8_t numberOfWeekDaySchedulesPerUser = 0; + if (!DoorLockServer::Instance().GetNumberOfWeekDaySchedulesPerUserSupported(endpointId, numberOfWeekDaySchedulesPerUser)) + { + ChipLogError(Zcl, + "Unable to get number of supported week day schedules per user when initializing lock endpoint, defaulting to " + "10 [endpointId=%d]", + endpointId); + numberOfWeekDaySchedulesPerUser = CHIP_LOCK_MANAGER_WEEK_DAY_SCHEDULES_PER_USER_NUMBER; + } + + uint8_t numberOfYearDaySchedulesPerUser = 0; + if (!DoorLockServer::Instance().GetNumberOfYearDaySchedulesPerUserSupported(endpointId, numberOfYearDaySchedulesPerUser)) + { + ChipLogError(Zcl, + "Unable to get number of supported year day schedules per user when initializing lock endpoint, defaulting to " + "10 [endpointId=%d]", + endpointId); + numberOfYearDaySchedulesPerUser = CHIP_LOCK_MANAGER_YEAR_DAY_SCHEDULES_PER_USER_NUMBER; + } + + mEndpoints.emplace_back(endpointId, numberOfSupportedUsers, numberOfSupportedCredentials, numberOfWeekDaySchedulesPerUser, + numberOfYearDaySchedulesPerUser, numberOfCredentialsSupportedPerUser); + + ChipLogProgress(Zcl, + "Initialized new lock door endpoint " + "[id=%d,users=%d,credentials=%d,weekDaySchedulesPerUser=%d,yearDaySchedulesPerUser=%d," + "numberOfCredentialsSupportedPerUser=%d]", + endpointId, numberOfSupportedUsers, numberOfSupportedCredentials, numberOfWeekDaySchedulesPerUser, + numberOfYearDaySchedulesPerUser, numberOfCredentialsSupportedPerUser); + + return true; +} + +bool LockManager::Lock(chip::EndpointId endpointId, const Optional & pin, DlOperationError & err) +{ + auto lockEndpoint = getEndpoint(endpointId); + if (nullptr == lockEndpoint) + { + ChipLogError(Zcl, "Unable to lock the door - endpoint does not exist or not initialized [endpointId=%d]", endpointId); + return false; + } + + VerifyOrReturnValue(lockEndpoint->Lock(pin, err), false); + + return DoorLockServer::Instance().SetLockState(endpointId, DlLockState::kLocked); +} + +bool LockManager::Unlock(chip::EndpointId endpointId, const Optional & pin, DlOperationError & err) +{ + auto lockEndpoint = getEndpoint(endpointId); + if (nullptr == lockEndpoint) + { + ChipLogError(Zcl, "Unable to unlock the door - endpoint does not exist or not initialized [endpointId=%d]", endpointId); + return false; + } + + VerifyOrReturnValue(lockEndpoint->Unlock(pin, err), false); + + return DoorLockServer::Instance().SetLockState(endpointId, DlLockState::kUnlocked); +} + +bool LockManager::GetUser(chip::EndpointId endpointId, uint16_t userIndex, EmberAfPluginDoorLockUserInfo & user) +{ + auto lockEndpoint = getEndpoint(endpointId); + if (nullptr == lockEndpoint) + { + ChipLogError(Zcl, "Unable to get the user - endpoint does not exist or not initialized [endpointId=%d]", endpointId); + return false; + } + return lockEndpoint->GetUser(userIndex, user); +} + +bool LockManager::SetUser(chip::EndpointId endpointId, uint16_t userIndex, chip::FabricIndex creator, chip::FabricIndex modifier, + const chip::CharSpan & userName, uint32_t uniqueId, DlUserStatus userStatus, DlUserType usertype, + DlCredentialRule credentialRule, const DlCredential * credentials, size_t totalCredentials) +{ + auto lockEndpoint = getEndpoint(endpointId); + if (nullptr == lockEndpoint) + { + ChipLogError(Zcl, "Unable to set the user - endpoint does not exist or not initialized [endpointId=%d]", endpointId); + return false; + } + return lockEndpoint->SetUser(userIndex, creator, modifier, userName, uniqueId, userStatus, usertype, credentialRule, + credentials, totalCredentials); +} + +bool LockManager::GetCredential(chip::EndpointId endpointId, uint16_t credentialIndex, DlCredentialType credentialType, + EmberAfPluginDoorLockCredentialInfo & credential) +{ + auto lockEndpoint = getEndpoint(endpointId); + if (nullptr == lockEndpoint) + { + ChipLogError(Zcl, "Unable to get the credential - endpoint does not exist or not initialized [endpointId=%d]", endpointId); + return false; + } + return lockEndpoint->GetCredential(credentialIndex, credentialType, credential); +} + +bool LockManager::SetCredential(chip::EndpointId endpointId, uint16_t credentialIndex, chip::FabricIndex creator, + chip::FabricIndex modifier, DlCredentialStatus credentialStatus, DlCredentialType credentialType, + const chip::ByteSpan & credentialData) +{ + auto lockEndpoint = getEndpoint(endpointId); + if (nullptr == lockEndpoint) + { + ChipLogError(Zcl, "Unable to set the credential - endpoint does not exist or not initialized [endpointId=%d]", endpointId); + return false; + } + return lockEndpoint->SetCredential(credentialIndex, creator, modifier, credentialStatus, credentialType, credentialData); +} + +DlStatus LockManager::GetSchedule(chip::EndpointId endpointId, uint8_t weekDayIndex, uint16_t userIndex, + EmberAfPluginDoorLockWeekDaySchedule & schedule) +{ + auto lockEndpoint = getEndpoint(endpointId); + if (nullptr == lockEndpoint) + { + ChipLogError(Zcl, "Unable to get the week day schedule - endpoint does not exist or not initialized [endpointId=%d]", + endpointId); + return DlStatus::kFailure; + } + return lockEndpoint->GetSchedule(weekDayIndex, userIndex, schedule); +} + +DlStatus LockManager::SetSchedule(chip::EndpointId endpointId, uint8_t weekDayIndex, uint16_t userIndex, DlScheduleStatus status, + DlDaysMaskMap daysMask, uint8_t startHour, uint8_t startMinute, uint8_t endHour, + uint8_t endMinute) +{ + auto lockEndpoint = getEndpoint(endpointId); + if (nullptr == lockEndpoint) + { + ChipLogError(Zcl, "Unable to set the week day schedule - endpoint does not exist or not initialized [endpointId=%d]", + endpointId); + return DlStatus::kFailure; + } + return lockEndpoint->SetSchedule(weekDayIndex, userIndex, status, daysMask, startHour, startMinute, endHour, endMinute); +} + +DlStatus LockManager::GetSchedule(chip::EndpointId endpointId, uint8_t yearDayIndex, uint16_t userIndex, + EmberAfPluginDoorLockYearDaySchedule & schedule) +{ + auto lockEndpoint = getEndpoint(endpointId); + if (nullptr == lockEndpoint) + { + ChipLogError(Zcl, "Unable to get the year day schedule - endpoint does not exist or not initialized [endpointId=%d]", + endpointId); + return DlStatus::kFailure; + } + return lockEndpoint->GetSchedule(yearDayIndex, userIndex, schedule); +} + +DlStatus LockManager::SetSchedule(chip::EndpointId endpointId, uint8_t yearDayIndex, uint16_t userIndex, DlScheduleStatus status, + uint32_t localStartTime, uint32_t localEndTime) +{ + auto lockEndpoint = getEndpoint(endpointId); + if (nullptr == lockEndpoint) + { + ChipLogError(Zcl, "Unable to set the year day schedule - endpoint does not exist or not initialized [endpointId=%d]", + endpointId); + return DlStatus::kFailure; + } + return lockEndpoint->SetSchedule(yearDayIndex, userIndex, status, localStartTime, localEndTime); +} + +LockEndpoint * LockManager::getEndpoint(chip::EndpointId endpointId) +{ + for (auto & mEndpoint : mEndpoints) + { + if (mEndpoint.GetEndpointId() == endpointId) + { + return &mEndpoint; + } + } + return nullptr; +} diff --git a/examples/lock-app/openiotsdk/main/ZclCallbacks.cpp b/examples/lock-app/openiotsdk/main/ZclCallbacks.cpp new file mode 100644 index 00000000000000..f383377cfd77f7 --- /dev/null +++ b/examples/lock-app/openiotsdk/main/ZclCallbacks.cpp @@ -0,0 +1,106 @@ +/* + * + * Copyright (c) 2020-2021 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 +#include + +#include "LockManager.h" + +using namespace chip; +using namespace chip::app::Clusters; +using namespace chip::app::Clusters::DoorLock; + +bool emberAfPluginDoorLockOnDoorLockCommand(chip::EndpointId endpointId, const Optional & pinCode, DlOperationError & err) +{ + return LockManager::Instance().Lock(endpointId, pinCode, err); +} + +bool emberAfPluginDoorLockOnDoorUnlockCommand(chip::EndpointId endpointId, const Optional & pinCode, + DlOperationError & err) +{ + return LockManager::Instance().Unlock(endpointId, pinCode, err); +} + +bool emberAfPluginDoorLockGetUser(chip::EndpointId endpointId, uint16_t userIndex, EmberAfPluginDoorLockUserInfo & user) +{ + return LockManager::Instance().GetUser(endpointId, userIndex, user); +} + +bool emberAfPluginDoorLockSetUser(chip::EndpointId endpointId, uint16_t userIndex, chip::FabricIndex creator, + chip::FabricIndex modifier, const chip::CharSpan & userName, uint32_t uniqueId, + DlUserStatus userStatus, DlUserType usertype, DlCredentialRule credentialRule, + const DlCredential * credentials, size_t totalCredentials) +{ + + return LockManager::Instance().SetUser(endpointId, userIndex, creator, modifier, userName, uniqueId, userStatus, usertype, + credentialRule, credentials, totalCredentials); +} + +bool emberAfPluginDoorLockGetCredential(chip::EndpointId endpointId, uint16_t credentialIndex, DlCredentialType credentialType, + EmberAfPluginDoorLockCredentialInfo & credential) +{ + return LockManager::Instance().GetCredential(endpointId, credentialIndex, credentialType, credential); +} + +bool emberAfPluginDoorLockSetCredential(chip::EndpointId endpointId, uint16_t credentialIndex, chip::FabricIndex creator, + chip::FabricIndex modifier, DlCredentialStatus credentialStatus, + DlCredentialType credentialType, const chip::ByteSpan & credentialData) +{ + return LockManager::Instance().SetCredential(endpointId, credentialIndex, creator, modifier, credentialStatus, credentialType, + credentialData); +} + +DlStatus emberAfPluginDoorLockGetSchedule(chip::EndpointId endpointId, uint8_t weekdayIndex, uint16_t userIndex, + EmberAfPluginDoorLockWeekDaySchedule & schedule) +{ + return LockManager::Instance().GetSchedule(endpointId, weekdayIndex, userIndex, schedule); +} + +DlStatus emberAfPluginDoorLockSetSchedule(chip::EndpointId endpointId, uint8_t weekdayIndex, uint16_t userIndex, + DlScheduleStatus status, DlDaysMaskMap daysMask, uint8_t startHour, uint8_t startMinute, + uint8_t endHour, uint8_t endMinute) +{ + return LockManager::Instance().SetSchedule(endpointId, weekdayIndex, userIndex, status, daysMask, startHour, startMinute, + endHour, endMinute); +} + +DlStatus emberAfPluginDoorLockSetSchedule(chip::EndpointId endpointId, uint8_t yearDayIndex, uint16_t userIndex, + DlScheduleStatus status, uint32_t localStartTime, uint32_t localEndTime) +{ + return LockManager::Instance().SetSchedule(endpointId, yearDayIndex, userIndex, status, localStartTime, localEndTime); +} + +DlStatus emberAfPluginDoorLockGetSchedule(chip::EndpointId endpointId, uint8_t yearDayIndex, uint16_t userIndex, + EmberAfPluginDoorLockYearDaySchedule & schedule) +{ + return LockManager::Instance().GetSchedule(endpointId, yearDayIndex, userIndex, schedule); +} + +void MatterPostAttributeChangeCallback(const chip::app::ConcreteAttributePath & attributePath, uint8_t type, uint16_t size, + uint8_t * value) +{ + VerifyOrReturn(attributePath.mClusterId == DoorLock::Id && attributePath.mAttributeId == DoorLock::Attributes::LockState::Id); + + emberAfDoorLockClusterPrintln("Door Lock attribute changed"); +} + +void emberAfDoorLockClusterInitCallback(EndpointId endpoint) +{ + DoorLockServer::Instance().InitServer(endpoint); + LockManager::Instance().InitEndpoint(endpoint); +} diff --git a/examples/lock-app/openiotsdk/main/include/CHIPProjectConfig.h b/examples/lock-app/openiotsdk/main/include/CHIPProjectConfig.h new file mode 100644 index 00000000000000..b72d5bd3db306b --- /dev/null +++ b/examples/lock-app/openiotsdk/main/include/CHIPProjectConfig.h @@ -0,0 +1,33 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +#define CHIP_DEVICE_CONFIG_ENABLE_WIFI_STATION 0 +#define CHIP_DEVICE_CONFIG_ENABLE_WIFI_AP 0 + +// Use a default pairing code if one hasn't been provisioned in flash. +#define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE 20202021 +#define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR 0xF00 + +// Lock Manager settings +#define CHIP_LOCK_MANAGER_USER_NUMBER 10 +#define CHIP_LOCK_MANAGER_CREDENTIALS_NUMBER 10 +#define CHIP_LOCK_MANAGER_CREDENTIALS_PER_USER_NUMBER 5 +#define CHIP_LOCK_MANAGER_WEEK_DAY_SCHEDULES_PER_USER_NUMBER 10 +#define CHIP_LOCK_MANAGER_YEAR_DAY_SCHEDULES_PER_USER_NUMBER 10 diff --git a/examples/lock-app/openiotsdk/main/include/LockEndpoint.h b/examples/lock-app/openiotsdk/main/include/LockEndpoint.h new file mode 100644 index 00000000000000..bee91e7265239f --- /dev/null +++ b/examples/lock-app/openiotsdk/main/include/LockEndpoint.h @@ -0,0 +1,117 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +#include +#include + +struct LockUserInfo +{ + char userName[DOOR_LOCK_USER_NAME_BUFFER_SIZE]; + uint32_t userUniqueId; + DlUserStatus userStatus; + DlUserType userType; + DlCredentialRule credentialRule; + std::vector credentials; + chip::FabricIndex createdBy; + chip::FabricIndex lastModifiedBy; +}; + +struct LockCredentialInfo; +struct WeekDaysScheduleInfo; +struct YearDayScheduleInfo; + +static constexpr size_t DOOR_LOCK_CREDENTIAL_INFO_MAX_DATA_SIZE = 20; + +class LockEndpoint +{ +public: + LockEndpoint(chip::EndpointId endpointId, uint16_t numberOfLockUsersSupported, uint16_t numberOfCredentialsSupported, + uint8_t weekDaySchedulesPerUser, uint8_t yearDaySchedulesPerUser, uint8_t numberOfCredentialsPerUser) : + mEndpointId{ endpointId }, + mLockState{ DlLockState::kLocked }, mLockUsers(numberOfLockUsersSupported), + mLockCredentials(numberOfCredentialsSupported + 1), + mWeekDaySchedules(numberOfLockUsersSupported, std::vector(weekDaySchedulesPerUser)), + mYearDaySchedules(numberOfLockUsersSupported, std::vector(yearDaySchedulesPerUser)) + { + for (auto & lockUser : mLockUsers) + { + lockUser.credentials.reserve(numberOfCredentialsPerUser); + } + } + + inline chip::EndpointId GetEndpointId() const { return mEndpointId; } + + bool Lock(const Optional & pin, DlOperationError & err); + bool Unlock(const Optional & pin, DlOperationError & err); + + bool GetUser(uint16_t userIndex, EmberAfPluginDoorLockUserInfo & user) const; + bool SetUser(uint16_t userIndex, chip::FabricIndex creator, chip::FabricIndex modifier, const chip::CharSpan & userName, + uint32_t uniqueId, DlUserStatus userStatus, DlUserType usertype, DlCredentialRule credentialRule, + const DlCredential * credentials, size_t totalCredentials); + + bool GetCredential(uint16_t credentialIndex, DlCredentialType credentialType, + EmberAfPluginDoorLockCredentialInfo & credential) const; + + bool SetCredential(uint16_t credentialIndex, chip::FabricIndex creator, chip::FabricIndex modifier, + DlCredentialStatus credentialStatus, DlCredentialType credentialType, const chip::ByteSpan & credentialData); + + DlStatus GetSchedule(uint8_t weekDayIndex, uint16_t userIndex, EmberAfPluginDoorLockWeekDaySchedule & schedule); + DlStatus GetSchedule(uint8_t yearDayIndex, uint16_t userIndex, EmberAfPluginDoorLockYearDaySchedule & schedule); + DlStatus SetSchedule(uint8_t weekDayIndex, uint16_t userIndex, DlScheduleStatus status, DlDaysMaskMap daysMask, + uint8_t startHour, uint8_t startMinute, uint8_t endHour, uint8_t endMinute); + DlStatus SetSchedule(uint8_t yearDayIndex, uint16_t userIndex, DlScheduleStatus status, uint32_t localStartTime, + uint32_t localEndTime); + +private: + bool setLockState(DlLockState lockState, const Optional & pin, DlOperationError & err); + const char * lockStateToString(DlLockState lockState) const; + + chip::EndpointId mEndpointId; + DlLockState mLockState; + + // This is very naive implementation of users/credentials/schedules database and by no means the best practice. Proper storage + // of those items is out of scope of this example. + std::vector mLockUsers; + std::vector mLockCredentials; + std::vector> mWeekDaySchedules; + std::vector> mYearDaySchedules; +}; + +struct LockCredentialInfo +{ + DlCredentialStatus status; + DlCredentialType credentialType; + chip::FabricIndex createdBy; + chip::FabricIndex modifiedBy; + uint8_t credentialData[DOOR_LOCK_CREDENTIAL_INFO_MAX_DATA_SIZE]; + size_t credentialDataSize; +}; + +struct WeekDaysScheduleInfo +{ + DlScheduleStatus status; + EmberAfPluginDoorLockWeekDaySchedule schedule; +}; + +struct YearDayScheduleInfo +{ + DlScheduleStatus status; + EmberAfPluginDoorLockYearDaySchedule schedule; +}; diff --git a/examples/lock-app/openiotsdk/main/include/LockManager.h b/examples/lock-app/openiotsdk/main/include/LockManager.h new file mode 100644 index 00000000000000..2fccdc9745f7a7 --- /dev/null +++ b/examples/lock-app/openiotsdk/main/include/LockManager.h @@ -0,0 +1,65 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +#include +#include +#include + +#include + +class LockManager +{ +public: + LockManager() {} + + bool InitEndpoint(chip::EndpointId endpointId); + + bool Lock(chip::EndpointId endpointId, const Optional & pin, DlOperationError & err); + bool Unlock(chip::EndpointId endpointId, const Optional & pin, DlOperationError & err); + + bool GetUser(chip::EndpointId endpointId, uint16_t userIndex, EmberAfPluginDoorLockUserInfo & user); + bool SetUser(chip::EndpointId endpointId, uint16_t userIndex, chip::FabricIndex creator, chip::FabricIndex modifier, + const chip::CharSpan & userName, uint32_t uniqueId, DlUserStatus userStatus, DlUserType usertype, + DlCredentialRule credentialRule, const DlCredential * credentials, size_t totalCredentials); + + bool GetCredential(chip::EndpointId endpointId, uint16_t credentialIndex, DlCredentialType credentialType, + EmberAfPluginDoorLockCredentialInfo & credential); + + bool SetCredential(chip::EndpointId endpointId, uint16_t credentialIndex, chip::FabricIndex creator, chip::FabricIndex modifier, + DlCredentialStatus credentialStatus, DlCredentialType credentialType, const chip::ByteSpan & credentialData); + + DlStatus GetSchedule(chip::EndpointId endpointId, uint8_t weekDayIndex, uint16_t userIndex, + EmberAfPluginDoorLockWeekDaySchedule & schedule); + DlStatus GetSchedule(chip::EndpointId endpointId, uint8_t yearDayIndex, uint16_t userIndex, + EmberAfPluginDoorLockYearDaySchedule & schedule); + DlStatus SetSchedule(chip::EndpointId endpointId, uint8_t weekDayIndex, uint16_t userIndex, DlScheduleStatus status, + DlDaysMaskMap daysMask, uint8_t startHour, uint8_t startMinute, uint8_t endHour, uint8_t endMinute); + DlStatus SetSchedule(chip::EndpointId endpointId, uint8_t yearDayIndex, uint16_t userIndex, DlScheduleStatus status, + uint32_t localStartTime, uint32_t localEndTime); + + static LockManager & Instance(); + +private: + LockEndpoint * getEndpoint(chip::EndpointId endpointId); + + std::vector mEndpoints; + + static LockManager instance; +}; diff --git a/examples/lock-app/openiotsdk/main/main.cpp b/examples/lock-app/openiotsdk/main/main.cpp new file mode 100644 index 00000000000000..fbd72e0542fc85 --- /dev/null +++ b/examples/lock-app/openiotsdk/main/main.cpp @@ -0,0 +1,112 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +#include +#include +#include + +#include +#include +#include +#include + +#include "openiotsdk_platform.h" + +using namespace ::chip; +using namespace ::chip::DeviceLayer; + +static void app_thread(void * argument) +{ + CHIP_ERROR error; + + if (openiotsdk_network_init(true)) + { + ChipLogError(NotSpecified, "Network initialization failed"); + goto exit; + } + + // Init ZCL Data Model and start server + static chip::CommonCaseDeviceServerInitParams initParams; + (void) initParams.InitializeStaticResourcesBeforeServerInit(); + initParams.operationalServicePort = CHIP_PORT; + initParams.userDirectedCommissioningPort = CHIP_UDC_PORT; + + error = Server::GetInstance().Init(initParams); + SuccessOrExit(error); + + // Now that the server has started and we are done with our startup logging, + // log our discovery/onboarding information again so it's not lost in the + // noise. + ConfigurationMgr().LogDeviceConfig(); + + PrintOnboardingCodes(RendezvousInformationFlags(RendezvousInformationFlag::kOnNetwork)); + + // Initialize device attestation config + SetDeviceAttestationCredentialsProvider(Credentials::Examples::GetExampleDACProvider()); + + ChipLogProgress(NotSpecified, "Open IoT SDK lock-app example application run"); + + while (true) + { + // Add forever delay to ensure proper workload for this thread + osDelay(osWaitForever); + } + + Server::GetInstance().Shutdown(); + +exit: + osThreadTerminate(osThreadGetId()); +} + +int main() +{ + ChipLogProgress(NotSpecified, "Open IoT SDK lock-app example application start"); + + if (openiotsdk_platform_init()) + { + ChipLogError(NotSpecified, "Open IoT SDK platform initialization failed"); + return EXIT_FAILURE; + } + + if (openiotsdk_chip_init()) + { + ChipLogError(NotSpecified, "Open IoT SDK CHIP stack initialization failed"); + return EXIT_FAILURE; + } + + static const osThreadAttr_t thread_attr = { + .stack_size = 16 * 1024 // Allocate enough stack for app thread + }; + + osThreadId_t appThread = osThreadNew(app_thread, NULL, &thread_attr); + if (appThread == NULL) + { + ChipLogError(NotSpecified, "Failed to create app thread"); + return EXIT_FAILURE; + } + + if (openiotsdk_platform_run()) + { + ChipLogError(NotSpecified, "Open IoT SDK platform run failed"); + return EXIT_FAILURE; + } + + return EXIT_SUCCESS; +} diff --git a/examples/lock-app/qpg/src/AppTask.cpp b/examples/lock-app/qpg/src/AppTask.cpp index bc24d7fbbe8b46..3306379bbe41da 100644 --- a/examples/lock-app/qpg/src/AppTask.cpp +++ b/examples/lock-app/qpg/src/AppTask.cpp @@ -28,7 +28,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/ota-provider-app/esp32/main/main.cpp b/examples/ota-provider-app/esp32/main/main.cpp index 27f46ed6154efc..17276f9ac6cb56 100644 --- a/examples/ota-provider-app/esp32/main/main.cpp +++ b/examples/ota-provider-app/esp32/main/main.cpp @@ -20,6 +20,7 @@ #include "esp_spi_flash.h" #include "esp_spiffs.h" #include "nvs_flash.h" +#include #include #include #include @@ -75,6 +76,9 @@ chip::Callback::Callback onTransferFailedCallback(OnTransfe static void InitServer(intptr_t context) { + // Print QR Code URL + PrintOnboardingCodes(chip::RendezvousInformationFlags(CONFIG_RENDEZVOUS_MODE)); + Esp32AppServer::Init(); // Init ZCL Data Model and CHIP App Server AND Initialize device attestation config BdxOtaSender * bdxOtaSender = otaProvider.GetBdxOtaSender(); diff --git a/examples/ota-provider-app/ota-provider-common/ota-provider-app.matter b/examples/ota-provider-app/ota-provider-common/ota-provider-app.matter index 440398ff636ee9..892c5c6deb165b 100644 --- a/examples/ota-provider-app/ota-provider-common/ota-provider-app.matter +++ b/examples/ota-provider-app/ota-provider-common/ota-provider-app.matter @@ -799,7 +799,7 @@ server cluster UserLabel = 65 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster AccessControl; server cluster AccessControl { diff --git a/examples/ota-requestor-app/ameba/main/DeviceCallbacks.cpp b/examples/ota-requestor-app/ameba/main/DeviceCallbacks.cpp index 259ff3d726f529..8e6b1192b96dd8 100644 --- a/examples/ota-requestor-app/ameba/main/DeviceCallbacks.cpp +++ b/examples/ota-requestor-app/ameba/main/DeviceCallbacks.cpp @@ -26,7 +26,7 @@ #include "CHIPDeviceManager.h" #include -#include +#include #include #include #include @@ -90,11 +90,11 @@ void DeviceCallbacks::PostAttributeChangeCallback(EndpointId endpointId, Cluster { switch (clusterId) { - case ZCL_ON_OFF_CLUSTER_ID: + case app::Clusters::OnOff::Id: OnOnOffPostAttributeChangeCallback(endpointId, attributeId, value); break; - case ZCL_IDENTIFY_CLUSTER_ID: + case app::Clusters::Identify::Id: OnIdentifyPostAttributeChangeCallback(endpointId, attributeId, value); break; diff --git a/examples/ota-requestor-app/esp32/CMakeLists.txt b/examples/ota-requestor-app/esp32/CMakeLists.txt index 6d522a07c7d1fd..567bd30267ff78 100644 --- a/examples/ota-requestor-app/esp32/CMakeLists.txt +++ b/examples/ota-requestor-app/esp32/CMakeLists.txt @@ -46,6 +46,10 @@ idf_build_set_property(COMPILE_OPTIONS "-Wno-error=maybe-uninitialized" APPEND) if (CONFIG_ENABLE_PW_RPC) get_filename_component(CHIP_ROOT ./third_party/connectedhomeip REALPATH) include(third_party/connectedhomeip/third_party/pigweed/repo/pw_build/pigweed.cmake) +include($ENV{PW_ROOT}/pw_assert/backend.cmake) +include($ENV{PW_ROOT}/pw_log/backend.cmake) +include($ENV{PW_ROOT}/pw_sys_io/backend.cmake) +include($ENV{PW_ROOT}/pw_trace/backend.cmake) pw_set_module_config(pw_rpc_CONFIG pw_rpc.disable_global_mutex_config) pw_set_backend(pw_log pw_log_basic) diff --git a/examples/ota-requestor-app/esp32/main/CMakeLists.txt b/examples/ota-requestor-app/esp32/main/CMakeLists.txt index 184e29acd10a32..c711b84c438ef5 100644 --- a/examples/ota-requestor-app/esp32/main/CMakeLists.txt +++ b/examples/ota-requestor-app/esp32/main/CMakeLists.txt @@ -177,6 +177,7 @@ target_link_libraries(${COMPONENT_LIB} PUBLIC pw_log pw_rpc.server pw_sys_io + pw_trace pw_trace_tokenized pw_trace_tokenized.trace_buffer pw_trace_tokenized.rpc_service diff --git a/examples/ota-requestor-app/esp32/main/main.cpp b/examples/ota-requestor-app/esp32/main/main.cpp index ba9ed616b05e5f..4b3c4d7a331339 100644 --- a/examples/ota-requestor-app/esp32/main/main.cpp +++ b/examples/ota-requestor-app/esp32/main/main.cpp @@ -27,6 +27,7 @@ #include "freertos/FreeRTOS.h" #include "freertos/task.h" #include "nvs_flash.h" +#include #include #include #include @@ -65,6 +66,9 @@ constexpr EndpointId kNetworkCommissioningEndpointSecondary = 0xFFFE; static void InitServer(intptr_t context) { + // Print QR Code URL + PrintOnboardingCodes(chip::RendezvousInformationFlags(CONFIG_RENDEZVOUS_MODE)); + Esp32AppServer::Init(); // Init ZCL Data Model and CHIP App Server AND Initialize device attestation config // We only have network commissioning on endpoint 0. diff --git a/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.matter b/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.matter index db07bab0b0a735..52ef6e1109a4ef 100644 --- a/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.matter +++ b/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.matter @@ -981,7 +981,7 @@ server cluster UserLabel = 65 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Descriptor { @@ -1131,7 +1131,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 259; + device type anonymousEndpointType = 259, version 1; server cluster Identify { ram attribute identifyTime; @@ -1169,7 +1169,7 @@ endpoint 1 { } } endpoint 65534 { - device type anonymousEndpointType = 61442; + device type anonymousEndpointType = 61442, version 1; server cluster Descriptor { callback attribute deviceTypeList; diff --git a/examples/ota-requestor-app/telink/CMakeLists.txt b/examples/ota-requestor-app/telink/CMakeLists.txt index c30aa60e529cdb..6b634ce3eb5dbc 100644 --- a/examples/ota-requestor-app/telink/CMakeLists.txt +++ b/examples/ota-requestor-app/telink/CMakeLists.txt @@ -18,7 +18,6 @@ cmake_minimum_required(VERSION 3.13.1) set(BOARD tlsr9518adk80d) get_filename_component(CHIP_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/third_party/connectedhomeip REALPATH) -get_filename_component(NLIO_ROOT ${CHIP_ROOT}/third_party/nlio/repo/include REALPATH) get_filename_component(TELINK_COMMON ${CHIP_ROOT}/examples/platform/telink REALPATH) get_filename_component(GEN_DIR ${CHIP_ROOT}/zzz_generated/ REALPATH) @@ -39,7 +38,6 @@ target_include_directories(app PRIVATE include ${GEN_DIR}/app-common ${GEN_DIR}/ota-requestor-app - ${NLIO_ROOT} ${TELINK_COMMON}/util/include ${TELINK_COMMON}/app/include) diff --git a/examples/ota-requestor-app/telink/include/CHIPProjectConfig.h b/examples/ota-requestor-app/telink/include/CHIPProjectConfig.h index 9cfa65977d1717..2fda70c57da9dc 100644 --- a/examples/ota-requestor-app/telink/include/CHIPProjectConfig.h +++ b/examples/ota-requestor-app/telink/include/CHIPProjectConfig.h @@ -31,18 +31,9 @@ #define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE 20202021 #define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR 0xF00 -/** - * CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE - * - * Enable support for Chip-over-BLE (CHIPoBLE). - */ -#define CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE 1 - /** * CHIP_SYSTEM_CONFIG_PACKETBUFFER_POOL_SIZE * * Reduce packet buffer pool size to 8 (default 15) to reduce ram consumption */ #define CHIP_SYSTEM_CONFIG_PACKETBUFFER_POOL_SIZE 8 - -#define CHIP_DEVICE_CONFIG_ENABLE_EXTENDED_DISCOVERY 1 diff --git a/examples/ota-requestor-app/telink/prj.conf b/examples/ota-requestor-app/telink/prj.conf index 7f270da20b8e5f..c801f50ac570a7 100755 --- a/examples/ota-requestor-app/telink/prj.conf +++ b/examples/ota-requestor-app/telink/prj.conf @@ -30,7 +30,6 @@ CONFIG_OPENTHREAD_PANID=4660 CONFIG_OPENTHREAD_CHANNEL=15 CONFIG_OPENTHREAD_NETWORK_NAME="OpenThreadDemo" CONFIG_OPENTHREAD_XPANID="11:11:11:11:22:22:22:22" -CONFIG_NET_CONFIG_IEEE802154_DEV_NAME="IEEE802154_b91" # Disable Matter OTA DFU CONFIG_CHIP_OTA_REQUESTOR=y diff --git a/examples/ota-requestor-app/telink/src/AppTask.cpp b/examples/ota-requestor-app/telink/src/AppTask.cpp index 314e228772899b..9c8bb471a4317b 100644 --- a/examples/ota-requestor-app/telink/src/AppTask.cpp +++ b/examples/ota-requestor-app/telink/src/AppTask.cpp @@ -31,7 +31,6 @@ #include #include -#include #include #include diff --git a/examples/persistent-storage/efr32/include/CHIPProjectConfig.h b/examples/persistent-storage/efr32/include/CHIPProjectConfig.h index 4502afd537724f..24733d37871d5b 100644 --- a/examples/persistent-storage/efr32/include/CHIPProjectConfig.h +++ b/examples/persistent-storage/efr32/include/CHIPProjectConfig.h @@ -64,16 +64,6 @@ */ #define CHIP_DEVICE_CONFIG_DEVICE_HARDWARE_VERSION 1 -/** - * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING - * - * A string identifying the software version running on the device. - * CHIP service currently expects the software version to be in the format - * {MAJOR_VERSION}.0d{MINOR_VERSION} - */ -#ifndef CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING -#define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING "0.1ALPHA" -#endif /** * CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE * diff --git a/examples/pigweed-app/efr32/include/CHIPProjectConfig.h b/examples/pigweed-app/efr32/include/CHIPProjectConfig.h index 9c6a21703649ac..6af96beac88f4a 100644 --- a/examples/pigweed-app/efr32/include/CHIPProjectConfig.h +++ b/examples/pigweed-app/efr32/include/CHIPProjectConfig.h @@ -63,17 +63,6 @@ */ #define CHIP_DEVICE_CONFIG_DEVICE_HARDWARE_VERSION 1 -/** - * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING - * - * A string identifying the software version running on the device. - * CHIP service currently expects the software version to be in the format - * {MAJOR_VERSION}.0d{MINOR_VERSION} - */ -#ifndef CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING -#define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING "0.1ALPHA" -#endif - /** * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION * diff --git a/examples/pigweed-app/esp32/CMakeLists.txt b/examples/pigweed-app/esp32/CMakeLists.txt index 81aa021ac5d815..08d38727e94e1b 100644 --- a/examples/pigweed-app/esp32/CMakeLists.txt +++ b/examples/pigweed-app/esp32/CMakeLists.txt @@ -47,6 +47,10 @@ set(PIGWEED_ROOT "${CHIP_ROOT}/third_party/pigweed/repo") include(${PIGWEED_ROOT}/pw_build/pigweed.cmake) include(${PIGWEED_ROOT}/pw_protobuf_compiler/proto.cmake) +include($ENV{PW_ROOT}/pw_assert/backend.cmake) +include($ENV{PW_ROOT}/pw_log/backend.cmake) +include($ENV{PW_ROOT}/pw_sys_io/backend.cmake) +include($ENV{PW_ROOT}/pw_trace/backend.cmake) pw_set_module_config(pw_rpc_CONFIG pw_rpc.disable_global_mutex_config) pw_set_backend(pw_log pw_log_basic) diff --git a/examples/placeholder/linux/apps/app1/config.matter b/examples/placeholder/linux/apps/app1/config.matter index f6d04ad8886a5a..1298138f97d403 100644 --- a/examples/placeholder/linux/apps/app1/config.matter +++ b/examples/placeholder/linux/apps/app1/config.matter @@ -1161,7 +1161,7 @@ client cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1210,7 +1210,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -2618,7 +2618,7 @@ server cluster ApplicationBasic = 1293 { } endpoint 0 { - device type anonymousEndpointType = 65280; + device type anonymousEndpointType = 65280, version 1; binding cluster OnOff; binding cluster GeneralCommissioning; binding cluster Switch; @@ -3036,7 +3036,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 258; + device type anonymousEndpointType = 258, version 1; binding cluster OnOff; server cluster Identify { diff --git a/examples/placeholder/linux/apps/app2/config.matter b/examples/placeholder/linux/apps/app2/config.matter index f6d04ad8886a5a..1298138f97d403 100644 --- a/examples/placeholder/linux/apps/app2/config.matter +++ b/examples/placeholder/linux/apps/app2/config.matter @@ -1161,7 +1161,7 @@ client cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -1210,7 +1210,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -2618,7 +2618,7 @@ server cluster ApplicationBasic = 1293 { } endpoint 0 { - device type anonymousEndpointType = 65280; + device type anonymousEndpointType = 65280, version 1; binding cluster OnOff; binding cluster GeneralCommissioning; binding cluster Switch; @@ -3036,7 +3036,7 @@ endpoint 0 { } } endpoint 1 { - device type anonymousEndpointType = 258; + device type anonymousEndpointType = 258, version 1; binding cluster OnOff; server cluster Identify { diff --git a/examples/platform/ameba/pw_sys_io/CMakeLists.txt b/examples/platform/ameba/pw_sys_io/CMakeLists.txt index c0ff32a9f695cb..04bc802eda0eb8 100644 --- a/examples/platform/ameba/pw_sys_io/CMakeLists.txt +++ b/examples/platform/ameba/pw_sys_io/CMakeLists.txt @@ -1,11 +1,9 @@ include($ENV{PW_ROOT}/pw_build/pigweed.cmake) # This is compiled in gn build, just provide headers and let linker sort it out. -pw_add_module_library(pw_sys_io.ameba - SOURCES +pw_add_library(pw_sys_io.ameba INTERFACE PRIVATE_DEPS pw_sys_io HEADERS public ) - diff --git a/examples/platform/beken/common/CommonDeviceCallbacks.cpp b/examples/platform/beken/common/CommonDeviceCallbacks.cpp index 23677ad7342406..990c381cfe2df6 100644 --- a/examples/platform/beken/common/CommonDeviceCallbacks.cpp +++ b/examples/platform/beken/common/CommonDeviceCallbacks.cpp @@ -18,7 +18,6 @@ #include "CommonDeviceCallbacks.h" #include -#include #include #include #include diff --git a/examples/platform/bouffalolab/common/toolchain/riscv_toolchain.gni b/examples/platform/bouffalolab/common/toolchain/riscv_toolchain.gni index d382cb3179ee66..db46fc1a98f4fa 100644 --- a/examples/platform/bouffalolab/common/toolchain/riscv_toolchain.gni +++ b/examples/platform/bouffalolab/common/toolchain/riscv_toolchain.gni @@ -23,9 +23,9 @@ template("riscv_toolchain") { _tool_name_root = "" if ("linux" == host_os) { - _tool_name_root = "${root_build_dir}/../../${bouffalolab_toolchain}/Linux/bin/riscv64-unknown-elf-" + _tool_name_root = "${bouffalolab_sdk_root}/toolchain/riscv/Linux/bin/riscv64-unknown-elf-" } else if ("mac" == host_os || "darwin" == host_os) { - _tool_name_root = "${root_build_dir}/../../${bouffalolab_toolchain}/Darwin/bin/riscv64-unknown-elf-" + _tool_name_root = "${bouffalolab_sdk_root}/toolchain/riscv/Darwin/bin/riscv64-unknown-elf-" } ar = _tool_name_root + "ar" diff --git a/examples/platform/esp32/common/CommonDeviceCallbacks.cpp b/examples/platform/esp32/common/CommonDeviceCallbacks.cpp index 081c591fb4e670..929fc26052f801 100644 --- a/examples/platform/esp32/common/CommonDeviceCallbacks.cpp +++ b/examples/platform/esp32/common/CommonDeviceCallbacks.cpp @@ -32,7 +32,6 @@ #include "esp_log.h" #include "route_hook/esp_route_hook.h" #include -#include #include #include #include diff --git a/examples/platform/esp32/pw_sys_io/CMakeLists.txt b/examples/platform/esp32/pw_sys_io/CMakeLists.txt index 2ca42f77764a91..7002fb633d5b23 100644 --- a/examples/platform/esp32/pw_sys_io/CMakeLists.txt +++ b/examples/platform/esp32/pw_sys_io/CMakeLists.txt @@ -1,8 +1,7 @@ include($ENV{PW_ROOT}/pw_build/pigweed.cmake) # This is compiled in gn build, just provide headers and let linker sort it out. -pw_add_module_library(pw_sys_io.esp32 - SOURCES +pw_add_library(pw_sys_io.esp32 INTERFACE PRIVATE_DEPS pw_sys_io HEADERS diff --git a/examples/platform/linux/BUILD.gn b/examples/platform/linux/BUILD.gn index 605c19860db9b1..08580aad33c1f5 100644 --- a/examples/platform/linux/BUILD.gn +++ b/examples/platform/linux/BUILD.gn @@ -70,6 +70,7 @@ source_set("app-main") { "${chip_root}/src/lib", "${chip_root}/src/lib/shell", "${chip_root}/src/lib/shell:shell_core", + "${chip_root}/src/platform/logging:force_stdio", ] if (chip_enable_transport_trace) { diff --git a/examples/platform/mt793x/link_wrapper.c b/examples/platform/mt793x/link_wrapper.c index 2b741940828196..134a372a7cacaa 100644 --- a/examples/platform/mt793x/link_wrapper.c +++ b/examples/platform/mt793x/link_wrapper.c @@ -58,6 +58,14 @@ void __assert_func(const char * file, int line, const char * func, const char * #include #include +void * __wrap__calloc_r(size_t nmemb, size_t size) +{ + void * p = pvPortCalloc(nmemb, size); + while (!p) + ; + return p; +} + void * __wrap__malloc_r(void * REENT, size_t size) { void * p = pvPortMalloc(size); diff --git a/examples/platform/nrfconnect/pw_sys_io/CMakeLists.txt b/examples/platform/nrfconnect/pw_sys_io/CMakeLists.txt index 9e3a33c158b099..329a95cc7ff8cc 100644 --- a/examples/platform/nrfconnect/pw_sys_io/CMakeLists.txt +++ b/examples/platform/nrfconnect/pw_sys_io/CMakeLists.txt @@ -8,9 +8,11 @@ target_compile_options(suppress_zephyr_warnings INTERFACE -Wno-undef ) -pw_add_module_library(pw_sys_io.nrfconnect +pw_add_library(pw_sys_io.nrfconnect STATIC SOURCES sys_io_nrfconnect.cc + PUBLIC_INCLUDES + public PRIVATE_DEPS pw_sys_io suppress_zephyr_warnings diff --git a/examples/platform/openiotsdk/app/CMakeLists.txt b/examples/platform/openiotsdk/app/CMakeLists.txt new file mode 100644 index 00000000000000..191409ac8c815c --- /dev/null +++ b/examples/platform/openiotsdk/app/CMakeLists.txt @@ -0,0 +1,35 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +cmake_minimum_required(VERSION 3.21) + +# Declare Open IoT SDK app interface target +add_library(openiotsdk-app + openiotsdk_platform.cpp + ${CHIP_ROOT}/examples/providers/DeviceInfoProviderImpl.cpp +) + +target_include_directories(openiotsdk-app + PUBLIC + . + ${CHIP_ROOT}/examples/providers +) + +target_link_libraries(openiotsdk-app + PUBLIC + openiotsdk-chip + cmsis-rtos-implementation +) diff --git a/examples/platform/openiotsdk/app/openiotsdk_platform.cpp b/examples/platform/openiotsdk/app/openiotsdk_platform.cpp new file mode 100644 index 00000000000000..18ca62d06b4ac2 --- /dev/null +++ b/examples/platform/openiotsdk/app/openiotsdk_platform.cpp @@ -0,0 +1,218 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * This file provides the common Open IoT SDK platform functions. + * It can be used in Matter examples implementation. + */ + +#include "openiotsdk_platform.h" + +#include "cmsis_os2.h" +#include "iotsdk/ip_network_api.h" +#include "mbedtls/platform.h" + +#include +#include +#include +#include +#include +#include + +using namespace ::chip; +using namespace ::chip::Platform; +using namespace ::chip::DeviceLayer; + +#define NETWORK_UP_FLAG 0x00000001U +#define NETWORK_DOWN_FLAG 0x00000002U +#define ALL_EVENTS_FLAGS (NETWORK_UP_FLAG | NETWORK_DOWN_FLAG) + +#define EVENT_TIMEOUT 5000 + +static osEventFlagsId_t event_flags_id; + +static DeviceLayer::DeviceInfoProviderImpl gDeviceInfoProvider; + +/** Wait for specific event and check error */ +static int wait_for_event(uint32_t event) +{ + int res = EXIT_SUCCESS; + int ret = osEventFlagsWait(event_flags_id, ALL_EVENTS_FLAGS, osFlagsWaitAny, ms2tick(EVENT_TIMEOUT)); + if (ret < 0) + { + ChipLogError(NotSpecified, "osEventFlagsWait failed %d", ret); + return EXIT_FAILURE; + } + + if (!(ret & event)) + { + res = EXIT_FAILURE; + } + + ret = osEventFlagsClear(event_flags_id, ALL_EVENTS_FLAGS); + if (ret < 0) + { + ChipLogError(NotSpecified, "osEventFlagsClear failed %d", ret); + return EXIT_FAILURE; + } + + return res; +} + +static void post_network_connect() +{ + // Iterate on the network interface to see if we already have beed assigned addresses. + for (chip::Inet::InterfaceAddressIterator it; it.HasCurrent(); it.Next()) + { + char ifName[chip::Inet::InterfaceId::kMaxIfNameLength]; + if (it.IsUp() && CHIP_NO_ERROR == it.GetInterfaceName(ifName, sizeof(ifName))) + { + chip::Inet::IPAddress addr; + if ((it.GetAddress(addr) == CHIP_NO_ERROR)) + { + char ipStrBuf[chip::Inet::IPAddress::kMaxStringLength] = { 0 }; + addr.ToString(ipStrBuf); + + ChipLogProgress(DeviceLayer, "Got IP address on interface: %s IP: %s", ifName, ipStrBuf); + } + } + } +} + +/** This callback is called by the ip network task. It translates from a network event code + * to platform event and sends it. + * + * @param event network up or down event. + */ +static void network_state_callback(network_state_callback_event_t event) +{ + uint32_t event_flag = (event == NETWORK_UP) ? NETWORK_UP_FLAG : NETWORK_DOWN_FLAG; + ChipLogDetail(NotSpecified, "Network %s", (event == NETWORK_UP) ? "UP" : "DOWN"); + int res = osEventFlagsSet(event_flags_id, event_flag); + if (res < 0) + { + ChipLogError(NotSpecified, "osEventFlagsSet failed %d", res); + } +} + +int openiotsdk_platform_init(void) +{ + int ret; + osKernelState_t state; + + ret = mbedtls_platform_setup(NULL); + if (ret) + { + ChipLogError(NotSpecified, "Mbed TLS platform initialization failed: %d", ret); + return EXIT_FAILURE; + } + + ret = osKernelInitialize(); + if (ret != osOK) + { + ChipLogError(NotSpecified, "osKernelInitialize failed: %d", ret); + return EXIT_FAILURE; + } + + state = osKernelGetState(); + if (state != osKernelReady) + { + ChipLogError(NotSpecified, "Kernel not ready: %d", state); + return EXIT_FAILURE; + } + + return EXIT_SUCCESS; +} + +int openiotsdk_chip_init(void) +{ + CHIP_ERROR err; + +#if NDEBUG + chip::Logging::SetLogFilter(chip::Logging::LogCategory::kLogCategory_Progress); +#endif + + err = MemoryInit(); + if (err != CHIP_NO_ERROR) + { + ChipLogError(NotSpecified, "Memory initialization failed: %s", err.AsString()); + return EXIT_FAILURE; + } + + err = PlatformMgr().InitChipStack(); + if (err != CHIP_NO_ERROR) + { + ChipLogError(NotSpecified, "Chip stack initialization failed: %s", err.AsString()); + return EXIT_FAILURE; + } + + err = PlatformMgr().StartEventLoopTask(); + if (err != CHIP_NO_ERROR) + { + ChipLogError(NotSpecified, "Chip stack start failed: %s", err.AsString()); + return EXIT_FAILURE; + } + + DeviceLayer::SetDeviceInfoProvider(&gDeviceInfoProvider); + + return EXIT_SUCCESS; +} + +int openiotsdk_platform_run(void) +{ + int ret = osKernelStart(); + if (ret != osOK) + { + ChipLogError(NotSpecified, "Failed to start kernel: %d", ret); + return EXIT_FAILURE; + } + + return EXIT_SUCCESS; +} + +int openiotsdk_network_init(bool wait) +{ + int ret; + + event_flags_id = osEventFlagsNew(NULL); + if (event_flags_id == NULL) + { + ChipLogError(NotSpecified, "Create event flags failed"); + return EXIT_FAILURE; + } + + ret = start_network_task(network_state_callback, NETWORK_THREAD_STACK_SIZE_DEFAULT); + if (ret != osOK) + { + ChipLogError(NotSpecified, "start_network_task failed %d", ret); + return EXIT_FAILURE; + } + + if (wait) + { + if (wait_for_event(NETWORK_UP_FLAG) != EXIT_SUCCESS) + { + ChipLogError(NotSpecified, "Network initialization failed"); + return EXIT_FAILURE; + } + post_network_connect(); + } + + return EXIT_SUCCESS; +} diff --git a/examples/platform/openiotsdk/app/openiotsdk_platform.h b/examples/platform/openiotsdk/app/openiotsdk_platform.h new file mode 100644 index 00000000000000..5dee7b82c7049d --- /dev/null +++ b/examples/platform/openiotsdk/app/openiotsdk_platform.h @@ -0,0 +1,69 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * This file provides the common Open IoT SDK platform functions. + * It can be used in Matter examples implementation. + */ + +#ifndef OPENIOTSDK_PLATFORM_H +#define OPENIOTSDK_PLATFORM_H + +#include +#include + +// Default stack size for network thread (8kB) +#define NETWORK_THREAD_STACK_SIZE_DEFAULT (8 * 1024) + +/** + * @brief Initialise the Open IoT SDK platform + * Mbedtls platform setup + * OS kernel initialization and check + * + * @return EXIT_SUCCESS or EXIT_FAILURE + */ +int openiotsdk_platform_init(void); + +/** + * @brief Initialise the CHIP sources + * Platform memory and CHIP stack initialization + * Start CHIP event loop task + * + * @return EXIT_SUCCESS or EXIT_FAILURE + */ +int openiotsdk_chip_init(void); + +/** + * @brief Run the Open IoT SDK platform + * Start the OS kernel + * + * @return EXIT_SUCCESS or EXIT_FAILURE + */ +int openiotsdk_platform_run(void); + +/** + * @brief Initialise the Open IoT SDK network + * Run the network task and wait for newtork up + * + * @param wait Wait for network up + * @return EXIT_SUCCESS or EXIT_FAILURE + */ +int openiotsdk_network_init(bool wait); + +#endif /* ! OPENIOTSDK_PLATFORM_H */ diff --git a/examples/platform/qpg/project_include/OpenThreadConfig.h b/examples/platform/qpg/project_include/OpenThreadConfig.h index 9cdf83d93b596b..90b9f33d209e1d 100644 --- a/examples/platform/qpg/project_include/OpenThreadConfig.h +++ b/examples/platform/qpg/project_include/OpenThreadConfig.h @@ -48,12 +48,6 @@ // Enable use of external heap allocator (calloc/free) for OpenThread. #define OPENTHREAD_CONFIG_HEAP_EXTERNAL_ENABLE 1 -#if CHIP_DEVICE_CONFIG_THREAD_FTD -#define OPENTHREAD_CONFIG_NUM_MESSAGE_BUFFERS 44 -#else -#define OPENTHREAD_CONFIG_NUM_MESSAGE_BUFFERS 22 -#endif - // Limit CLI buffers #define OPENTHREAD_CONFIG_CLI_UART_RX_BUFFER_SIZE 384 #define OPENTHREAD_CONFIG_CLI_UART_TX_BUFFER_SIZE 512 diff --git a/examples/platform/silabs/SiWx917/BUILD.gn b/examples/platform/silabs/SiWx917/BUILD.gn new file mode 100644 index 00000000000000..990a43d59d66c7 --- /dev/null +++ b/examples/platform/silabs/SiWx917/BUILD.gn @@ -0,0 +1,94 @@ +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/chip.gni") +import("//build_overrides/efr32_sdk.gni") +import("${chip_root}/src/lib/lib.gni") +import("${chip_root}/src/platform/device.gni") +import("${efr32_sdk_build_root}/SiWx917_sdk.gni") + +config("chip_examples_project_config") { + include_dirs = [ "project_include" ] + + # Link options that provide a replacement for dynamic memory operations in standard + # library with the FreeRTOS malloc in platform code. + ldflags = [ + # memory allocation -- these must be re-entrant and do locking + "-Wl,--wrap=malloc", + "-Wl,--wrap=free", + "-Wl,--wrap=realloc", + "-Wl,--wrap=calloc", + "-Wl,--wrap=MemoryAlloc", + + # Wrap these in case internal newlib call them (e.g. strdup will) + # directly call _malloc_r) + "-Wl,--wrap=_malloc_r", + "-Wl,--wrap=_realloc_r", + "-Wl,--wrap=_free_r", + "-Wl,--wrap=_calloc_r", + ] +} + +source_set("efr-matter-shell") { + if (chip_build_libshell) { + defines = [ "ENABLE_CHIP_SHELL" ] + + sources = [ "matter_shell.cpp" ] + include_dirs = [ "." ] + + public_deps = [ + "${chip_root}/examples/shell/shell_common:shell_common", + "${chip_root}/src/lib/shell:shell", + "${chip_root}/src/lib/shell:shell_core", + ] + } +} + +config("attestation-credentials-config") { + include_dirs = [ "${chip_root}" ] + + defines = [ + # Set to 1 to enable SI917 attestation credentials + "SI917_ATTESTATION_CREDENTIALS", + ] +} + +source_set("efr32-attestation-credentials") { + sources = [ + "../SilabsDeviceAttestationCreds.cpp", + "../SilabsDeviceAttestationCreds.h", + ] + + public_deps = [ + "${chip_root}/src/credentials", + "${chip_root}/src/platform:platform_base", + ] + + public_configs = [ ":attestation-credentials-config" ] +} + +source_set("efr32-factory-data-provider") { + sources = [ + "SiWx917DeviceDataProvider.cpp", + "SiWx917DeviceDataProvider.h", + ] + + public_deps = [ + "${chip_root}/src/credentials", + "${chip_root}/src/platform:platform_base", + "${chip_root}/src/setup_payload", + ] + + #public_configs = [ "" ] +} diff --git a/examples/platform/silabs/SiWx917/BaseApplication.cpp b/examples/platform/silabs/SiWx917/BaseApplication.cpp new file mode 100644 index 00000000000000..b401c1825578f6 --- /dev/null +++ b/examples/platform/silabs/SiWx917/BaseApplication.cpp @@ -0,0 +1,407 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2019 Google LLC. + * 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. + */ + +/********************************************************** + * Includes + *********************************************************/ + +#include "AppConfig.h" +#include "AppEvent.h" +#include "AppTask.h" + +#ifdef DISPLAY_ENABLED +#include "lcd.h" +#ifdef QR_CODE_ENABLED +#include "qrcodegen.h" +#endif // QR_CODE_ENABLED +#endif // DISPLAY_ENABLED + +#include "SiWx917DeviceDataProvider.h" +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#ifdef SL_WIFI +#include "wfx_host_events.h" +#include +#include +#endif // SL_WIFI + +/********************************************************** + * Defines and Constants + *********************************************************/ + +#define FACTORY_RESET_TRIGGER_TIMEOUT 3000 +#define FACTORY_RESET_CANCEL_WINDOW_TIMEOUT 3000 +#ifndef APP_TASK_STACK_SIZE +#define APP_TASK_STACK_SIZE (4096) +#endif +#define APP_TASK_PRIORITY 2 +#define APP_EVENT_QUEUE_SIZE 10 +#define EXAMPLE_VENDOR_ID 0xcafe + +using namespace chip; +using namespace ::chip::DeviceLayer; + +namespace { + +/********************************************************** + * Variable declarations + *********************************************************/ + +TimerHandle_t sFunctionTimer; // FreeRTOS app sw timer. +TimerHandle_t sLightTimer; + +TaskHandle_t sAppTaskHandle; +QueueHandle_t sAppEventQueue; + +#ifdef SL_WIFI +app::Clusters::NetworkCommissioning::Instance + sWiFiNetworkCommissioningInstance(0 /* Endpoint Id */, &(NetworkCommissioning::SlWiFiDriver::GetInstance())); +#endif /* SL_WIFI */ + +#if !(defined(CHIP_DEVICE_CONFIG_ENABLE_SED) && CHIP_DEVICE_CONFIG_ENABLE_SED) + +bool sIsProvisioned = false; +bool sIsEnabled = false; +bool sIsAttached = false; +bool sHaveBLEConnections = false; + +#endif // CHIP_DEVICE_CONFIG_ENABLE_SED + +EmberAfIdentifyEffectIdentifier sIdentifyEffect = EMBER_ZCL_IDENTIFY_EFFECT_IDENTIFIER_STOP_EFFECT; + +uint8_t sAppEventQueueBuffer[APP_EVENT_QUEUE_SIZE * sizeof(AppEvent)]; +StaticQueue_t sAppEventQueueStruct; + +StackType_t appStack[APP_TASK_STACK_SIZE / sizeof(StackType_t)]; +StaticTask_t appTaskStruct; + +BaseApplication::Function_t mFunction; +bool mFunctionTimerActive; + +Identify * gIdentifyptr = nullptr; + +#ifdef DISPLAY_ENABLED +SilabsLCD slLCD; +#endif + +} // namespace + +/********************************************************** + * AppTask Definitions + *********************************************************/ + +CHIP_ERROR BaseApplication::StartAppTask(TaskFunction_t taskFunction) +{ + sAppEventQueue = xQueueCreateStatic(APP_EVENT_QUEUE_SIZE, sizeof(AppEvent), sAppEventQueueBuffer, &sAppEventQueueStruct); + if (sAppEventQueue == NULL) + { + SILABS_LOG("Failed to allocate app event queue"); + appError(APP_ERROR_EVENT_QUEUE_FAILED); + } + + // Start App task. + sAppTaskHandle = + xTaskCreateStatic(taskFunction, APP_TASK_NAME, ArraySize(appStack), &sAppEventQueue, 1, appStack, &appTaskStruct); + if (sAppTaskHandle == nullptr) + { + SILABS_LOG("Failed to create app task"); + appError(APP_ERROR_CREATE_TASK_FAILED); + } + return CHIP_NO_ERROR; +} + +CHIP_ERROR BaseApplication::Init(Identify * identifyObj) +{ + CHIP_ERROR err = CHIP_NO_ERROR; + + if (identifyObj == nullptr) + { + SILABS_LOG("Invalid Identify Object!"); + appError(CHIP_ERROR_INVALID_ARGUMENT); + } + + gIdentifyptr = identifyObj; + +#ifdef SL_WIFI + /* + * Wait for the WiFi to be initialized + */ + SILABS_LOG("APP: Wait WiFi Init"); + while (!wfx_hw_ready()) + { + vTaskDelay(10); + } + SILABS_LOG("APP: Done WiFi Init"); + /* We will init server when we get IP */ + + sWiFiNetworkCommissioningInstance.Init(); +#endif + + // Create FreeRTOS sw timer for Function Selection. + sFunctionTimer = xTimerCreate("FnTmr", // Just a text name, not used by the RTOS kernel + 1, // == default timer period (mS) + false, // no timer reload (==one-shot) + (void *) this, // init timer id = app task obj context + FunctionTimerEventHandler // timer callback handler + ); + if (sFunctionTimer == NULL) + { + SILABS_LOG("funct timer create failed"); + appError(APP_ERROR_CREATE_TIMER_FAILED); + } + + // Create FreeRTOS sw timer for LED Management. + sLightTimer = xTimerCreate("LightTmr", // Text Name + 10, // Default timer period (mS) + true, // reload timer + (void *) this, // Timer Id + LightTimerEventHandler // Timer callback handler + ); + if (sLightTimer == NULL) + { + SILABS_LOG("Light Timer create failed"); + appError(APP_ERROR_CREATE_TIMER_FAILED); + } + + SILABS_LOG("Current Software Version: %s", CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING); + + ConfigurationMgr().LogDeviceConfig(); + + // Create buffer for QR code that can fit max size and null terminator. + char qrCodeBuffer[chip::QRCodeBasicSetupPayloadGenerator::kMaxQRCodeBase38RepresentationLength + 1]; + chip::MutableCharSpan QRCode(qrCodeBuffer); + + if (EFR32::EFR32DeviceDataProvider::GetDeviceDataProvider().GetSetupPayload(QRCode) == CHIP_NO_ERROR) + { + // Print setup info on LCD if available +#ifdef QR_CODE_ENABLED + slLCD.SetQRCode((uint8_t *) QRCode.data(), QRCode.size()); + slLCD.ShowQRCode(true, true); +#else + PrintQrCodeURL(QRCode); +#endif // QR_CODE_ENABLED + } + else + { + SILABS_LOG("Getting QR code failed!"); + } + + return err; +} + +void BaseApplication::FunctionTimerEventHandler(TimerHandle_t xTimer) +{ + AppEvent event; + event.Type = AppEvent::kEventType_Timer; + event.TimerEvent.Context = (void *) xTimer; + event.Handler = FunctionEventHandler; + PostEvent(&event); +} + +void BaseApplication::FunctionEventHandler(AppEvent * aEvent) +{ + if (aEvent->Type != AppEvent::kEventType_Timer) + { + return; + } + + // If we reached here, the button was held past FACTORY_RESET_TRIGGER_TIMEOUT, + // initiate factory reset + if (mFunctionTimerActive && mFunction == kFunction_StartBleAdv) + { + SILABS_LOG("Factory Reset Triggered. Release button within %ums to cancel.", FACTORY_RESET_CANCEL_WINDOW_TIMEOUT); + + // Start timer for FACTORY_RESET_CANCEL_WINDOW_TIMEOUT to allow user to + // cancel, if required. + StartFunctionTimer(FACTORY_RESET_CANCEL_WINDOW_TIMEOUT); + +#if CHIP_DEVICE_CONFIG_ENABLE_SED == 1 + StartStatusLEDTimer(); +#endif // CHIP_DEVICE_CONFIG_ENABLE_SED + + mFunction = kFunction_FactoryReset; + } + else if (mFunctionTimerActive && mFunction == kFunction_FactoryReset) + { + // Actually trigger Factory Reset + mFunction = kFunction_NoneSelected; + +#if CHIP_DEVICE_CONFIG_ENABLE_SED == 1 + StopStatusLEDTimer(); +#endif // CHIP_DEVICE_CONFIG_ENABLE_SED + + chip::Server::GetInstance().ScheduleFactoryReset(); + } +} + +void BaseApplication::LightEventHandler() +{ + // Collect connectivity and configuration state from the CHIP stack. Because + // the CHIP event loop is being run in a separate task, the stack must be + // locked while these values are queried. However we use a non-blocking + // lock request (TryLockCHIPStack()) to avoid blocking other UI activities + // when the CHIP task is busy (e.g. with a long crypto operation). +#if !(defined(CHIP_DEVICE_CONFIG_ENABLE_SED) && CHIP_DEVICE_CONFIG_ENABLE_SED) + if (PlatformMgr().TryLockChipStack()) + { +#ifdef SL_WIFI + sIsProvisioned = ConnectivityMgr().IsWiFiStationProvisioned(); + sIsEnabled = ConnectivityMgr().IsWiFiStationEnabled(); + sIsAttached = ConnectivityMgr().IsWiFiStationConnected(); +#endif /* SL_WIFI */ +#if CHIP_ENABLE_OPENTHREAD + sIsProvisioned = ConnectivityMgr().IsThreadProvisioned(); + sIsEnabled = ConnectivityMgr().IsThreadEnabled(); + sIsAttached = ConnectivityMgr().IsThreadAttached(); +#endif /* CHIP_ENABLE_OPENTHREAD */ + sHaveBLEConnections = (ConnectivityMgr().NumBLEConnections() != 0); + PlatformMgr().UnlockChipStack(); + } +#endif // CHIP_DEVICE_CONFIG_ENABLE_SED + + // Update the status LED if factory reset has not been initiated. + // + // If system has "full connectivity", keep the LED On constantly. + // + // If thread and service provisioned, but not attached to the thread network + // yet OR no connectivity to the service OR subscriptions are not fully + // established THEN blink the LED Off for a short period of time. + // + // If the system has ble connection(s) uptill the stage above, THEN blink + // the LEDs at an even rate of 100ms. + // + // Otherwise, blink the LED ON for a very short time. +} + +void BaseApplication::CancelFunctionTimer() +{ + if (xTimerStop(sFunctionTimer, 0) == pdFAIL) + { + SILABS_LOG("app timer stop() failed"); + appError(APP_ERROR_STOP_TIMER_FAILED); + } + + mFunctionTimerActive = false; +} + +void BaseApplication::StartFunctionTimer(uint32_t aTimeoutInMs) +{ + if (xTimerIsTimerActive(sFunctionTimer)) + { + SILABS_LOG("app timer already started!"); + CancelFunctionTimer(); + } + + // timer is not active, change its period to required value (== restart). + // FreeRTOS- Block for a maximum of 100 ticks if the change period command + // cannot immediately be sent to the timer command queue. + if (xTimerChangePeriod(sFunctionTimer, aTimeoutInMs / portTICK_PERIOD_MS, 100) != pdPASS) + { + SILABS_LOG("app timer start() failed"); + appError(APP_ERROR_START_TIMER_FAILED); + } + + mFunctionTimerActive = true; +} + +void BaseApplication::StartStatusLEDTimer() +{ + if (pdPASS != xTimerStart(sLightTimer, 0)) + { + SILABS_LOG("Light Time start failed"); + appError(APP_ERROR_START_TIMER_FAILED); + } +} + +void BaseApplication::StopStatusLEDTimer() +{ + + if (xTimerStop(sLightTimer, 100) != pdPASS) + { + SILABS_LOG("Light Time start failed"); + appError(APP_ERROR_START_TIMER_FAILED); + } +} + +void BaseApplication::LightTimerEventHandler(TimerHandle_t xTimer) +{ + LightEventHandler(); +} + +#ifdef DISPLAY_ENABLED +SilabsLCD & BaseApplication::GetLCD(void) +{ + return slLCD; +} +#endif + +void BaseApplication::PostEvent(const AppEvent * aEvent) +{ + if (sAppEventQueue != NULL) + { + BaseType_t status; + if (xPortIsInsideInterrupt()) + { + BaseType_t higherPrioTaskWoken = pdFALSE; + status = xQueueSendFromISR(sAppEventQueue, aEvent, &higherPrioTaskWoken); + +#ifdef portYIELD_FROM_ISR + portYIELD_FROM_ISR(higherPrioTaskWoken); +#elif portEND_SWITCHING_ISR // portYIELD_FROM_ISR or portEND_SWITCHING_ISR + portEND_SWITCHING_ISR(higherPrioTaskWoken); +#else // portYIELD_FROM_ISR or portEND_SWITCHING_ISR +#error "Must have portYIELD_FROM_ISR or portEND_SWITCHING_ISR" +#endif // portYIELD_FROM_ISR or portEND_SWITCHING_ISR + } + else + { + status = xQueueSend(sAppEventQueue, aEvent, 1); + } + + if (!status) + { + SILABS_LOG("Failed to post event to app task event queue"); + } + } + else + { + SILABS_LOG("Event Queue is NULL should never happen"); + } +} + +void BaseApplication::DispatchEvent(AppEvent * aEvent) +{ + if (aEvent->Handler) + { + aEvent->Handler(aEvent); + } + else + { + SILABS_LOG("Event received with no handler. Dropping event."); + } +} diff --git a/examples/platform/silabs/SiWx917/BaseApplication.h b/examples/platform/silabs/SiWx917/BaseApplication.h new file mode 100644 index 00000000000000..2c0e07edb35289 --- /dev/null +++ b/examples/platform/silabs/SiWx917/BaseApplication.h @@ -0,0 +1,175 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2019 Google LLC. + * 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 + +/********************************************************** + * Includes + *********************************************************/ + +#include +#include + +#include "AppEvent.h" +#include "FreeRTOS.h" +#include "timers.h" // provides FreeRTOS timer support +#include +#include +#include +#include + +#ifdef DISPLAY_ENABLED +#include "demo-ui.h" +#include "lcd.h" +#ifdef QR_CODE_ENABLED +#include "qrcodegen.h" +#endif // QR_CODE_ENABLED +#endif // DISPLAY_ENABLED + +/********************************************************** + * Defines + *********************************************************/ + +// Application-defined error codes in the CHIP_ERROR space. +#define APP_ERROR_EVENT_QUEUE_FAILED CHIP_APPLICATION_ERROR(0x01) +#define APP_ERROR_CREATE_TASK_FAILED CHIP_APPLICATION_ERROR(0x02) +#define APP_ERROR_UNHANDLED_EVENT CHIP_APPLICATION_ERROR(0x03) +#define APP_ERROR_CREATE_TIMER_FAILED CHIP_APPLICATION_ERROR(0x04) +#define APP_ERROR_START_TIMER_FAILED CHIP_APPLICATION_ERROR(0x05) +#define APP_ERROR_STOP_TIMER_FAILED CHIP_APPLICATION_ERROR(0x06) + +/********************************************************** + * BaseApplication Declaration + *********************************************************/ + +class BaseApplication +{ + +public: + BaseApplication() = default; + virtual ~BaseApplication(){}; + + /** + * @brief Create AppTask task and Event Queue + * If an error occurs during creation, application will hang after printing out error code + * + * @return CHIP_ERROR CHIP_NO_ERROR if no errors + */ + CHIP_ERROR StartAppTask(TaskFunction_t taskFunction); + + /** + * @brief PostEvent function that add event to AppTask queue for processing + * + * @param event AppEvent to post + */ + static void PostEvent(const AppEvent * event); + +#ifdef DISPLAY_ENABLED + /** + * @brief Return LCD object + */ + static SilabsLCD & GetLCD(void); +#endif + + /** + * @brief Function called to start the LED light timer + */ + static void StartStatusLEDTimer(void); + + /** + * @brief Function to stop LED light timer + * Turns off Status LED before stopping timer + */ + static void StopStatusLEDTimer(void); + + enum Function_t + { + kFunction_NoneSelected = 0, + kFunction_SoftwareUpdate = 0, + kFunction_StartBleAdv = 1, + kFunction_FactoryReset = 2, + + kFunction_Invalid + } Function; + +protected: + CHIP_ERROR Init(Identify * identifyObj); + + /** + * @brief Function called to start the function timer + * + * @param aTimeoutMs timer duration in ms + */ + static void StartFunctionTimer(uint32_t aTimeoutMs); + + /** + * @brief Function to stop function timer + */ + static void CancelFunctionTimer(void); + + /** + * @brief Function call event callback function for processing + * + * @param event triggered event to be processed + */ + void DispatchEvent(AppEvent * event); + + /** + * @brief Function Timer finished callback function + * Post an FunctionEventHandler event + * + * @param xTimer timer that finished + */ + static void FunctionTimerEventHandler(TimerHandle_t xTimer); + + /** + * @brief Timer Event processing function + * Trigger factory if Press and Hold duration is respected + * + * @param aEvent post event being processed + */ + static void FunctionEventHandler(AppEvent * aEvent); + + /** + * @brief PB0 Button event processing function + * Press and hold will trigger a factory reset timer start + * Press and release will restart BLEAdvertising if not commisionned + * + * @param aEvent button event being processed + */ + static void ButtonHandler(AppEvent * aEvent); + + /** + * @brief Light Timer finished callback function + * Calls LED processing function + * + * @param xTimer timer that finished + */ + static void LightTimerEventHandler(TimerHandle_t xTimer); + + /** + * @brief Updates device LEDs + */ + static void LightEventHandler(); + + /********************************************************** + * Protected Attributes declaration + *********************************************************/ + bool mSyncClusterToButtonAction; +}; diff --git a/examples/platform/silabs/SiWx917/FreeRTOSConfig.h b/examples/platform/silabs/SiWx917/FreeRTOSConfig.h new file mode 100644 index 00000000000000..02b441ec790272 --- /dev/null +++ b/examples/platform/silabs/SiWx917/FreeRTOSConfig.h @@ -0,0 +1,252 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/*************************************************************************** + * # License + * + * The licensor of this software is Silicon Laboratories Inc. Your use of this + * software is governed by the terms of Silicon Labs Master Software License + * Agreement (MSLA) available at + * www.silabs.com/about-us/legal/master-software-license-agreement. This + * software is Third Party Software licensed by Silicon Labs from a third party + * and is governed by the sections of the MSLA applicable to Third Party + * Software and the additional terms set forth below. + * + ******************************************************************************/ +/* + FreeRTOS V9.0.0 - Copyright (C) 2016 Real Time Engineers Ltd. + All rights reserved + + VISIT http://www.FreeRTOS.org TO ENSURE YOU ARE USING THE LATEST VERSION. + + This file is part of the FreeRTOS distribution. + + FreeRTOS is free software; you can redistribute it and/or modify it under + the terms of the GNU General Public License (version 2) as published by the + Free Software Foundation >>>> AND MODIFIED BY <<<< the FreeRTOS exception. + + *************************************************************************** + >>! NOTE: The modification to the GPL is included to allow you to !<< + >>! distribute a combined work that includes FreeRTOS without being !<< + >>! obliged to provide the source code for proprietary components !<< + >>! outside of the FreeRTOS kernel. !<< + *************************************************************************** + + FreeRTOS is distributed in the hope that it will be useful, but WITHOUT ANY + WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS + FOR A PARTICULAR PURPOSE. Full license text is available on the following + link: http://www.freertos.org/a00114.html + + *************************************************************************** + * * + * FreeRTOS provides completely free yet professionally developed, * + * robust, strictly quality controlled, supported, and cross * + * platform software that is more than just the market leader, it * + * is the industry's de facto standard. * + * * + * Help yourself get started quickly while simultaneously helping * + * to support the FreeRTOS project by purchasing a FreeRTOS * + * tutorial book, reference manual, or both: * + * http://www.FreeRTOS.org/Documentation * + * * + *************************************************************************** + + http://www.FreeRTOS.org/FAQHelp.html - Having a problem? Start by reading + the FAQ page "My application does not run, what could be wrong?". Have you + defined configASSERT()? + + http://www.FreeRTOS.org/support - In return for receiving this top quality + embedded software for free we request you assist our global community by + participating in the support forum. + + http://www.FreeRTOS.org/training - Investing in training allows your team to + be as productive as possible as early as possible. Now you can receive + FreeRTOS training directly from Richard Barry, CEO of Real Time Engineers + Ltd, and the world's leading authority on the world's leading RTOS. + + http://www.FreeRTOS.org/plus - A selection of FreeRTOS ecosystem products, + including FreeRTOS+Trace - an indispensable productivity tool, a DOS + compatible FAT file system, and our tiny thread aware UDP/IP stack. + + http://www.FreeRTOS.org/labs - Where new FreeRTOS products go to incubate. + Come and try FreeRTOS+TCP, our new open source TCP/IP stack for FreeRTOS. + + http://www.OpenRTOS.com - Real Time Engineers ltd. license FreeRTOS to High + Integrity Systems ltd. to sell under the OpenRTOS brand. Low cost OpenRTOS + licenses offer ticketed support, indemnification and commercial middleware. + + http://www.SafeRTOS.com - High Integrity Systems also provide a safety + engineered and independently SIL3 certified version for use in safety and + mission critical applications that require provable dependability. + + 1 tab == 4 spaces! +*/ + +#pragma once + +#ifdef __cplusplus +extern "C" { +#endif + +#include + +#include + +/*----------------------------------------------------------- + * Application specific definitions. + * + * These definitions should be adjusted for your particular hardware and + * application requirements. + * + * THESE PARAMETERS ARE DESCRIBED WITHIN THE 'CONFIGURATION' SECTION OF THE + * FreeRTOS API DOCUMENTATION AVAILABLE ON THE FreeRTOS.org WEB SITE. + * + * See http://www.freertos.org/a00110.html. + *----------------------------------------------------------*/ + +extern uint32_t SystemCoreClock; + +/* Energy saving modes. */ +#if defined(SL_CATALOG_POWER_MANAGER_PRESENT) +#define configUSE_TICKLESS_IDLE 1 +#else +#define configUSE_TICKLESS_IDLE 0 +#endif // SL_CATALOG_POWER_MANAGER_PRESENT + +#define configTICK_RATE_HZ (1000) +/* Definition used by Keil to replace default system clock source. */ +#define configOVERRIDE_DEFAULT_TICK_CONFIGURATION 1 + +/* Hook function related definitions. */ +#define configUSE_TICK_HOOK (1) +#define configCHECK_FOR_STACK_OVERFLOW (2) +#define configUSE_MALLOC_FAILED_HOOK (1) +#define configUSE_IDLE_HOOK (0) + +/* Main functions*/ +/* Run time stats gathering related definitions. */ +#define configGENERATE_RUN_TIME_STATS (0) + +/* Co-routine related definitions. */ +#define configUSE_CO_ROUTINES (0) +#define configMAX_CO_ROUTINE_PRIORITIES (1) + +/* Software timer related definitions. */ +#define configUSE_TIMERS (1) +#define configTIMER_TASK_PRIORITY (40) /* Highest priority */ +#define configTIMER_QUEUE_LENGTH (10) +#define configTIMER_TASK_STACK_DEPTH (1024) + +/* Interrupt priorities used by the kernel port layer itself. These are generic +to all Cortex-M ports, and do not rely on any particular library functions. */ +#define configKERNEL_INTERRUPT_PRIORITY (255) +/* !!!! configMAX_SYSCALL_INTERRUPT_PRIORITY must not be set to zero !!!! +See http://www.FreeRTOS.org/RTOS-Cortex-M3-M4.html. */ +#define configMAX_SYSCALL_INTERRUPT_PRIORITY 48 +#define configENABLE_FPU 0 +#define configENABLE_MPU 0 +/* FreeRTOS Secure Side Only and TrustZone Security Extension */ +#define configRUN_FREERTOS_SECURE_ONLY 1 +#define configENABLE_TRUSTZONE 0 +/* FreeRTOS MPU specific definitions. */ +#define configINCLUDE_APPLICATION_DEFINED_PRIVILEGED_FUNCTIONS (0) + +#define configCPU_CLOCK_HZ (SystemCoreClock) +#define configUSE_PREEMPTION (1) +#define configUSE_TIME_SLICING (1) +#define configUSE_PORT_OPTIMISED_TASK_SELECTION (0) +#define configUSE_TICKLESS_IDLE_SIMPLE_DEBUG (1) /* See into vPortSuppressTicksAndSleep source code for explanation */ +#define configMAX_PRIORITIES (56) +#define configMINIMAL_STACK_SIZE (320) /* Number of words to use for Idle and Timer stacks */ +#define configMAX_TASK_NAME_LEN (10) +#define configUSE_16_BIT_TICKS (0) +#define configIDLE_SHOULD_YIELD (1) +#define configUSE_MUTEXES (1) +#define configUSE_RECURSIVE_MUTEXES (1) +#define configUSE_COUNTING_SEMAPHORES (1) +#define configUSE_TASK_NOTIFICATIONS 1 +#define configUSE_TRACE_FACILITY 1 +#define configQUEUE_REGISTRY_SIZE (10) +#define configUSE_QUEUE_SETS (0) +#define configUSE_NEWLIB_REENTRANT (1) +#define configENABLE_BACKWARD_COMPATIBILITY (1) +#define configSUPPORT_STATIC_ALLOCATION (1) +#define configSUPPORT_DYNAMIC_ALLOCATION (1) + +#ifndef configTOTAL_HEAP_SIZE +#define configTOTAL_HEAP_SIZE ((size_t)(34 * 1024)) +#endif // configTOTAL_HEAP_SIZE + +/* Optional functions - most linkers will remove unused functions anyway. */ +#define INCLUDE_vTaskPrioritySet (1) +#define INCLUDE_uxTaskPriorityGet (1) +#define INCLUDE_vTaskDelete (1) +#define INCLUDE_vTaskSuspend (1) +#define INCLUDE_xResumeFromISR (1) +#define INCLUDE_vTaskDelayUntil (1) +#define INCLUDE_vTaskDelay (1) +#define INCLUDE_xTaskGetSchedulerState (1) +#define INCLUDE_xTaskGetCurrentTaskHandle (1) +#define INCLUDE_uxTaskGetStackHighWaterMark (1) +#define INCLUDE_xTaskGetIdleTaskHandle (1) +#define INCLUDE_xTimerGetTimerDaemonTaskHandle (1) +#define INCLUDE_pcTaskGetTaskName (1) +#define INCLUDE_eTaskGetState (1) +#define INCLUDE_xEventGroupSetBitFromISR (1) +#define INCLUDE_xEventGroupSetBitsFromISR (1) +#define INCLUDE_xSemaphoreGetMutexHolder (1) +#define INCLUDE_xTimerPendFunctionCall (1) +#define INCLUDE_xTaskGetHandle (1) + +/* Stop if an assertion fails. */ +#define configASSERT(x) \ + if ((x) == 0) \ + { \ + taskDISABLE_INTERRUPTS(); \ + printf("\nFREERTOS ASSERT ( %s )\n", #x); \ + for (;;) \ + ; \ + } +#define configASSERTNULL(x) \ + if ((x) == NULL) \ + { \ + taskDISABLE_INTERRUPTS(); \ + for (;;) \ + ; \ + } + +/* Definitions that map the FreeRTOS port interrupt handlers to their CMSIS +standard names. */ +#define vPortSVCHandler SVC_Handler +#define xPortPendSVHandler PendSV_Handler +/* Ensure Cortex-M port compatibility. */ +#define SysTick_Handler xPortSysTickHandler + +/* Thread local storage pointers used by the SDK */ +#ifndef configNUM_SDK_THREAD_LOCAL_STORAGE_POINTERS +#define configNUM_SDK_THREAD_LOCAL_STORAGE_POINTERS 0 +#endif + +#if defined(__GNUC__) +/* For the linker. */ +#define fabs __builtin_fabs +#endif + +#ifdef __cplusplus +} +#endif diff --git a/examples/platform/silabs/SiWx917/LEDWidget.cpp b/examples/platform/silabs/SiWx917/LEDWidget.cpp new file mode 100644 index 00000000000000..10ffcac363520d --- /dev/null +++ b/examples/platform/silabs/SiWx917/LEDWidget.cpp @@ -0,0 +1,89 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2019 Google LLC. + * 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 "LEDWidget.h" + +extern "C" { +#include "sl_simple_led_instances.h" +} + +#include + +using namespace ::chip::System; + +void LEDWidget::InitGpio(void) +{ + // Sets gpio pin mode for ALL board Leds. + sl_simple_led_init_instances(); +} + +void LEDWidget::Init(const sl_led_t * led) +{ + mLastChangeTimeMS = 0; + mBlinkOnTimeMS = 0; + mBlinkOffTimeMS = 0; + mLed = led; + + Set(false); +} + +void LEDWidget::Invert(void) +{ + if (mLed) + { + sl_led_toggle(mLed); + } +} + +void LEDWidget::Set(bool state) +{ + mLastChangeTimeMS = mBlinkOnTimeMS = mBlinkOffTimeMS = 0; + if (mLed) + { + state ? sl_led_turn_on(mLed) : sl_led_turn_off(mLed); + } +} + +void LEDWidget::Blink(uint32_t changeRateMS) +{ + Blink(changeRateMS, changeRateMS); +} + +void LEDWidget::Blink(uint32_t onTimeMS, uint32_t offTimeMS) +{ + mBlinkOnTimeMS = onTimeMS; + mBlinkOffTimeMS = offTimeMS; + Animate(); +} + +void LEDWidget::Animate() +{ + if (mBlinkOnTimeMS != 0 && mBlinkOffTimeMS != 0) + { + uint64_t nowMS = chip::System::SystemClock().GetMonotonicMilliseconds64().count(); + uint64_t stateDurMS = sl_led_get_state(mLed) ? mBlinkOnTimeMS : mBlinkOffTimeMS; + uint64_t nextChangeTimeMS = mLastChangeTimeMS + stateDurMS; + + if (nextChangeTimeMS < nowMS) + { + Invert(); + mLastChangeTimeMS = nowMS; + } + } +} diff --git a/examples/platform/silabs/SiWx917/LEDWidget.h b/examples/platform/silabs/SiWx917/LEDWidget.h new file mode 100644 index 00000000000000..d779cb9d3ef4b6 --- /dev/null +++ b/examples/platform/silabs/SiWx917/LEDWidget.h @@ -0,0 +1,41 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2019 Google LLC. + * 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 "sl_led.h" +#include + +class LEDWidget +{ +public: + static void InitGpio(void); + void Init(const sl_led_t * led); + void Set(bool state); + void Invert(void); + void Blink(uint32_t changeRateMS); + void Blink(uint32_t onTimeMS, uint32_t offTimeMS); + void Animate(); + +private: + uint64_t mLastChangeTimeMS; + uint32_t mBlinkOnTimeMS; + uint32_t mBlinkOffTimeMS; + const sl_led_t * mLed; +}; diff --git a/examples/platform/silabs/SiWx917/MemMonitoring.cpp b/examples/platform/silabs/SiWx917/MemMonitoring.cpp new file mode 100644 index 00000000000000..9da075e4e79d42 --- /dev/null +++ b/examples/platform/silabs/SiWx917/MemMonitoring.cpp @@ -0,0 +1,111 @@ +/* + * + * Copyright (c) 2021 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 "MemMonitoring.h" + +#include "AppConfig.h" +#include "FreeRTOS.h" +#include + +#define BLE_STACK_TASK_NAME "Bluetooth stack" +#define BLE_LINK_TASK_NAME "Bluetooth linklayer" + +static StackType_t monitoringStack[MONITORING_STACK_SIZE_byte / sizeof(StackType_t)]; +static StaticTask_t monitoringTaskStruct; + +size_t nbAllocSuccess = 0; +size_t nbFreeSuccess = 0; +size_t largestBlockAllocated = 0; + +void MemMonitoring::startHeapMonitoring() +{ + xTaskCreateStatic(HeapMonitoring, "Monitoring", MONITORING_STACK_SIZE_byte / sizeof(StackType_t), NULL, 1, monitoringStack, + &monitoringTaskStruct); +} + +void MemMonitoring::HeapMonitoring(void * pvParameter) +{ + + UBaseType_t appTaskValue; + UBaseType_t bleEventTaskValue; + UBaseType_t bleTaskValue; + UBaseType_t linkLayerTaskValue; + UBaseType_t openThreadTaskValue; + UBaseType_t eventLoopTaskValue; + + TaskHandle_t eventLoopHandleStruct = xTaskGetHandle(CHIP_DEVICE_CONFIG_CHIP_TASK_NAME); + TaskHandle_t otTaskHandle = xTaskGetHandle(CHIP_DEVICE_CONFIG_THREAD_TASK_NAME); + TaskHandle_t appTaskHandle = xTaskGetHandle(APP_TASK_NAME); + TaskHandle_t bleStackTaskHandle = xTaskGetHandle(BLE_STACK_TASK_NAME); + TaskHandle_t bleLinkTaskHandle = xTaskGetHandle(BLE_LINK_TASK_NAME); + TaskHandle_t bleEventTaskHandle = xTaskGetHandle(CHIP_DEVICE_CONFIG_BLE_APP_TASK_NAME); + +#if CHIP_SYSTEM_CONFIG_USE_LWIP + UBaseType_t lwipTaskValue; + TaskHandle_t lwipHandle = xTaskGetHandle(TCPIP_THREAD_NAME); +#endif // CHIP_SYSTEM_CONFIG_USE_LWIP + + while (true) + { + appTaskValue = uxTaskGetStackHighWaterMark(appTaskHandle); + bleEventTaskValue = uxTaskGetStackHighWaterMark(bleEventTaskHandle); + bleTaskValue = uxTaskGetStackHighWaterMark(bleStackTaskHandle); + linkLayerTaskValue = uxTaskGetStackHighWaterMark(bleLinkTaskHandle); + openThreadTaskValue = uxTaskGetStackHighWaterMark(otTaskHandle); + eventLoopTaskValue = uxTaskGetStackHighWaterMark(eventLoopHandleStruct); +#if CHIP_SYSTEM_CONFIG_USE_LWIP + lwipTaskValue = uxTaskGetStackHighWaterMark(lwipHandle); +#endif // CHIP_SYSTEM_CONFIG_USE_LWIP + + SILABS_LOG("============================="); + SILABS_LOG(" "); + SILABS_LOG("Largest Block allocated 0x%x", largestBlockAllocated); + SILABS_LOG("Number Of Successful Alloc 0x%x", nbAllocSuccess); + SILABS_LOG("Number Of Successful Frees 0x%x", nbFreeSuccess); + SILABS_LOG(" "); + SILABS_LOG("App Task most bytes ever Free 0x%x", (appTaskValue * 4)); + SILABS_LOG("BLE Event most bytes ever Free 0x%x", (bleEventTaskValue * 4)); + SILABS_LOG("BLE Stack most bytes ever Free 0x%x", (bleTaskValue * 4)); + SILABS_LOG("Link Layer Task most bytes ever Free 0x%x", (linkLayerTaskValue * 4)); + SILABS_LOG("OpenThread Task most bytes ever Free 0x%x", (openThreadTaskValue * 4)); + SILABS_LOG("Event Loop Task most bytes ever Free 0x%x", (eventLoopTaskValue * 4)); +#if CHIP_SYSTEM_CONFIG_USE_LWIP + SILABS_LOG("LWIP Task most bytes ever Free 0x%x", (lwipTaskValue * 4)); +#endif // CHIP_SYSTEM_CONFIG_USE_LWIP + SILABS_LOG(" "); + SILABS_LOG("============================="); + vTaskDelay(pdMS_TO_TICKS(5000)); + } +} + +extern "C" void memMonitoringTrackAlloc(void * ptr, size_t size) +{ + if (ptr != NULL) + { + nbAllocSuccess++; + if (largestBlockAllocated < size) + { + largestBlockAllocated = size; + } + } +} + +extern "C" void memMonitoringTrackFree(void * ptr, size_t size) +{ + nbFreeSuccess++; +} diff --git a/examples/platform/silabs/SiWx917/OTAConfig.cpp b/examples/platform/silabs/SiWx917/OTAConfig.cpp new file mode 100644 index 00000000000000..1056cf5a3533b4 --- /dev/null +++ b/examples/platform/silabs/SiWx917/OTAConfig.cpp @@ -0,0 +1,101 @@ +/* + * + * Copyright (c) 2021 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 "OTAConfig.h" + +#include "application_properties.h" +#include + +#if defined(SL_COMPONENT_CATALOG_PRESENT) +#include "sl_component_catalog.h" +#endif + +// Only include app properties if the Gecko SDK component that does it automatically isn't present +#if !defined(SL_CATALOG_GECKO_BOOTLOADER_INTERFACE_PRESENT) +// Header used for building the image GBL file +#define APP_PROPERTIES_VERSION 1 +#define APP_PROPERTIES_ID \ + { \ + 0 \ + } + +__attribute__((used)) ApplicationProperties_t sl_app_properties = { + /// @brief Magic value indicating that this is an ApplicationProperties_t + /// Must equal @ref APPLICATION_PROPERTIES_MAGIC + .magic = APPLICATION_PROPERTIES_MAGIC, + + /// Version number of this struct + .structVersion = APPLICATION_PROPERTIES_VERSION, + + /// Type of signature this application is signed with + .signatureType = APPLICATION_SIGNATURE_NONE, + + /// Location of the signature. Typically a pointer to the end of application + .signatureLocation = 0, + + /// Information about the application + .app = { + + /// Bitfield representing type of application + /// e.g. @ref APPLICATION_TYPE_BLUETOOTH_APP + .type = APPLICATION_TYPE_THREAD, + + /// Version number for this application + .version = APP_PROPERTIES_VERSION, + + /// Capabilities of this application + .capabilities = 0, + + /// Unique ID (e.g. UUID/GUID) for the product this application is built for + .productId = APP_PROPERTIES_ID, + }, + + /// Pointer to information about the certificate + .cert = NULL, + + /// Pointer to Long Token Data Section + .longTokenSectionAddress = NULL, +}; +#endif // SL_CATALOG_GECKO_BOOTLOADER_INTERFACE_PRESENT + +// Global OTA objects +chip::DefaultOTARequestor gRequestorCore; +chip::DefaultOTARequestorStorage gRequestorStorage; +chip::DeviceLayer::DefaultOTARequestorDriver gRequestorUser; +chip::BDXDownloader gDownloader; +chip::OTAImageProcessorImpl gImageProcessor; + +void OTAConfig::Init() +{ + // Initialize and interconnect the Requestor and Image Processor objects -- START + SetRequestorInstance(&gRequestorCore); + + gRequestorStorage.Init(chip::Server::GetInstance().GetPersistentStorage()); + gRequestorCore.Init(chip::Server::GetInstance(), gRequestorStorage, gRequestorUser, gDownloader); + + // Periodic query timeout must be set prior to requestor being initialized + gRequestorUser.SetPeriodicQueryTimeout(OTA_PERIODIC_TIMEOUT); + gRequestorUser.Init(&gRequestorCore, &gImageProcessor); + + gImageProcessor.SetOTAImageFile("test.txt"); + gImageProcessor.SetOTADownloader(&gDownloader); + + // Connect the Downloader and Image Processor objects + gDownloader.SetImageProcessorDelegate(&gImageProcessor); + // Initialize and interconnect the Requestor and Image Processor objects -- END +} diff --git a/examples/platform/silabs/SiWx917/OTAConfig.h b/examples/platform/silabs/SiWx917/OTAConfig.h new file mode 100644 index 00000000000000..a4f8ac4369e175 --- /dev/null +++ b/examples/platform/silabs/SiWx917/OTAConfig.h @@ -0,0 +1,34 @@ +/* + * + * Copyright (c) 2021 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 +#include +#include +#include +#include + +class OTAConfig +{ +public: + OTAConfig(){}; + + static void Init(); + static constexpr uint32_t kInitOTARequestorDelaySec = 3; +}; diff --git a/examples/platform/silabs/SiWx917/SiWx917/hal/rsi_hal.h b/examples/platform/silabs/SiWx917/SiWx917/hal/rsi_hal.h new file mode 100644 index 00000000000000..8e4e6e25952583 --- /dev/null +++ b/examples/platform/silabs/SiWx917/SiWx917/hal/rsi_hal.h @@ -0,0 +1,105 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef _HAL_RSI_HAL_H_ +#define _HAL_RSI_HAL_H_ +#include "rsi_board_configuration.h" + +#define RSI_HAL_NO_COM_PORT /* This will be done by the project */ + +/* Should be enums */ +#define RSI_HAL_RESET_PIN 0 +#define RSI_HAL_MODULE_INTERRUPT 1 +#define RSI_HAL_SLEEP_CONFIRM_PIN 2 +#define RSI_HAL_WAKEUP_INDICATION_PIN 3 +#define RSI_HAL_MODULE_INTERRUPT_PIN 4 + +//! Timer related macros +//! Macro to configure timer type in single shot +#define RSI_HAL_TIMER_TYPE_SINGLE_SHOT 0 + +// Macro to configure timer type in periodic +#define RSI_HAL_TIMER_TYPE_PERIODIC 1 + +// Macro to configure timer in micro seconds mode +#define RSI_HAL_TIMER_MODE_MICRO 0 + +// Macro to configure timer in milli seconds mode +#define RSI_HAL_TIMER_MODE_MILLI 1 + +//! GPIO Pins related Macros +//! Macro to configure GPIO in output mode +#define RSI_HAL_GPIO_OUTPUT_MODE 1 + +// Macro to configure GPIO in input mode +#define RSI_HAL_GPIO_INPUT_MODE 0 + +// Macro to drive low value on GPIO +#define RSI_HAL_GPIO_LOW 0 + +// Macro to drive high value on GPIO +#define RSI_HAL_GPIO_HIGH 1 + +/****************************************************** + * * Function Declarations + * ******************************************************/ + +void rsi_hal_board_init(void); +void rsi_switch_to_high_clk_freq(void); +void rsi_hal_intr_config(void (*rsi_interrupt_handler)(void)); +void rsi_hal_intr_mask(void); +void rsi_hal_intr_unmask(void); +void rsi_hal_intr_clear(void); +uint8_t rsi_hal_intr_pin_status(void); +void rsi_hal_config_gpio(uint8_t gpio_number, uint8_t mode, uint8_t value); +void rsi_hal_set_gpio(uint8_t gpio_number); +uint8_t rsi_hal_get_gpio(uint8_t gpio_number); +void rsi_hal_clear_gpio(uint8_t gpio_number); +int16_t rsi_spi_transfer(uint8_t * tx_buff, uint8_t * rx_buff, uint16_t transfer_length, uint8_t mode); +int16_t rsi_uart_send(uint8_t * ptrBuf, uint16_t bufLen); +int16_t rsi_uart_recv(uint8_t * ptrBuf, uint16_t bufLen); +int16_t rsi_com_port_send(uint8_t * ptrBuf, uint16_t bufLen); +int16_t rsi_com_port_receive(uint8_t * ptrBuf, uint16_t bufLen); +uint32_t rsi_get_random_number(void); +int32_t rsi_timer_start(uint8_t timer_node, uint8_t mode, uint8_t type, uint32_t duration, void (*rsi_timer_expiry_handler)(void)); +int32_t rsi_timer_stop(uint8_t timer_node); +uint32_t rsi_timer_read(uint8_t timer_node); +void rsi_delay_us(uint32_t delay_us); +void rsi_delay_ms(uint32_t delay_ms); +uint32_t rsi_hal_gettickcount(void); +void SysTick_Handler(void); + +void rsi_interrupt_handler(void); +void ABRD(void); + +void Error_Handler(void); + +/* RTC Related API's */ +uint32_t rsi_rtc_get_time(void); +int32_t rsi_rtc_set_time(uint32_t time); +/* End - RTC Related API's */ + +#ifdef LOGGING_STATS +void rsi_hal_log_stats_intr_config(void (*rsi_give_wakeup_indication)()); +#endif /* LOGGING_STATS */ +#ifdef RSI_WITH_OS +void rsi_os_delay_ms(uint32_t delay_ms); +void PORTD_IRQHandler(void); + +#endif /* RSI_WITH_OS */ + +#endif diff --git a/examples/platform/silabs/SiWx917/SiWx917/hal/rsi_hal_mcu_platform_init.c b/examples/platform/silabs/SiWx917/SiWx917/hal/rsi_hal_mcu_platform_init.c new file mode 100644 index 00000000000000..b2effb5997f388 --- /dev/null +++ b/examples/platform/silabs/SiWx917/SiWx917/hal/rsi_hal_mcu_platform_init.c @@ -0,0 +1,113 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * Includes + */ +#include "rsi_board.h" +#include "rsi_pll.h" +#include "rsi_rom_clks.h" +#include "siwx917_utils.h" +#include "system_RS1xxxx.h" + +#define SOC_PLL_REF_FREQUENCY 32000000 /* PLL input REFERENCE clock 32MHZ */ + +// Note: Change this macro to required PLL frequency in hertz +#define PS4_SOC_FREQ 80000000 /* PLL out clock 80MHz */ +#define SWITCH_QSPI_TO_SOC_PLL +#define ICACHE_DISABLE +#define DEBUG_DISABLE + +#define PMU_GOOD_TIME 31 /*Duration in us*/ +#define XTAL_GOOD_TIME 31 /*Duration in us*/ + +/*Pre-fetch and regestring */ +#define ICACHE2_ADDR_TRANSLATE_1_REG *(volatile uint32_t *) (0x20280000 + 0x24) +#define MISC_CFG_SRAM_REDUNDANCY_CTRL *(volatile uint32_t *) (0x46008000 + 0x18) +#define MISC_CONFIG_MISC_CTRL1 *(volatile uint32_t *) (0x46008000 + 0x44) +#define MISC_QUASI_SYNC_MODE *(volatile uint32_t *) (0x46008000 + 0x84) + +/** + * @fn void soc_pll_config() + * @brief This function to configure clock for SiWx917 SoC (80MHz) + * Configure the PLL frequency and Switch M4 clock to PLL clock for speed operations + * + * @param[in] none + * @param[out] none + * @return int + * @section description + * configure clock for SiWx917 SoC + * + */ +int soc_pll_config(void) +{ + RSI_CLK_SocPllLockConfig(1, 1, 7); + + RSI_CLK_SocPllRefClkConfig(2); + + RSI_CLK_M4SocClkConfig(M4CLK, M4_ULPREFCLK, 0); + + /*Enable fre-fetch and register if SOC-PLL frequency is more than or equal to 120M*/ +#if (PS4_SOC_FREQ >= 120000000) + ICACHE2_ADDR_TRANSLATE_1_REG = BIT(21); + MISC_CFG_SRAM_REDUNDANCY_CTRL = BIT(4); + MISC_CONFIG_MISC_CTRL1 |= BIT(4); +#if !(defined WISE_AOC_4) + MISC_QUASI_SYNC_MODE |= BIT(6); + MISC_QUASI_SYNC_MODE |= (BIT(6) | BIT(7)); +#endif /* !WISE_AOC_4 */ +#endif /* (PS4_SOC_FREQ > 120000000) */ + + RSI_CLK_SetSocPllFreq(M4CLK, PS4_SOC_FREQ, SOC_PLL_REF_FREQUENCY); + + RSI_CLK_M4SocClkConfig(M4CLK, M4_SOCPLLCLK, 0); + +#ifdef SWITCH_QSPI_TO_SOC_PLL + RSI_CLK_QspiClkConfig(M4CLK, QSPI_INTFPLLCLK, 0, 0, 0); +#endif /* SWITCH_QSPI_TO_SOC_PLL */ + + return 0; +} + +/*==============================================*/ +/** + * @fn void rsi_hal_board_init() + * @brief This function Initializes the platform + * @param[in] none + * @param[out] none + * @return none + * @section description + * This function initializes the platform + * + */ +void rsi_hal_board_init(void) +{ + SystemCoreClockUpdate(); + + /* configure clock for SiWx917 SoC */ + soc_pll_config(); + SILABS_LOG("%s, soc_pll_config, SystemCoreClock=%d\n", __func__, SystemCoreClock); + +#ifdef COMMON_FLASH_EN + /* Before TA going to power save mode ,set m4ss_ref_clk_mux_ctrl ,tass_ref_clk_mux_ctrl, + AON domain power supply controls form TA to M4 */ + RSI_Set_Cntrls_To_M4(); +#endif +#ifdef DEBUG_UART + DEBUGINIT(); +#endif +} diff --git a/examples/platform/silabs/SiWx917/SiWx917/hal/rsi_hal_mcu_timer.c b/examples/platform/silabs/SiWx917/SiWx917/hal/rsi_hal_mcu_timer.c new file mode 100644 index 00000000000000..e7141d4646060c --- /dev/null +++ b/examples/platform/silabs/SiWx917/SiWx917/hal/rsi_hal_mcu_timer.c @@ -0,0 +1,221 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * Includes + */ + +#include "rsi_driver.h" +#ifdef RSI_WITH_OS +/* FreeRTOS includes. */ +#include "FreeRTOS.h" +#include "StackMacros.h" +#include "task.h" +#include "timers.h" + +#if defined(SysTick) +#undef SysTick_Handler +/* FreeRTOS SysTick interrupt handler prototype */ +extern void SysTick_Handler(void); +/* FreeRTOS tick timer interrupt handler prototype */ +extern void xPortSysTickHandler(void); +#endif /* SysTick */ +#endif + +static volatile uint32_t _dwTickCount; // systick cout variable + +/*===================================================*/ +/** + * @fn int32_t rsi_timer_start(uint8_t timer_no, uint8_t mode,uint8_t type,uint32_t duration,void (* + * rsi_timer_expiry_handler)()) + * @brief Starts and configures timer + * @param[in] timer_node, timer node to be configured. + * @param[in] mode , mode of the timer + * 0 - Micro seconds mode + * 1 - Milli seconds mode + * @param[in] type, type of the timer + * 0 - single shot type + * 1 - periodic type + * @param[in] duration, timer duration + * @param[in] rsi_timer_expiry_handler() ,call back function to handle timer interrupt + * @param[out] none + * @return 0 - success + * !0 - Failure + * @description This HAL API should contain the code to initialize the timer and start the timer + * + */ + +int32_t rsi_timer_start(uint8_t timer_node, uint8_t mode, uint8_t type, uint32_t duration, void (*rsi_timer_expiry_handler)(void)) +{ + + //! Initialise the timer + + //! register the call back + + //! Start timer + + return 0; +} + +/*===================================================*/ +/** + * @fn int32_t rsi_timer_stop(uint8_t timer_no) + * @brief Stops timer + * @param[in] timer_node, timer node to stop + * @param[out] none + * @return 0 - success + * !0 - Failure + * @description This HAL API should contain the code to stop the timer + * + */ + +int32_t rsi_timer_stop(uint8_t timer_node) +{ + + //! Stop the timer + + return 0; +} + +/*===================================================*/ +/** + * @fn uint32_t rsi_timer_read(uint8_t timer_node) + * @brief read timer + * @param[in] timer_node, timer node to read + * @param[out] none + * @return timer value + * @description This HAL API should contain API to read the timer + * + */ + +uint32_t rsi_timer_read(uint8_t timer_node) +{ + + volatile uint32_t timer_val = 0; + + //! read the timer and return timer value + + return timer_val; +} + +/*===================================================*/ +/** + * @fn void rsi_delay_us(uint32_t delay) + * @brief create delay in micro seconds + * @param[in] delay_us, timer delay in micro seconds + * @param[out] none + * @return none + * @description This HAL API should contain the code to create delay in micro seconds + * + */ +void rsi_delay_us(uint32_t delay_us) +{ + + //! call the API for delay in micro seconds + + return; +} + +/*===================================================*/ +/** + * @fn void rsi_delay_ms(uint32_t delay) + * @brief create delay in micro seconds + * @param[in] delay, timer delay in micro seconds + * @param[out] none + * @return none + * @description This HAL API should contain the code to create delay in micro seconds + * + */ +void rsi_delay_ms1(uint32_t delay_ms) +{ + + //! call the API for delay in milli seconds + + return; +} + +/*===================================================*/ +/** + * @fn void SysTick_Handler(void); + * @brief systick cout variable + * @param[in] none + * @param[out] none + * @return none + * @description This HAL API is systick cout variable + * + */ + +void SysTick_Handler(void) +{ + _dwTickCount++; +#ifdef RSI_WITH_OS + if (xTaskGetSchedulerState() != taskSCHEDULER_NOT_STARTED) + { + xPortSysTickHandler(); + } +#endif +} +/*===================================================*/ +/** + * @fn uint32_t GetTickCount( void ) + * @brief gets the tick count from systic ISR + * @param[in] delay, timer delay in micro seconds + * @param[out] none + * @return Returns the systick current tick count + * @description This HAL API gets the tick count from systic ISR + * + */ + +uint32_t GetTickCount(void) +{ + return _dwTickCount; // gets the tick count from systic ISR +} + +/*===================================================*/ +/** + * @fn void rsi_delay_ms(uint32_t delay) + * @brief create delay in milli seconds + * @param[in] delay, timer delay in milli seconds + * @param[out] none + * @return none + * @description This HAL API should contain the code to create delay in milli seconds + * + */ + +void rsi_delay_ms(uint32_t delay_ms) +{ + uint64_t waitTime = rsi_hal_gettickcount() + delay_ms; + + while (waitTime > rsi_hal_gettickcount()) + { + // we busy wait + } +} + +/*===================================================*/ +/** + * @fn uint32_t rsi_hal_gettickcount() + * @brief provides a tick value in milliseconds + * @return tick value + * @description This HAL API should contain the code to read the timer tick count value in milliseconds + * + */ + +uint32_t rsi_hal_gettickcount(void) +{ + return GetTickCount(); +} diff --git a/examples/platform/silabs/SiWx917/SiWx917/rs911x.gni b/examples/platform/silabs/SiWx917/SiWx917/rs911x.gni new file mode 100644 index 00000000000000..0cca17540074ab --- /dev/null +++ b/examples/platform/silabs/SiWx917/SiWx917/rs911x.gni @@ -0,0 +1,144 @@ +import("//build_overrides/chip.gni") +import("//build_overrides/efr32_sdk.gni") +import("//build_overrides/pigweed.gni") + +examples_plat_dir = "${chip_root}/examples/platform/silabs/SiWx917" +wifi_sdk_dir = "${chip_root}/src/platform/silabs/SiWx917/wifi" +wiseconnect_sdk_root = "${chip_root}/third_party/silabs/wisemcu-wifi-bt-sdk" +rs911x_cflags = [] + +rs911x_src_plat = [ + "${examples_plat_dir}/SiWx917/rsi_if.c", + "${examples_plat_dir}/SiWx917/wfx_rsi_host.c", + "${wifi_sdk_dir}/wfx_notify.cpp", + + "${examples_plat_dir}/SiWx917/hal/rsi_hal_mcu_timer.c", + "${examples_plat_dir}/SiWx917/hal/rsi_hal_mcu_platform_init.c", + + "${wiseconnect_sdk_root}/platforms/si91x/hal/src/rsi_bootup_config.c", + "${wiseconnect_sdk_root}/platforms/si91x/hal/src/rsi_hal_mcu_m4.c", + "${wiseconnect_sdk_root}/platforms/si91x/hal/src/rsi_hal_mcu_m4_rom.c", + "${wiseconnect_sdk_root}/platforms/si91x/hal/src/rsi_hal_mcu_interrupt.c", +] +rs911x_plat_incs = [ + "${wifi_sdk_dir}", + "${wifi_sdk_dir}/hal", + "${wiseconnect_sdk_root}/platforms/si91x/hal/inc", + + # "${wiseconnect_sdk_root}/sapi/include", + "${chip_root}/src/platform/silabs/SiWx917", + "${chip_root}/src/platform/silabs/SiWx917/bluetooth", + "${examples_plat_dir}/SiWx917", + "${wiseconnect_sdk_root}/platforms/si91x/hal/inc", +] + +# +# All the stuff from wiseconnect +# +rs911x_src_sapi = [ + "${wiseconnect_sdk_root}/sapi/wlan/rsi_wlan_apis.c", + "${wiseconnect_sdk_root}/sapi/common/rsi_apis_non_rom.c", + "${wiseconnect_sdk_root}/sapi/common/rsi_apis_rom.c", + "${wiseconnect_sdk_root}/sapi/common/rsi_common_apis.c", + "${wiseconnect_sdk_root}/sapi/common/rsi_device_init_apis.c", + + # "${wiseconnect_sdk_root}/sapi/common/rsi_wisemcu_hardware_setup.c", + "${wiseconnect_sdk_root}/sapi/driver/device_interface/spi/rsi_spi_frame_rd_wr.c", + "${wiseconnect_sdk_root}/sapi/driver/device_interface/spi/rsi_spi_functs.c", + "${wiseconnect_sdk_root}/sapi/driver/device_interface/spi/rsi_spi_iface_init.c", + "${wiseconnect_sdk_root}/sapi/driver/device_interface/spi/rsi_spi_mem_rd_wr.c", + "${wiseconnect_sdk_root}/sapi/driver/device_interface/spi/rsi_spi_reg_rd_wr.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_common.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_device_init.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_driver_event_handlers.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_driver.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_events_rom.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_events.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_iap.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_nwk_rom.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_nwk.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_pkt_mgmt_rom.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_pkt_mgmt.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_queue_rom.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_queue.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_scheduler_rom.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_scheduler.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_setregion_countryinfo.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_timer.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_utils_rom.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_utils.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_wlan.c", + "${wiseconnect_sdk_root}/sapi/rtos/freertos_wrapper/rsi_os_wrapper.c", +] + +foreach(src_file, rs911x_src_sapi) { + rs911x_cflags += [ + "-Wno-empty-body", + "-Wno-cpp", + "-Wno-missing-braces", + "-Wno-sign-compare", + "-Wno-error", + "-Wno-unknown-warning-option", + "-Wno-unused-variable", + "-Wno-implicit-function-declaration", + "-Wno-unused-function", + ] +} + +rs911x_inc_plat = [ + "${wifi_sdk_dir}", + "${examples_plat_dir}/SiWx917", + "${examples_plat_dir}/SiWx917/hal", + "${wiseconnect_sdk_root}/sapi/include", + + #CCP Platfrom + "${wiseconnect_sdk_root}/platforms/si91x/hal/inc", + "${wiseconnect_sdk_root}/platforms/si91x/boards/brd4325a/inc", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/peripheral_drivers/inc", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/systemlevel/inc", + "${wiseconnect_sdk_root}/platforms/si91x/core/chip/inc", + "${wiseconnect_sdk_root}/platforms/si91x/core/config", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/cmsis_driver/config", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/rom_driver/inc", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/cmsis_driver", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/cmsis_driver/CMSIS/Driver/Include", + + "${wiseconnect_sdk_root}/platforms/si91x/core/cmsis", + "${wiseconnect_sdk_root}/platforms/si91x/service/system/inc", +] + +# Apparently - the rsi library needs this +rs911x_src_sock = [ + "${wiseconnect_sdk_root}/sapi/network/socket/rsi_socket.c", + "${wiseconnect_sdk_root}/sapi/network/socket/rsi_socket_rom.c", +] +rs911x_sock_inc = [ "${wifi_sdk_dir}/rsi-sockets" ] + +# +# If we use LWIP - not built-in sockets +# +rs911x_src_lwip = [ + "${wifi_sdk_dir}/ethernetif.cpp", + "${wifi_sdk_dir}/dhcp_client.cpp", + "${wifi_sdk_dir}/lwip_netif.cpp", +] +rs911x_defs = [ + "CCP_SI917_BRINGUP=1", + "SL_HEAP_SIZE=32768", + "SL_WIFI=1", + "RS911X_WIFI", + "RSI_WLAN_ENABLE", + "RSI_WITH_OS", + "RSI_M4_INTERFACE", #Enable CCP bus Interface + "RSI_WLAN_API_ENABLE", + "HMAC_512", + "LITTLE_ENDIAN_ORDER", + "_CHIP_9118", + + # "ROM_WIRELESS" + #__CC_ARM DEBUG_UART _CHIP_9118 LITTLE_ENDIAN_ORDER HMAC_512 +] +rs911x_sock_defs = [ + "RS911X_SOCKETS", + "RSI_IPV6_ENABLE", +] diff --git a/examples/platform/silabs/SiWx917/SiWx917/rsi_if.c b/examples/platform/silabs/SiWx917/SiWx917/rsi_if.c new file mode 100644 index 00000000000000..3b15cd8f29e7af --- /dev/null +++ b/examples/platform/silabs/SiWx917/SiWx917/rsi_if.c @@ -0,0 +1,836 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include +#include + +#include "sl_status.h" + +#include "FreeRTOS.h" +#include "event_groups.h" +#include "task.h" + +#include "wfx_host_events.h" + +#include "rsi_driver.h" +#include "rsi_wlan_non_rom.h" + +#include "rsi_common_apis.h" +#include "rsi_data_types.h" +#include "rsi_error.h" +#include "rsi_nwk.h" +#include "rsi_socket.h" +#include "rsi_utils.h" +#include "rsi_wlan.h" +#include "rsi_wlan_apis.h" +#include "rsi_wlan_config.h" +//#include "rsi_wlan_non_rom.h" +#include "rsi_bootup_config.h" + +#include "dhcp_client.h" +#include "wfx_rsi.h" + +#define VAL(str) #str +#define TOSTRING(str) VAL(str) + +/* Rsi driver Task will use as its stack */ +StackType_t driverRsiTaskStack[WFX_RSI_WLAN_TASK_SZ] = { 0 }; + +/* Structure that will hold the TCB of the wfxRsi Task being created. */ +StaticTask_t driverRsiTaskBuffer; + +/* Declare a variable to hold the data associated with the created event group. */ +StaticEventGroup_t rsiDriverEventGroup; + +bool hasNotifiedIPV6 = false; +#if (CHIP_DEVICE_CONFIG_ENABLE_IPV4) +bool hasNotifiedIPV4 = false; +#endif /* CHIP_DEVICE_CONFIG_ENABLE_IPV4 */ +bool hasNotifiedWifiConnectivity = false; + +/* + * This file implements the interface to the RSI SAPIs + */ +static uint8_t wfx_rsi_drv_buf[WFX_RSI_BUF_SZ]; +wfx_wifi_scan_ext_t * temp_reset; +uint8_t security; + +/****************************************************************** + * @fn int32_t wfx_rsi_get_ap_info(wfx_wifi_scan_result_t *ap) + * @brief + * Getting the AP details + * @param[in] ap: access point + * @return + * status + *********************************************************************/ +int32_t wfx_rsi_get_ap_info(wfx_wifi_scan_result_t * ap) +{ + int32_t status; + uint8_t rssi; + ap->security = security; + ap->chan = wfx_rsi.ap_chan; + memcpy(&ap->bssid[0], &wfx_rsi.ap_mac.octet[0], BSSID_MAX_STR_LEN); + status = rsi_wlan_get(RSI_RSSI, &rssi, sizeof(rssi)); + if (status == RSI_SUCCESS) + { + ap->rssi = (-1) * rssi; + } + return status; +} + +/****************************************************************** + * @fn int32_t wfx_rsi_get_ap_ext(wfx_wifi_scan_ext_t *extra_info) + * @brief + * Getting the AP extra details + * @param[in] extra info: access point extra information + * @return + * status + *********************************************************************/ +int32_t wfx_rsi_get_ap_ext(wfx_wifi_scan_ext_t * extra_info) +{ + /* TODO : Place holder until we have similar functionality + * available for SiWx917 + */ + int32_t status = 0; + return status; +} + +/****************************************************************** + * @fn int32_t wfx_rsi_reset_count() + * @brief + * Getting the driver reset count + * @param[in] None + * @return + * status + *********************************************************************/ +int32_t wfx_rsi_reset_count() +{ + /* TODO : Place holder until we have similar functionality + * available for SiWx917 + */ + int32_t status = 0; + return status; +} + +/****************************************************************** + * @fn wfx_rsi_disconnect() + * @brief + * Getting the driver disconnect status + * @param[in] None + * @return + * status + *********************************************************************/ +int32_t wfx_rsi_disconnect() +{ + int32_t status = rsi_wlan_disconnect(); + return status; +} + +/****************************************************************** + * @fn wfx_rsi_join_cb(uint16_t status, const uint8_t *buf, const uint16_t len) + * @brief + * called when driver join with cb + * @param[in] status: + * @param[in] buf: + * @param[in] len: + * @return + * None + *********************************************************************/ +static void wfx_rsi_join_cb(uint16_t status, const uint8_t * buf, const uint16_t len) +{ + WFX_RSI_LOG("%s: status: %02x", __func__, status); + wfx_rsi.dev_state &= ~WFX_RSI_ST_STA_CONNECTING; + if (status != RSI_SUCCESS) + { + /* + * We should enable retry.. (Need config variable for this) + */ + WFX_RSI_LOG("%s: failed. retry: %d", __func__, wfx_rsi.join_retries); +#if (WFX_RSI_CONFIG_MAX_JOIN != 0) + if (++wfx_rsi.join_retries < WFX_RSI_CONFIG_MAX_JOIN) +#endif + { + xEventGroupSetBits(wfx_rsi.events, WFX_EVT_STA_START_JOIN); + } + } + else + { + /* + * Join was complete - Do the DHCP + */ + WFX_RSI_LOG("%s: join completed.", __func__); +#ifdef RS911X_SOCKETS + xEventGroupSetBits(wfx_rsi.events, WFX_EVT_STA_DO_DHCP); +#else + xEventGroupSetBits(wfx_rsi.events, WFX_EVT_STA_CONN); +#endif + } +} + +/****************************************************************** + * @fn wfx_rsi_join_fail_cb(uint16_t status, uint8_t *buf, uint32_t len) + * @brief + * called when driver fail to join with cb + * @param[in] status: + * @param[in] buf: + * @param[in] len: + * @return + * None + *********************************************************************/ +static void wfx_rsi_join_fail_cb(uint16_t status, uint8_t * buf, uint32_t len) +{ + WFX_RSI_LOG("%s: error: failed status: %02x on try %d", __func__, status, wfx_rsi.join_retries); + wfx_rsi.join_retries += 1; + wfx_rsi.dev_state &= ~WFX_RSI_ST_STA_CONNECTING; + xEventGroupSetBits(wfx_rsi.events, WFX_EVT_STA_START_JOIN); +} +#ifdef RS911X_SOCKETS + +/****************************************************************** + * @fn wfx_rsi_ipchange_cb(uint16_t status, uint8_t *buf, uint32_t len) + * @brief + * DHCP should end up here + * @param[in] status: + * @param[in] buf: + * @param[in] len: + * @return + * None + *********************************************************************/ +static void wfx_rsi_ipchange_cb(uint16_t status, uint8_t * buf, uint32_t len) +{ + WFX_RSI_LOG("%s: status: %02x", __func__, status); + if (status != RSI_SUCCESS) + { + /* Restart DHCP? */ + xEventGroupSetBits(wfx_rsi.events, WFX_EVT_STA_DO_DHCP); + } + else + { + wfx_rsi.dev_state |= WFX_RSI_ST_STA_DHCP_DONE; + xEventGroupSetBits(wfx_rsi.events, WFX_EVT_STA_DHCP_DONE); + } +} + +#else +/************************************************************************************* + * @fn wfx_rsi_wlan_pkt_cb(uint16_t status, uint8_t *buf, uint32_t len) + * @brief + * Got RAW WLAN data pkt + * @param[in] status: + * @param[in] buf: + * @param[in] len: + * @return + * None + *****************************************************************************************/ +static void wfx_rsi_wlan_pkt_cb(uint16_t status, uint8_t * buf, uint32_t len) +{ + // WFX_RSI_LOG("%s: status=%d, len=%d", __func__, status, len); + if (status != RSI_SUCCESS) + { + return; + } + wfx_host_received_sta_frame_cb(buf, len); +} +#endif /* !Socket support */ + +/************************************************************************************* + * @fn static int32_t wfx_rsi_init(void) + * @brief + * driver initialization + * @param[in] None + * @return + * None + *****************************************************************************************/ +static int32_t wfx_rsi_init(void) +{ + int32_t status; + uint8_t buf[RSI_RESPONSE_HOLD_BUFF_SIZE]; + + WFX_RSI_LOG("%s: start wireless drv task", __func__); + /* + * Create the driver task + */ + wfx_rsi.drv_task = xTaskCreateStatic((TaskFunction_t) rsi_wireless_driver_task, "rsi_drv", WFX_RSI_WLAN_TASK_SZ, NULL, + WLAN_TASK_PRIORITY, driverRsiTaskStack, &driverRsiTaskBuffer); + if (NULL == wfx_rsi.drv_task) + { + WFX_RSI_LOG("%s: error: rsi_wireless_driver_task failed", __func__); + return RSI_ERROR_INVALID_PARAM; + } + + /* Initialize WiSeConnect or Module features. */ + WFX_RSI_LOG("%s: rsi_wireless_init", __func__); + if ((status = rsi_wireless_init(OPER_MODE_0, COEX_MODE_0)) != RSI_SUCCESS) + { + WFX_RSI_LOG("%s: error: rsi_wireless_init failed with status: %02x", __func__, status); + return status; + } + + WFX_RSI_LOG("%s: get FW version..", __func__); + /* + * Get the MAC and other info to let the user know about it. + */ + if (rsi_wlan_get(RSI_FW_VERSION, buf, sizeof(buf)) != RSI_SUCCESS) + { + WFX_RSI_LOG("%s: error: rsi_wlan_get(RSI_FW_VERSION) failed with status: %02x", __func__, status); + return status; + } + + buf[sizeof(buf) - 1] = 0; + WFX_RSI_LOG("%s: RSI firmware version: %s", __func__, buf); + //! Send feature frame + if ((status = rsi_send_feature_frame()) != RSI_SUCCESS) + { + WFX_RSI_LOG("%s: error: rsi_send_feature_frame failed with status: %02x", __func__, status); + return status; + } + + WFX_RSI_LOG("%s: sent rsi_send_feature_frame", __func__); + /* initializes wlan radio parameters and WLAN supplicant parameters. + */ + (void) rsi_wlan_radio_init(); /* Required so we can get MAC address */ + if ((status = rsi_wlan_get(RSI_MAC_ADDRESS, &wfx_rsi.sta_mac.octet[0], RESP_BUFF_SIZE)) != RSI_SUCCESS) + { + WFX_RSI_LOG("%s: error: rsi_wlan_get failed with status: %02x", __func__, status); + return status; + } + + WFX_RSI_LOG("%s: WLAN: MAC %02x:%02x:%02x %02x:%02x:%02x", __func__, wfx_rsi.sta_mac.octet[0], wfx_rsi.sta_mac.octet[1], + wfx_rsi.sta_mac.octet[2], wfx_rsi.sta_mac.octet[3], wfx_rsi.sta_mac.octet[4], wfx_rsi.sta_mac.octet[5]); + wfx_rsi.events = xEventGroupCreateStatic(&rsiDriverEventGroup); + /* + * Register callbacks - We are only interested in the connectivity CBs + */ + if ((status = rsi_wlan_register_callbacks(RSI_JOIN_FAIL_CB, wfx_rsi_join_fail_cb)) != RSI_SUCCESS) + { + WFX_RSI_LOG("%s: RSI callback register join failed with status: %02x", __func__, status); + return status; + } +#ifdef RS911X_SOCKETS + (void) rsi_wlan_register_callbacks(RSI_IP_CHANGE_NOTIFY_CB, wfx_rsi_ipchange_cb); +#else + if ((status = rsi_wlan_register_callbacks(RSI_WLAN_DATA_RECEIVE_NOTIFY_CB, wfx_rsi_wlan_pkt_cb)) != RSI_SUCCESS) + { + WFX_RSI_LOG("%s: RSI callback register data-notify failed with status: %02x", __func__, status); + return status; + } +#endif + wfx_rsi.dev_state |= WFX_RSI_ST_DEV_READY; + WFX_RSI_LOG("%s: RSI: OK", __func__); + return RSI_SUCCESS; +} + +/************************************************************************************* + * @fn void wfx_show_err(char *msg) + * @brief + * driver shows error message + * @param[in] msg + * @return + * None + *****************************************************************************************/ +void wfx_show_err(char * msg) +{ + WFX_RSI_LOG("%s: message: %d", __func__, msg); +} + +/*************************************************************************************** + * @fn static void wfx_rsi_save_ap_info() + * @brief + * Saving the details of the AP + * @param[in] None + * @return + * None + *******************************************************************************************/ +static void wfx_rsi_save_ap_info() +{ + int32_t status; + rsi_rsp_scan_t rsp; + + status = + rsi_wlan_scan_with_bitmap_options((int8_t *) &wfx_rsi.sec.ssid[0], AP_CHANNEL_NO_0, &rsp, sizeof(rsp), SCAN_BITMAP_OPTN_1); + if (status) + { + /* + * Scan is done - failed + */ + } + else + { + wfx_rsi.sec.security = rsp.scan_info->security_mode; + wfx_rsi.ap_chan = rsp.scan_info->rf_channel; + memcpy(&wfx_rsi.ap_mac.octet[0], &rsp.scan_info->bssid[0], BSSID_MAX_STR_LEN); + } + if ((wfx_rsi.sec.security == RSI_WPA) || (wfx_rsi.sec.security == RSI_WPA2)) + { + // saving the security before changing into mixed mode + security = wfx_rsi.sec.security; + wfx_rsi.sec.security = RSI_WPA_WPA2_MIXED; + } + if (wfx_rsi.sec.security == SME_WPA3) + { + // returning 3 for WPA3 when DGWIFI read security-type is called + security = WPA3_SECURITY; + wfx_rsi.sec.security = RSI_WPA3; + } + WFX_RSI_LOG("%s: WLAN: connecting to %s==%s, sec=%d, status=%02x", __func__, &wfx_rsi.sec.ssid[0], &wfx_rsi.sec.passkey[0], + wfx_rsi.sec.security, status); +} + +/******************************************************************************************** + * @fn static void wfx_rsi_do_join(void) + * @brief + * Start an async Join command + * @return + * None + **********************************************************************************************/ +static void wfx_rsi_do_join(void) +{ + int32_t status; + + if (wfx_rsi.dev_state & (WFX_RSI_ST_STA_CONNECTING | WFX_RSI_ST_STA_CONNECTED)) + { + WFX_RSI_LOG("%s: not joining - already in progress", __func__); + } + else + { + WFX_RSI_LOG("%s: WLAN: connecting to %s==%s, sec=%d", __func__, &wfx_rsi.sec.ssid[0], &wfx_rsi.sec.passkey[0], + wfx_rsi.sec.security); + /* + * Join the network + */ + /* TODO - make the WFX_SECURITY_xxx - same as RSI_xxx + * Right now it's done by hand - we need something better + */ + wfx_rsi.dev_state |= WFX_RSI_ST_STA_CONNECTING; + + /* Try to connect Wifi with given Credentials + * until there is a success or maximum number of tries allowed + */ + while (++wfx_rsi.join_retries < WFX_RSI_CONFIG_MAX_JOIN) + { + + /* Call rsi connect call with given ssid and password + * And check there is a success + */ + + if ((status = rsi_wlan_connect_async((int8_t *) &wfx_rsi.sec.ssid[0], (rsi_security_mode_t) wfx_rsi.sec.security, + &wfx_rsi.sec.passkey[0], wfx_rsi_join_cb)) != RSI_SUCCESS) + { + + wfx_rsi.dev_state &= ~WFX_RSI_ST_STA_CONNECTING; + WFX_RSI_LOG("%s: rsi_wlan_connect_async failed with status: %02x on try %d", __func__, status, + wfx_rsi.join_retries); + vTaskDelay(400); + /* TODO - Start a timer.. to retry */ + } + else + { + break; // exit while loop + } + } + if (wfx_rsi.join_retries == MAX_JOIN_RETRIES_COUNT) + { + WFX_RSI_LOG("Connect failed after %d tries", wfx_rsi.join_retries); + } + else + { + WFX_RSI_LOG("%s: starting JOIN to %s after %d tries\n", __func__, (char *) &wfx_rsi.sec.ssid[0], wfx_rsi.join_retries); + } + WFX_RSI_LOG("Returning the do join"); + } +} + +/********************************************************************************* + * @fn void wfx_rsi_task(void *arg) + * @brief + * The main WLAN task - started by wfx_wifi_start () that interfaces with RSI. + * The rest of RSI stuff come in call-backs. + * The initialization has been already done. + * @param[in] arg: + * @return + * None + **********************************************************************************/ +/* ARGSUSED */ +void wfx_rsi_task(void * arg) +{ + EventBits_t flags; + int32_t status = 0; +#ifndef RS911X_SOCKETS + TickType_t last_dhcp_poll, now; + struct netif * sta_netif; +#endif + (void) arg; + uint32_t rsi_status = wfx_rsi_init(); + if (rsi_status != RSI_SUCCESS) + { + WFX_RSI_LOG("%s: error: wfx_rsi_init with status: %02x", __func__, rsi_status); + return; + } +#ifndef RS911X_SOCKETS + wfx_lwip_start(); + last_dhcp_poll = xTaskGetTickCount(); + sta_netif = wfx_get_netif(SL_WFX_STA_INTERFACE); +#endif + wfx_started_notify(); + + WFX_RSI_LOG("%s: starting event wait", __func__); +#ifdef CHIP_ONNETWORK_PAIRING + memcpy(&wfx_rsi.sec.ssid[0], TOSTRING(CHIP_WIFI_SSID), sizeof(TOSTRING(CHIP_WIFI_SSID))); + memcpy(&wfx_rsi.sec.passkey[0], TOSTRING(CHIP_WIFI_PSK), sizeof(TOSTRING(CHIP_WIFI_PSK))); + xEventGroupSetBits(wfx_rsi.events, WFX_EVT_STA_START_JOIN); +#endif + + for (;;) + { + /* + * This is the main job of this task. + * Wait for commands from the ConnectivityManager + * Make state changes (based on call backs) + */ + flags = xEventGroupWaitBits(wfx_rsi.events, + WFX_EVT_STA_CONN | WFX_EVT_STA_DISCONN | WFX_EVT_STA_START_JOIN +#ifdef RS911X_SOCKETS + | WFX_EVT_STA_DO_DHCP | WFX_EVT_STA_DHCP_DONE +#endif /* RS911X_SOCKETS */ +#ifdef SL_WFX_CONFIG_SOFTAP + | WFX_EVT_AP_START | WFX_EVT_AP_STOP +#endif /* SL_WFX_CONFIG_SOFTAP */ +#ifdef SL_WFX_CONFIG_SCAN + | WFX_EVT_SCAN +#endif /* SL_WFX_CONFIG_SCAN */ + | 0, + pdTRUE, /* Clear the bits */ + pdFALSE, /* Wait for any bit */ + pdMS_TO_TICKS(250)); /* 250 mSec */ + + if (flags) + { + WFX_RSI_LOG("%s: wait event encountered: %x", __func__, flags); + } +#ifdef RS911X_SOCKETS + if (flags & WFX_EVT_STA_DO_DHCP) + { + /* + * Do DHCP - + */ + if ((status = rsi_config_ipaddress(RSI_IP_VERSION_4, RSI_DHCP | RSI_DHCP_UNICAST_OFFER, NULL, NULL, NULL, + &wfx_rsi.ip4_addr[0], IP_CONF_RSP_BUFF_LENGTH_4, STATION)) != RSI_SUCCESS) + { + /* We should try this again.. (perhaps sleep) */ + /* TODO - Figure out what to do here */ + } + } +#else /* !RS911X_SOCKET - using LWIP */ + /* + * Let's handle DHCP polling here + */ + if (wfx_rsi.dev_state & WFX_RSI_ST_STA_CONNECTED) + { + if ((now = xTaskGetTickCount()) > (last_dhcp_poll + pdMS_TO_TICKS(250))) + { +#if (CHIP_DEVICE_CONFIG_ENABLE_IPV4) + uint8_t dhcp_state = dhcpclient_poll(sta_netif); + if (dhcp_state == DHCP_ADDRESS_ASSIGNED && !hasNotifiedIPV4) + { + wfx_dhcp_got_ipv4((uint32_t) sta_netif->ip_addr.u_addr.ip4.addr); + hasNotifiedIPV4 = true; + if (!hasNotifiedWifiConnectivity) + { + wfx_connected_notify(CONNECTION_STATUS_SUCCESS, &wfx_rsi.ap_mac); + hasNotifiedWifiConnectivity = true; + } + } + else if (dhcp_state == DHCP_OFF) + { + wfx_ip_changed_notify(IP_STATUS_FAIL); + hasNotifiedIPV4 = false; + } +#endif /* CHIP_DEVICE_CONFIG_ENABLE_IPV4 */ + /* Checks if the assigned IPv6 address is preferred by evaluating + * the first block of IPv6 address ( block 0) + */ + if ((ip6_addr_ispreferred(netif_ip6_addr_state(sta_netif, 0))) && !hasNotifiedIPV6) + { + wfx_ipv6_notify(GET_IPV6_SUCCESS); + hasNotifiedIPV6 = true; + if (!hasNotifiedWifiConnectivity) + { + wfx_connected_notify(CONNECTION_STATUS_SUCCESS, &wfx_rsi.ap_mac); + hasNotifiedWifiConnectivity = true; + } + } + last_dhcp_poll = now; + } + } +#endif /* RS911X_SOCKETS */ + if (flags & WFX_EVT_STA_START_JOIN) + { + // saving the AP related info + wfx_rsi_save_ap_info(); + // Joining to the network + wfx_rsi_do_join(); + } + if ((flags & WFX_EVT_STA_CONN)) + { + /* + * Initiate the Join command (assuming we have been provisioned) + */ + WFX_RSI_LOG("%s: starting LwIP STA", __func__); + wfx_rsi.dev_state |= WFX_RSI_ST_STA_CONNECTED; +#ifndef RS911X_SOCKETS + hasNotifiedWifiConnectivity = false; +#if (CHIP_DEVICE_CONFIG_ENABLE_IPV4) + hasNotifiedIPV4 = false; +#endif // CHIP_DEVICE_CONFIG_ENABLE_IPV4 + hasNotifiedIPV6 = false; + wfx_lwip_set_sta_link_up(); +#endif /* !RS911X_SOCKETS */ + /* We need to get AP Mac - TODO */ + // Uncomment once the hook into MATTER is moved to IP connectivity instead + // of AP connectivity. wfx_connected_notify(0, &wfx_rsi.ap_mac); // This + // is independent of IP connectivity. + } + if (flags & WFX_EVT_STA_DISCONN) + { + wfx_rsi.dev_state &= + ~(WFX_RSI_ST_STA_READY | WFX_RSI_ST_STA_CONNECTING | WFX_RSI_ST_STA_CONNECTED | WFX_RSI_ST_STA_DHCP_DONE); + WFX_RSI_LOG("%s: disconnect notify", __func__); + /* TODO: Implement disconnect notify */ +#ifndef RS911X_SOCKETS + wfx_lwip_set_sta_link_down(); // Internally dhcpclient_poll(netif) -> + // wfx_ip_changed_notify(0) for IPV4 +#if (CHIP_DEVICE_CONFIG_ENABLE_IPV4) + wfx_ip_changed_notify(IP_STATUS_FAIL); + hasNotifiedIPV4 = false; +#endif /* CHIP_DEVICE_CONFIG_ENABLE_IPV4 */ + wfx_ipv6_notify(GET_IPV6_FAIL); + hasNotifiedIPV6 = false; + hasNotifiedWifiConnectivity = false; +#endif /* !RS911X_SOCKETS */ + } +#ifdef SL_WFX_CONFIG_SCAN + if (flags & WFX_EVT_SCAN) + { + if (!(wfx_rsi.dev_state & WFX_RSI_ST_SCANSTARTED)) + { + WFX_RSI_LOG("%s: start SSID scan", __func__); + int x; + wfx_wifi_scan_result_t ap; + rsi_scan_info_t * scan; + int32_t status; + uint8_t bgscan_results[BG_SCAN_RES_SIZE] = { 0 }; + status = rsi_wlan_bgscan_profile(1, (rsi_rsp_scan_t *) bgscan_results, BG_SCAN_RES_SIZE); + + WFX_RSI_LOG("%s: status: %02x size = %d", __func__, status, BG_SCAN_RES_SIZE); + rsi_rsp_scan_t * rsp = (rsi_rsp_scan_t *) bgscan_results; + if (status) + { + /* + * Scan is done - failed + */ + } + else + for (x = 0; x < rsp->scan_count[0]; x++) + { + scan = &rsp->scan_info[x]; + strcpy(&ap.ssid[0], (char *) &scan->ssid[0]); + if (wfx_rsi.scan_ssid) + { + WFX_RSI_LOG("Inside scan_ssid"); + WFX_RSI_LOG("SCAN SSID: %s , ap scan: %s", wfx_rsi.scan_ssid, ap.ssid); + if (strcmp(wfx_rsi.scan_ssid, ap.ssid) == CMP_SUCCESS) + { + WFX_RSI_LOG("Inside ap details"); + ap.security = scan->security_mode; + ap.rssi = (-1) * scan->rssi_val; + memcpy(&ap.bssid[0], &scan->bssid[0], BSSID_MAX_STR_LEN); + (*wfx_rsi.scan_cb)(&ap); + } + } + else + { + WFX_RSI_LOG("Inside else"); + ap.security = scan->security_mode; + ap.rssi = (-1) * scan->rssi_val; + memcpy(&ap.bssid[0], &scan->bssid[0], BSSID_MAX_STR_LEN); + (*wfx_rsi.scan_cb)(&ap); + } + } + wfx_rsi.dev_state &= ~WFX_RSI_ST_SCANSTARTED; + /* Terminate with end of scan which is no ap sent back */ + (*wfx_rsi.scan_cb)((wfx_wifi_scan_result_t *) 0); + wfx_rsi.scan_cb = (void (*)(wfx_wifi_scan_result_t *)) 0; + + if (wfx_rsi.scan_ssid) + { + vPortFree(wfx_rsi.scan_ssid); + wfx_rsi.scan_ssid = (char *) 0; + } + } + } +#endif /* SL_WFX_CONFIG_SCAN */ +#ifdef SL_WFX_CONFIG_SOFTAP + /* TODO */ + if (flags & WFX_EVT_AP_START) + { + } + if (flags & WFX_EVT_AP_STOP) + { + } +#endif /* SL_WFX_CONFIG_SOFTAP */ + } +} + +#if CHIP_DEVICE_CONFIG_ENABLE_IPV4 +/******************************************************************************************** + * @fn void wfx_dhcp_got_ipv4(uint32_t ip) + * @brief + * Acquire the new ip address + * @param[in] ip: internet protocol + * @return + * None + **********************************************************************************************/ +void wfx_dhcp_got_ipv4(uint32_t ip) +{ + /* + * Acquire the new IP address + */ + wfx_rsi.ip4_addr[0] = (ip) &HEX_VALUE_FF; + wfx_rsi.ip4_addr[1] = (ip >> 8) & HEX_VALUE_FF; + wfx_rsi.ip4_addr[2] = (ip >> 16) & HEX_VALUE_FF; + wfx_rsi.ip4_addr[3] = (ip >> 24) & HEX_VALUE_FF; + WFX_RSI_LOG("%s: DHCP OK: IP=%d.%d.%d.%d", __func__, wfx_rsi.ip4_addr[0], wfx_rsi.ip4_addr[1], wfx_rsi.ip4_addr[2], + wfx_rsi.ip4_addr[3]); + /* Notify the Connectivity Manager - via the app */ + wfx_ip_changed_notify(IP_STATUS_SUCCESS); + wfx_rsi.dev_state |= WFX_RSI_ST_STA_READY; +} +#endif /* CHIP_DEVICE_CONFIG_ENABLE_IPV4 */ + +/* + * WARNING - Taken from RSI and broken up + * This is my own RSI stuff for not copying code and allocating an extra + * level of indirection - when using LWIP buffers + * see also: int32_t rsi_wlan_send_data_xx(uint8_t *buffer, uint32_t length) + */ +/******************************************************************************************** + * @fn void *wfx_rsi_alloc_pkt() + * @brief + * Allocate packet to send data + * @param[in] None + * @return + * None + **********************************************************************************************/ +void * wfx_rsi_alloc_pkt() +{ + rsi_pkt_t * pkt; + + // Allocate packet to send data + if ((pkt = rsi_pkt_alloc(&rsi_driver_cb->wlan_cb->wlan_tx_pool)) == NULL) + { + return (void *) 0; + } + + return (void *) pkt; +} + +/******************************************************************************************** + * @fn void wfx_rsi_pkt_add_data(void *p, uint8_t *buf, uint16_t len, uint16_t off) + * @brief + * add the data into packet + * @param[in] p: + * @param[in] buf: + * @param[in] len: + * @param[in] off: + * @return + * None + **********************************************************************************************/ +void wfx_rsi_pkt_add_data(void * p, uint8_t * buf, uint16_t len, uint16_t off) +{ + rsi_pkt_t * pkt; + + pkt = (rsi_pkt_t *) p; + memcpy(((char *) pkt->data) + off, buf, len); +} + +/******************************************************************************************** + * @fn int32_t wfx_rsi_send_data(void *p, uint16_t len) + * @brief + * Driver send a data + * @param[in] p: + * @param[in] len: + * @return + * None + **********************************************************************************************/ +int32_t wfx_rsi_send_data(void * p, uint16_t len) +{ + int32_t status; + register uint8_t * host_desc; + rsi_pkt_t * pkt; + + pkt = (rsi_pkt_t *) p; + host_desc = pkt->desc; + memset(host_desc, 0, RSI_HOST_DESC_LENGTH); + rsi_uint16_to_2bytes(host_desc, (len & 0xFFF)); + + // Fill packet type + host_desc[1] |= (RSI_WLAN_DATA_Q << 4); + host_desc[2] |= 0x01; + + rsi_enqueue_pkt(&rsi_driver_cb->wlan_tx_q, pkt); + +#ifndef RSI_SEND_SEM_BITMAP + rsi_driver_cb_non_rom->send_wait_bitmap |= BIT(0); +#endif + // Set TX packet pending event + rsi_set_event(RSI_TX_EVENT); + + if (rsi_wait_on_wlan_semaphore(&rsi_driver_cb_non_rom->send_data_sem, RSI_SEND_DATA_RESPONSE_WAIT_TIME) != RSI_ERROR_NONE) + { + return RSI_ERROR_RESPONSE_TIMEOUT; + } + status = rsi_wlan_get_status(); + + return status; +} + +int32_t wfx_rsi_init_platform() +{ + int32_t status; + /*init task - RS911x*/ + WFX_RSI_LOG("RSI_INIT"); + WFX_RSI_LOG("%s: starting(HEAP_SZ = %d)", __func__, SL_HEAP_SIZE); + //! Driver initialization + status = rsi_driver_init(wfx_rsi_drv_buf, WFX_RSI_BUF_SZ); + if ((status < RSI_DRIVER_STATUS) || (status > WFX_RSI_BUF_SZ)) + { + WFX_RSI_LOG("%s: error: RSI drv init failed with status: %02x", __func__, status); + } + + WFX_RSI_LOG("%s: rsi_device_init", __func__); + /* ! Redpine module intialisation */ + if ((status = rsi_device_init(LOAD_NWP_FW)) != RSI_SUCCESS) + { + WFX_RSI_LOG("%s: error: rsi_device_init failed with status: %02x", __func__, status); + return status; + } + + return status; +} + +struct wfx_rsi wfx_rsi; diff --git a/examples/platform/silabs/SiWx917/SiWx917/rsi_wlan_config.h b/examples/platform/silabs/SiWx917/SiWx917/rsi_wlan_config.h new file mode 100644 index 00000000000000..4f2dc070ec83ac --- /dev/null +++ b/examples/platform/silabs/SiWx917/SiWx917/rsi_wlan_config.h @@ -0,0 +1,570 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef RSI_CONFIG_H +#define RSI_CONFIG_H + +#include "rsi_wlan_defines.h" + +//! Enable feature +#define RSI_ENABLE 1 +//! Disable feature +#define RSI_DISABLE 0 + +//! To enable concurrent mode +#define CONCURRENT_MODE RSI_DISABLE + +//! opermode command paramaters +/*=======================================================================*/ +//! To set wlan feature select bit map +#define RSI_FEATURE_BIT_MAP (FEAT_SECURITY_OPEN) + +//! TCP IP BYPASS feature check +//#define RSI_TCP_IP_BYPASS RSI_DISABLE +//! TCP/IP feature select bitmap for selecting TCP/IP features +//#define RSI_TCP_IP_FEATURE_BIT_MAP (TCP_IP_FEAT_DHCPV4_CLIENT | TCP_IP_FEAT_ICMP) + +#define RSI_TCP_IP_BYPASS RSI_ENABLE +//#define RSI_TCP_IP_FEATURE_BIT_MAP (TCP_IP_FEAT_DHCPV4_CLIENT | TCP_IP_FEAT_ICMP) +#define RSI_TCP_IP_FEATURE_BIT_MAP (TCP_IP_FEAT_BYPASS /*| TCP_IP_FEAT_EXTENSION_VALID*/) + +//! To set custom feature select bit map +#define RSI_CUSTOM_FEATURE_BIT_MAP FEAT_CUSTOM_FEAT_EXTENTION_VALID + +//! To set Extended custom feature select bit map +#define RSI_EXT_CUSTOM_FEATURE_BIT_MAP EXT_FEAT_UART_SEL_FOR_DEBUG_PRINTS + +#define RSI_EXT_TCPIP_FEATURE_BITMAP 0 + +/*=======================================================================*/ +//! Feature frame parameters +/*=======================================================================*/ +#define PLL_MODE 0 +#define RF_TYPE 1 //! 0 - External RF 1- Internal RF +#define WIRELESS_MODE 0 +#define ENABLE_PPP 0 +#define AFE_TYPE 1 +#define FEATURE_ENABLES 0 +/*=======================================================================*/ +//! Band command paramters +/*=======================================================================*/ + +//! RSI_BAND_2P4GHZ(2.4GHz) or RSI_BAND_5GHZ(5GHz) or RSI_DUAL_BAND +#define RSI_BAND RSI_BAND_2P4GHZ +/*=======================================================================*/ +//! set region command paramters +/*=======================================================================*/ + +//! RSI_ENABLE or RSI_DISABLE Set region support +#define RSI_SET_REGION_SUPPORT RSI_DISABLE //@ RSI_ENABLE or RSI_DISABLE set region + +//! If 1:region configurations taken from user ;0:region configurations taken from beacon +#define RSI_SET_REGION_FROM_USER_OR_BEACON 1 + +//! 0-Default Region domain ,1-US, 2-EUROPE, 3-JAPAN +#define RSI_REGION_CODE 3 + +//! 0- Without On Board Antenna , 1- With On Board Antenna +#define RSI_MODULE_TYPE 1 + +/*=======================================================================*/ +//! set region AP command paramters +/*=======================================================================*/ + +//! RSI_ENABLE or RSI_DISABLE Set region AP support +#define RSI_SET_REGION_AP_SUPPORT RSI_DISABLE + +//! If 1:region configurations taken from user ;0:region configurations taken from firmware +#define RSI_SET_REGION_AP_FROM_USER RSI_DISABLE + +//! "US" or "EU" or "JP" or other region codes +#define RSI_COUNTRY_CODE "US " + +/*=======================================================================*/ + +//! Rejoin parameters +/*=======================================================================*/ + +//! RSI_ENABLE or RSI_DISABLE rejoin params +#define RSI_REJOIN_PARAMS_SUPPORT RSI_DISABLE + +//! Rejoin retry count. If 0 retries infinity times +#define RSI_REJOIN_MAX_RETRY 0 + +//! Periodicity of rejoin attempt +#define RSI_REJOIN_SCAN_INTERVAL 4 + +//! Beacon missed count +#define RSI_REJOIN_BEACON_MISSED_COUNT 40 + +//! RSI_ENABLE or RSI_DISABLE retry for first time join failure +#define RSI_REJOIN_FIRST_TIME_RETRY RSI_DISABLE + +/*=======================================================================*/ + +//! BG scan command parameters +/*=======================================================================*/ + +//! RSI_ENABLE or RSI_DISABLE BG Scan support +#define RSI_BG_SCAN_SUPPORT RSI_DISABLE + +//! RSI_ENABLE or RSI_DISABLE BG scan +#define RSI_BG_SCAN_ENABLE RSI_ENABLE + +//! RSI_ENABLE or RSI_DISABLE instant BG scan +#define RSI_INSTANT_BG 1 // RSI_DISABLE + +//! BG scan threshold value +#define RSI_BG_SCAN_THRESHOLD 63 + +//! RSSI tolerance Threshold +#define RSI_RSSI_TOLERANCE_THRESHOLD 4 + +//! BG scan periodicity +#define RSI_BG_SCAN_PERIODICITY 2 + +//! Active scan duration +#define RSI_ACTIVE_SCAN_DURATION 50 + +//! Passive scan duration +#define RSI_PASSIVE_SCAN_DURATION 50 + +//! Multi probe +#define RSI_MULTIPROBE RSI_DISABLE + +/*=======================================================================*/ + +//! RSI_ENABLE or RSI_DISABLE to set RTS threshold config +#define RSI_WLAN_CONFIG_ENABLE RSI_ENABLE + +#define CONFIG_RTSTHRESHOLD 1 + +#define RSI_RTS_THRESHOLD 2346 + +/*=======================================================================*/ + +//! Roaming parameters +/*=======================================================================*/ + +//! RSI_ENABLE or RSI_DISABLE Roaming support +#define RSI_ROAMING_SUPPORT RSI_DISABLE + +//! roaming threshold value +#define RSI_ROAMING_THRESHOLD 67 + +//! roaming hysterisis value +#define RSI_ROAMING_HYSTERISIS 4 + +/*=======================================================================*/ +//! High Throughput Capabilies related information +/*=======================================================================*/ + +//! RSI_ENABLE or RSI_DISABLE 11n mode in AP mode +#define RSI_MODE_11N_ENABLE RSI_DISABLE + +//! HT caps bit map. +#define RSI_HT_CAPS_BIT_MAP 10 + +/*=======================================================================*/ +//! Scan command parameters +/*=======================================================================*/ + +//! scan channel bit map in 2.4GHz band,valid if given channel to scan is 0 +#define RSI_SCAN_CHANNEL_BIT_MAP_2_4 0 + +//! scan channle bit map in 5GHz band ,valid if given channel to scan is 0 +#define RSI_SCAN_CHANNEL_BIT_MAP_5 0 + +//! scan_feature_bitmap ,valid only if specific channel to scan and ssid are given +#define RSI_SCAN_FEAT_BITMAP 0 + +/*=======================================================================*/ +//! Enterprise configuration command parameters +/*=======================================================================*/ + +//! Enterprise method ,should be one of among TLS, TTLS, FAST or PEAP +#define RSI_EAP_METHOD "TTLS" +//! This parameter is used to configure the module in Enterprise security mode +#define RSI_EAP_INNER_METHOD "\"auth=MSCHAPV2\"" +//! Private Key Password is required for encrypted private key, format is like "\"12345678\"" +#define RSI_PRIVATE_KEY_PASSWORD "" +/*=======================================================================*/ +//! AP configuration command parameters +/*=======================================================================*/ + +//! This Macro is used to enable AP keep alive functionality +#define RSI_AP_KEEP_ALIVE_ENABLE RSI_ENABLE + +//! This parameter is used to configure keep alive type +#define RSI_AP_KEEP_ALIVE_TYPE RSI_NULL_BASED_KEEP_ALIVE + +//! This parameter is used to configure keep alive period +#define RSI_AP_KEEP_ALIVE_PERIOD 100 + +//! This parameter is used to configure maximum stations supported +#define RSI_MAX_STATIONS_SUPPORT 4 +/*=======================================================================*/ +//! Join command parameters +/*=======================================================================*/ + +//! Tx power level +#define RSI_POWER_LEVEL RSI_POWER_LEVEL_HIGH + +//! RSI_JOIN_FEAT_STA_BG_ONLY_MODE_ENABLE or RSI_JOIN_FEAT_LISTEN_INTERVAL_VALID +#define RSI_JOIN_FEAT_BIT_MAP 0 + +//! +#define RSI_LISTEN_INTERVAL 0 + +//! Transmission data rate. Physical rate at which data has to be transmitted. +#define RSI_DATA_RATE RSI_DATA_RATE_AUTO + +/*=======================================================================*/ +//! Ipconf command parameters +/*=======================================================================*/ + +//! DHCP client host name +#define RSI_DHCP_HOST_NAME "dhcp_client" + +//! Transmit test command parameters +/*=======================================================================*/ +//! TX TEST rate flags +#define RSI_TX_TEST_RATE_FLAGS 0 + +//! TX TEST per channel bandwidth +#define RSI_TX_TEST_PER_CH_BW 0 + +//! TX TEST aggregation enable or disable +#define RSI_TX_TEST_AGGR_ENABLE RSI_DISABLE + +//! TX TEST delay +#define RSI_TX_TEST_DELAY 0 + +/*======================================================================*/ +//! ssl parameters +/*=======================================================================*/ +//! ssl version +#define RSI_SSL_VERSION 0 + +//! ssl ciphers +#define RSI_SSL_CIPHERS SSL_ALL_CIPHERS + +//! Enable TCP over SSL with TLS version depends on remote side +#define PROTOCOL_DFLT_VERSION BIT(0) + +//! Enable TCP over SSL with TLS version 1.0 +#define PROTOCOL_TLS_1_0 (BIT(0) | BIT(13)) + +//! Enable TCP over SSL with TLS version 1.1 +#define PROTOCOL_TLS_1_1 (BIT(0) | BIT(14)) + +//! Enable TCP over SSL with TLS version 1.2 +#define PROTOCOL_TLS_1_2 (BIT(0) | BIT(15)) +/*=======================================================================*/ +//! Power save command parameters +/*=======================================================================*/ +//! set handshake type of power mode +#define RSI_HAND_SHAKE_TYPE MSG_BASED + +//! 0 - LP, 1- ULP mode with RAM retention and 2 - ULP with Non RAM retention +#define RSI_SELECT_LP_OR_ULP_MODE RSI_ULP_WITH_RAM_RET + +//! set DTIM aligment required +//! 0 - module wakes up at beacon which is just before or equal to listen_interval +//! 1 - module wakes up at DTIM beacon which is just before or equal to listen_interval +#define RSI_DTIM_ALIGNED_TYPE 0 + +//! Monitor interval for the FAST PSP mode +//! default is 50 ms, and this parameter is valid for FAST PSP only +#define RSI_MONITOR_INTERVAL 50 + +//! Number of DTIMs to skip during powersave +#define RSI_NUM_OF_DTIM_SKIP 0 + +//! WMM PS parameters +//! set wmm enable or disable +#define RSI_WMM_PS_ENABLE RSI_DISABLE + +//! set wmm enable or disable +//! 0- TX BASED 1 - PERIODIC +#define RSI_WMM_PS_TYPE 0 + +//! set wmm wake up interval +#define RSI_WMM_PS_WAKE_INTERVAL 20 + +//! set wmm UAPSD bitmap +#define RSI_WMM_PS_UAPSD_BITMAP 15 + +/*=======================================================================*/ +//! Socket configuration +/*=======================================================================*/ +//! RSI_ENABLE or RSI_DISABLE High performance socket +#define HIGH_PERFORMANCE_ENABLE RSI_ENABLE //@ RSI_ENABLE or RSI_DISABLE High performance socket + +#define TOTAL_SOCKETS 1 //@ Total number of sockets. TCP TX + TCP RX + UDP TX + UDP RX +#define TOTAL_TCP_SOCKETS 1 //@ Total TCP sockets. TCP TX + TCP RX +#define TOTAL_UDP_SOCKETS 0 //@ Total UDP sockets. UDP TX + UDP RX +#define TCP_TX_ONLY_SOCKETS 0 //@ Total TCP TX only sockets. TCP TX +#define TCP_RX_ONLY_SOCKETS 1 //@ Total TCP RX only sockets. TCP RX +#define UDP_TX_ONLY_SOCKETS 0 //@ Total UDP TX only sockets. UDP TX +#define UDP_RX_ONLY_SOCKETS 0 //@ Total UDP RX only sockets. UDP RX +#define TCP_RX_HIGH_PERFORMANCE_SOCKETS 1 //@ Total TCP RX High Performance sockets +#define TCP_RX_WINDOW_SIZE_CAP 10 //@ TCP RX Window size +#define TCP_RX_WINDOW_DIV_FACTOR 10 //@ TCP RX Window division factor +/*=======================================================================*/ + +//! Socket Create parameters +/*=======================================================================*/ + +//! Initial timeout for Socket +#define RSI_SOCKET_KEEPALIVE_TIMEOUT 1200 + +//! VAP ID for Concurrent mode +#define RSI_VAP_ID 0 + +//! Timeout for join or scan +/*=======================================================================*/ + +//! RSI_ENABLE or RSI_DISABLE Timeout support +#define RSI_TIMEOUT_SUPPORT RSI_DISABLE + +//! roaming threshold value +#define RSI_TIMEOUT_BIT_MAP 1 + +//! roaming hysterisis value +#define RSI_TIMEOUT_VALUE 1500 + +//! Timeout for ping request +/*=======================================================================*/ + +//! Timeout for PING_REQUEST +#define RSI_PING_REQ_TIMEOUT_MS 1000 + +//! Store Config Profile parameters +/*=======================================================================*/ + +//! Client profile +#define RSI_WLAN_PROFILE_CLIENT 0 +//! P2P profile +#define RSI_WLAN_PROFILE_P2P 1 +//! EAP profile +#define RSI_WLAN_PROFILE_EAP 2 +//! AP profile +#define RSI_WLAN_PROFILE_AP 6 +//! All profiles +#define RSI_WLAN_PROFILE_ALL 0xFF + +//! AP Config Profile Parameters +/*==============================================================================*/ + +//! Transmission data rate. Physical rate at which data has to be transmitted. +#define RSI_CONFIG_AP_DATA_RATE RSI_DATA_RATE_AUTO +//! To set wlan feature select bit map +#define RSI_CONFIG_AP_WLAN_FEAT_BIT_MAP (FEAT_SECURITY_PSK) +//! TCP/IP feature select bitmap for selecting TCP/IP features +#define RSI_CONFIG_AP_TCP_IP_FEAT_BIT_MAP (TCP_IP_FEAT_DHCPV4_SERVER) +//! To set custom feature select bit map +#define RSI_CONFIG_AP_CUSTOM_FEAT_BIT_MAP 0 +//! Tx power level +#define RSI_CONFIG_AP_TX_POWER RSI_POWER_LEVEL_HIGH +//! AP SSID +#define RSI_CONFIG_AP_SSID "SILABS_AP" +//! RSI_BAND_2P4GHZ(2.4GHz) or RSI_BAND_5GHZ(5GHz) or RSI_DUAL_BAND +#define RSI_CONFIG_AP_BAND RSI_BAND_2P4GHZ +//! To configure AP channle number +#define RSI_CONFIG_AP_CHANNEL 6 +//! To configure security type +#define RSI_CONFIG_AP_SECURITY_TYPE RSI_WPA +//! To configure encryption type +#define RSI_CONFIG_AP_ENCRYPTION_TYPE 1 +//! To configure PSK +#define RSI_CONFIG_AP_PSK "1234567890" +//! To configure beacon interval +#define RSI_CONFIG_AP_BEACON_INTERVAL 100 +//! To configure DTIM period +#define RSI_CONFIG_AP_DTIM 2 +//! This parameter is used to configure keep alive type +#define RSI_CONFIG_AP_KEEP_ALIVE_TYPE 0 //! RSI_NULL_BASED_KEEP_ALIVE + +#define RSI_CONFIG_AP_KEEP_ALIVE_COUNTER 0 //! 100 +//! This parameter is used to configure keep alive period +#define RSI_CONFIG_AP_KEEP_ALIVE_PERIOD 100 +//! This parameter is used to configure maximum stations supported +#define RSI_CONFIG_AP_MAX_STATIONS_COUNT 4 +//! P2P Network parameters +//! TCP_STACK_USED BIT(0) - IPv4, BIT(1) -IPv6, (BIT(0) | BIT(1)) - Both IPv4 and IPv6 +#define RSI_CONFIG_AP_TCP_STACK_USED BIT(0) +//! IP address of the module +//! E.g: 0x0A0AA8C0 == 192.168.10.10 +#define RSI_CONFIG_AP_IP_ADDRESS 0x0A0AA8C0 +//! IP address of netmask +//! E.g: 0x00FFFFFF == 255.255.255.0 +#define RSI_CONFIG_AP_SN_MASK_ADDRESS 0x00FFFFFF +//! IP address of Gateway +//! E.g: 0x0A0AA8C0 == 192.168.10.10 +#define RSI_CONFIG_AP_GATEWAY_ADDRESS 0x0A0AA8C0 + +//! Client Profile Parameters +/* ===================================================================================== */ + +//! To configure data rate +#define RSI_CONFIG_CLIENT_DATA_RATE RSI_DATA_RATE_AUTO +//! To configure wlan feature bitmap +#define RSI_CONFIG_CLIENT_WLAN_FEAT_BIT_MAP 0 +//! To configure tcp/ip feature bitmap +#define RSI_CONFIG_CLIENT_TCP_IP_FEAT_BIT_MAP BIT(2) +//! To configure custom feature bit map +#define RSI_CONFIG_CLIENT_CUSTOM_FEAT_BIT_MAP 0 +//! To configure TX power +#define RSI_CONFIG_CLIENT_TX_POWER RSI_POWER_LEVEL_HIGH +//! To configure listen interval +#define RSI_CONFIG_CLIENT_LISTEN_INTERVAL 0 +//! To configure SSID +#define RSI_CONFIG_CLIENT_SSID "SILABS_AP" +//! RSI_BAND_2P4GHZ(2.4GHz) or RSI_BAND_5GHZ(5GHz) or RSI_DUAL_BAND +#define RSI_CONFIG_CLIENT_BAND RSI_BAND_2P4GHZ +//! To configure channel number +#define RSI_CONFIG_CLIENT_CHANNEL 0 +//! To configure security type +#define RSI_CONFIG_CLIENT_SECURITY_TYPE 0 // RSI_WPA +//! To configure encryption type +#define RSI_CONFIG_CLIENT_ENCRYPTION_TYPE 0 +//! To configure PSK +#define RSI_CONFIG_CLIENT_PSK "1234567890" +//! To configure PMK +#define RSI_CONFIG_CLIENT_PMK "" +//! Client Network parameters +//! TCP_STACK_USED BIT(0) - IPv4, BIT(1) -IPv6, (BIT(0) | BIT(1)) - Both IPv4 and IPv6 +#define RSI_CONFIG_CLIENT_TCP_STACK_USED BIT(0) +//! DHCP mode 1- Enable 0- Disable +//! If DHCP mode is disabled given IP statically +#define RSI_CONFIG_CLIENT_DHCP_MODE RSI_DHCP +//! IP address of the module +//! E.g: 0x0A0AA8C0 == 192.168.10.10 +#define RSI_CONFIG_CLIENT_IP_ADDRESS 0x0A0AA8C0 +//! IP address of netmask +//! E.g: 0x00FFFFFF == 255.255.255.0 +#define RSI_CONFIG_CLIENT_SN_MASK_ADDRESS 0x00FFFFFF +//! IP address of Gateway +//! E.g: 0x010AA8C0 == 192.168.10.1 +#define RSI_CONFIG_CLIENT_GATEWAY_ADDRESS 0x010AA8C0 +//! scan channel bit map in 2.4GHz band,valid if given channel to scan is 0 +#define RSI_CONFIG_CLIENT_SCAN_FEAT_BITMAP 0 +//! Scan channel magic code +#define RSI_CONFIG_CLIENT_MAGIC_CODE 0x4321 +//! scan channel bit map in 2.4GHz band,valid if given channel to scan is 0 +#define RSI_CONFIG_CLIENT_SCAN_CHAN_BITMAP_2_4_GHZ 0 +//! scan channle bit map in 5GHz band ,valid if given channel to scan is 0 +#define RSI_CONFIG_CLIENT_SCAN_CHAN_BITMAP_5_0_GHZ 0 + +//! EAP Client Profile Parameters +/* =========================================================================== */ + +//! To configure data rate +#define RSI_CONFIG_EAP_DATA_RATE RSI_DATA_RATE_AUTO +//! To configure wlan feature bitmap +#define RSI_CONFIG_EAP_WLAN_FEAT_BIT_MAP 0 +//! To configure tcp/ip feature bitmap +#define RSI_CONFIG_EAP_TCP_IP_FEAT_BIT_MAP BIT(2) +//! To configure custom feature bit map +#define RSI_CONFIG_EAP_CUSTOM_FEAT_BIT_MAP 0 +//! To configure EAP TX power +#define RSI_CONFIG_EAP_TX_POWER RSI_POWER_LEVEL_HIGH +//! To Configure scan channel feature bitmap +#define RSI_CONFIG_EAP_SCAN_FEAT_BITMAP 0 +//! scan channel bit map in 2.4GHz band,valid if given channel to scan is 0 +#define RSI_CONFIG_EAP_CHAN_MAGIC_CODE 0 // 0x4321 +//! scan channel bit map in 2.4GHz band,valid if given channel to scan is 0 +#define RSI_CONFIG_EAP_SCAN_CHAN_BITMAP_2_4_GHZ 0 +//! scan channle bit map in 5GHz band ,valid if given channel to scan is 0 +#define RSI_CONFIG_EAP_SCAN_CHAN_BITMAP_5_0_GHZ 0 +//! To configure SSID +#define RSI_CONFIG_EAP_SSID "SILABS_AP" +//! RSI_BAND_2P4GHZ(2.4GHz) or RSI_BAND_5GHZ(5GHz) or RSI_DUAL_BAND +#define RSI_CONFIG_EAP_BAND RSI_BAND_2P4GHZ +//! To set security type +#define RSI_CONFIG_EAP_SECURITY_TYPE RSI_WPA2_EAP +//! To set encryption type +#define RSI_CONFIG_EAP_ENCRYPTION_TYPE 0 +//! To set channel number +#define RSI_CONFIG_EAP_CHANNEL 0 +//! Enterprise method ,should be one of among TLS, TTLS, FAST or PEAP +#define RSI_CONFIG_EAP_METHOD "TLS" +//! This parameter is used to configure the module in Enterprise security mode +#define RSI_CONFIG_EAP_INNER_METHOD "\"auth=MSCHAPV2\"" +//! To configure EAP user identity +#define RSI_CONFIG_EAP_USER_IDENTITY "\"user1\"" +//! TO configure EAP password +#define RSI_CONFIG_EAP_PASSWORD "\"test123\"" +//! EAP Network parameters +//! TCP_STACK_USED BIT(0) - IPv4, BIT(1) -IPv6, (BIT(0) | BIT(1)) - Both IPv4 and IPv6 +#define RSI_CONFIG_EAP_TCP_STACK_USED BIT(0) +//! DHCP mode 1- Enable 0- Disable +//! If DHCP mode is disabled given IP statically +#define RSI_CONFIG_EAP_DHCP_MODE RSI_DHCP +//! IP address of the module +//! E.g: 0x0A0AA8C0 == 192.168.10.10 +#define RSI_CONFIG_EAP_IP_ADDRESS 0x0A0AA8C0 +//! IP address of netmask +//! E.g: 0x00FFFFFF == 255.255.255.0 +#define RSI_CONFIG_EAP_SN_MASK_ADDRESS 0x00FFFFFF +//! IP address of Gateway +//! E.g: 0x010AA8C0 == 192.168.10.1 +#define RSI_CONFIG_EAP_GATEWAY_ADDRESS 0x010AA8C0 + +//! P2P Profile parameters +/* ================================================================================= */ + +//! To configure data rate +#define RSI_CONFIG_P2P_DATA_RATE RSI_DATA_RATE_AUTO +//! To configure wlan feature bitmap +#define RSI_CONFIG_P2P_WLAN_FEAT_BIT_MAP 0 +//! To configure P2P tcp/ip feature bitmap +#define RSI_CONFIG_P2P_TCP_IP_FEAT_BIT_MAP BIT(2) +//! To configure P2P custom feature bitmap +#define RSI_CONFIG_P2P_CUSTOM_FEAT_BIT_MAP 0 +//! TO configure P2P tx power level +#define RSI_CONFIG_P2P_TX_POWER RSI_POWER_LEVEL_HIGH +//! Set P2P go intent +#define RSI_CONFIG_P2P_GO_INTNET 16 //! Support only Autonomous GO mode +//! Set device name +#define RSI_CONFIG_P2P_DEVICE_NAME "WSC1.1" +//! Set device operating channel +#define RSI_CONFIG_P2P_OPERATING_CHANNEL 11 +//! Set SSID postfix +#define RSI_CONFIG_P2P_SSID_POSTFIX "WSC_1_0_0" +//! Set P2P join SSID +#define RSI_CONFIG_P2P_JOIN_SSID "SILABS_AP" +//! Set psk key +#define RSI_CONFIG_P2P_PSK_KEY "12345678" +//! P2P Network parameters +//! TCP_STACK_USED BIT(0) - IPv4, BIT(1) -IPv6, (BIT(0) | BIT(1)) - Both IPv4 and IPv6 +#define RSI_CONFIG_P2P_TCP_STACK_USED BIT(0) +//! DHCP mode 1- Enable 0- Disable +//! If DHCP mode is disabled given IP statically +#define RSI_CONFIG_P2P_DHCP_MODE 1 +//! IP address of the module +//! E.g: 0x0A0AA8C0 == 192.168.10.10 +#define RSI_CONFIG_P2P_IP_ADDRESS 0x0A0AA8C0 +//! IP address of netmask +//! E.g: 0x00FFFFFF == 255.255.255.0 +#define RSI_CONFIG_P2P_SN_MASK_ADDRESS 0x00FFFFFF +//! IP address of Gateway +//! E.g: 0x010AA8C0 == 192.168.10.1 +#define RSI_CONFIG_P2P_GATEWAY_ADDRESS 0x010AA8C0 + +#endif diff --git a/examples/platform/silabs/SiWx917/SiWx917/wfx_rsi.h b/examples/platform/silabs/SiWx917/SiWx917/wfx_rsi.h new file mode 100644 index 00000000000000..4309e97ccc04d5 --- /dev/null +++ b/examples/platform/silabs/SiWx917/SiWx917/wfx_rsi.h @@ -0,0 +1,100 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef _WFX_RSI_H_ +#define _WFX_RSI_H_ +/* + * Interface to RSI Sapis + */ + +#define WFX_RSI_WLAN_TASK_SZ (1024 + 512 + 256 + 1024 + 512) /* Unknown how big this should be */ +#define WFX_RSI_TASK_SZ (1024 + 1024 + 1024) /* Stack for the WFX/RSI task */ +#define WFX_RSI_BUF_SZ (1024 * 15) /* May need tweak */ +#define WFX_RSI_CONFIG_MAX_JOIN 5 /* Max join retries */ +#define WFX_RSI_NUM_TIMERS 2 /* Number of RSI timers to alloc */ + +/* + * Various events fielded by the wfx_rsi task + * Make sure that we only use 8 bits (otherwise freeRTOS - may need some changes) + */ +#define WFX_EVT_STA_CONN 0x01 +#define WFX_EVT_STA_DISCONN 0x02 +#define WFX_EVT_AP_START 0x04 +#define WFX_EVT_AP_STOP 0x08 +#define WFX_EVT_SCAN 0x10 /* This is used as scan result and start */ +#define WFX_EVT_STA_START_JOIN 0x20 +#define WFX_EVT_STA_DO_DHCP 0x40 +#define WFX_EVT_STA_DHCP_DONE 0x80 + +#define WFX_RSI_ST_DEV_READY 0x01 +#define WFX_RSI_ST_AP_READY 0x02 +#define WFX_RSI_ST_STA_PROVISIONED 0x04 +#define WFX_RSI_ST_STA_CONNECTING 0x08 +#define WFX_RSI_ST_STA_CONNECTED 0x10 +#define WFX_RSI_ST_STA_DHCP_DONE 0x40 /* Requested to do DHCP after conn */ +#define WFX_RSI_ST_STA_MODE 0x80 /* Enable Station Mode */ +#define WFX_RSI_ST_AP_MODE 0x100 /* Enable AP Mode */ +#define WFX_RSI_ST_STA_READY (WFX_RSI_ST_STA_CONNECTED | WFX_RSI_ST_STA_DHCP_DONE) +#define WFX_RSI_ST_STARTED 0x200 /* RSI task started */ +#define WFX_RSI_ST_SCANSTARTED 0x400 /* Scan Started */ + +struct wfx_rsi +{ + EventGroupHandle_t events; + TaskHandle_t drv_task; + TaskHandle_t wlan_task; + TaskHandle_t init_task; + TaskHandle_t ble_task; + uint16_t dev_state; + uint16_t ap_chan; /* The chan our STA is using */ + wfx_wifi_provision_t sec; +#ifdef SL_WFX_CONFIG_SCAN + void (*scan_cb)(wfx_wifi_scan_result_t *); + char * scan_ssid; /* Which one are we scanning for */ +#endif +#ifdef SL_WFX_CONFIG_SOFTAP + sl_wfx_mac_address_t softap_mac; +#endif + sl_wfx_mac_address_t sta_mac; + sl_wfx_mac_address_t ap_mac; /* To which our STA is connected */ + sl_wfx_mac_address_t ap_bssid; /* To which our STA is connected */ + uint16_t join_retries; + uint8_t ip4_addr[4]; /* Not sure if this is enough */ +}; +#define RSI_SCAN_RESP_SZ 54 + +extern struct wfx_rsi wfx_rsi; +#ifdef __cplusplus +extern "C" { +#endif +void wfx_rsidev_init(void); +void wfx_rsi_task(void * arg); +void efr32Log(const char * aFormat, ...); +#if CHIP_DEVICE_CONFIG_ENABLE_IPV4 +void wfx_ip_changed_notify(int got_ip); +#endif /* CHIP_DEVICE_CONFIG_ENABLE_IPV4 */ +int32_t wfx_rsi_get_ap_info(wfx_wifi_scan_result_t * ap); +int32_t wfx_rsi_get_ap_ext(wfx_wifi_scan_ext_t * extra_info); +int32_t wfx_rsi_reset_count(); +int32_t wfx_rsi_disconnect(); +#define WFX_RSI_LOG(...) efr32Log(__VA_ARGS__); + +#ifdef __cplusplus +} +#endif + +#endif /* _WFX_RSI_H_ */ diff --git a/examples/platform/silabs/SiWx917/SiWx917/wfx_rsi_host.c b/examples/platform/silabs/SiWx917/SiWx917/wfx_rsi_host.c new file mode 100644 index 00000000000000..f44b6e9b8f7ff0 --- /dev/null +++ b/examples/platform/silabs/SiWx917/SiWx917/wfx_rsi_host.c @@ -0,0 +1,441 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include "stdbool.h" +#include +#include +#include + +#include "sl_status.h" + +#include "FreeRTOS.h" +#include "event_groups.h" +#include "task.h" + +#include "wfx_host_events.h" +#include "wfx_rsi.h" + +/* wfxRsi Task will use as its stack */ +StackType_t wfxRsiTaskStack[WFX_RSI_TASK_SZ] = { 0 }; + +/* Structure that will hold the TCB of the wfxRsi Task being created. */ +StaticTask_t wfxRsiTaskBuffer; + +/********************************************************************* + * @fn sl_status_t wfx_wifi_start(void) + * @brief + * Called from ConnectivityManagerImpl.cpp - to enable the device + * Create the RSI task and let it deal with life. + * @param[in] None + * @return Returns SL_STATUS_OK if successful, + * SL_STATUS_FAIL otherwise + ***********************************************************************/ +sl_status_t wfx_wifi_start(void) +{ + if (wfx_rsi.dev_state & WFX_RSI_ST_STARTED) + { + WFX_RSI_LOG("%s: already started.", __func__); + return SL_STATUS_OK; + } + wfx_rsi.dev_state |= WFX_RSI_ST_STARTED; + WFX_RSI_LOG("%s: starting..", __func__); + /* + * Create the Wifi driver task + */ + wfx_rsi.wlan_task = xTaskCreateStatic(wfx_rsi_task, "wfx_rsi", WFX_RSI_TASK_SZ, NULL, WLAN_DRIVER_TASK_PRIORITY, + wfxRsiTaskStack, &wfxRsiTaskBuffer); + + if (NULL == wfx_rsi.wlan_task) + { + WFX_RSI_LOG("%s: error: failed to create task.", __func__); + return SL_STATUS_FAIL; + } + return SL_STATUS_OK; +} + +int32_t wfx_rsi_platform() +{ + return wfx_rsi_init_platform(); +} + +/********************************************************************* + * @fn void wfx_enable_sta_mode(void) + * @brief + * driver enable the STA mode + * @param[in] None + * @return None + ***********************************************************************/ +void wfx_enable_sta_mode(void) +{ + wfx_rsi.dev_state |= WFX_RSI_ST_STA_MODE; +} + +/********************************************************************* + * @fn bool wfx_is_sta_mode_enabled(void) + * @brief + * driver enabled the STA mode + * @param[in] None + * @return mode + ***********************************************************************/ +bool wfx_is_sta_mode_enabled(void) +{ + bool mode; + mode = !!(wfx_rsi.dev_state & WFX_RSI_ST_STA_MODE); + // WFX_RSI_LOG("%s: %d", __func__, (mode ? "yes" : "no")); + return mode; +} + +/********************************************************************* + * @fn sl_wfx_state_t wfx_get_wifi_state(void) + * @brief + * get the wifi state + * @param[in] None + * @return return SL_WFX_NOT_INIT if successful, + * SL_WFX_started otherwise + ***********************************************************************/ +sl_wfx_state_t wfx_get_wifi_state(void) +{ + if (wfx_rsi.dev_state & WFX_RSI_ST_STA_DHCP_DONE) + { + return SL_WFX_STA_INTERFACE_CONNECTED; + } + if (wfx_rsi.dev_state & WFX_RSI_ST_DEV_READY) + { + return SL_WFX_STARTED; + } + return SL_WFX_NOT_INIT; +} + +/********************************************************************* + * @fn sl_wfx_state_t wfx_get_wifi_state(void) + * @brief + * get the wifi mac address + * @param[in] Interface: + * @param[in] addr : address + * @return + * None + ***********************************************************************/ +void wfx_get_wifi_mac_addr(sl_wfx_interface_t interface, sl_wfx_mac_address_t * addr) +{ + sl_wfx_mac_address_t * mac; + +#ifdef SL_WFX_CONFIG_SOFTAP + mac = (interface == SL_WFX_SOFTAP_INTERFACE) ? &wfx_rsi.softap_mac : &wfx_rsi.sta_mac; +#else + mac = &wfx_rsi.sta_mac; +#endif + *addr = *mac; + WFX_RSI_LOG("%s: %02x:%02x:%02x:%02x:%02x:%02x", __func__, mac->octet[0], mac->octet[1], mac->octet[2], mac->octet[3], + mac->octet[4], mac->octet[5]); +} + +/********************************************************************* + * @fn void wfx_set_wifi_provision(wfx_wifi_provision_t *cfg) + * @brief + * Driver set the wifi provision + * @param[in] cfg: wifi configuration + * @return + * None + ***********************************************************************/ +void wfx_set_wifi_provision(wfx_wifi_provision_t * cfg) +{ + WFX_RSI_LOG("%s: SSID: %s", __func__, &wfx_rsi.sec.ssid[0]); + + wfx_rsi.sec = *cfg; + wfx_rsi.dev_state |= WFX_RSI_ST_STA_PROVISIONED; +} + +/********************************************************************* + * @fn bool wfx_get_wifi_provision(wfx_wifi_provision_t *wifiConfig) + * @brief + * Driver get the wifi provision + * @param[in] wifiConfig: wifi configuration + * @return return false if successful, + * true otherwise + ***********************************************************************/ +bool wfx_get_wifi_provision(wfx_wifi_provision_t * wifiConfig) +{ + if (wifiConfig != NULL) + { + if (wfx_rsi.dev_state & WFX_RSI_ST_STA_PROVISIONED) + { + *wifiConfig = wfx_rsi.sec; + return true; + } + } + return false; +} + +/********************************************************************* + * @fn bool wfx_is_sta_provisioned(void) + * @brief + * Driver is STA provisioned + * @param[in] None + * @return None + ***********************************************************************/ +bool wfx_is_sta_provisioned(void) +{ + bool status = (wfx_rsi.dev_state & WFX_RSI_ST_STA_PROVISIONED) ? true : false; + WFX_RSI_LOG("%s: status: SSID -> %s: %s", __func__, &wfx_rsi.sec.ssid[0], (status ? "provisioned" : "not provisioned")); + return status; +} + +/********************************************************************* + * @fn void wfx_clear_wifi_provision(void) + * @brief + * Driver is clear the wifi provision + * @param[in] None + * @return None + ***********************************************************************/ +void wfx_clear_wifi_provision(void) +{ + memset(&wfx_rsi.sec, 0, sizeof(wfx_rsi.sec)); + wfx_rsi.dev_state &= ~WFX_RSI_ST_STA_PROVISIONED; + WFX_RSI_LOG("%s: completed.", __func__); +} + +/************************************************************************* + * @fn sl_status_t wfx_connect_to_ap(void) + * @brief + * Start a JOIN command to the AP - Done by the wfx_rsi task + * @param[in] None + * @return returns SL_STATUS_OK if successful, + * SL_STATUS_INVALID_CONFIGURATION otherwise + ****************************************************************************/ +sl_status_t wfx_connect_to_ap(void) +{ + if (wfx_rsi.dev_state & WFX_RSI_ST_STA_PROVISIONED) + { + WFX_RSI_LOG("%s: connecting to access point -> SSID: %s, PSK:%s", __func__, &wfx_rsi.sec.ssid[0], &wfx_rsi.sec.passkey[0]); + xEventGroupSetBits(wfx_rsi.events, WFX_EVT_STA_START_JOIN); + } + else + { + WFX_RSI_LOG("%s: error: access point not provisioned", __func__); + return SL_STATUS_INVALID_CONFIGURATION; + } + return SL_STATUS_OK; +} + +/********************************************************************* + * @fn void wfx_setup_ip6_link_local(sl_wfx_interface_t whichif) + * @brief + * Implement the ipv6 setup + * @param[in] whichif: + * @return None + ***********************************************************************/ +void wfx_setup_ip6_link_local(sl_wfx_interface_t whichif) +{ + /* + * TODO: Implement IPV6 setup, currently in wfx_rsi_task() + * This is hooked with MATTER code. + */ + WFX_RSI_LOG("%s: warning: not implemented.", __func__); +} + +/********************************************************************* + * @fn bool wfx_is_sta_connected(void) + * @brief + * called fuction when driver is connected to STA + * @param[in] None + * @return returns ture if successful, + * false otherwise + ***********************************************************************/ +bool wfx_is_sta_connected(void) +{ + bool status; + status = (wfx_rsi.dev_state & WFX_RSI_ST_STA_CONNECTED) ? true : false; + WFX_RSI_LOG("%s: status: %s", __func__, (status ? "connected" : "not connected")); + return status; +} + +/********************************************************************* + * @fn wifi_mode_t wfx_get_wifi_mode() + * @brief + * get the wifi mode + * @param[in] None + * @return return WIFI_MODE_NULL if successful, + * WIFI_MODE_STA otherwise + ***********************************************************************/ +wifi_mode_t wfx_get_wifi_mode() +{ + if (wfx_rsi.dev_state & WFX_RSI_ST_DEV_READY) + return WIFI_MODE_STA; + return WIFI_MODE_NULL; +} + +/********************************************************************* + * @fn sl_status_t wfx_sta_discon(void) + * @brief + * called fuction when STA disconnected + * @param[in] None + * @return return SL_STATUS_OK if successful, + * SL_STATUS_FAIL otherwise + ***********************************************************************/ +sl_status_t wfx_sta_discon(void) +{ + WFX_RSI_LOG("%s: started.", __func__); + int32_t status; + status = wfx_rsi_disconnect(); + wfx_rsi.dev_state &= ~WFX_RSI_ST_STA_CONNECTED; + WFX_RSI_LOG("%s: completed.", __func__); + return status; +} +#if CHIP_DEVICE_CONFIG_ENABLE_IPV4 +/********************************************************************* + * @fn bool wfx_have_ipv4_addr(sl_wfx_interface_t which_if) + * @brief + * called fuction when driver have ipv4 address + * @param[in] which_if: + * @return returns ture if successful, + * false otherwise + ***********************************************************************/ +bool wfx_have_ipv4_addr(sl_wfx_interface_t which_if) +{ + bool status = false; + if (which_if == SL_WFX_STA_INTERFACE) + { + status = (wfx_rsi.dev_state & WFX_RSI_ST_STA_DHCP_DONE) ? true : false; + } + else + { + status = false; /* TODO */ + } + WFX_RSI_LOG("%s: status: %d", __func__, status); + return status; +} +#endif /* CHIP_DEVICE_CONFIG_ENABLE_IPV4 */ + +/********************************************************************* + * @fn bool wfx_have_ipv6_addr(sl_wfx_interface_t which_if) + * @brief + * called fuction when driver have ipv6 address + * @param[in] which_if: + * @return returns ture if successful, + * false otherwise + ***********************************************************************/ +bool wfx_have_ipv6_addr(sl_wfx_interface_t which_if) +{ + bool status = false; + if (which_if == SL_WFX_STA_INTERFACE) + { + status = (wfx_rsi.dev_state & WFX_RSI_ST_STA_CONNECTED) ? true : false; + } + else + { + status = false; /* TODO */ + } + WFX_RSI_LOG("%s: status: %d", __func__, status); + return status; +} + +/********************************************************************* + * @fn bool wfx_hw_ready(void) + * @brief + * called fuction when driver ready + * @param[in] None + * @return returns ture if successful, + * false otherwise + ***********************************************************************/ +bool wfx_hw_ready(void) +{ + return (wfx_rsi.dev_state & WFX_RSI_ST_DEV_READY) ? true : false; +} + +/********************************************************************* + * @fn int32_t wfx_get_ap_info(wfx_wifi_scan_result_t *ap) + * @brief + * get the access point information + * @param[in] ap: access point + * @return + * access point information + ***********************************************************************/ +int32_t wfx_get_ap_info(wfx_wifi_scan_result_t * ap) +{ + return wfx_rsi_get_ap_info(ap); +} + +/********************************************************************* + * @fn int32_t wfx_get_ap_ext(wfx_wifi_scan_ext_t *extra_info) + * @brief + * get the access point extra information + * @param[in] extra_info:access point extra information + * @return + * access point extra information + ***********************************************************************/ +int32_t wfx_get_ap_ext(wfx_wifi_scan_ext_t * extra_info) +{ + return wfx_rsi_get_ap_ext(extra_info); +} + +/*************************************************************************** + * @fn int32_t wfx_reset_counts(){ + * @brief + * get the driver reset count + * @param[in] None + * @return + * reset count + *****************************************************************************/ +int32_t wfx_reset_counts() +{ + return wfx_rsi_reset_count(); +} + +#ifdef SL_WFX_CONFIG_SCAN +/******************************************************************************* + * @fn bool wfx_start_scan(char *ssid, void (*callback)(wfx_wifi_scan_result_t *)) + * @brief + * called fuction when driver start scaning + * @param[in] ssid: + * @return returns ture if successful, + * false otherwise + *******************************************************************************/ +bool wfx_start_scan(char * ssid, void (*callback)(wfx_wifi_scan_result_t *)) +{ + int sz; + + if (wfx_rsi.scan_cb) + return false; /* Already in progress */ + if (ssid) + { + sz = strlen(ssid); + if ((wfx_rsi.scan_ssid = (char *) pvPortMalloc(sz + 1)) == (char *) 0) + { + return false; + } + strcpy(wfx_rsi.scan_ssid, ssid); + } + wfx_rsi.scan_cb = callback; + xEventGroupSetBits(wfx_rsi.events, WFX_EVT_SCAN); + + return true; +} + +/*************************************************************************** + * @fn void wfx_cancel_scan(void) + * @brief + * called function when driver cancel scaning + * @param[in] None + * @return + * None + *****************************************************************************/ +void wfx_cancel_scan(void) +{ + /* Not possible */ + WFX_RSI_LOG("%s: cannot cancel scan", __func__); +} +#endif /* SL_WFX_CONFIG_SCAN */ diff --git a/examples/platform/silabs/SiWx917/SiWx917/wfx_rsidev.c b/examples/platform/silabs/SiWx917/SiWx917/wfx_rsidev.c new file mode 100644 index 00000000000000..d7a464151cac53 --- /dev/null +++ b/examples/platform/silabs/SiWx917/SiWx917/wfx_rsidev.c @@ -0,0 +1,272 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifdef _WFX_NOT_USED_USING_HAL_INSTEAD_ +#include +#include +#include + +#include "em_bus.h" +#include "em_cmu.h" +#include "em_gpio.h" +#include "em_ldma.h" +#include "em_usart.h" +#include "gpiointerrupt.h" + +/* Need Lwip stuff before rsi is included */ +#include "wfx_host_events.h" + +#include "FreeRTOS.h" +#include "event_groups.h" +#include "rsi_common_apis.h" +#include "rsi_data_types.h" +#include "rsi_error.h" +#include "rsi_nwk.h" +#include "rsi_socket.h" +#include "rsi_utils.h" +#include "rsi_wlan.h" +#include "rsi_wlan_apis.h" +#include "rsi_wlan_config.h" +#include "task.h" + +#include "wfx_host_pinout.h" +#include "wfx_rsi.h" + +/* The following stuff comes from hal/rsi_hal_mcu_interrupt.c */ +static void (*rsi_intr_cb)(void); +/********************************************************************* + * @fn void rsi_hal_intr_config(void (*rsi_interrupt_handler)(void)) + * @brief + * get the hal intr configuration + * @param[in] rsi_interrupt_handler: + * @return + * None + ***********************************************************************/ +void rsi_hal_intr_config(void (*rsi_interrupt_handler)(void)) +{ + rsi_intr_cb = rsi_interrupt_handler; +} + +/*********************************************************************** + * @fn static void wfx_spi_wakeup_irq_callback(uint8_t irqNumber) + * @brief + * end of stuff from hal/rsi_hal_mcu_interrupt.c + * @param[in] irqNumber: + * @return None + * **********************************************************************/ +static void wfx_spi_wakeup_irq_callback(uint8_t irqNumber) +{ + BaseType_t bus_task_woken; + uint32_t interrupt_mask; + + if (irqNumber != SL_WFX_HOST_PINOUT_SPI_IRQ) + return; + // Get and clear all pending GPIO interrupts + interrupt_mask = GPIO_IntGet(); + GPIO_IntClear(interrupt_mask); + if (rsi_intr_cb) + (*rsi_intr_cb)(); +} + +/*********************************************************************** + * @fn static void wfx_host_gpio_init(void) + * @brief + * function called when host gpio intialization + * @param[in] None + * @return None + * **********************************************************************/ +static void wfx_host_gpio_init(void) +{ + // Enable GPIO clock. + CMU_ClockEnable(cmuClock_GPIO, true); + + // Configure WF200 reset pin. + GPIO_PinModeSet(SL_WFX_HOST_PINOUT_RESET_PORT, SL_WFX_HOST_PINOUT_RESET_PIN, gpioModePushPull, PINOUT_CLEAR); + // Configure WF200 WUP pin. + GPIO_PinModeSet(SL_WFX_HOST_PINOUT_WUP_PORT, SL_WFX_HOST_PINOUT_WUP_PIN, gpioModePushPull, PINOUT_CLEAR); + + // GPIO used as IRQ. + GPIO_PinModeSet(SL_WFX_HOST_PINOUT_SPI_WIRQ_PORT, SL_WFX_HOST_PINOUT_SPI_WIRQ_PIN, gpioModeInputPull, PINOUT_CLEAR); + CMU_OscillatorEnable(cmuOsc_LFXO, true, true); + + // Set up interrupt based callback function - trigger on both edges. + GPIOINT_Init(); + GPIO_ExtIntConfig(SL_WFX_HOST_PINOUT_SPI_WIRQ_PORT, SL_WFX_HOST_PINOUT_SPI_WIRQ_PIN, SL_WFX_HOST_PINOUT_SPI_IRQ, true, false, + true); + GPIOINT_CallbackRegister(SL_WFX_HOST_PINOUT_SPI_IRQ, wfx_spi_wakeup_irq_callback); + + // Change GPIO interrupt priority (FreeRTOS asserts unless this is done here!) + NVIC_SetPriority(GPIO_EVEN_IRQn, WFX_GPIO_NVIC_PRIORITY); + NVIC_SetPriority(GPIO_ODD_IRQn, WFX_GPIO_NVIC_PRIORITY); +} + +#define USART SL_WFX_HOST_PINOUT_SPI_PERIPHERAL + +/*********************************************************************** + * @fn static int sl_wfx_host_spi_set_config(void *usart) + * @brief + * set the configuration of spi + * @param[in] usart: + * @return returns 0 if successful, + * -1 otherwise + * **********************************************************************/ +static int sl_wfx_host_spi_set_config(void * usart) +{ + int ret = -1; + + if (0) + { +#if defined(USART0) + } + else if (usart == USART0) + { + usart_clock = cmuClock_USART0; + usart_tx_signal = dmadrvPeripheralSignal_USART0_TXBL; + usart_rx_signal = dmadrvPeripheralSignal_USART0_RXDATAV; + ret = 0; +#endif +#if defined(USART1) + } + else if (usart == USART1) + { + usart_clock = cmuClock_USART1; + usart_tx_signal = dmadrvPeripheralSignal_USART1_TXBL; + usart_rx_signal = dmadrvPeripheralSignal_USART1_RXDATAV; + ret = 0; +#endif +#if defined(USART2) + } + else if (usart == USART2) + { + usart_clock = cmuClock_USART2; + usart_tx_signal = dmadrvPeripheralSignal_USART2_TXBL; + usart_rx_signal = dmadrvPeripheralSignal_USART2_RXDATAV; + ret = 0; +#endif +#if defined(USART3) + } + else if (usart == USART3) + { + usart_clock = cmuClock_USART3; + usart_tx_signal = dmadrvPeripheralSignal_USART3_TXBL; + usart_rx_signal = dmadrvPeripheralSignal_USART3_RXDATAV; + ret = 0; +#endif +#if defined(USART4) + } + else if (usart == USART4) + { + usart_clock = cmuClock_USART4; + usart_tx_signal = dmadrvPeripheralSignal_USART4_TXBL; + usart_rx_signal = dmadrvPeripheralSignal_USART4_RXDATAV; + ret = 0; +#endif +#if defined(USART5) + } + else if (usart == USART5) + { + usart_clock = cmuClock_USART5; + usart_tx_signal = dmadrvPeripheralSignal_USART5_TXBL; + usart_rx_signal = dmadrvPeripheralSignal_USART5_RXDATAV; + ret = 0; +#endif +#if defined(USARTRF0) + } + else if (usart == USARTRF0) + { + usart_clock = cmuClock_USARTRF0; + usart_tx_signal = dmadrvPeripheralSignal_USARTRF0_TXBL; + usart_rx_signal = dmadrvPeripheralSignal_USARTRF0_RXDATAV; + ret = 0; +#endif +#if defined(USARTRF1) + } + else if (usart == USARTRF1) + { + usart_clock = cmuClock_USARTRF1; + usart_tx_signal = dmadrvPeripheralSignal_USARTRF1_TXBL; + usart_rx_signal = dmadrvPeripheralSignal_USARTRF1_RXDATAV; + ret = 0; +#endif + } + + return ret; +} + +/**************************************************************************** + * @fn sl_status_t sl_wfx_host_init_bus(void) + * @brief + * Initialize SPI peripheral + * @param[in] None + * @return returns SL_STATUS_OK if successful, + * SL_STATUS_FAIL otherwise + *****************************************************************************/ +sl_status_t sl_wfx_host_init_bus(void) +{ + int res; + + // Initialize and enable the USART + USART_InitSync_TypeDef usartInit = USART_INITSYNC_DEFAULT; + + res = sl_wfx_host_spi_set_config(USART); + if (res != SPI_CONFIG_SUCESS) + { + return SL_STATUS_FAIL; + } + + spi_enabled = true; + dummy_tx_data = 0; + usartInit.baudrate = 36000000u; + usartInit.msbf = true; + CMU_ClockEnable(cmuClock_HFPER, true); + CMU_ClockEnable(cmuClock_GPIO, true); + CMU_ClockEnable(usart_clock, true); + USART_InitSync(USART, &usartInit); + USART->CTRL |= (1u << _USART_CTRL_SMSDELAY_SHIFT); + USART->ROUTELOC0 = + (USART->ROUTELOC0 & ~(_USART_ROUTELOC0_TXLOC_MASK | _USART_ROUTELOC0_RXLOC_MASK | _USART_ROUTELOC0_CLKLOC_MASK)) | + (SL_WFX_HOST_PINOUT_SPI_TX_LOC << _USART_ROUTELOC0_TXLOC_SHIFT) | + (SL_WFX_HOST_PINOUT_SPI_RX_LOC << _USART_ROUTELOC0_RXLOC_SHIFT) | + (SL_WFX_HOST_PINOUT_SPI_CLK_LOC << _USART_ROUTELOC0_CLKLOC_SHIFT); + + USART->ROUTEPEN = USART_ROUTEPEN_TXPEN | USART_ROUTEPEN_RXPEN | USART_ROUTEPEN_CLKPEN; + GPIO_DriveStrengthSet(SL_WFX_HOST_PINOUT_SPI_CLK_PORT, gpioDriveStrengthStrongAlternateStrong); + GPIO_PinModeSet(SL_WFX_HOST_PINOUT_SPI_TX_PORT, SL_WFX_HOST_PINOUT_SPI_TX_PIN, gpioModePushPull, PINOUT_CLEAR); + GPIO_PinModeSet(SL_WFX_HOST_PINOUT_SPI_RX_PORT, SL_WFX_HOST_PINOUT_SPI_RX_PIN, gpioModeInput, PINOUT_CLEAR); + GPIO_PinModeSet(SL_WFX_HOST_PINOUT_SPI_CLK_PORT, SL_WFX_HOST_PINOUT_SPI_CLK_PIN, gpioModePushPull, PINOUT_CLEAR); + + DMADRV_Init(); + DMADRV_AllocateChannel(&tx_dma_channel, NULL); + DMADRV_AllocateChannel(&rx_dma_channel, NULL); + GPIO_PinModeSet(SL_WFX_HOST_PINOUT_SPI_CS_PORT, SL_WFX_HOST_PINOUT_SPI_CS_PIN, gpioModePushPull, PINOUT_SET); + USART->CMD = USART_CMD_CLEARRX | USART_CMD_CLEARTX; + + return SL_STATUS_OK; +} + +/*********************************************************************** + * @fn void wfx_rsidev_init(void) + * @brief + * function called when driver rsidev intialization + * @param[in] None + * @return None + * **********************************************************************/ +void wfx_rsidev_init(void) +{ + wfx_host_gpio_init(); +} +#endif /* _NOT_USED */ diff --git a/examples/platform/silabs/SiWx917/SiWx917DeviceDataProvider.cpp b/examples/platform/silabs/SiWx917/SiWx917DeviceDataProvider.cpp new file mode 100644 index 00000000000000..9116c26f2c4607 --- /dev/null +++ b/examples/platform/silabs/SiWx917/SiWx917DeviceDataProvider.cpp @@ -0,0 +1,335 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include "SiWx917DeviceDataProvider.h" +#include +#include +#include +#include +#include + +namespace chip { +namespace DeviceLayer { +namespace EFR32 { + +// using namespace chip::Credentials; +using namespace chip::DeviceLayer::Internal; + +CHIP_ERROR EFR32DeviceDataProvider::GetSetupDiscriminator(uint16_t & setupDiscriminator) +{ + CHIP_ERROR err; + uint32_t setupDiscriminator32; + + err = SILABSConfig::ReadConfigValue(SILABSConfig::kConfigKey_SetupDiscriminator, setupDiscriminator32); +#if defined(CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR) && CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + setupDiscriminator32 = CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR; + err = CHIP_NO_ERROR; + } +#endif // defined(CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR) && CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR + + VerifyOrReturnLogError(setupDiscriminator32 <= kMaxDiscriminatorValue, CHIP_ERROR_INVALID_ARGUMENT); + setupDiscriminator = static_cast(setupDiscriminator32); + return CHIP_NO_ERROR; +} + +CHIP_ERROR EFR32DeviceDataProvider::GetSpake2pIterationCount(uint32_t & iterationCount) +{ + CHIP_ERROR err = SILABSConfig::ReadConfigValue(SILABSConfig::kConfigKey_Spake2pIterationCount, iterationCount); + +#if defined(CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_ITERATION_COUNT) && CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_ITERATION_COUNT + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + iterationCount = CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_ITERATION_COUNT; + err = CHIP_NO_ERROR; + } +#endif // defined(CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_ITERATION_COUNT) && CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_ITERATION_COUNT + return err; +} + +CHIP_ERROR EFR32DeviceDataProvider::GetSpake2pSalt(MutableByteSpan & saltBuf) +{ + static constexpr size_t kSpake2pSalt_MaxBase64Len = BASE64_ENCODED_LEN(chip::Crypto::kSpake2p_Max_PBKDF_Salt_Length) + 1; + + CHIP_ERROR err = CHIP_NO_ERROR; + char saltB64[kSpake2pSalt_MaxBase64Len] = { 0 }; + size_t saltB64Len = 0; + + err = SILABSConfig::ReadConfigValueStr(SILABSConfig::kConfigKey_Spake2pSalt, saltB64, sizeof(saltB64), saltB64Len); + +#if defined(CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_SALT) + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + saltB64Len = strlen(CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_SALT); + ReturnErrorCodeIf(saltB64Len > sizeof(saltB64), CHIP_ERROR_BUFFER_TOO_SMALL); + memcpy(saltB64, CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_SALT, saltB64Len); + err = CHIP_NO_ERROR; + } +#endif // defined(CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_SALT) + + ReturnErrorOnFailure(err); + + uint8_t saltByteArray[kSpake2pSalt_MaxBase64Len] = { 0 }; + size_t saltLen = chip::Base64Decode32(saltB64, saltB64Len, saltByteArray); + ReturnErrorCodeIf(saltLen > saltBuf.size(), CHIP_ERROR_BUFFER_TOO_SMALL); + + memcpy(saltBuf.data(), saltByteArray, saltLen); + saltBuf.reduce_size(saltLen); + + return CHIP_NO_ERROR; +} + +CHIP_ERROR EFR32DeviceDataProvider::GetSpake2pVerifier(MutableByteSpan & verifierBuf, size_t & verifierLen) +{ + static constexpr size_t kSpake2pSerializedVerifier_MaxBase64Len = + BASE64_ENCODED_LEN(chip::Crypto::kSpake2p_VerifierSerialized_Length) + 1; + + CHIP_ERROR err = CHIP_NO_ERROR; + char verifierB64[kSpake2pSerializedVerifier_MaxBase64Len] = { 0 }; + size_t verifierB64Len = 0; + + err = SILABSConfig::ReadConfigValueStr(SILABSConfig::kConfigKey_Spake2pVerifier, verifierB64, sizeof(verifierB64), + verifierB64Len); + +#if defined(CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_VERIFIER) + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + verifierB64Len = strlen(CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_VERIFIER); + ReturnErrorCodeIf(verifierB64Len > sizeof(verifierB64), CHIP_ERROR_BUFFER_TOO_SMALL); + memcpy(verifierB64, CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_VERIFIER, verifierB64Len); + err = CHIP_NO_ERROR; + } +#endif // defined(CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_VERIFIER) + + ReturnErrorOnFailure(err); + + verifierLen = chip::Base64Decode32(verifierB64, verifierB64Len, reinterpret_cast(verifierB64)); + ReturnErrorCodeIf(verifierLen > verifierBuf.size(), CHIP_ERROR_BUFFER_TOO_SMALL); + + memcpy(verifierBuf.data(), verifierB64, verifierLen); + verifierBuf.reduce_size(verifierLen); + + return CHIP_NO_ERROR; +} + +CHIP_ERROR EFR32DeviceDataProvider::GetSetupPayload(MutableCharSpan & payloadBuf) +{ + CHIP_ERROR err = CHIP_NO_ERROR; + uint8_t payloadBitSet[kTotalPayloadDataSizeInBytes] = { 0 }; + size_t bitSetLen = 0; + + err = SILABSConfig::ReadConfigValueBin(SILABSConfig::kConfigKey_SetupPayloadBitSet, payloadBitSet, kTotalPayloadDataSizeInBytes, + bitSetLen); + +#if defined(CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE) && CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + static constexpr uint8_t kTestSetupPayloadBitset[] = { 0x88, 0xFF, 0x2F, 0x00, 0x44, 0x00, 0xE0, 0x4B, 0x84, 0x68, 0x02 }; + bitSetLen = sizeof(kTestSetupPayloadBitset); + ReturnErrorCodeIf(bitSetLen > kTotalPayloadDataSizeInBytes, CHIP_ERROR_BUFFER_TOO_SMALL); + memcpy(payloadBitSet, kTestSetupPayloadBitset, bitSetLen); + err = CHIP_NO_ERROR; + } +#endif // defined(CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_VERIFIER) + + ReturnErrorOnFailure(err); + + size_t prefixLen = strlen(kQRCodePrefix); + + if (payloadBuf.size() < prefixLen + 1) + { + err = CHIP_ERROR_BUFFER_TOO_SMALL; + } + else + { + MutableCharSpan subSpan = payloadBuf.SubSpan(prefixLen, payloadBuf.size() - prefixLen); + memcpy(payloadBuf.data(), kQRCodePrefix, prefixLen); + err = base38Encode(MutableByteSpan(payloadBitSet), subSpan); + // Reduce output span size to be the size of written data + payloadBuf.reduce_size(subSpan.size() + prefixLen); + } + + return err; +} + +CHIP_ERROR EFR32DeviceDataProvider::GetVendorName(char * buf, size_t bufSize) +{ + size_t vendorNameLen = 0; // without counting null-terminator + return SILABSConfig::ReadConfigValueStr(SILABSConfig::kConfigKey_VendorName, buf, bufSize, vendorNameLen); +} + +CHIP_ERROR EFR32DeviceDataProvider::GetVendorId(uint16_t & vendorId) +{ + ChipError err = CHIP_NO_ERROR; + uint32_t vendorId32 = 0; + + err = SILABSConfig::ReadConfigValue(SILABSConfig::kConfigKey_VendorId, vendorId32); + +#if defined(CHIP_DEVICE_CONFIG_DEVICE_VENDOR_ID) && CHIP_DEVICE_CONFIG_DEVICE_VENDOR_ID + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + vendorId32 = CHIP_DEVICE_CONFIG_DEVICE_VENDOR_ID; + err = CHIP_NO_ERROR; + } +#endif // defined(CHIP_DEVICE_CONFIG_DEVICE_VENDOR_ID) && CHIP_DEVICE_CONFIG_DEVICE_VENDOR_ID + + ReturnErrorOnFailure(err); + vendorId = static_cast(vendorId32); + return err; +} + +CHIP_ERROR EFR32DeviceDataProvider::GetProductName(char * buf, size_t bufSize) +{ + size_t productNameLen = 0; // without counting null-terminator + return SILABSConfig::ReadConfigValueStr(SILABSConfig::kConfigKey_ProductName, buf, bufSize, productNameLen); +} + +CHIP_ERROR EFR32DeviceDataProvider::GetProductId(uint16_t & productId) +{ + ChipError err = CHIP_NO_ERROR; + uint32_t productId32 = 0; + + err = SILABSConfig::ReadConfigValue(SILABSConfig::kConfigKey_ProductId, productId32); + +#if defined(CHIP_DEVICE_CONFIG_DEVICE_PRODUCT_ID) && CHIP_DEVICE_CONFIG_DEVICE_PRODUCT_ID + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + productId32 = CHIP_DEVICE_CONFIG_DEVICE_PRODUCT_ID; + err = CHIP_NO_ERROR; + } +#endif // defined(CHIP_DEVICE_CONFIG_DEVICE_PRODUCT_ID) && CHIP_DEVICE_CONFIG_DEVICE_PRODUCT_ID + ReturnErrorOnFailure(err); + + productId = static_cast(productId32); + return err; +} + +CHIP_ERROR EFR32DeviceDataProvider::GetHardwareVersionString(char * buf, size_t bufSize) +{ + size_t hardwareVersionStringLen = 0; // without counting null-terminator + CHIP_ERROR err = + SILABSConfig::ReadConfigValueStr(SILABSConfig::kConfigKey_HardwareVersionString, buf, bufSize, hardwareVersionStringLen); +#if defined(CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING) + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + memcpy(buf, CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING, sizeof(bufSize)); + err = CHIP_NO_ERROR; + } +#endif // CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING + return err; +} + +CHIP_ERROR EFR32DeviceDataProvider::GetHardwareVersion(uint16_t & hardwareVersion) +{ + CHIP_ERROR err; + uint32_t hardwareVersion32; + + err = SILABSConfig::ReadConfigValue(SILABSConfig::kConfigKey_HardwareVersion, hardwareVersion32); +#if defined(CHIP_DEVICE_CONFIG_DEVICE_HARDWARE_VERSION) + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + hardwareVersion32 = CHIP_DEVICE_CONFIG_DEVICE_HARDWARE_VERSION; + err = CHIP_NO_ERROR; + } +#endif // defined(CHIP_DEVICE_CONFIG_DEVICE_HARDWARE_VERSION) + + hardwareVersion = static_cast(hardwareVersion32); + return err; +} + +CHIP_ERROR EFR32DeviceDataProvider::GetRotatingDeviceIdUniqueId(MutableByteSpan & uniqueIdSpan) +{ + ChipError err = CHIP_ERROR_WRONG_KEY_TYPE; +#if CHIP_ENABLE_ROTATING_DEVICE_ID + static_assert(ConfigurationManager::kRotatingDeviceIDUniqueIDLength >= ConfigurationManager::kMinRotatingDeviceIDUniqueIDLength, + "Length of unique ID for rotating device ID is smaller than minimum."); + + size_t uniqueIdLen = 0; + err = + SILABSConfig::ReadConfigValueBin(SILABSConfig::kConfigKey_UniqueId, uniqueIdSpan.data(), uniqueIdSpan.size(), uniqueIdLen); +#ifdef CHIP_DEVICE_CONFIG_ROTATING_DEVICE_ID_UNIQUE_ID + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + constexpr uint8_t uniqueId[] = CHIP_DEVICE_CONFIG_ROTATING_DEVICE_ID_UNIQUE_ID; + + ReturnErrorCodeIf(sizeof(uniqueId) > uniqueIdSpan.size(), CHIP_ERROR_BUFFER_TOO_SMALL); + memcpy(uniqueIdSpan.data(), uniqueId, sizeof(uniqueId)); + uniqueIdLen = sizeof(uniqueId); + } +#endif // CHIP_DEVICE_CONFIG_ROTATING_DEVICE_ID_UNIQUE_ID + + ReturnErrorOnFailure(err); + uniqueIdSpan.reduce_size(uniqueIdLen); + +#endif // CHIP_ENABLE_ROTATING_DEVICE_ID + return err; +} + +CHIP_ERROR EFR32DeviceDataProvider::GetSerialNumber(char * buf, size_t bufSize) +{ + size_t serialNumberLen = 0; // without counting null-terminator + return SILABSConfig::ReadConfigValueStr(SILABSConfig::kConfigKey_SerialNum, buf, bufSize, serialNumberLen); +} + +CHIP_ERROR EFR32DeviceDataProvider::GetManufacturingDate(uint16_t & year, uint8_t & month, uint8_t & day) +{ + CHIP_ERROR err; + constexpr uint8_t kDateStringLength = 10; // YYYY-MM-DD + char dateStr[kDateStringLength + 1]; + size_t dateLen; + char * parseEnd; + + err = SILABSConfig::ReadConfigValueBin(SILABSConfig::kConfigKey_ManufacturingDate, reinterpret_cast(dateStr), + sizeof(dateStr), dateLen); + SuccessOrExit(err); + + VerifyOrExit(dateLen == kDateStringLength, err = CHIP_ERROR_INVALID_ARGUMENT); + + // Cast does not lose information, because we then check that we only parsed + // 4 digits, so our number can't be bigger than 9999. + year = static_cast(strtoul(dateStr, &parseEnd, 10)); + VerifyOrExit(parseEnd == dateStr + 4, err = CHIP_ERROR_INVALID_ARGUMENT); + + // Cast does not lose information, because we then check that we only parsed + // 2 digits, so our number can't be bigger than 99. + month = static_cast(strtoul(dateStr + 5, &parseEnd, 10)); + VerifyOrExit(parseEnd == dateStr + 7, err = CHIP_ERROR_INVALID_ARGUMENT); + + // Cast does not lose information, because we then check that we only parsed + // 2 digits, so our number can't be bigger than 99. + day = static_cast(strtoul(dateStr + 8, &parseEnd, 10)); + VerifyOrExit(parseEnd == dateStr + 10, err = CHIP_ERROR_INVALID_ARGUMENT); + +exit: + if (err != CHIP_NO_ERROR && err != CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + ChipLogError(DeviceLayer, "Invalid manufacturing date: %s", dateStr); + } + return err; + return CHIP_ERROR_NOT_IMPLEMENTED; +} + +EFR32DeviceDataProvider & EFR32DeviceDataProvider::GetDeviceDataProvider() +{ + static EFR32DeviceDataProvider sDataProvider; + return sDataProvider; +} + +} // namespace EFR32 +} // namespace DeviceLayer +} // namespace chip diff --git a/examples/platform/silabs/SiWx917/SiWx917DeviceDataProvider.h b/examples/platform/silabs/SiWx917/SiWx917DeviceDataProvider.h new file mode 100644 index 00000000000000..99d90496b30d12 --- /dev/null +++ b/examples/platform/silabs/SiWx917/SiWx917DeviceDataProvider.h @@ -0,0 +1,67 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +#pragma once + +#include +#include + +namespace chip { +namespace DeviceLayer { +namespace EFR32 { + +/** + * @brief This class provides Commissionable data, Device Attestation Credentials, + * and Device Instance Info. + */ + +class EFR32DeviceDataProvider : public CommissionableDataProvider, + public Internal::GenericDeviceInstanceInfoProvider +{ +public: + EFR32DeviceDataProvider() : + CommissionableDataProvider(), Internal::GenericDeviceInstanceInfoProvider( + ConfigurationManagerImpl::GetDefaultInstance()) + {} + + static EFR32DeviceDataProvider & GetDeviceDataProvider(); + CHIP_ERROR GetSetupPayload(MutableCharSpan & payloadBuf); + + // ===== Members functions that implement the CommissionableDataProvider + CHIP_ERROR GetSetupDiscriminator(uint16_t & setupDiscriminator) override; + CHIP_ERROR SetSetupDiscriminator(uint16_t setupDiscriminator) override { return CHIP_ERROR_NOT_IMPLEMENTED; } + CHIP_ERROR GetSpake2pIterationCount(uint32_t & iterationCount) override; + CHIP_ERROR GetSpake2pSalt(MutableByteSpan & saltBuf) override; + CHIP_ERROR GetSpake2pVerifier(MutableByteSpan & verifierBuf, size_t & verifierLen) override; + // Per spec 5.1.7. Passcode cannot be stored on the device + CHIP_ERROR GetSetupPasscode(uint32_t & setupPasscode) override { return CHIP_ERROR_NOT_IMPLEMENTED; }; + CHIP_ERROR SetSetupPasscode(uint32_t setupPasscode) override { return CHIP_ERROR_NOT_IMPLEMENTED; } + + // ===== Members functions that implement the GenericDeviceInstanceInfoProvider + CHIP_ERROR GetVendorName(char * buf, size_t bufSize) override; + CHIP_ERROR GetVendorId(uint16_t & vendorId) override; + CHIP_ERROR GetProductName(char * buf, size_t bufSize) override; + CHIP_ERROR GetProductId(uint16_t & productId) override; + CHIP_ERROR GetHardwareVersionString(char * buf, size_t bufSize) override; + CHIP_ERROR GetRotatingDeviceIdUniqueId(MutableByteSpan & uniqueIdSpan) override; + CHIP_ERROR GetSerialNumber(char * buf, size_t bufSize) override; + CHIP_ERROR GetManufacturingDate(uint16_t & year, uint8_t & month, uint8_t & day) override; + CHIP_ERROR GetHardwareVersion(uint16_t & hardwareVersion) override; +}; + +} // namespace EFR32 +} // namespace DeviceLayer +} // namespace chip diff --git a/examples/platform/silabs/SiWx917/args.gni b/examples/platform/silabs/SiWx917/args.gni new file mode 100644 index 00000000000000..1726b62a75d86b --- /dev/null +++ b/examples/platform/silabs/SiWx917/args.gni @@ -0,0 +1,21 @@ +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/chip.gni") + +chip_ble_project_config_include = "" +chip_device_project_config_include = "" +chip_project_config_include = "" +chip_inet_project_config_include = "" +chip_system_project_config_include = "" diff --git a/examples/platform/silabs/SiWx917/board_config.h b/examples/platform/silabs/SiWx917/board_config.h new file mode 100644 index 00000000000000..ed92fdd145a1c7 --- /dev/null +++ b/examples/platform/silabs/SiWx917/board_config.h @@ -0,0 +1,54 @@ +/* + * Copyright (c) 2018, The OpenThread Authors. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the copyright holder nor the + * names of its contributors may be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" + * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE + * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN + * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + */ + +/** + * @file + * This file includes dev board compile-time configuration constants for SiWx917. + * + */ + +#pragma once + +/// Dev board suppports OQPSK modulation in 2.4GHz band. +#define RADIO_CONFIG_2P4GHZ_OQPSK_SUPPORT 1 +#define RADIO_CONFIG_915MHZ_OQPSK_SUPPORT 0 + +/// The PA(s) is(are) fed from the DCDC +#if (BRD4166A) +#define RADIO_CONFIG_PA_USES_DCDC 1 +#else +#define RADIO_CONFIG_PA_USES_DCDC 0 +#endif + +#ifndef RADIO_CONFIG_DEBUG_COUNTERS_SUPPORT +#define RADIO_CONFIG_DEBUG_COUNTERS_SUPPORT 0 /// Set to 1 to enable debug counters in radio.c +#endif + +#ifndef RADIO_CONFIG_DMP_SUPPORT +#define RADIO_CONFIG_DMP_SUPPORT 0 /// Set to 1 to enable Dynamic Multi-Protocol support in radio.c +#endif diff --git a/examples/platform/silabs/SiWx917/device/inc/system_si917.h b/examples/platform/silabs/SiWx917/device/inc/system_si917.h new file mode 100644 index 00000000000000..9c566512c5425a --- /dev/null +++ b/examples/platform/silabs/SiWx917/device/inc/system_si917.h @@ -0,0 +1,167 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +#ifdef __cplusplus +extern "C" { +#endif + +#include "core_cm4.h" /* Cortex-M4 processor and core peripherals */ +#include +//#include "cmsis_gcc.h" + +/******************************************************************************* + * @addtogroup Parts + * @{ + ******************************************************************************/ +/******************************************************************************* + * @addtogroup EFR32 EFR32 + * @{ + ******************************************************************************/ + +/******************************************************************************* + ****************************** TYPEDEFS *********************************** + ******************************************************************************/ + +/* Interrupt vectortable entry */ +typedef union +{ + void (*VECTOR_TABLE_Type)(void); + void * topOfStack; +} tVectorEntry; + +/******************************************************************************* + ************************** GLOBAL VARIABLES ******************************* + ******************************************************************************/ +//#ifndef CCP_SI917_BRINGUP +extern uint32_t SystemCoreClock; /**< System Clock Frequency (Core Clock) */ +//#endif /* CCP_SI917_BRINGUP */ +extern uint32_t SystemHfrcoFreq; /**< System HFRCO frequency */ + +/******************************************************************************* + ***************************** PROTOTYPES ********************************** + ******************************************************************************/ + +void Reset_Handler(void); /**< Reset Handler */ +void NMI_Handler(void); /**< NMI Handler */ +void HardFault_Handler(void); /**< Hard Fault Handler */ +void MemManage_Handler(void); /**< MPU Fault Handler */ +void BusFault_Handler(void); /**< Bus Fault Handler */ +void UsageFault_Handler(void); /**< Usage Fault Handler */ +void SVC_Handler(void); /**< SVCall Handler */ +void DebugMon_Handler(void); /**< Debug Monitor Handler */ +void PendSV_Handler(void); /**< PendSV Handler */ +void SysTick_Handler(void); /**< SysTick Handler */ + +void EMU_IRQHandler(void); /**< EMU IRQ Handler */ +void FRC_PRI_IRQHandler(void); /**< FRC_PRI IRQ Handler */ +void WDOG0_IRQHandler(void); /**< WDOG0 IRQ Handler */ +void WDOG1_IRQHandler(void); /**< WDOG1 IRQ Handler */ +void FRC_IRQHandler(void); /**< FRC IRQ Handler */ +void MODEM_IRQHandler(void); /**< MODEM IRQ Handler */ +void RAC_SEQ_IRQHandler(void); /**< RAC_SEQ IRQ Handler */ +void RAC_RSM_IRQHandler(void); /**< RAC_RSM IRQ Handler */ +void BUFC_IRQHandler(void); /**< BUFC IRQ Handler */ +void LDMA_IRQHandler(void); /**< LDMA IRQ Handler */ +void GPIO_EVEN_IRQHandler(void); /**< GPIO_EVEN IRQ Handler */ +void TIMER0_IRQHandler(void); /**< TIMER0 IRQ Handler */ +void USART0_RX_IRQHandler(void); /**< USART0_RX IRQ Handler */ +void USART0_TX_IRQHandler(void); /**< USART0_TX IRQ Handler */ +void ACMP0_IRQHandler(void); /**< ACMP0 IRQ Handler */ +void ADC0_IRQHandler(void); /**< ADC0 IRQ Handler */ +void IDAC0_IRQHandler(void); /**< IDAC0 IRQ Handler */ +void I2C0_IRQHandler(void); /**< I2C0 IRQ Handler */ +void GPIO_ODD_IRQHandler(void); /**< GPIO_ODD IRQ Handler */ +void TIMER1_IRQHandler(void); /**< TIMER1 IRQ Handler */ +void USART1_RX_IRQHandler(void); /**< USART1_RX IRQ Handler */ +void USART1_TX_IRQHandler(void); /**< USART1_TX IRQ Handler */ +void LEUART0_IRQHandler(void); /**< LEUART0 IRQ Handler */ +void PCNT0_IRQHandler(void); /**< PCNT0 IRQ Handler */ +void CMU_IRQHandler(void); /**< CMU IRQ Handler */ +void MSC_IRQHandler(void); /**< MSC IRQ Handler */ +void CRYPTO0_IRQHandler(void); /**< CRYPTO IRQ Handler */ +void LETIMER0_IRQHandler(void); /**< LETIMER0 IRQ Handler */ +void AGC_IRQHandler(void); /**< AGC IRQ Handler */ +void PROTIMER_IRQHandler(void); /**< PROTIMER IRQ Handler */ +void RTCC_IRQHandler(void); /**< RTCC IRQ Handler */ +void SYNTH_IRQHandler(void); /**< SYNTH IRQ Handler */ +void CRYOTIMER_IRQHandler(void); /**< CRYOTIMER IRQ Handler */ +void RFSENSE_IRQHandler(void); /**< RFSENSE IRQ Handler */ +void FPUEH_IRQHandler(void); /**< FPUEH IRQ Handler */ +void SMU_IRQHandler(void); /**< SMU IRQ Handler */ +void WTIMER0_IRQHandler(void); /**< WTIMER0 IRQ Handler */ +void WTIMER1_IRQHandler(void); /**< WTIMER1 IRQ Handler */ +void PCNT1_IRQHandler(void); /**< PCNT1 IRQ Handler */ +void PCNT2_IRQHandler(void); /**< PCNT2 IRQ Handler */ +void USART2_RX_IRQHandler(void); /**< USART2_RX IRQ Handler */ +void USART2_TX_IRQHandler(void); /**< USART2_TX IRQ Handler */ +void I2C1_IRQHandler(void); /**< I2C1 IRQ Handler */ +void USART3_RX_IRQHandler(void); /**< USART3_RX IRQ Handler */ +void USART3_TX_IRQHandler(void); /**< USART3_TX IRQ Handler */ +void VDAC0_IRQHandler(void); /**< VDAC0 IRQ Handler */ +void CSEN_IRQHandler(void); /**< CSEN IRQ Handler */ +void LESENSE_IRQHandler(void); /**< LESENSE IRQ Handler */ +void CRYPTO1_IRQHandler(void); /**< CRYPTO1 IRQ Handler */ +void TRNG0_IRQHandler(void); /**< TRNG0 IRQ Handler */ +void SYSCFG_IRQHandler(void); /**< SYSCFG IRQ Handler */ + +uint32_t SystemCoreClockGet(void); + +/******************************************************************************* + * @brief + * Update CMSIS SystemCoreClock variable. + * + * @details + * CMSIS defines a global variable SystemCoreClock + *that shall hold the core frequency in Hz. If the + *core frequency is dynamically changed, the variable + *must be kept updated in order to be CMSIS compliant. + * + * Notice that only if changing the core clock + *frequency through the EFR CMU API, this variable + *will be kept updated. This function is only provided + * for CMSIS compliance and if a user modifies the + *the core clock outside the CMU API. + ******************************************************************************/ +#ifndef CCP_SI917_BRINGUP +static __INLINE void SystemCoreClockUpdate(void) +{ + (void) SystemCoreClockGet(); +} +#endif /* CCP_SI917_BRINGUP */ + +uint32_t SystemMaxCoreClockGet(void); + +void SystemInit(void); +uint32_t SystemHFClockGet(void); + +uint32_t SystemHFXOClockGet(void); +void SystemHFXOClockSet(uint32_t freq); + +uint32_t SystemLFRCOClockGet(void); +uint32_t SystemULFRCOClockGet(void); + +uint32_t SystemLFXOClockGet(void); +void SystemLFXOClockSet(uint32_t freq); + +/** @} End of group */ +/** @} End of group Parts */ + +#ifdef __cplusplus +} +#endif diff --git a/examples/platform/silabs/SiWx917/device/src/startup_RS1xxxx.c b/examples/platform/silabs/SiWx917/device/src/startup_RS1xxxx.c new file mode 100644 index 00000000000000..a62ea68bbbef12 --- /dev/null +++ b/examples/platform/silabs/SiWx917/device/src/startup_RS1xxxx.c @@ -0,0 +1,530 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include "rsi_ps_ram_func.h" +#include "system_RS1xxxx.h" +#include "system_si917.h" + +/*----------Stack Configuration-----------------------------------------------*/ +#define STACK_SIZE 0x00000C00 /*!< Stack size (in Words) */ +__attribute__((section(".co_stack"))) unsigned long pulStack[STACK_SIZE]; + +#define EXT_IRQ_COUNT 98 /**< Number of External (NVIC) interrupts */ // senthil copied from "efr32mg12p432f1024gl125.h" +#define TOTAL_INTERRUPTS (16 + EXT_IRQ_COUNT) + +#ifndef __INITIAL_SP +#define __INITIAL_SP __StackTop +#endif +#ifndef __VECTOR_TABLE_ATTRIBUTE +#define __VECTOR_TABLE_ATTRIBUTE __attribute__((used, section(".vectors"))) +#endif + +/*----------Macro definition--------------------------------------------------*/ +#define WEAK __attribute__((weak)) + +/*----------Declaration of the default fault handlers-------------------------*/ +// #ifndef __START +// extern void _start(void) __attribute__((noreturn)); /* Pre Main (C library entry point) */ +// #else +// extern int __START(void) __attribute__((noreturn)); /* main entry point */ +// #endif + +/* System exception vector handler */ +__attribute__((used)) void WEAK Reset_Handler(void); +void WEAK NMI_Handler(void); +void WEAK HardFault_Handler(void); +void WEAK MemManage_Handler(void); +void WEAK BusFault_Handler(void); +void WEAK UsageFault_Handler(void); +void WEAK SVC_Handler(void); +void WEAK DebugMon_Handler(void); +void WEAK PendSV_Handler(void); +void WEAK SysTick_Handler(void); + +/*Boot up functions*/ +void RSI_Default_Reset_Handler(void); +void RSI_Default_WakeUp_Handler(void); +void RSI_PS_RestoreCpuContext(void); + +void WEAK IRQ000_Handler(void); /*!< ULP Processor Interrupt 0 */ +void WEAK IRQ001_Handler(void); /*!< ULP Processor Interrupt 1 */ +void WEAK IRQ002_Handler(void); /*!< ULP Processor Interrupt 2 */ +void WEAK IRQ003_Handler(void); /*!< ULP Processor Interrupt 3 */ +void WEAK IRQ004_Handler(void); /*!< ULP Processor Interrupt 4 */ +void WEAK IRQ005_Handler(void); /*!< ULP Processor Interrupt 5 */ +void WEAK IRQ006_Handler(void); /*!< ULP Processor Interrupt 6 */ +void WEAK IRQ007_Handler(void); /*!< ULP Processor Interrupt 7 */ +void WEAK IRQ008_Handler(void); /*!< ULP Processor Interrupt 8 */ +void WEAK IRQ009_Handler(void); /*!< ULP Processor Interrupt 9 */ +void WEAK IRQ010_Handler(void); /*!< ULP Processor Interrupt 10 */ +void WEAK IRQ011_Handler(void); /*!< ULP Processor Interrupt 11 */ +void WEAK IRQ012_Handler(void); /*!< ULP Processor Interrupt 12 */ +void WEAK IRQ013_Handler(void); /*!< ULP Processor Interrupt 13 */ +void WEAK IRQ014_Handler(void); /*!< ULP Processor Interrupt 14 */ +void WEAK IRQ015_Handler(void); /*!< ULP Processor Interrupt 15 */ +void WEAK IRQ016_Handler(void); /*!< ULP Processor Interrupt 15 */ +void WEAK IRQ017_Handler(void); /*!< ULP Processor Interrupt 17 */ +void WEAK IRQ018_Handler(void); /*!< ULP Processor Interrupt 18 */ +void WEAK IRQ019_Handler(void); /*!< ULP Processor Interrupt 19 */ +void WEAK IRQ020_Handler(void); /*!< Sleep Sensor Interrupts 0 */ /*WDT*/ +void WEAK IRQ021_Handler(void); /*!< Sleep Sensor Interrupts 1 */ +void WEAK IRQ022_Handler(void); /*!< Sleep Sensor Interrupts 2 */ +void WEAK IRQ023_Handler(void); /*!< Sleep Sensor Interrupts 3 */ +void WEAK IRQ024_Handler(void); /*!< Sleep Sensor Interrupts 4 */ +void WEAK IRQ025_Handler(void); /*!< Sleep Sensor Interrupts 5 */ +void WEAK IRQ026_Handler(void); /*!< Sleep Sensor Interrupts 6 */ +void WEAK IRQ027_Handler(void); /*!< Sleep Sensor Interrupts 7 */ +void WEAK IRQ028_Handler(void); /*!< Sleep Sensor Interrupts 8 */ /*Alarm*/ +void WEAK IRQ029_Handler(void); /*!< Sleep Sensor Interrupts 9 */ /*Msec and sec interrupt */ +void WEAK IRQ030_Handler(void); /*!< Reserved */ +void WEAK IRQ031_Handler(void); /*!< M4SS DMA interrupt */ +void WEAK IRQ032_Handler(void); /*!< Reserved */ +void WEAK IRQ033_Handler(void); /*!< M4SS DMA interrupt */ +void WEAK IRQ034_Handler(void); /*!< M4SS SCT interrupt */ +void WEAK HIF1_IRQHandler(void); /*!< HIF Interrupt 1 */ +void WEAK HIF2_IRQHandler(void); /*!< HIF Interrupt 2 */ +void WEAK IRQ037_Handler(void); /*!< SIO Interrupt */ +void WEAK IRQ038_Handler(void); /*!< USART 1 Interrupt */ +void WEAK IRQ039_Handler(void); /*!< Reserved */ +void WEAK IRQ040_Handler(void); /*!< Reserved */ +void WEAK IRQ041_Handler(void); /*!< Reserved */ +void WEAK IRQ042_Handler(void); /*!< I2C Interrupt */ +void WEAK IRQ043_Handler(void); /*!< Reserved */ +void WEAK IRQ044_Handler(void); /*!< SSI Slave Interrupt */ +void WEAK IRQ045_Handler(void); /*!< Reserved */ +void WEAK IRQ046_Handler(void); /*!< GSPI Master 1 Interrupt */ +void WEAK IRQ047_Handler(void); /*!< Reserved */ +void WEAK IRQ048_Handler(void); /*!< MCPWM Interrupt */ +void WEAK IRQ049_Handler(void); /*!< QEI Interrupt */ +void WEAK IRQ050_Handler(void); /*!< GPIO Group Interrupt 0 */ +void WEAK IRQ051_Handler(void); /*!< GPIO Group Interrupt 1 */ +void WEAK IRQ052_Handler(void); /*!< GPIO Pin Interrupt 0 */ +void WEAK IRQ053_Handler(void); /*!< GPIO Pin Interrupt 1 */ +void WEAK IRQ054_Handler(void); /*!< GPIO Pin Interrupt 2 */ +void WEAK IRQ055_Handler(void); /*!< GPIO Pin Interrupt 3 */ +void WEAK IRQ056_Handler(void); /*!< GPIO Pin Interrupt 4 */ +void WEAK IRQ057_Handler(void); /*!< GPIO Pin Interrupt 5 */ +void WEAK IRQ058_Handler(void); /*!< GPIO Pin Interrupt 6 */ +void WEAK IRQ059_Handler(void); /*!< GPIO Pin Interrupt 7 */ +void WEAK IRQ060_Handler(void); /*!< QSPI Interrupt */ +void WEAK IRQ061_Handler(void); /*!< I2C 2 Interrupt */ +void WEAK IRQ062_Handler(void); /*!< Ethernet Interrupt */ +void WEAK IRQ063_Handler(void); /*!< Reserved */ +void WEAK IRQ064_Handler(void); /*!< I2S master Interrupt */ +void WEAK IRQ065_Handler(void); /*!< Reserved */ +void WEAK IRQ066_Handler(void); /*!< Can 1 Interrupt */ +void WEAK IRQ067_Handler(void); /*!< Reserved */ +void WEAK IRQ068_Handler(void); /*!< SDMEM Interrupt */ +void WEAK IRQ069_Handler(void); /*!< PLL clock ind Interrupt */ +void WEAK IRQ070_Handler(void); /*!< Reserved */ +void WEAK IRQ071_Handler(void); /*!< CCI system Interrupt Out */ +void WEAK IRQ072_Handler(void); /*!< FPU exception */ +void WEAK IRQ073_Handler(void); /*!< USB INTR */ +void WEAK IRQ074_Handler(void); /*!< TASS_P2P_INTR */ +void WEAK IRQ075_Handler(void); /*!< WLAN Band1 intr0 */ +void WEAK IRQ076_Handler(void); /*!< WLAN Band1 intr1 */ +void WEAK IRQ077_Handler(void); /*!< Reserved */ +void WEAK IRQ078_Handler(void); /*!< Reserved */ +void WEAK IRQ079_Handler(void); /*!< BT intr */ +void WEAK IRQ080_Handler(void); /*!< ZB intr */ +void WEAK IRQ081_Handler(void); /*!< Reserved */ +void WEAK IRQ082_Handler(void); /*!< Modem disabled mode trigger intr */ +void WEAK IRQ083_Handler(void); /*!< gpio intr */ +void WEAK IRQ084_Handler(void); /*!< uart intr */ +void WEAK IRQ085_Handler(void); /*!< watch dog level intr */ +void WEAK IRQ086_Handler(void); /*!< ULP Sleep sensor interrupt */ +void WEAK IRQ087_Handler(void); /*!< ECDH intr */ +void WEAK IRQ088_Handler(void); /*!< DH intr */ +void WEAK IRQ089_Handler(void); /*!< QSPI intr */ +void WEAK IRQ090_Handler(void); /*!< ULP processor interrupt TASS */ +void WEAK IRQ091_Handler(void); /*!< Sys Tick Timer */ +void WEAK IRQ092_Handler(void); /*!< Real Timer interrupt */ +void WEAK IRQ093_Handler(void); /*!< PLL lock interrupt */ +void WEAK IRQ094_Handler(void); /*!< Reserved */ +void WEAK IRQ095_Handler(void); /*!< UART2 Interrupt */ +void WEAK IRQ096_Handler(void); /*!< I2S Interrupt */ +void WEAK IRQ097_Handler(void); /*!< I2C Interrupt */ +void WEAK IRQ098_Handler(void); /*!< RESERVED */ + +/*----------Symbols defined in linker script----------------------------------*/ +extern unsigned long _sidata; /*!< Start address for the initialization + values of the .data section. */ +extern unsigned long _sdata; /*!< Start address for the .data section */ +extern unsigned long _edata; /*!< End address for the .data section */ +extern unsigned long _sbss; /*!< Start address for the .bss section */ +extern unsigned long _ebss; /*!< End address for the .bss section */ +extern void _eram; /*!< End address for ram */ +extern uint32_t __etext; +extern unsigned long __StackTop; + +/*----------Function prototypes-----------------------------------------------*/ +extern int main(void); /*!< The entry point for the application */ +void Default_Reset_Handler(void); /*!< Default reset handler */ +static void Default_Handler(void); /*!< Default exception handler */ +/** + *@brief The minimal vector table for a Cortex M4. Note that the proper constructs + * must be placed on this to ensure that it ends up at physical address + * 0x00000000. + */ + +//(void *)0x300001 +/*CCP new */ +extern const tVectorEntry __VECTOR_TABLE[TOTAL_INTERRUPTS]; +const tVectorEntry __VECTOR_TABLE[TOTAL_INTERRUPTS] __attribute__((aligned(512))) __VECTOR_TABLE_ATTRIBUTE = { + /* Cortex-M Exception Handlers */ + { .topOfStack = &__INITIAL_SP }, /* Initial Stack Pointer */ + /*{ (void *)&pulStack[STACK_SIZE - 1] },*/ + { (void *) 0x300001 }, /* Reset Handler : IN CCP Platform system start + from bootloader which inturn call reset handler */ + { NMI_Handler }, /* NMI Handler */ + { HardFault_Handler }, /* Hard Fault Handler */ + { MemManage_Handler }, /* MPU Fault Handler */ + { BusFault_Handler }, /* Bus Fault Handler */ + { UsageFault_Handler }, /* Usage Fault Handler */ + { 0 }, /* Reserved */ + { 0 }, /* Reserved */ + { 0 }, /* Reserved */ + { 0 }, /* Reserved */ + { SVC_Handler }, /* SVCall Handler */ + { DebugMon_Handler }, /* Debug Monitor Handler */ + { 0 }, /* Application properties*/ + { PendSV_Handler }, /* PendSV Handler */ + { SysTick_Handler }, /* SysTick Handler */ + + /* External interrupts */ + + { IRQ000_Handler }, /* 0 */ + { IRQ001_Handler }, /* 1 */ + { IRQ002_Handler }, /* 2 */ + { IRQ003_Handler }, /* 3 */ + { IRQ004_Handler }, /* 4 */ + { IRQ005_Handler }, /* 5 */ + { IRQ006_Handler }, /* 6 */ + { IRQ007_Handler }, /* 7 */ + { IRQ008_Handler }, /* 8 */ + { IRQ009_Handler }, /* 9 */ + { IRQ010_Handler }, /* 10 */ + { IRQ011_Handler }, /* 11 */ + { IRQ012_Handler }, /* 12 */ + { IRQ013_Handler }, /* 13 */ + { IRQ014_Handler }, /* 14 */ + { IRQ015_Handler }, /* 15 */ + { IRQ016_Handler }, /* 16 */ + { IRQ017_Handler }, /* 17 */ + { IRQ018_Handler }, /* 18 */ + { IRQ019_Handler }, /* 19 */ + { IRQ020_Handler }, /* 20 */ + { IRQ021_Handler }, /* 21 */ + { IRQ022_Handler }, /* 22 */ + { IRQ023_Handler }, /* 23 */ + { IRQ024_Handler }, /* 24 */ + { IRQ025_Handler }, /* 25 */ + { IRQ026_Handler }, /* 26 */ + { IRQ027_Handler }, /* 27 */ + { IRQ028_Handler }, /* 28 */ + { IRQ029_Handler }, /* 29 */ + { (void *) &__StackTop - 0x0c }, /* 30 */ + { IRQ031_Handler }, /* 31 */ + { RSI_Default_Reset_Handler }, /* 32 */ + { IRQ033_Handler }, /* 33 */ + { IRQ034_Handler }, /* 34 */ + { HIF1_IRQHandler }, /* 35 */ + { HIF2_IRQHandler }, /* 36 */ + { IRQ037_Handler }, /* 37 */ + { IRQ038_Handler }, /* 38 */ + { IRQ039_Handler }, /* 39 */ + { RSI_PS_RestoreCpuContext }, /* 40 */ + { IRQ041_Handler }, /* 41 */ + { IRQ042_Handler }, /* 42 */ + { (void *) 0x10AD10AD }, /* 43 */ + { IRQ044_Handler }, /* 44 */ + { 0 }, /* 45 */ + { IRQ046_Handler }, /* 46 */ + { IRQ047_Handler }, /* 47 */ + { IRQ048_Handler }, /* 48 */ + { IRQ049_Handler }, /* 49 */ + { IRQ050_Handler }, /* 50 - Reserved */ + { IRQ051_Handler }, + { IRQ052_Handler }, + { IRQ053_Handler }, + { IRQ054_Handler }, + { IRQ055_Handler }, + { IRQ056_Handler }, + { IRQ057_Handler }, + { IRQ058_Handler }, + { IRQ059_Handler }, + { IRQ060_Handler }, + { IRQ061_Handler }, + { IRQ062_Handler }, + { IRQ063_Handler }, + { IRQ064_Handler }, + { 0 }, + { IRQ066_Handler }, + { 0 }, + { IRQ068_Handler }, + { IRQ069_Handler }, + { 0 }, + { IRQ071_Handler }, + { IRQ072_Handler }, + { IRQ073_Handler }, + { IRQ074_Handler }, + { IRQ075_Handler }, + { IRQ076_Handler }, + { 0 }, + { 0 }, + { IRQ079_Handler }, + { IRQ080_Handler }, + { 0 }, + { IRQ082_Handler }, + { IRQ083_Handler }, + { IRQ084_Handler }, + { IRQ085_Handler }, + { IRQ086_Handler }, + { IRQ087_Handler }, + { IRQ088_Handler }, + { IRQ089_Handler }, + { IRQ090_Handler }, + { IRQ091_Handler }, + { IRQ092_Handler }, + { IRQ093_Handler }, + { 0 }, + { IRQ095_Handler }, + { 0 }, + { IRQ097_Handler }, +}; + +/** + * @brief This is the code that gets never called, Dummy handler + * @param None + * @retval None + */ +void Default_Reset_Handler(void) +{ + /*Generic Default reset handler for CM4 */ + while (1) + ; +} + +void Copy_Table() +{ + uint32_t *pSrc, *pDest; + extern uint32_t __etext; + extern uint32_t __data_start__; + extern uint32_t __data_end__; + pSrc = &__etext; + pDest = &__data_start__; + + for (; pDest < &__data_end__;) + { + *pDest++ = *pSrc++; + } +} + +void Zero_Table() +{ + uint32_t * pDest; + extern uint32_t __bss_start__; + extern uint32_t __bss_end__; + pDest = &__bss_start__; + + for (; pDest < &__bss_end__;) + { + *pDest++ = 0UL; + } +} +void Reset_Handler(void) +{ +#ifndef __NO_SYSTEM_INIT + SystemInit(); /* CMSIS System Initialization */ +#endif + +#ifdef BOOTLOADER_ENABLE + SystemInit2(); +#endif /* BOOTLOADER_ENABLE */ + +#if defined(__GNUC__) && defined(__START) + Copy_Table(); + Zero_Table(); + __START(); +#else +#if 0 // senthil_ccp + __PROGRAM_START(); /* Enter PreMain (C library entry point) */ +#else + Copy_Table(); + Zero_Table(); + _start(); +#endif +#endif /* __GNUC__ */ +} + +void RSI_Default_Reset_Handler(void) +{ +#ifndef __NO_SYSTEM_INIT + SystemInit(); /* CMSIS System Initialization */ +#endif + +#ifdef BOOTLOADER_ENABLE + SystemInit2(); +#endif /* BOOTLOADER_ENABLE */ + +#if defined(__GNUC__) && defined(__START) + Copy_Table(); + Zero_Table(); + __START(); +#else +#if 0 // senthil_ccp + __PROGRAM_START(); /* Enter PreMain (C library entry point) */ +#else + Copy_Table(); + Zero_Table(); + _start(); +#endif +#endif /* __GNUC__ */ +} + +/** + *@brief Provide weak aliases for each Exception handler to the Default_Handler. + * As they are weak aliases, any function with the same name will override + * this definition. + */ +//#pragma weak Reset_Handler = RSI_Default_Reset_Handler +#pragma weak NMI_Handler = Default_Handler +#pragma weak HardFault_Handler = Default_Handler +#pragma weak MemManage_Handler = Default_Handler +#pragma weak BusFault_Handler = Default_Handler +#pragma weak UsageFault_Handler = Default_Handler +#pragma weak SVC_Handler = Default_Handler +#pragma weak DebugMon_Handler = Default_Handler +#pragma weak PendSV_Handler = Default_Handler +#pragma weak SysTick_Handler = Default_Handler +/*----------------------------------external interrupts------------------------------ */ +#pragma weak IRQ000_Handler = Default_Handler +#pragma weak IRQ001_Handler = Default_Handler +#pragma weak IRQ002_Handler = Default_Handler +#pragma weak IRQ003_Handler = Default_Handler +#pragma weak IRQ004_Handler = Default_Handler +#pragma weak IRQ005_Handler = Default_Handler +#pragma weak IRQ006_Handler = Default_Handler +#pragma weak IRQ007_Handler = Default_Handler +#pragma weak IRQ008_Handler = Default_Handler +#pragma weak IRQ009_Handler = Default_Handler +#pragma weak IRQ010_Handler = Default_Handler +#pragma weak IRQ011_Handler = Default_Handler +#pragma weak IRQ012_Handler = Default_Handler +#pragma weak IRQ013_Handler = Default_Handler +#pragma weak IRQ014_Handler = Default_Handler +#pragma weak IRQ015_Handler = Default_Handler +#pragma weak IRQ016_Handler = Default_Handler +#pragma weak IRQ017_Handler = Default_Handler +#pragma weak IRQ018_Handler = Default_Handler +#pragma weak IRQ019_Handler = Default_Handler +#pragma weak IRQ020_Handler = Default_Handler +#pragma weak IRQ021_Handler = Default_Handler +#pragma weak IRQ022_Handler = Default_Handler +#pragma weak IRQ023_Handler = Default_Handler +#pragma weak IRQ024_Handler = Default_Handler +#pragma weak IRQ025_Handler = Default_Handler +#pragma weak IRQ026_Handler = Default_Handler +#pragma weak IRQ027_Handler = Default_Handler +#pragma weak IRQ028_Handler = Default_Handler +#pragma weak IRQ029_Handler = Default_Handler +#pragma weak IRQ030_Handler = Default_Handler +#pragma weak IRQ031_Handler = Default_Handler +#pragma weak IRQ032_Handler = Default_Handler +#pragma weak IRQ033_Handler = Default_Handler +#pragma weak IRQ034_Handler = Default_Handler +#pragma weak HIF1_IRQHandler = Default_Handler +#pragma weak HIF2_IRQHandler = Default_Handler +#pragma weak IRQ037_Handler = Default_Handler +#pragma weak IRQ038_Handler = Default_Handler +#pragma weak IRQ039_Handler = Default_Handler +#pragma weak IRQ040_Handler = Default_Handler +#pragma weak IRQ041_Handler = Default_Handler +#pragma weak IRQ042_Handler = Default_Handler +#pragma weak IRQ043_Handler = Default_Handler +#pragma weak IRQ044_Handler = Default_Handler +#pragma weak IRQ045_Handler = Default_Handler +#pragma weak IRQ046_Handler = Default_Handler +#pragma weak IRQ047_Handler = Default_Handler +#pragma weak IRQ048_Handler = Default_Handler +#pragma weak IRQ049_Handler = Default_Handler +#pragma weak IRQ050_Handler = Default_Handler +#pragma weak IRQ051_Handler = Default_Handler +#pragma weak IRQ052_Handler = Default_Handler +#pragma weak IRQ053_Handler = Default_Handler +#pragma weak IRQ054_Handler = Default_Handler +#pragma weak IRQ055_Handler = Default_Handler +#pragma weak IRQ056_Handler = Default_Handler +#pragma weak IRQ057_Handler = Default_Handler +#pragma weak IRQ058_Handler = Default_Handler +#pragma weak IRQ059_Handler = Default_Handler +#pragma weak IRQ060_Handler = Default_Handler +#pragma weak IRQ061_Handler = Default_Handler +#pragma weak IRQ062_Handler = Default_Handler +#pragma weak IRQ063_Handler = Default_Handler +#pragma weak IRQ064_Handler = Default_Handler +#pragma weak IRQ065_Handler = Default_Handler +#pragma weak IRQ066_Handler = Default_Handler +#pragma weak IRQ067_Handler = Default_Handler +#pragma weak IRQ068_Handler = Default_Handler +#pragma weak IRQ069_Handler = Default_Handler +#pragma weak IRQ070_Handler = Default_Handler +#pragma weak IRQ071_Handler = Default_Handler +#pragma weak IRQ072_Handler = Default_Handler +#pragma weak IRQ073_Handler = Default_Handler +#pragma weak IRQ074_Handler = Default_Handler +#pragma weak IRQ075_Handler = Default_Handler +#pragma weak IRQ076_Handler = Default_Handler +#pragma weak IRQ077_Handler = Default_Handler +#pragma weak IRQ078_Handler = Default_Handler +#pragma weak IRQ079_Handler = Default_Handler +#pragma weak IRQ080_Handler = Default_Handler +#pragma weak IRQ081_Handler = Default_Handler +#pragma weak IRQ082_Handler = Default_Handler +#pragma weak IRQ083_Handler = Default_Handler +#pragma weak IRQ084_Handler = Default_Handler +#pragma weak IRQ085_Handler = Default_Handler +#pragma weak IRQ086_Handler = Default_Handler +#pragma weak IRQ087_Handler = Default_Handler +#pragma weak IRQ088_Handler = Default_Handler +#pragma weak IRQ089_Handler = Default_Handler +#pragma weak IRQ090_Handler = Default_Handler +#pragma weak IRQ091_Handler = Default_Handler +#pragma weak IRQ092_Handler = Default_Handler +#pragma weak IRQ093_Handler = Default_Handler +#pragma weak IRQ094_Handler = Default_Handler +#pragma weak IRQ095_Handler = Default_Handler +#pragma weak IRQ096_Handler = Default_Handler +#pragma weak IRQ097_Handler = Default_Handler +#pragma weak IRQ098_Handler = Default_Handler + +/** + * @brief This is the code that gets called when the processor receives an + * unexpected interrupt. This simply enters an infinite loop, + * preserving the system state for examination by a debugger. + * @param None + * @retval None + */ +static void Default_Handler(void) +{ + /* Go into an infinite loop. */ + while (1) + { + } +} + +/*********************** (C) COPYRIGHT 2009 Coocox ************END OF FILE*****/ diff --git a/examples/platform/silabs/SiWx917/device/src/startup_si917.c b/examples/platform/silabs/SiWx917/device/src/startup_si917.c new file mode 100644 index 00000000000000..03cb7fffe07744 --- /dev/null +++ b/examples/platform/silabs/SiWx917/device/src/startup_si917.c @@ -0,0 +1,403 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include "system_si917.h" +#include +#include +//#include "cmsis_gcc.h" + +#ifdef BOOTLOADER_ENABLE +#include "api/btl_interface.h" + +#endif + +#ifdef SL_APP_PROPERTIES +#include "api/application_properties.h" + +#endif + +#define EXT_IRQ_COUNT 51 /**< Number of External (NVIC) interrupts */ // senthil copied from "efr32mg12p432f1024gl125.h" +#define TOTAL_INTERRUPTS (16 + EXT_IRQ_COUNT) + +#ifdef BOOTLOADER_ENABLE +extern MainBootloaderTable_t mainStageTable; + +extern void SystemInit2(void); + +/*---------------------------------------------------------------------------- + * Exception / Interrupt Handler Function Prototype + *----------------------------------------------------------------------------*/ +typedef void (*VECTOR_TABLE_Type)(void); +#endif + +#ifdef SL_APP_PROPERTIES +extern ApplicationProperties_t sl_app_properties; + +/*---------------------------------------------------------------------------- + * Exception / Interrupt Handler Function Prototype + *----------------------------------------------------------------------------*/ +typedef void (*VECTOR_TABLE_Type)(void); +#endif + +/*--------------------------------------------------------------------------- + * External References + *---------------------------------------------------------------------------*/ +extern uint32_t __INITIAL_SP; +extern uint32_t __StackTop; + +#ifndef __INITIAL_SP +#define __INITIAL_SP __StackTop +#endif +#ifndef __VECTOR_TABLE_ATTRIBUTE +#define __VECTOR_TABLE_ATTRIBUTE __attribute__((used, section(".vectors"))) +#endif + +extern void __PROGRAM_START(void); + +#if defined(__START) && defined(__GNUC__) +extern int __START(void) __attribute__((noreturn)); /* main entry point */ +void Zero_Table(); +void Copy_Table(); +#endif /* __START */ + +/*--------------------------------------------------------------------------- + * Internal References + *---------------------------------------------------------------------------*/ +void Reset_Handler(void); +void Default_Handler(void); + +#if defined(__GNUC__) +#ifndef __STACK_SIZE +#define __STACK_SIZE 0x00000400 +#endif /* __STACK_SIZE */ + +#ifndef __HEAP_SIZE +#define __HEAP_SIZE 0x00000C00 +#endif /* __HEAP_SIZE */ +#endif /* __GNUC__ */ + +/*---------------------------------------------------------------------------- + * Exception / Interrupt Handler + *----------------------------------------------------------------------------*/ +/* Cortex-M Processor Exceptions */ +void NMI_Handler(void) __attribute__((weak, alias("Default_Handler"))); +void HardFault_Handler(void) __attribute__((weak, alias("Default_Handler"))); +void MemManage_Handler(void) __attribute__((weak, alias("Default_Handler"))); +void BusFault_Handler(void) __attribute__((weak, alias("Default_Handler"))); +void UsageFault_Handler(void) __attribute__((weak, alias("Default_Handler"))); +void DebugMon_Handler(void) __attribute__((weak, alias("Default_Handler"))); +void SVC_Handler(void) __attribute__((weak, alias("Default_Handler"))); +void PendSV_Handler(void) __attribute__((weak, alias("Default_Handler"))); +void SysTick_Handler(void) __attribute__((weak, alias("Default_Handler"))); +#ifndef SL_APP_PROPERTIES +/* Provide a dummy value for the sl_app_properties symbol. */ +void sl_app_properties(void); /* Prototype to please MISRA checkers. */ +void sl_app_properties(void) __attribute__((weak, alias("Default_Handler"))); +#endif + +/* Part Specific Interrupts */ + +void EMU_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void FRC_PRI_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void WDOG0_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void WDOG1_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void FRC_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void MODEM_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void RAC_SEQ_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void RAC_RSM_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void BUFC_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void LDMA_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void GPIO_EVEN_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void TIMER0_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void USART0_RX_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void USART0_TX_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void ACMP0_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void ADC0_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void IDAC0_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void I2C0_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void GPIO_ODD_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void TIMER1_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void USART1_RX_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void USART1_TX_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void LEUART0_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void PCNT0_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void CMU_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void MSC_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void CRYPTO0_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void LETIMER0_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void AGC_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void PROTIMER_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void RTCC_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void SYNTH_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void CRYOTIMER_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void RFSENSE_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void FPUEH_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void SMU_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void WTIMER0_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void WTIMER1_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void PCNT1_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void PCNT2_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void USART2_RX_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void USART2_TX_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void I2C1_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void USART3_RX_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void USART3_TX_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void VDAC0_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void CSEN_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void LESENSE_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void CRYPTO1_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); +void TRNG0_IRQHandler(void) __attribute__((weak, alias("Default_Handler"))); + +#if 0 // senthil_ccp + +#ifndef __PROGRAM_START + +/** + \brief Initializes data and bss sections + \details This default implementations initialized all data and additional bss + sections relying on .copy.table and .zero.table specified properly + in the used linker script. + + */ +void __cmsis_start(void) +{ + extern void _start(void) __NO_RETURN; + + typedef struct { + uint32_t const* src; + uint32_t* dest; + uint32_t wlen; + } __copy_table_t; + + typedef struct { + uint32_t* dest; + uint32_t wlen; + } __zero_table_t; + + extern const __copy_table_t __copy_table_start__; + extern const __copy_table_t __copy_table_end__; + extern const __zero_table_t __zero_table_start__; + extern const __zero_table_t __zero_table_end__; + + for (__copy_table_t const* pTable = &__copy_table_start__; pTable < &__copy_table_end__; ++pTable) { + for(uint32_t i=0u; iwlen; ++i) { + pTable->dest[i] = pTable->src[i]; + } + } + + for (__zero_table_t const* pTable = &__zero_table_start__; pTable < &__zero_table_end__; ++pTable) { + for(uint32_t i=0u; iwlen; ++i) { + pTable->dest[i] = 0u; + } + } + + _start(); +} + +#define __PROGRAM_START __cmsis_start +#endif + +#endif / senthil_ccp +/*---------------------------------------------------------------------------- + * Exception / Interrupt Vector table + *----------------------------------------------------------------------------*/ + +#if defined(__GNUC__) +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wpedantic" +#endif + +#if defined(__ICCARM__) +#pragma data_alignment = 512 +extern const tVectorEntry __VECTOR_TABLE[TOTAL_INTERRUPTS]; +const tVectorEntry __VECTOR_TABLE[TOTAL_INTERRUPTS] __VECTOR_TABLE_ATTRIBUTE = { +#elif defined(__GNUC__) +extern const tVectorEntry __VECTOR_TABLE[TOTAL_INTERRUPTS]; +// const tVectorEntry __VECTOR_TABLE[TOTAL_INTERRUPTS] __attribute__((aligned(512))) __VECTOR_TABLE_ATTRIBUTE = { +const tVectorEntry __VECTOR_TABLE[TOTAL_INTERRUPTS] __attribute__((aligned(512))) __VECTOR_TABLE_ATTRIBUTE = { +#else +extern const tVectorEntry __VECTOR_TABLE[TOTAL_INTERRUPTS]; +const tVectorEntry __VECTOR_TABLE[TOTAL_INTERRUPTS] __VECTOR_TABLE_ATTRIBUTE = { +#endif + /* Cortex-M Exception Handlers */ + { .topOfStack = &__INITIAL_SP }, /* Initial Stack Pointer */ + { Reset_Handler }, /* Reset Handler */ + { NMI_Handler }, /* NMI Handler */ + { HardFault_Handler }, /* Hard Fault Handler */ + { MemManage_Handler }, /* MPU Fault Handler */ + { BusFault_Handler }, /* Bus Fault Handler */ + { UsageFault_Handler }, /* Usage Fault Handler */ + { Default_Handler }, /* Reserved */ + { Default_Handler }, /* Reserved */ + { Default_Handler }, /* Reserved */ +#ifdef BOOTLOADER_ENABLE + { (VECTOR_TABLE_Type) &mainStageTable }, +#else + { Default_Handler }, /* Reserved */ +#endif + { SVC_Handler }, /* SVCall Handler */ + { DebugMon_Handler }, /* Debug Monitor Handler */ +#ifdef SL_APP_PROPERTIES + { (VECTOR_TABLE_Type) &sl_app_properties }, /* Application properties*/ +#else + { sl_app_properties }, /* Application properties*/ +#endif + { PendSV_Handler }, /* PendSV Handler */ + { SysTick_Handler }, /* SysTick Handler */ + + /* External interrupts */ + + { EMU_IRQHandler }, /* 0 */ + { FRC_PRI_IRQHandler }, /* 1 */ + { WDOG0_IRQHandler }, /* 2 */ + { WDOG1_IRQHandler }, /* 3 */ + { FRC_IRQHandler }, /* 4 */ + { MODEM_IRQHandler }, /* 5 */ + { RAC_SEQ_IRQHandler }, /* 6 */ + { RAC_RSM_IRQHandler }, /* 7 */ + { BUFC_IRQHandler }, /* 8 */ + { LDMA_IRQHandler }, /* 9 */ + { GPIO_EVEN_IRQHandler }, /* 10 */ + { TIMER0_IRQHandler }, /* 11 */ + { USART0_RX_IRQHandler }, /* 12 */ + { USART0_TX_IRQHandler }, /* 13 */ + { ACMP0_IRQHandler }, /* 14 */ + { ADC0_IRQHandler }, /* 15 */ + { IDAC0_IRQHandler }, /* 16 */ + { I2C0_IRQHandler }, /* 17 */ + { GPIO_ODD_IRQHandler }, /* 18 */ + { TIMER1_IRQHandler }, /* 19 */ + { USART1_RX_IRQHandler }, /* 20 */ + { USART1_TX_IRQHandler }, /* 21 */ + { LEUART0_IRQHandler }, /* 22 */ + { PCNT0_IRQHandler }, /* 23 */ + { CMU_IRQHandler }, /* 24 */ + { MSC_IRQHandler }, /* 25 */ + { CRYPTO0_IRQHandler }, /* 26 */ + { LETIMER0_IRQHandler }, /* 27 */ + { AGC_IRQHandler }, /* 28 */ + { PROTIMER_IRQHandler }, /* 29 */ + { RTCC_IRQHandler }, /* 30 */ + { SYNTH_IRQHandler }, /* 31 */ + { CRYOTIMER_IRQHandler }, /* 32 */ + { RFSENSE_IRQHandler }, /* 33 */ + { FPUEH_IRQHandler }, /* 34 */ + { SMU_IRQHandler }, /* 35 */ + { WTIMER0_IRQHandler }, /* 36 */ + { WTIMER1_IRQHandler }, /* 37 */ + { PCNT1_IRQHandler }, /* 38 */ + { PCNT2_IRQHandler }, /* 39 */ + { USART2_RX_IRQHandler }, /* 40 */ + { USART2_TX_IRQHandler }, /* 41 */ + { I2C1_IRQHandler }, /* 42 */ + { USART3_RX_IRQHandler }, /* 43 */ + { USART3_TX_IRQHandler }, /* 44 */ + { VDAC0_IRQHandler }, /* 45 */ + { CSEN_IRQHandler }, /* 46 */ + { LESENSE_IRQHandler }, /* 47 */ + { CRYPTO1_IRQHandler }, /* 48 */ + { TRNG0_IRQHandler }, /* 49 */ + { Default_Handler }, /* 50 - Reserved */ +}; + +#if defined(__GNUC__) +#pragma GCC diagnostic pop +#endif + +//#if defined (__START) && defined (__GNUC__) //senthil_ccp +void Copy_Table() +{ + uint32_t *pSrc, *pDest; + extern uint32_t __etext; + extern uint32_t __data_start__; + extern uint32_t __data_end__; + pSrc = &__etext; + pDest = &__data_start__; + + for (; pDest < &__data_end__;) + { + *pDest++ = *pSrc++; + } +} + +void Zero_Table() +{ + uint32_t * pDest; + extern uint32_t __bss_start__; + extern uint32_t __bss_end__; + pDest = &__bss_start__; + + for (; pDest < &__bss_end__;) + { + *pDest++ = 0UL; + } +} +//#endif /* __START */ + +/*--------------------------------------------------------------------------- + * Reset Handler called on controller reset + *---------------------------------------------------------------------------*/ +#if 0 + void SysTick_Handler(void) +{ + SysTick_Handler(); +} +#endif + +void Reset_Handler(void) +{ +#ifndef __NO_SYSTEM_INIT + SystemInit(); /* CMSIS System Initialization */ +#endif + +#ifdef BOOTLOADER_ENABLE + SystemInit2(); +#endif /* BOOTLOADER_ENABLE */ + +#if defined(__GNUC__) && defined(__START) + Copy_Table(); + Zero_Table(); + __START(); +#else +#if 0 // senthil_ccp + __PROGRAM_START(); /* Enter PreMain (C library entry point) */ +#else + Copy_Table(); + Zero_Table(); + _start(); +#endif +#endif /* __GNUC__ */ +} + +#if defined(__ARMCC_VERSION) && (__ARMCC_VERSION >= 6010050) +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wmissing-noreturn" +#endif + +/*---------------------------------------------------------------------------- + * Default Handler for Exceptions / Interrupts + *----------------------------------------------------------------------------*/ +void Default_Handler(void) +{ + while (true) + { + } +} + +#if defined(__ARMCC_VERSION) && (__ARMCC_VERSION >= 6010050) +#pragma clang diagnostic pop +#endif diff --git a/examples/platform/silabs/SiWx917/display/demo-ui-bitmaps.h b/examples/platform/silabs/SiWx917/display/demo-ui-bitmaps.h new file mode 100644 index 00000000000000..4eca9c0c48e7aa --- /dev/null +++ b/examples/platform/silabs/SiWx917/display/demo-ui-bitmaps.h @@ -0,0 +1,356 @@ +/***************************************************************************/ /** + * @file + * @brief User Interface bitmaps for demo. + ******************************************************************************* + * # License + * Copyright 2020 Silicon Laboratories Inc. + *www.silabs.com + ******************************************************************************* + * + * The licensor of this software is Silicon + *Laboratories Inc. Your use of this software is + *governed by the terms of Silicon Labs Master + *Software License Agreement (MSLA) available at + * www.silabs.com/about-us/legal/master-software-license-agreement. + *This software is distributed to you in Source Code + *format and is governed by the sections of the MSLA + *applicable to Source Code. + * + ******************************************************************************/ + +#ifndef SILABS_DEMO_UI_BITMAPS_H +#define SILABS_DEMO_UI_BITMAPS_H + +#define SILICONLABS_BITMAP_WIDTH 128 +#define SILICONLABS_BITMAP_HEIGHT 45 + +#define ZIGBEE_BITMAP_WIDTH 16 +#define ZIGBEE_BITMAP_HEIGHT 16 + +#define RAIL_BITMAP_WIDTH 16 +#define RAIL_BITMAP_HEIGHT 16 + +#define CONNECT_BITMAP_WIDTH 16 +#define CONNECT_BITMAP_HEIGHT 16 + +#define BLUETOOTH_BITMAP_WIDTH 16 +#define BLUETOOTH_BITMAP_HEIGHT 18 + +#define SILABS_BITMAP \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xf0, 0xff, 0xff, 0xff, 0xf7, 0xff, 0xff, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xcf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ + 0xfd, 0xff, 0xff, 0x01, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0xff, 0xff, 0x9f, 0xff, 0xff, 0x3f, 0x00, \ + 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xf3, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0xfe, \ + 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x1f, 0xf0, 0xff, \ + 0xff, 0xff, 0x1f, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x1f, 0xe0, 0xff, 0xff, 0xff, 0xc3, 0xff, \ + 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0xc0, 0xff, 0xff, 0xff, 0xf0, 0xff, 0xff, 0x07, 0x00, 0x00, \ + 0x00, 0x00, 0x00, 0xff, 0xff, 0x07, 0xc0, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, \ + 0xff, 0x01, 0xc0, 0xff, 0xff, 0x07, 0xfc, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x7f, 0x00, 0x80, 0xff, \ + 0xff, 0x01, 0xfe, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x0f, 0x00, 0x80, 0xff, 0x7f, 0x00, 0xff, 0xff, \ + 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x3f, 0x80, 0xff, 0xff, 0xff, 0x00, 0x00, 0xf0, \ + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x0f, 0x80, 0xff, 0xff, 0xff, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0x01, \ + 0x00, 0x00, 0xc0, 0xff, 0x03, 0xc0, 0xff, 0xff, 0xff, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xe0, 0xff, \ + 0x01, 0xc0, 0xff, 0xff, 0xff, 0xf1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0xe0, 0xff, 0x00, 0xc0, 0xff, 0xff, \ + 0xff, 0xc3, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0xf0, 0x7f, 0x00, 0x80, 0xff, 0xff, 0xff, 0x0f, 0xfc, 0xff, \ + 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0xf8, 0x3f, 0x00, 0x80, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, \ + 0x0f, 0x00, 0xfc, 0x1f, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xc0, 0xff, 0xff, 0xff, 0x0f, 0x00, 0xfe, 0x0f, \ + 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x1f, 0x00, 0xff, 0x07, 0x00, 0x00, 0xf0, 0xff, \ + 0xff, 0xff, 0xff, 0xff, 0x3f, 0xfc, 0xff, 0xff, 0x1f, 0x80, 0xff, 0x07, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, \ + 0x3f, 0xf8, 0xff, 0xff, 0x1f, 0xc0, 0xff, 0x03, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0x00, 0xf0, 0xff, 0xff, \ + 0x0f, 0xf0, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x3f, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x0f, 0xfc, 0xff, 0x03, \ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x07, 0xfe, 0xff, 0x01, 0x00, 0x00, 0x3f, 0x00, \ + 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x83, 0xff, 0xff, 0x01, 0x00, 0xc0, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, \ + 0x00, 0xfc, 0xff, 0xff, 0xe1, 0xff, 0xff, 0x03, 0x00, 0xf0, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, \ + 0xf8, 0xff, 0xff, 0x03, 0x00, 0xf8, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x03, \ + 0x00, 0xfe, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0xdf, 0xff, 0xff, 0xff, 0x07, 0x00, 0xff, 0xff, 0x01, \ + 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, \ + 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xc0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0xff, 0x3f, 0xc0, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ + 0xc0, 0xff, 0xff, 0xff, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x81, 0xff, 0xff, 0xff, \ + 0x1f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff + +#define THREAD_BITMAP_WIDTH 16 +#define THREAD_BITMAP_HEIGHT 18 + +#define THREAD_BITMAP \ + 0x1F, 0xF8, 0x07, 0xE0, 0x03, 0xCE, 0x01, 0x9F, 0x01, 0xB3, 0x00, 0x33, 0xF0, 0x3F, 0xF8, 0x1F, 0x0C, 0x03, 0x0C, 0x03, 0x18, \ + 0x03, 0x11, 0x83, 0x01, 0x83, 0x03, 0xC3, 0x07, 0xE3, 0x1F, 0xFB, 0x7f, 0xff, 0xff, 0xff + +#define WIFI_BITMAP_WIDTH 18 +#define WIFI_BITMAP_HEIGHT 18 + +#define WIFI_BITMAP \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x03, 0xFF, 0x01, 0xE0, 0x03, 0x00, 0xC7, 0xFF, 0xB8, 0xFF, 0xF7, 0x07, 0xF8, 0x0F, 0xC0, 0x3F, \ + 0x3F, 0xFF, 0xFF, 0xFF, 0x3F, 0xFF, 0x7F, 0xF8, 0xFF, 0xE1, 0xFF, 0xCF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F + +#define MATTER_LOGO_WIDTH 18 +#define MATTER_LOGO_HEIGHT 17 + +#define MATTER_LOGO_BITMAP \ + 0xFF, 0xFF, 0xFF, 0xF3, 0xFF, 0xCF, 0xFF, 0x3F, 0xFF, 0xFF, 0xFC, 0x3F, 0x12, 0xFF, 0x01, 0xFE, 0xFF, 0xFF, 0xF3, 0x3F, 0x8F, \ + 0x7F, 0xFC, 0xFC, 0xFC, 0xE3, 0xF1, 0x87, 0x87, 0xC7, 0xDE, 0x88, 0x33, 0xC7, 0xCF, 0xFC, 0xFF, 0xFF, 0x03 + +// APP Logo, boolean only. must be 64x64 +#if IS_DEMO_SWITCH +#define ON_DEMO_BITMAP \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0x7F, 0x00, 0x00, 0x00, 0x00, 0xFE, 0xFF, 0xFF, \ + 0x3F, 0x00, 0x00, 0x00, 0x00, 0xFC, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, 0x00, 0xFC, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, \ + 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, \ + 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0xC0, 0xFF, 0xFF, 0x03, 0xF8, 0xFF, 0xFF, 0x1F, 0xE0, 0xFF, 0xFF, \ + 0x07, 0xF8, 0xFF, 0xFF, 0x1F, 0xE0, 0xFF, 0xFF, 0x07, 0xF8, 0xFF, 0xFF, 0x1F, 0xE0, 0xFF, 0xFF, 0x07, 0xF8, 0xFF, 0xFF, \ + 0x1F, 0xE0, 0xFF, 0xFF, 0x07, 0xF8, 0xFF, 0xFF, 0x1F, 0xE0, 0xFF, 0xFF, 0x07, 0xF8, 0xFF, 0xFF, 0x1F, 0xE0, 0xFF, 0xFF, \ + 0x07, 0xF8, 0xFF, 0xFF, 0x1F, 0xE0, 0xFF, 0xFF, 0x07, 0xF8, 0xFF, 0xFF, 0x1F, 0xE0, 0xFF, 0xFF, 0x07, 0xF8, 0xFF, 0xFF, \ + 0x1F, 0xC0, 0xFF, 0xFF, 0x03, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, \ + 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, \ + 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, \ + 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, \ + 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, \ + 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, \ + 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, \ + 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, \ + 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, \ + 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, \ + 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, \ + 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, \ + 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, \ + 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, \ + 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, \ + 0x00, 0xFC, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, 0x00, 0xFC, 0xFF, 0xFF, 0x7F, 0x00, 0x00, 0x00, 0x00, 0xFE, 0xFF, 0xFF, \ + 0xFF, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF + +#define OFF_DEMO_BITMAP \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x01, 0x00, 0x00, 0x80, 0xFF, 0xFF, 0xFF, 0x7F, 0x00, 0x00, 0x00, 0x00, 0xFE, 0xFF, 0xFF, \ + 0x3F, 0x00, 0x00, 0x00, 0x00, 0xFC, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, 0x00, 0xFC, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, \ + 0x00, 0xFC, 0xFF, 0xFF, 0x3F, 0xF8, 0xFF, 0xFF, 0x1F, 0xFC, 0xFF, 0xFF, 0x3F, 0xF8, 0xFF, 0xFF, 0x1F, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0x3C, 0x00, 0x00, 0x3C, 0xFC, 0xFF, 0xFF, 0x3F, 0x3C, 0x00, 0x00, 0x3C, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0x3C, 0x00, 0x00, 0x3C, 0xFC, 0xFF, 0xFF, 0x3F, 0x3C, 0x00, 0x00, 0x3C, 0xFC, 0xFF, 0xFF, 0x3F, 0x3C, 0x00, 0x00, \ + 0x3C, 0xFC, 0xFF, 0xFF, 0x3F, 0x3C, 0x00, 0x00, 0x3C, 0xFC, 0xFF, 0xFF, 0x3F, 0x3C, 0x00, 0x00, 0x3C, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0x3C, 0x00, 0x00, 0x3C, 0xFC, 0xFF, 0xFF, 0x3F, 0x3C, 0x00, 0x00, 0x3C, 0xFC, 0xFF, 0xFF, 0x3F, 0x3C, 0x00, 0x00, \ + 0x3C, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0x3F, 0xF8, 0xFF, 0xFF, 0x1F, 0xFC, 0xFF, 0xFF, \ + 0x3F, 0xF8, 0xFF, 0xFF, 0x1F, 0xFC, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, 0x00, 0xFC, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, \ + 0x00, 0xFC, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, 0x00, 0xFC, 0xFF, 0xFF, 0x7F, 0x00, 0x00, 0x00, 0x00, 0xFE, 0xFF, 0xFF, \ + 0xFF, 0x01, 0x00, 0x00, 0x80, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF +#elif IS_DEMO_LIGHT +#define ON_DEMO_BITMAP \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfc, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfc, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xcf, 0xff, 0xff, 0xff, 0xff, 0xf3, 0xff, 0xff, \ + 0x8f, 0xff, 0xff, 0xff, 0xff, 0xf1, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0xff, 0xf0, 0xff, 0xff, 0x1f, 0xfe, 0x07, 0xe0, \ + 0x7f, 0xf8, 0xff, 0xff, 0x3f, 0xfc, 0x00, 0x00, 0x3f, 0xfc, 0xff, 0xff, 0x7f, 0x3c, 0xe0, 0x07, 0x3c, 0xfe, 0xff, 0xff, \ + 0xff, 0x1f, 0xfe, 0x7f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xc7, 0xff, 0xff, \ + 0xe3, 0xff, 0xff, 0xff, 0xff, 0xe3, 0xff, 0xff, 0xc7, 0xff, 0xff, 0xff, 0xff, 0xf1, 0xff, 0xff, 0x8f, 0xff, 0xff, 0xff, \ + 0xff, 0xf1, 0xff, 0xff, 0x8f, 0xff, 0xff, 0xff, 0xff, 0xf8, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, \ + 0x3f, 0xfe, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, \ + 0x7f, 0xfe, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, \ + 0x7f, 0xfc, 0xff, 0x0f, 0x38, 0xfe, 0xff, 0xff, 0x7f, 0x1c, 0xf0, 0x0f, 0x38, 0xfe, 0x03, 0xc0, 0x7f, 0x1c, 0xf0, 0x0f, \ + 0x38, 0xfe, 0x27, 0xe9, 0x7f, 0x1c, 0xf0, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, \ + 0x7f, 0xfc, 0xff, 0xff, 0x3f, 0xfe, 0xe7, 0xe7, 0x7f, 0xfc, 0xff, 0xff, 0x7f, 0xfe, 0xef, 0xf7, 0x7f, 0xfe, 0xff, 0xff, \ + 0x7f, 0xfc, 0xef, 0xf7, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xfc, 0xef, 0xf3, 0x3f, 0xff, 0xff, 0xff, 0xff, 0xf8, 0xcf, 0xf3, \ + 0x1f, 0xff, 0xff, 0xff, 0xff, 0xf8, 0xdf, 0xfb, 0x1f, 0xff, 0xff, 0xff, 0xff, 0xf1, 0xdf, 0xfb, 0x8f, 0xff, 0xff, 0xff, \ + 0xff, 0xe3, 0x9f, 0xf9, 0xc7, 0xff, 0xff, 0xff, 0xff, 0xc3, 0x9f, 0xf9, 0xc3, 0xff, 0xff, 0xff, 0xff, 0xc7, 0x9f, 0xfd, \ + 0xe3, 0xff, 0xff, 0xff, 0xff, 0x8f, 0xbf, 0xfd, 0xf1, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x3f, 0xfc, 0xf8, 0xff, 0xff, 0xff, \ + 0xff, 0x3f, 0x3e, 0x7c, 0xfc, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfc, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfc, 0x3f, \ + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf8, 0x1f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf8, 0x1f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf8, 0x1f, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf8, 0x1f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf8, 0x1f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf1, 0x8f, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xc0, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0x3f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff + +#define OFF_DEMO_BITMAP \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xe0, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xe0, 0x07, 0xfc, 0xff, 0xff, 0xff, \ + 0xff, 0x1f, 0xfe, 0x7f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xc7, 0xff, 0xff, \ + 0xe3, 0xff, 0xff, 0xff, 0xff, 0xe3, 0xff, 0xff, 0xc7, 0xff, 0xff, 0xff, 0xff, 0xf1, 0xff, 0xff, 0x8f, 0xff, 0xff, 0xff, \ + 0xff, 0xf1, 0xff, 0xff, 0x8f, 0xff, 0xff, 0xff, 0xff, 0xf8, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, \ + 0x3f, 0xfe, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, \ + 0x7f, 0xfe, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, \ + 0x7f, 0xfc, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, \ + 0x3f, 0xfe, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, \ + 0x7f, 0xfc, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, \ + 0x7f, 0xfc, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xfc, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0xff, 0xf8, 0xff, 0xff, \ + 0x1f, 0xff, 0xff, 0xff, 0xff, 0xf8, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0xff, 0xf1, 0xff, 0xff, 0x8f, 0xff, 0xff, 0xff, \ + 0xff, 0xe3, 0xff, 0xff, 0xc7, 0xff, 0xff, 0xff, 0xff, 0xc3, 0xff, 0xff, 0xc3, 0xff, 0xff, 0xff, 0xff, 0xc7, 0xff, 0xff, \ + 0xe3, 0xff, 0xff, 0xff, 0xff, 0x8f, 0xff, 0xff, 0xf1, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xf8, 0xff, 0xff, 0xff, \ + 0xff, 0x3f, 0xfe, 0x7f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfc, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfc, 0x3f, \ + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf8, 0x1f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf8, 0x1f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf8, 0x1f, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf8, 0x1f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf8, 0x1f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf1, 0x8f, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xc0, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0x3f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff +#elif IS_DEMO_LOCK +#define ON_DEMO_BITMAP \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x1F, 0xF8, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x03, 0xC0, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x7F, 0x00, 0x00, 0xFE, 0xFF, 0xFF, 0xFF, 0xFF, 0x3F, 0x00, 0x00, \ + 0xFC, 0xFF, 0xFF, 0xFF, 0xFF, 0x1F, 0xE0, 0x07, 0xF8, 0xFF, 0xFF, 0xFF, 0xFF, 0x1F, 0xF8, 0x1F, 0xF8, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x0F, 0xFC, 0x3F, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0xFE, 0x7F, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0xFE, 0x7F, \ + 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x07, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0xFF, 0xFF, \ + 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x07, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, \ + 0x00, 0xF8, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, \ + 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, \ + 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, \ + 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, \ + 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x80, 0x01, 0x00, 0xE0, 0xFF, 0xFF, \ + 0x07, 0x00, 0xE0, 0x07, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xF0, 0x0F, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xF8, 0x1F, \ + 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xF8, 0x1F, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xFC, 0x3F, 0x00, 0xE0, 0xFF, 0xFF, \ + 0x07, 0x00, 0xFC, 0x3F, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xF8, 0x1F, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xF8, 0x1F, \ + 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xF0, 0x0F, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xE0, 0x07, 0x00, 0xE0, 0xFF, 0xFF, \ + 0x07, 0x00, 0x80, 0x01, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, \ + 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, \ + 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, \ + 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, \ + 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, \ + 0x00, 0xF8, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF + +#define OFF_DEMO_BITMAP \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x1F, 0xF8, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x03, 0xC0, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x7F, 0x00, 0x00, 0xFE, 0xFF, 0xFF, 0xFF, 0xFF, 0x3F, 0x00, 0x00, \ + 0xFC, 0xFF, 0xFF, 0xFF, 0xFF, 0x1F, 0xE0, 0x07, 0xF8, 0xFF, 0xFF, 0xFF, 0xFF, 0x1F, 0xF8, 0x1F, 0xF8, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x0F, 0xFC, 0x3F, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0xFE, 0x7F, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0xFE, 0x7F, \ + 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x07, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE0, 0xFF, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, \ + 0x00, 0xF8, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, \ + 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, \ + 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, \ + 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, \ + 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x80, 0x01, 0x00, 0xE0, 0xFF, 0xFF, \ + 0x07, 0x00, 0xE0, 0x07, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xF0, 0x0F, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xF8, 0x1F, \ + 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xF8, 0x1F, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xFC, 0x3F, 0x00, 0xE0, 0xFF, 0xFF, \ + 0x07, 0x00, 0xFC, 0x3F, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xF8, 0x1F, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xF8, 0x1F, \ + 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xF0, 0x0F, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0xE0, 0x07, 0x00, 0xE0, 0xFF, 0xFF, \ + 0x07, 0x00, 0x80, 0x01, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, \ + 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, \ + 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, \ + 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, \ + 0x07, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, \ + 0x00, 0xF8, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF +#elif IS_DEMO_THERMOSTAT +#define ON_DEMO_BITMAP \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0xE0, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x03, 0xC0, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x01, 0x80, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0x81, 0x81, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xC1, 0x83, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE0, 0x07, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE0, 0x07, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE0, 0x07, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xE0, 0x07, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE0, 0x07, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE0, 0x07, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE0, 0x07, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE0, 0x07, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xE0, 0x07, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE0, 0x07, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0x00, 0x00, 0xFE, 0xFF, 0xFF, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0xFC, 0xFF, 0xFF, 0xFF, 0xFF, 0x3F, 0x00, 0x00, \ + 0xFC, 0xFF, 0xFF, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x0F, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0x00, 0x00, \ + 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x07, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0x00, 0x00, \ + 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x0F, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0xFF, 0xFF, 0x1F, 0x00, 0x00, \ + 0xF8, 0xFF, 0xFF, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0xFC, 0xFF, 0xFF, 0xFF, 0xFF, 0x7F, 0x00, 0x00, 0xFE, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x01, 0x80, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0xE0, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF +#define OFF_DEMO_BITMAP ON_DEMO_BITMAP + +#else // Unknown demo.... +#define ON_DEMO_BITMAP \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0x7F, 0xFE, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x03, 0xC0, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x01, 0x80, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x7F, 0x00, 0x00, 0xFE, 0xFF, 0xFF, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0xFC, 0xFF, 0xFF, 0xFF, 0xFF, 0x1F, 0x00, 0x00, \ + 0xF8, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x07, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0xF0, 0x0F, \ + 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0x3F, 0xFC, 0x3F, 0xFC, 0xFF, 0xFF, 0xFF, 0xFF, 0x7F, 0xFE, 0x7F, 0xFE, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xF8, 0x1F, 0xF8, 0x1F, 0xFF, 0xFF, 0xFF, 0xFF, 0xF0, 0x0F, 0xF0, \ + 0x0F, 0xFF, 0xFF, 0xFF, 0x7F, 0xE0, 0x07, 0xE0, 0x07, 0xFE, 0xFF, 0xFF, 0x7F, 0xC0, 0x03, 0xC0, 0x03, 0xFE, 0xFF, 0xFF, \ + 0x7F, 0xC0, 0x03, 0xC0, 0x03, 0xFE, 0xFF, 0xFF, 0x3F, 0xC0, 0x03, 0xC0, 0x03, 0xFC, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, \ + 0x00, 0xFC, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, 0x00, 0xFC, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, \ + 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, \ + 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0xFF, \ + 0x8F, 0x01, 0x80, 0x01, 0x80, 0xF1, 0xFF, 0xFF, 0xCF, 0x03, 0xC0, 0x03, 0xC0, 0xF3, 0xFF, 0xFF, 0xEF, 0x07, 0xE0, 0x07, \ + 0xE0, 0xF7, 0xFF, 0xFF, 0xFF, 0x0F, 0xF0, 0x0F, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0x1F, 0xF8, 0x1F, 0xF8, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x3F, 0xFC, 0x3F, 0xFC, 0xFF, 0xFF, 0xFF, 0x7F, 0x7E, 0x7E, 0x7E, 0x7E, 0xFE, 0xFF, 0xFF, 0x3F, 0xFC, 0x3F, 0xFC, \ + 0x3F, 0xFC, 0xFF, 0xFF, 0x1F, 0xF8, 0x1F, 0xF8, 0x1F, 0xF8, 0xFF, 0xFF, 0x1F, 0xF0, 0x0F, 0xF0, 0x0F, 0xF8, 0xFF, 0xFF, \ + 0x1F, 0xE0, 0x07, 0xE0, 0x07, 0xF8, 0xFF, 0xFF, 0x3F, 0xC0, 0x03, 0xC0, 0x03, 0xFC, 0xFF, 0xFF, 0x3F, 0x80, 0x01, 0x80, \ + 0x01, 0xFC, 0xFF, 0xFF, 0x7F, 0x00, 0x00, 0x00, 0x00, 0xFE, 0xFF, 0xFF, 0x7F, 0x00, 0x00, 0x00, 0x00, 0xFE, 0xFF, 0xFF, \ + 0xFF, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0x01, 0x00, 0x00, 0x80, 0xFF, 0xFF, 0xFF, 0xFF, 0x03, 0x00, 0x00, \ + 0xC0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x1F, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0xFF, 0xFF, 0x7F, 0x00, 0x00, 0xFE, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x01, 0x80, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF + +#define OFF_DEMO_BITMAP \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0x7F, 0xFE, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x03, 0xC0, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x01, 0x80, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x7F, 0x00, 0x00, 0xFE, 0xFF, 0xFF, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0xFC, 0xFF, 0xFF, 0xFF, 0xFF, 0x1F, 0x00, 0x00, \ + 0xF8, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x07, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x03, 0x00, 0x00, \ + 0xC0, 0xFF, 0xFF, 0xFF, 0xFF, 0x03, 0x00, 0x00, 0xC0, 0xFF, 0xFF, 0xFF, 0xFF, 0x01, 0x00, 0x00, 0x80, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x01, 0x00, 0x00, 0x80, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, \ + 0x00, 0xFF, 0xFF, 0xFF, 0x7F, 0x00, 0x00, 0x00, 0x00, 0xFE, 0xFF, 0xFF, 0x7F, 0x00, 0x00, 0x00, 0x00, 0xFE, 0xFF, 0xFF, \ + 0x7F, 0x00, 0x00, 0x00, 0x00, 0xFE, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, 0x00, 0xFC, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, \ + 0x00, 0xFC, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, 0x00, 0xFC, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, \ + 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, \ + 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0xFF, \ + 0x0F, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0x00, \ + 0x00, 0xF0, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0xFF, \ + 0x0F, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0x00, \ + 0x00, 0xF0, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, \ + 0x1F, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, 0x00, 0xFC, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, \ + 0x00, 0xFC, 0xFF, 0xFF, 0x7F, 0x00, 0x00, 0x00, 0x00, 0xFE, 0xFF, 0xFF, 0x7F, 0x00, 0x00, 0x00, 0x00, 0xFE, 0xFF, 0xFF, \ + 0xFF, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0x01, 0x00, 0x00, 0x80, 0xFF, 0xFF, 0xFF, 0xFF, 0x03, 0x00, 0x00, \ + 0xC0, 0xFF, 0xFF, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0x1F, 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0xFF, 0xFF, 0x7F, 0x00, 0x00, 0xFE, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x01, 0x80, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x3F, 0xFC, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, \ + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF + +#endif + +#endif // SILABS_DEMO_UI_BITMAPS_H diff --git a/examples/platform/silabs/SiWx917/display/demo-ui.c b/examples/platform/silabs/SiWx917/display/demo-ui.c new file mode 100644 index 00000000000000..73a8d52ea71090 --- /dev/null +++ b/examples/platform/silabs/SiWx917/display/demo-ui.c @@ -0,0 +1,136 @@ +/** + * @file + * @brief User Interface core logic for demo. + ******************************************************************************* + * # License + * Copyright 2020 Silicon Laboratories Inc. + *www.silabs.com + ******************************************************************************* + * + * The licensor of this software is Silicon + *Laboratories Inc. Your use of this software is + *governed by the terms of Silicon Labs Master + *Software License Agreement (MSLA) available at + * www.silabs.com/about-us/legal/master-software-license-agreement. + *This software is distributed to you in Source Code + *format and is governed by the sections of the MSLA + *applicable to Source Code. + * + ******************************************************************************/ + +#include "demo-ui.h" +#include "demo-ui-bitmaps.h" +#include "dmd/dmd.h" +#include "em_types.h" +#include "glib.h" +#include +#include + +// Main Logo and App image +#define SILICONLABS_X_POSITION ((glibContext.pDisplayGeometry->xSize - SILICONLABS_BITMAP_WIDTH) / 2) +#define SILICONLABS_Y_POSITION 0 +#define APP_BITMAP_WIDTH 64 +#define APP_BITMAP_HEIGHT 64 +#define APP_X_POSITION ((glibContext.pDisplayGeometry->xSize - APP_BITMAP_WIDTH) / 2) +#define APP_Y_POSITION (glibContext.pDisplayGeometry->ySize - APP_BITMAP_HEIGHT - 5) +#define PROT1_ID_X_POSITION 1 +#define PROT2_ID_X_POSITION 79 + +// Matter Logo +#define PROT2_BITMAP_WIDTH MATTER_LOGO_WIDTH +#define PROT2_BITMAP_HEIGHT MATTER_LOGO_HEIGHT +#define PROT2_X_POSITION 104 +#define PROT2_Y_POSITION (APP_Y_POSITION + (APP_Y_POSITION / 2)) +#define PROT2_BITMAP (matterLogoBitmap) +#define PROT2_BITMAP_CONN (matterLogoBitmap) + +// Networking Protocol Logo +#ifdef SL_WIFI +#define PROT1_BITMAP_WIDTH WIFI_BITMAP_WIDTH +#define PROT1_BITMAP_HEIGHT WIFI_BITMAP_HEIGHT +#define PROT1_X_POSITION 8 +#define PROT1_Y_POSITION (APP_Y_POSITION + (APP_Y_POSITION / 2)) +#define PROT1_BITMAP (networkBitMap) +#define PROT1_BITMAP_CONN (networkBitMap) +#else +#define PROT1_BITMAP_WIDTH THREAD_BITMAP_WIDTH +#define PROT1_BITMAP_HEIGHT THREAD_BITMAP_HEIGHT +#define PROT1_X_POSITION 8 +#define PROT1_Y_POSITION (APP_Y_POSITION + (APP_Y_POSITION / 2)) +#define PROT1_BITMAP (networkBitMap) +#define PROT1_BITMAP_CONN (networkBitMap) +#endif + +/******************************************************************************* + *************************** LOCAL VARIABLES ******************************** + ******************************************************************************/ +static GLIB_Context_t glibContext; /* Global glib context */ + +static const uint8_t siliconlabsBitmap[] = { SILABS_BITMAP }; +static const uint8_t matterLogoBitmap[] = { MATTER_LOGO_BITMAP }; + +static const uint8_t OnStateBitMap[] = { ON_DEMO_BITMAP }; +static const uint8_t OffStateBitMap[] = { OFF_DEMO_BITMAP }; + +#ifdef SL_WIFI +static const uint8_t networkBitMap[] = { WIFI_BITMAP }; +#else +static const uint8_t networkBitMap[] = { THREAD_BITMAP }; +#endif + +// Future usage +// static const uint8_t unconnectedBitMap[] = { QUESTION_MARK_BITMAP }; + +/******************************************************************************* + ************************** LOCAL FUNCTIONS ******************************** + ******************************************************************************/ +static void demoUIDisplayLogo(void) +{ + GLIB_drawBitmap(&glibContext, SILICONLABS_X_POSITION, SILICONLABS_Y_POSITION, SILICONLABS_BITMAP_WIDTH, + SILICONLABS_BITMAP_HEIGHT, siliconlabsBitmap); +} + +/******************************************************************************* + ************************** GLOBAL FUNCTIONS ******************************* + ******************************************************************************/ +void demoUIInit(GLIB_Context_t * context) +{ + memcpy(&glibContext, context, sizeof(GLIB_Context_t)); +} + +void demoUIDisplayHeader(char * name) +{ + demoUIDisplayLogo(); + if (APP_NAME_MAX_LENGTH >= strlen(name)) + { + GLIB_drawStringOnLine(&glibContext, name, 5, GLIB_ALIGN_CENTER, 0, 0, true); + } + DMD_updateDisplay(); +} + +void demoUIDisplayApp(bool on) +{ + GLIB_drawBitmap(&glibContext, APP_X_POSITION, APP_Y_POSITION, APP_BITMAP_WIDTH, APP_BITMAP_HEIGHT, + (on ? OnStateBitMap : OffStateBitMap)); + DMD_updateDisplay(); +} + +void demoUIDisplayProtocol(demoUIProtocol protocol, bool isConnected) +{ + GLIB_drawBitmap(&glibContext, (protocol == DEMO_UI_PROTOCOL1 ? PROT1_X_POSITION : PROT2_X_POSITION), + (protocol == DEMO_UI_PROTOCOL1 ? PROT1_Y_POSITION : PROT2_Y_POSITION), + (protocol == DEMO_UI_PROTOCOL1 ? PROT1_BITMAP_WIDTH : PROT2_BITMAP_WIDTH), + (protocol == DEMO_UI_PROTOCOL1 ? PROT1_BITMAP_HEIGHT : PROT2_BITMAP_HEIGHT), + (protocol == DEMO_UI_PROTOCOL1 ? (isConnected ? PROT1_BITMAP_CONN : PROT1_BITMAP) + : (isConnected ? PROT2_BITMAP_CONN : PROT2_BITMAP))); + DMD_updateDisplay(); +} + +void demoUIClearMainScreen(uint8_t * name) +{ + GLIB_clear(&glibContext); + demoUIDisplayHeader((char *) name); + demoUIDisplayApp(false); + demoUIDisplayProtocol(DEMO_UI_PROTOCOL1, false); + demoUIDisplayProtocol(DEMO_UI_PROTOCOL2, false); +} diff --git a/examples/platform/silabs/SiWx917/display/demo-ui.h b/examples/platform/silabs/SiWx917/display/demo-ui.h new file mode 100644 index 00000000000000..6197a4e73c71ef --- /dev/null +++ b/examples/platform/silabs/SiWx917/display/demo-ui.h @@ -0,0 +1,139 @@ +/***************************************************************************/ /** + * @file + * @brief User Interface for demo. + ******************************************************************************* + * # License + * Copyright 2020 Silicon Laboratories Inc. + *www.silabs.com + ******************************************************************************* + * + * The licensor of this software is Silicon + *Laboratories Inc. Your use of this software is + *governed by the terms of Silicon Labs Master + *Software License Agreement (MSLA) available at + * www.silabs.com/about-us/legal/master-software-license-agreement. + *This software is distributed to you in Source Code + *format and is governed by the sections of the MSLA + *applicable to Source Code. + * + ******************************************************************************/ + +#pragma once + +#ifdef __cplusplus +extern "C" { +#endif + +#include "glib.h" +/**************************************************************************/ /** + * DEMO UI uses the underlying DMD interface and the + *GLIB and exposes several wrapper functions to + *application. These functions are used to display + * different bitmaps for the demo. + * + ******************************************************************************/ + +#define APP_NAME_MAX_LENGTH 20 + +/******************************************************************************* + ******************************** ENUMS ************************************ + ******************************************************************************/ + +typedef enum +{ + DEMO_UI_PROTOCOL1, + DEMO_UI_PROTOCOL2 +} demoUIProtocol; + +typedef enum +{ + DEMO_UI_LIGHT_OFF, + DEMO_UI_LIGHT_ON +} demoUILightState_t; + +typedef enum +{ + DEMO_UI_DIRECTION_PROT1, + DEMO_UI_DIRECTION_PROT2, + DEMO_UI_DIRECTION_SWITCH, + DEMO_UI_DIRECTION_INVALID +} demoUILightDirection_t; + +typedef enum +{ + DEMO_UI_NO_NETWORK, + DEMO_UI_SCANNING, + DEMO_UI_JOINING, + DEMO_UI_FORMING, + DEMO_UI_NETWORK_UP, + DEMO_UI_STATE_UNKNOWN +} demoUIZigBeeNetworkState_t; + +/******************************************************************************* + ****************************** PROTOTYPES ********************************* + ******************************************************************************/ + +/**************************************************************************/ /** + * @brief + * Initilize the GLIB and DMD interfaces. + * + * @param[in] void + * + * @return + * void + *****************************************************************************/ +void demoUIInit(GLIB_Context_t * context); + +/**************************************************************************/ /** + * @brief + * Update the display with Silicon Labs logo and + *application name. + * + * @param[in] name name of the current application. + * + * @return + * void + *****************************************************************************/ +void demoUIDisplayHeader(char * name); + +/**************************************************************************/ /** + * @brief + * Update the display with App image. Bool state only + *for now. + * + * @param[in] on status of App + * + * @return + * void + *****************************************************************************/ +void demoUIDisplayApp(bool on); + +/**************************************************************************/ /** + * @brief + * Update the display to show if the bluetooth is + *connected to the mobile device. + * + * @param[in] bool, true if the Light is connected to + *mobile device, false otherwise. + * + * @return + * void + *****************************************************************************/ +void demoUIDisplayProtocol(demoUIProtocol protocol, bool isConnected); + +/**************************************************************************/ /** + * @brief + * Clear the Lcd screen and display the main screen. + * + * @param[in] name - application name + * @param[in] showPROT1 - show protocol 1 related icon. + * @param[in] showPROT2 - show protocol 2 related icon. + * + * @return + * void + *****************************************************************************/ +void demoUIClearMainScreen(uint8_t * name); + +#ifdef __cplusplus +} +#endif diff --git a/examples/platform/silabs/SiWx917/display/lcd.cpp b/examples/platform/silabs/SiWx917/display/lcd.cpp new file mode 100644 index 00000000000000..6e1f2d2fe93de3 --- /dev/null +++ b/examples/platform/silabs/SiWx917/display/lcd.cpp @@ -0,0 +1,220 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +#include "demo-ui.h" +#include "lcd.h" + +#include "dmd.h" +#include "glib.h" + +#ifdef QR_CODE_ENABLED +#include "qrcodegen.h" +#endif // QR_CODE_ENABLED + +#include "sl_board_control.h" + +#define LCD_SIZE 128 +#define QR_CODE_VERSION 4 +#define QR_CODE_MODULE_SIZE 3 +#define QR_CODE_BORDER_SIZE 0 + +#ifdef QR_CODE_ENABLED +static uint8_t qrCode[qrcodegen_BUFFER_LEN_FOR_VERSION(QR_CODE_VERSION)]; +static uint8_t workBuffer[qrcodegen_BUFFER_LEN_FOR_VERSION(QR_CODE_VERSION)]; +#endif // QR_CODE_ENABLED + +CHIP_ERROR SilabsLCD::Init(uint8_t * name, bool initialState) +{ + EMSTATUS status; + CHIP_ERROR err = CHIP_NO_ERROR; + + // Check if Name is to long + if (name != nullptr) + { + if (APP_NAME_MAX_LENGTH < strlen((char *) name)) + { + SILABS_LOG("App Name too long"); + return CHIP_ERROR_INVALID_ARGUMENT; + } + else + { + strcpy((char *) mName, (char *) name); + } + } + + /* Enable the memory lcd */ + status = sl_board_enable_display(); + if (status != SL_STATUS_OK) + { + SILABS_LOG("Board Display enable fail %d", status); + err = CHIP_ERROR_INTERNAL; + } + + /* Initialize the DMD module for the DISPLAY device driver. */ + status = DMD_init(0); + if (DMD_OK != status) + { + SILABS_LOG("DMD init failed %d", status); + err = CHIP_ERROR_INTERNAL; + } + + /* Initialize the glib context */ + status = GLIB_contextInit(&glibContext); + if (GLIB_OK != status) + { + SILABS_LOG("Glib context init failed %d", status); + err = CHIP_ERROR_INTERNAL; + } + + glibContext.backgroundColor = White; + glibContext.foregroundColor = Black; + status = GLIB_clear(&glibContext); + if (GLIB_OK != status) + { + SILABS_LOG("Glib clear failed %d", status); + err = CHIP_ERROR_INTERNAL; + } + demoUIInit(&glibContext); + + dState.mainState = initialState; + + return err; +} + +/* This function is necessary because currently glib.h cannot be used within a C++ context. */ +void * SilabsLCD::Context() +{ + return (void *) &glibContext; +} + +int SilabsLCD::Clear() +{ + return GLIB_clear(&glibContext); +} + +int SilabsLCD::DrawPixel(void * pContext, int32_t x, int32_t y) +{ + return GLIB_drawPixel((GLIB_Context_t *) pContext, x, y); +} + +int SilabsLCD::Update(void) +{ + return DMD_updateDisplay(); +} + +void SilabsLCD::WriteDemoUI(bool state) +{ +#ifdef QR_CODE_ENABLED + if (mShowQRCode) + { + mShowQRCode = false; + } +#endif + dState.mainState = state; + WriteDemoUI(); +} + +void SilabsLCD::WriteDemoUI() +{ + Clear(); + if (customUI != nullptr) + { + customUI(&glibContext); + } + else + { + demoUIClearMainScreen(mName); + demoUIDisplayApp(dState.mainState); + } +} + +void SilabsLCD::SetCustomUI(customUICB cb) +{ + customUI = cb; +} + +#ifdef QR_CODE_ENABLED +void SilabsLCD::WriteQRCode() +{ + if (!qrcodegen_encodeText((const char *) mQRCodeBuffer, workBuffer, qrCode, qrcodegen_Ecc_LOW, QR_CODE_VERSION, QR_CODE_VERSION, + qrcodegen_Mask_AUTO, true)) + { + SILABS_LOG("qrcodegen_encodeText() failed"); + return; + } + + const int size = qrcodegen_getSize(qrCode); + + GLIB_clear(&glibContext); + + const int displaySize = (2 * QR_CODE_BORDER_SIZE + size) * QR_CODE_MODULE_SIZE; + const int displayX = (LCD_SIZE - displaySize) / 2; + const int displayY = displayX; + + for (int y = 0; y < size; ++y) + { + for (int x = 0; x < size; ++x) + { + if (qrcodegen_getModule(qrCode, x, y)) + { + LCDFillRect(displayX + (QR_CODE_BORDER_SIZE + x) * QR_CODE_MODULE_SIZE, + displayY + (QR_CODE_BORDER_SIZE + y) * QR_CODE_MODULE_SIZE, QR_CODE_MODULE_SIZE, QR_CODE_MODULE_SIZE); + } + } + } + + DMD_updateDisplay(); +} + +void SilabsLCD::SetQRCode(uint8_t * str, uint32_t size) +{ + if (size < chip::QRCodeBasicSetupPayloadGenerator::kMaxQRCodeBase38RepresentationLength + 1) + { + memcpy(mQRCodeBuffer, str, size); + } +} + +void SilabsLCD::ShowQRCode(bool show, bool forceRefresh) +{ + if (show != mShowQRCode || forceRefresh) + { + (show) ? WriteQRCode() : WriteDemoUI(); + mShowQRCode = show; + } +} + +void SilabsLCD::ToggleQRCode(void) +{ + (mShowQRCode) ? WriteDemoUI() : WriteQRCode(); + mShowQRCode = !mShowQRCode; +} + +void SilabsLCD::LCDFillRect(uint8_t x, uint8_t y, uint8_t w, uint8_t h) +{ + for (int i = 0; i < h; i++) + { + for (int j = 0; j < w; j++) + { + GLIB_drawPixel(&glibContext, x + j, y + i); + } + } +} +#endif // QR_CODE_ENABLED diff --git a/examples/platform/silabs/SiWx917/display/lcd.h b/examples/platform/silabs/SiWx917/display/lcd.h new file mode 100644 index 00000000000000..d375b7a133c9aa --- /dev/null +++ b/examples/platform/silabs/SiWx917/display/lcd.h @@ -0,0 +1,74 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +#include "AppConfig.h" +#include "glib.h" +#ifdef QR_CODE_ENABLED +#include "qrcodegen.h" +#include +#endif // QR_CODE_ENABLED + +#include "demo-ui.h" + +#define MAX_STR_LEN 48 + +class SilabsLCD +{ + +public: + typedef void (*customUICB)(GLIB_Context_t * context); + CHIP_ERROR Init(uint8_t * name = nullptr, bool initialState = false); + void * Context(); + int Clear(void); + int DrawPixel(void * pContext, int32_t x, int32_t y); + int Update(void); + void WriteDemoUI(bool state); + void SetCustomUI(customUICB cb); + +#ifdef QR_CODE_ENABLED + void SetQRCode(uint8_t * str, uint32_t size); + void ShowQRCode(bool show, bool forceRefresh = false); + void ToggleQRCode(void); +#endif + +private: + typedef struct demoState + { + bool mainState = false; + bool protocol1 = false; /* data */ + } DemoState_t; + + void WriteQRCode(); + void WriteDemoUI(); +#ifdef QR_CODE_ENABLED + void LCDFillRect(uint8_t x, uint8_t y, uint8_t w, uint8_t h); + char mQRCodeBuffer[chip::QRCodeBasicSetupPayloadGenerator::kMaxQRCodeBase38RepresentationLength + 1]; + bool mShowQRCode = true; +#endif + GLIB_Context_t glibContext; + +#ifdef SL_DEMO_NAME + uint8_t mName[] = SL_DEMO_NAME +#else + uint8_t mName[APP_NAME_MAX_LENGTH + 1]; +#endif + customUICB customUI = nullptr; + DemoState_t dState; +}; diff --git a/examples/platform/silabs/SiWx917/init_ccpPlatform.cpp b/examples/platform/silabs/SiWx917/init_ccpPlatform.cpp new file mode 100644 index 00000000000000..0d5bb78bea9e7c --- /dev/null +++ b/examples/platform/silabs/SiWx917/init_ccpPlatform.cpp @@ -0,0 +1,46 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2019 Google LLC. + * 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 "AppConfig.h" +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif +#include +#include + +#include + +#include "init_ccpPlatform.h" + +void initAntenna(void); + +void init_ccpPlatform(void) +{ + +#if SILABS_LOG_ENABLED + silabsInitLog(); +#endif +} + +#ifdef __cplusplus +} +#endif diff --git a/examples/platform/silabs/SiWx917/init_ccpPlatform.h b/examples/platform/silabs/SiWx917/init_ccpPlatform.h new file mode 100644 index 00000000000000..986e2fecb18dd9 --- /dev/null +++ b/examples/platform/silabs/SiWx917/init_ccpPlatform.h @@ -0,0 +1,28 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +/*******************************************************************************/ +#pragma once + +#ifdef __cplusplus +extern "C" { +#endif + +void init_ccpPlatform(void); +#ifdef __cplusplus +} +#endif diff --git a/examples/platform/silabs/SiWx917/ldscripts/SiWx917.ld b/examples/platform/silabs/SiWx917/ldscripts/SiWx917.ld new file mode 100644 index 00000000000000..13f0b226a4d9f6 --- /dev/null +++ b/examples/platform/silabs/SiWx917/ldscripts/SiWx917.ld @@ -0,0 +1,219 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +MEMORY +{ + FLASH (rx) : ORIGIN = 0x08012000, LENGTH = 0x200000 + RAM (rwx) : ORIGIN = 0xC, LENGTH = 262144 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapBase + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + KEEP(*(.vectors)) + + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + + LONG (__etext) + LONG (__data_start__) + LONG ((__data_end__ - __data_start__) / 4) + + __copy_table_end__ = .; + } > FLASH + + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + __zero_table_end__ = .; + } > FLASH + + __etext = ALIGN (4); + _sidata = __etext; + + .data : AT (__etext) + { + __data_start__ = .; + _sdata = __data_start__; + + *(vtable) + *(.data*) + . = ALIGN (4); + PROVIDE (__ram_func_section_start = .); + *(.ram) + PROVIDE (__ram_func_section_end = .); + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(4); + /* All data end */ + __data_end__ = .; + _edata = __data_end__; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + _sbss = __bss_start__; + *(.bss) + *(.bss.*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + _ebss = __bss_end__; + } > RAM + + .heap (COPY) : + { + __HeapBase = .; + __end__ = .; + end = __end__; + _end = __end__; + KEEP(*(.heap*)) + __HeapLimit = .; + } > RAM + + __main_flash_end__ = ORIGIN(FLASH) + LENGTH(FLASH); + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + KEEP(*(.stack*)) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM); + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + .nvm (DSECT) : { + KEEP(*(.simee*)) + } > FLASH + + /* Last page of flash is reserved for the manufacturing token space */ + linker_nvm_end = __main_flash_end__ - 2048; + linker_nvm_begin = linker_nvm_end - SIZEOF(.nvm); + linker_nvm_size = SIZEOF(.nvm); + __nvm3Base = linker_nvm_begin; + __attestation_credentials_base = linker_nvm_end; + + /* Check if data + heap + stack exceeds RAM limit */ + /*ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack")*/ + ASSERT( (linker_nvm_begin + SIZEOF(.nvm)) <= __main_flash_end__, "NVM3 is excessing the flash size !") + + /* Check if FLASH usage exceeds FLASH size */ +/* ASSERT( LENGTH(FLASH) >= (__etext), "FLASH memory overflowed !") */ /* Build error need to be checked for CCP */ + ASSERT((__etext + SIZEOF(.data)) <= __nvm3Base, "FLASH memory overlapped with NVM section.") +} diff --git a/examples/platform/silabs/SiWx917/matter_config.cpp b/examples/platform/silabs/SiWx917/matter_config.cpp new file mode 100644 index 00000000000000..caa6a34b218482 --- /dev/null +++ b/examples/platform/silabs/SiWx917/matter_config.cpp @@ -0,0 +1,175 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2022 Silabs. + * 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 "AppConfig.h" +#include "OTAConfig.h" +#include + +#include + +#include + +#ifdef __cplusplus +extern "C" { +#endif +#ifdef SL_WIFI +#include "wfx_host_events.h" +#endif /* SL_WIFI */ +#ifdef __cplusplus +} +#endif + +#if PW_RPC_ENABLED +#include "Rpc.h" +#endif + +#ifdef ENABLE_CHIP_SHELL +#include "matter_shell.h" +#endif + +#ifdef HEAP_MONITORING +#include "MemMonitoring.h" +#endif + +using namespace ::chip; +using namespace ::chip::Inet; +using namespace ::chip::DeviceLayer; + +#include +// If building with the SiWx917-provided crypto backend, we can use the + +#include "SiWx917DeviceDataProvider.h" + +#if EFR32_OTA_ENABLED +void EFR32MatterConfig::InitOTARequestorHandler(System::Layer * systemLayer, void * appState) +{ +#if 0 // TODO : OTA is not planned now for CCP + OTAConfig::Init(); +#endif +} +#endif + +void SI917MatterConfig::ConnectivityEventCallback(const ChipDeviceEvent * event, intptr_t arg){ + // Initialize OTA only when Thread or WiFi connectivity is established + /*if (((event->Type == DeviceEventType::kThreadConnectivityChange) && + (event->ThreadConnectivityChange.Result == kConnectivity_Established)) || + ((event->Type == DeviceEventType::kInternetConnectivityChange) && + (event->InternetConnectivityChange.IPv6 == kConnectivity_Established))) + { + SILABS_LOG("Scheduling OTA Requestor initialization") + chip::DeviceLayer::SystemLayer().StartTimer(chip::System::Clock::Seconds32(OTAConfig::kInitOTARequestorDelaySec), + InitOTARequestorHandler, nullptr); + }*/ + SILABS_LOG("Scheduling OTA Requestor initialization") +} + +CHIP_ERROR SI917MatterConfig::InitMatter(const char * appName) +{ + CHIP_ERROR err; + + mbedtls_platform_set_calloc_free(CHIPPlatformMemoryCalloc, CHIPPlatformMemoryFree); + + SILABS_LOG("=================================================="); + SILABS_LOG("%s starting", appName); + SILABS_LOG("=================================================="); + +#if PW_RPC_ENABLED + chip::rpc::Init(); +#endif + +#ifdef HEAP_MONITORING + MemMonitoring::startHeapMonitoring(); +#endif + SetDeviceInstanceInfoProvider(&EFR32::EFR32DeviceDataProvider::GetDeviceDataProvider()); + SetCommissionableDataProvider(&EFR32::EFR32DeviceDataProvider::GetDeviceDataProvider()); + + //============================================== + // Init Matter Stack + //============================================== + SILABS_LOG("Init CHIP Stack"); + // Init Chip memory management before the stack + ReturnErrorOnFailure(chip::Platform::MemoryInit()); + + SILABS_LOG("Init RSI 911x Platform"); + int32_t deviceInit = wfx_rsi_platform(); + if (deviceInit != SL_STATUS_OK) + { + SILABS_LOG("RSI init failed"); + return CHIP_ERROR_INTERNAL; + } + ReturnErrorOnFailure(PlatformMgr().InitChipStack()); + + chip::DeviceLayer::ConnectivityMgr().SetBLEDeviceName(appName); + + // Stop Matter event handling while setting up resources + chip::DeviceLayer::PlatformMgr().LockChipStack(); + + // Create initParams with SDK example defaults here + static chip::CommonCaseDeviceServerInitParams initParams; + + // Initialize the remaining (not overridden) providers to the SDK example defaults + (void) initParams.InitializeStaticResourcesBeforeServerInit(); + + // Init Matter Server and Start Event Loop + err = chip::Server::GetInstance().Init(initParams); + chip::DeviceLayer::PlatformMgr().UnlockChipStack(); + + ReturnErrorOnFailure(err); + + // OTA Requestor initialization will be triggered by the connectivity events + // TODO + // PlatformMgr().AddEventHandler(ConnectivityEventCallback, reinterpret_cast(nullptr)); + + SILABS_LOG("Starting Platform Manager Event Loop"); + ReturnErrorOnFailure(PlatformMgr().StartEventLoopTask()); + +#ifdef SL_WIFI + InitWiFi(); +#endif + +#ifdef ENABLE_CHIP_SHELL + chip::startShellTask(); +#endif + + return CHIP_NO_ERROR; +} + +#ifdef SL_WIFI +void SI917MatterConfig::InitWiFi(void) +{ +#ifdef RS911X_WIFI + /* + * Start up any RSI interface stuff + * (Not required) - Note that wfx_wifi_start will deal with + * starting up a rsi task - which will initialize the SPI interface. + */ +#endif +} +#endif // SL_WIFI + +// ================================================================================ +// FreeRTOS Callbacks +// ================================================================================ +extern "C" void vApplicationIdleHook(void) +{ + // FreeRTOS Idle callback + + // Check CHIP Config nvm3 and repack flash if necessary. + Internal::SILABSConfig::RepackNvm3Flash(); +} diff --git a/examples/platform/silabs/SiWx917/matter_config.h b/examples/platform/silabs/SiWx917/matter_config.h new file mode 100644 index 00000000000000..6b3bb622a075a2 --- /dev/null +++ b/examples/platform/silabs/SiWx917/matter_config.h @@ -0,0 +1,35 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2022 Silabs. + * 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 +#include +#include +#include + +class SI917MatterConfig +{ +public: + static CHIP_ERROR InitMatter(const char * appName); + +private: + static CHIP_ERROR InitOpenThread(void); + static void InitWiFi(void); + static void ConnectivityEventCallback(const chip::DeviceLayer::ChipDeviceEvent * event, intptr_t arg); + static void InitOTARequestorHandler(chip::System::Layer * systemLayer, void * appState); +}; diff --git a/examples/platform/silabs/SiWx917/pw_sys_io/BUILD.gn b/examples/platform/silabs/SiWx917/pw_sys_io/BUILD.gn new file mode 100644 index 00000000000000..20547c3b7beabc --- /dev/null +++ b/examples/platform/silabs/SiWx917/pw_sys_io/BUILD.gn @@ -0,0 +1,39 @@ +# Copyright (c) 2021 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/chip.gni") +import("//build_overrides/pigweed.gni") + +import("$dir_pw_build/target_types.gni") + +examples_plat_dir = "${chip_root}/examples/platform/silabs/SiWx917" + +config("default_config") { + include_dirs = [ "public" ] +} + +pw_source_set("pw_sys_io_efr32") { + sources = [ "sys_io_efr32.cc" ] + + deps = [ + "$dir_pw_sys_io:default_putget_bytes", + "$dir_pw_sys_io:facade", + ] + + cflags = [ "-Wconversion" ] + + public_configs = [ ":default_config" ] + + include_dirs = [ "${examples_plat_dir}" ] +} diff --git a/examples/platform/silabs/SiWx917/pw_sys_io/public/pw_sys_io_efr32/init.h b/examples/platform/silabs/SiWx917/pw_sys_io/public/pw_sys_io_efr32/init.h new file mode 100644 index 00000000000000..f11f5e928f3e14 --- /dev/null +++ b/examples/platform/silabs/SiWx917/pw_sys_io/public/pw_sys_io_efr32/init.h @@ -0,0 +1,27 @@ +/* + * + * Copyright (c) 2021 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +#include "pw_preprocessor/util.h" + +PW_EXTERN_C_START + +// The actual implement of PreMainInit() in sys_io_BACKEND. +void pw_sys_io_Init(); + +PW_EXTERN_C_END diff --git a/examples/platform/silabs/SiWx917/pw_sys_io/sys_io_siwx917.cc b/examples/platform/silabs/SiWx917/pw_sys_io/sys_io_siwx917.cc new file mode 100644 index 00000000000000..4bc7d98f7477c4 --- /dev/null +++ b/examples/platform/silabs/SiWx917/pw_sys_io/sys_io_siwx917.cc @@ -0,0 +1,81 @@ +/* + * + * Copyright (c) 2021 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include "pw_sys_io/sys_io.h" +#include +#include +#include +#include + +#include "uart.h" + +int16_t console_getchar(char * chr) +{ + int16_t retVal = 0; + + // Busy wait for pw_rcp reads + while (retVal == 0) + { + retVal = uartConsoleRead(chr, 1); + } + return retVal; +} + +int16_t console_putchar(const char * chr) +{ + return uartConsoleWrite(chr, 1); +} + +extern "C" void pw_sys_io_Init() +{ + uartConsoleInit(); +} + +namespace pw::sys_io { + +Status ReadByte(std::byte * dest) +{ + if (!dest) + return Status::InvalidArgument(); + + int16_t ret = console_getchar(reinterpret_cast(dest)); + return ret < 0 ? Status::FailedPrecondition() : OkStatus(); +} + +Status WriteByte(std::byte b) +{ + int16_t ret = console_putchar(reinterpret_cast(&b)); + return ret < 0 ? Status::FailedPrecondition() : OkStatus(); +} + +// Writes a string using pw::sys_io, and add newline characters at the end. +StatusWithSize WriteLine(const std::string_view & s) +{ + size_t chars_written = 0; + StatusWithSize result = WriteBytes(pw::as_bytes(pw::span(s))); + if (!result.ok()) + { + return result; + } + chars_written += result.size(); + result = WriteBytes(pw::as_bytes(pw::span("\r\n", 2))); + chars_written += result.size(); + + return StatusWithSize(result.status(), chars_written); +} + +} // namespace pw::sys_io diff --git a/examples/platform/silabs/SiWx917/siwx917_utils.cpp b/examples/platform/silabs/SiWx917/siwx917_utils.cpp new file mode 100644 index 00000000000000..49a23255cd93c5 --- /dev/null +++ b/examples/platform/silabs/SiWx917/siwx917_utils.cpp @@ -0,0 +1,36 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2022 Silabs. + * 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 "siwx917_utils.h" +#include "init_ccpPlatform.h" + +#include + +void appError(int err) +{ + SILABS_LOG("!!!!!!!!!!!! App Critical Error: %d !!!!!!!!!!!", err); + portDISABLE_INTERRUPTS(); + while (true) + ; +} + +void appError(CHIP_ERROR error) +{ + appError(static_cast(error.AsInteger())); +} diff --git a/examples/platform/silabs/SiWx917/siwx917_utils.h b/examples/platform/silabs/SiWx917/siwx917_utils.h new file mode 100644 index 00000000000000..2223275d841733 --- /dev/null +++ b/examples/platform/silabs/SiWx917/siwx917_utils.h @@ -0,0 +1,38 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2022 Silabs. + * 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 + +// SiWx917 Logging +#ifdef __cplusplus +extern "C" { +#endif + +void silabsInitLog(void); + +void efr32Log(const char * aFormat, ...); +#define SILABS_LOG(...) efr32Log(__VA_ARGS__); +void appError(int err); + +#ifdef __cplusplus +} + +#include +void appError(CHIP_ERROR error); +#endif diff --git a/examples/platform/silabs/SiWx917/uart.cpp b/examples/platform/silabs/SiWx917/uart.cpp new file mode 100644 index 00000000000000..d264e9644e9f08 --- /dev/null +++ b/examples/platform/silabs/SiWx917/uart.cpp @@ -0,0 +1,129 @@ +/* + * + * Copyright (c) 2021 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 "AppConfig.h" +#include "matter_shell.h" + +#ifdef __cplusplus +extern "C" { +#endif +#include "assert.h" +#include "rsi_board.h" +#include "uart.h" +#include "uartdrv.h" +#include +#include + +#if !defined(MIN) +#define MIN(A, B) ((A) < (B) ? (A) : (B)) +#endif + +#define UART_CONSOLE_ERR -1 // Negative value in case of UART Console action failed. Triggers a failure for PW_RPC + +void uartConsoleInit(void) +{ + // UART init is already done +} + +void USART_IRQHandler(void) +{ +#ifdef ENABLE_CHIP_SHELL + chip::NotifyShellProcessFromISR(); +#endif +#if defined(SL_WIFI) + /* TODO */ +#elif !defined(PW_RPC_ENABLED) + otSysEventSignalPending(); +#endif + +#if (defined(EFR32MG24) || defined(MGM24)) + EUSART_IntClear(SL_UARTDRV_EUSART_VCOM_PERIPHERAL, EUSART_IF_RXFL); +#endif +} + +/* + * @brief Callback triggered when a UARTDRV DMA buffer is full + */ +static void UART_rx_callback(UARTDRV_Handle_t handle, Ecode_t transferStatus, uint8_t * data, UARTDRV_Count_t transferCount) +{ + (void) transferStatus; + + uint8_t writeSize = (transferCount - lastCount); + if (RemainingSpace(&sReceiveFifo) >= writeSize) + { + WriteToFifo(&sReceiveFifo, data + lastCount, writeSize); + lastCount = 0; + } + + UARTDRV_Receive(vcom_handle, data, transferCount, UART_rx_callback); + +#ifdef ENABLE_CHIP_SHELL + chip::NotifyShellProcessFromISR(); +#endif +#if defined(SL_WIFI) + /* TODO */ +#elif !defined(PW_RPC_ENABLED) + otSysEventSignalPending(); +#endif +} + +/* + * @brief Read the data available from the console Uart + * @param Buffer that contains the data to write, number bytes to write. + * @return Amount of bytes written or ERROR (-1) + */ +int16_t uartConsoleWrite(const char * Buf, uint16_t BufLength) +{ + if (Buf == NULL || BufLength < 1) + { + return UART_CONSOLE_ERR; + } + + // Add Terminating char at the end of buffer + Buf[BufLength] = '\0'; + + Board_UARTPutSTR((uint8_t *) Buf); + + return BufLength; +} + +/* + * @brief Read the data available from the console Uart + * @param Buffer for the data to be read, number bytes to read. + * @return Amount of bytes that was read from the rx fifo or ERROR (-1) + */ +int16_t uartConsoleRead(char * Buf, uint16_t NbBytesToRead) +{ + uint32_t data; + + if (Buf == NULL || NbBytesToRead < 1) + { + return UART_CONSOLE_ERR; + } + + while (--NbBytesToRead >= 0) + { + data = Board_UARTGetChar(); + *Buf++ = (char) data; + } + + return NbBytesToRead; +} + +#ifdef __cplusplus +} +#endif diff --git a/examples/platform/silabs/SiWx917/uart.h b/examples/platform/silabs/SiWx917/uart.h new file mode 100644 index 00000000000000..035d5b3b0ede7d --- /dev/null +++ b/examples/platform/silabs/SiWx917/uart.h @@ -0,0 +1,33 @@ +/* + * + * Copyright (c) 2021 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 + +#ifdef __cplusplus +extern "C" { +#endif + +void uartConsoleInit(void); +int16_t uartConsoleWrite(const char * Buf, uint16_t BufLength); +int16_t uartConsoleRead(char * Buf, uint16_t NbBytesToRead); + +#ifdef __cplusplus +} // extern "C" +#endif diff --git a/examples/platform/silabs/efr32/BUILD.gn b/examples/platform/silabs/efr32/BUILD.gn index dbd8473a6c89de..f2ffefb77eed62 100644 --- a/examples/platform/silabs/efr32/BUILD.gn +++ b/examples/platform/silabs/efr32/BUILD.gn @@ -18,6 +18,8 @@ import("${chip_root}/src/lib/lib.gni") import("${chip_root}/src/platform/device.gni") import("${efr32_sdk_build_root}/efr32_sdk.gni") +silabs_common_plat_dir = "${chip_root}/examples/platform/silabs" + config("chip_examples_project_config") { include_dirs = [ "project_include" ] @@ -60,8 +62,11 @@ source_set("efr-matter-shell") { if (chip_build_libshell) { defines = [ "ENABLE_CHIP_SHELL" ] - sources = [ "matter_shell.cpp" ] - include_dirs = [ "." ] + sources = [ "${silabs_common_plat_dir}/matter_shell.cpp" ] + include_dirs = [ + ".", + "${silabs_common_plat_dir}", + ] public_deps = [ "${chip_root}/examples/shell/shell_common:shell_common", @@ -82,8 +87,8 @@ config("attestation-credentials-config") { source_set("efr32-attestation-credentials") { sources = [ - "../SilabsDeviceAttestationCreds.cpp", - "../SilabsDeviceAttestationCreds.h", + "${silabs_common_plat_dir}/SilabsDeviceAttestationCreds.cpp", + "${silabs_common_plat_dir}/SilabsDeviceAttestationCreds.h", ] public_deps = [ diff --git a/examples/platform/silabs/efr32/BaseApplication.cpp b/examples/platform/silabs/efr32/BaseApplication.cpp index 85748b35359d3f..a9ecfc63bb0c60 100644 --- a/examples/platform/silabs/efr32/BaseApplication.cpp +++ b/examples/platform/silabs/efr32/BaseApplication.cpp @@ -40,7 +40,6 @@ #include "EFR32DeviceDataProvider.h" #include #include -#include #include #include #include diff --git a/examples/platform/silabs/efr32/project_include/OpenThreadConfig.h b/examples/platform/silabs/efr32/project_include/OpenThreadConfig.h index dccf3c816b7b66..76842d5783dbc1 100644 --- a/examples/platform/silabs/efr32/project_include/OpenThreadConfig.h +++ b/examples/platform/silabs/efr32/project_include/OpenThreadConfig.h @@ -36,6 +36,31 @@ // Enable use of external heap allocator (calloc/free) for OpenThread. #define OPENTHREAD_CONFIG_HEAP_EXTERNAL_ENABLE 1 +#if CHIP_DEVICE_CONFIG_ENABLE_SED +#define OPENTHREAD_CONFIG_PARENT_SEARCH_ENABLE 0 +// In seconds +#define OPENTHREAD_CONFIG_MLE_CHILD_TIMEOUT_DEFAULT (SL_SLEEP_TIME_MS / 1000) +#endif + +/****Uncomment below section for OpenThread Debug logs*/ +// #define OPENTHREAD_CONFIG_LOG_LEVEL OT_LOG_LEVEL_DEBG + +// #ifndef OPENTHREAD_CONFIG_LOG_CLI +// #define OPENTHREAD_CONFIG_LOG_CLI 1 +// #endif + +// #ifndef OPENTHREAD_CONFIG_LOG_PKT_DUMP +// #define OPENTHREAD_CONFIG_LOG_PKT_DUMP 1 +// #endif + +// #ifndef OPENTHREAD_CONFIG_LOG_PLATFORM +// #define OPENTHREAD_CONFIG_LOG_PLATFORM 1 +// #endif + +// #ifndef OPENTHREAD_CONFIG_LOG_PREPEND_LEVEL +// #define OPENTHREAD_CONFIG_LOG_PREPEND_LEVEL 1 +// #endif + // EFR32MG21A020F1024IM32 has 96k of RAM. Reduce the number of buffers to // conserve RAM for this Series 2 part. #if defined(EFR32MG21) diff --git a/examples/platform/silabs/efr32/wf200/host_if.cpp b/examples/platform/silabs/efr32/wf200/host_if.cpp index c7224962adf1ad..a22735ae448529 100644 --- a/examples/platform/silabs/efr32/wf200/host_if.cpp +++ b/examples/platform/silabs/efr32/wf200/host_if.cpp @@ -357,6 +357,8 @@ static void sl_wfx_connect_callback(sl_wfx_connect_ind_body_t connect_indication { uint8_t * mac = connect_indication_body.mac; uint32_t status = connect_indication_body.status; + ap_info.chan = connect_indication_body.channel; + memcpy(&ap_info.security, &wifi_provision.security, sizeof(wifi_provision.security)); switch (status) { case WFM_STATUS_SUCCESS: { diff --git a/examples/platform/telink/Rpc.cpp b/examples/platform/telink/Rpc.cpp new file mode 100644 index 00000000000000..93348fc5dbcbcb --- /dev/null +++ b/examples/platform/telink/Rpc.cpp @@ -0,0 +1,219 @@ +/* + * + * Copyright (c) 2021 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. + */ + +#if defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE +#include "AppTask.h" +#endif // defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE +#include "PigweedLoggerMutex.h" +#include "pigweed/RpcService.h" +#include "pw_sys_io_telink/init.h" +#include +#include + +#include + +LOG_MODULE_DECLARE(app, CONFIG_MATTER_LOG_LEVEL); + +#if defined(PW_RPC_ATTRIBUTE_SERVICE) && PW_RPC_ATTRIBUTE_SERVICE +#include "pigweed/rpc_services/Attributes.h" +#endif // defined(PW_RPC_ATTRIBUTE_SERVICE) && PW_RPC_ATTRIBUTE_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 + +#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 + +#if defined(PW_RPC_DEVICE_SERVICE) && PW_RPC_DEVICE_SERVICE +#include "pigweed/rpc_services/Device.h" +#endif // defined(PW_RPC_DEVICE_SERVICE) && PW_RPC_DEVICE_SERVICE + +#if defined(PW_RPC_LIGHTING_SERVICE) && PW_RPC_LIGHTING_SERVICE +#include "pigweed/rpc_services/Lighting.h" +#endif // defined(PW_RPC_LIGHTING_SERVICE) && PW_RPC_LIGHTING_SERVICE + +#if defined(PW_RPC_LOCKING_SERVICE) && PW_RPC_LOCKING_SERVICE +#include "pigweed/rpc_services/Locking.h" +#endif // defined(PW_RPC_LOCKING_SERVICE) && PW_RPC_LOCKING_SERVICE + +#if defined(PW_RPC_OTCLI_SERVICE) && PW_RPC_OTCLI_SERVICE +#include "pigweed/rpc_services/OtCli.h" +#endif // defined(PW_RPC_OTCLI_SERVICE) && PW_RPC_OTCLI_SERVICE + +#if defined(PW_RPC_THREAD_SERVICE) && PW_RPC_THREAD_SERVICE +#include "pigweed/rpc_services/Thread.h" +#endif // defined(PW_RPC_THREAD_SERVICE) && PW_RPC_THREAD_SERVICE + +#if defined(PW_RPC_TRACING_SERVICE) && PW_RPC_TRACING_SERVICE +#define PW_TRACE_BUFFER_SIZE_BYTES 1024 +#include "pw_trace/trace.h" +#include "pw_trace_tokenized/trace_rpc_service_nanopb.h" + +// Define trace time for pw_trace +PW_TRACE_TIME_TYPE pw_trace_GetTraceTime() +{ + return (PW_TRACE_TIME_TYPE) chip::System::SystemClock().GetMonotonicMicroseconds64().count(); +} +// Microsecond time source +size_t pw_trace_GetTraceTimeTicksPerSecond() +{ + return 1000000; +} + +#endif // defined(PW_RPC_TRACING_SERVICE) && PW_RPC_TRACING_SERVICE + +namespace chip { +namespace rpc { + +#if defined(PW_RPC_DEVICE_SERVICE) && PW_RPC_DEVICE_SERVICE +namespace { + +void reboot_timer_handler(struct k_timer * dummy) +{ + sys_reboot(0); +} +K_TIMER_DEFINE(reboot_timer, reboot_timer_handler, NULL); + +} // namespace + +class TelinkDevice final : public Device +{ +public: + pw::Status Reboot(const pw_protobuf_Empty & request, pw_protobuf_Empty & response) override + { + k_timer_start(&reboot_timer, K_SECONDS(1), K_FOREVER); + return pw::OkStatus(); + } +}; +#endif // defined(PW_RPC_DEVICE_SERVICE) && PW_RPC_DEVICE_SERVICE + +#if defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE +class TelinkButton final : public Button +{ +public: + pw::Status Event(const chip_rpc_ButtonEvent & request, pw_protobuf_Empty & response) override + { + GetAppTask().ButtonEventHandler((AppTask::ButtonId_t) request.idx, request.pushed); + return pw::OkStatus(); + } +}; +#endif // defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE + +namespace { + +constexpr size_t kRpcTaskSize = 5120; +constexpr int kRpcPriority = 5; + +K_THREAD_STACK_DEFINE(rpc_stack_area, kRpcTaskSize); +struct k_thread rpc_thread_data; + +#if defined(PW_RPC_ATTRIBUTE_SERVICE) && PW_RPC_ATTRIBUTE_SERVICE +Attributes attributes_service; +#endif // defined(PW_RPC_ATTRIBUTE_SERVICE) && PW_RPC_ATTRIBUTE_SERVICE + +#if defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE +TelinkButton button_service; +#endif // defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE + +#if defined(PW_RPC_DESCRIPTOR_SERVICE) && PW_RPC_DESCRIPTOR_SERVICE +Descriptor descriptor_service; +#endif // defined(PW_RPC_DESCRIPTOR_SERVICE) && PW_RPC_DESCRIPTOR_SERVICE + +#if defined(PW_RPC_DEVICE_SERVICE) && PW_RPC_DEVICE_SERVICE +TelinkDevice device_service; +#endif // defined(PW_RPC_DEVICE_SERVICE) && PW_RPC_DEVICE_SERVICE + +#if defined(PW_RPC_LIGHTING_SERVICE) && PW_RPC_LIGHTING_SERVICE +Lighting lighting_service; +#endif // defined(PW_RPC_LIGHTING_SERVICE) && PW_RPC_LIGHTING_SERVICE + +#if defined(PW_RPC_LOCKING_SERVICE) && PW_RPC_LOCKING_SERVICE +Locking locking; +#endif // defined(PW_RPC_LOCKING_SERVICE) && PW_RPC_LOCKING_SERVICE + +#if defined(PW_RPC_OTCLI_SERVICE) && PW_RPC_OTCLI_SERVICE +OtCli ot_cli_service; +#endif // defined(PW_RPC_OTCLI_SERVICE) && PW_RPC_OTCLI_SERVICE + +#if defined(PW_RPC_THREAD_SERVICE) && PW_RPC_THREAD_SERVICE +Thread thread; +#endif // defined(PW_RPC_THREAD_SERVICE) && PW_RPC_THREAD_SERVICE + +#if defined(PW_RPC_TRACING_SERVICE) && PW_RPC_TRACING_SERVICE +pw::trace::TraceService trace_service; +#endif // defined(PW_RPC_TRACING_SERVICE) && PW_RPC_TRACING_SERVICE + +void RegisterServices(pw::rpc::Server & server) +{ +#if defined(PW_RPC_ATTRIBUTE_SERVICE) && PW_RPC_ATTRIBUTE_SERVICE + server.RegisterService(attributes_service); +#endif // defined(PW_RPC_ATTRIBUTE_SERVICE) && PW_RPC_ATTRIBUTE_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 + +#if defined(PW_RPC_DESCRIPTOR_SERVICE) && PW_RPC_DESCRIPTOR_SERVICE + server.RegisterService(descriptor_service); +#endif // defined(PW_RPC_DESCRIPTOR_SERVICE) && PW_RPC_DESCRIPTOR_SERVICE + +#if defined(PW_RPC_DEVICE_SERVICE) && PW_RPC_DEVICE_SERVICE + server.RegisterService(device_service); +#endif // defined(PW_RPC_DEVICE_SERVICE) && PW_RPC_DEVICE_SERVICE + +#if defined(PW_RPC_LIGHTING_SERVICE) && PW_RPC_LIGHTING_SERVICE + server.RegisterService(lighting_service); +#endif // defined(PW_RPC_LIGHTING_SERVICE) && PW_RPC_LIGHTING_SERVICE + +#if defined(PW_RPC_LOCKING_SERVICE) && PW_RPC_LOCKING_SERVICE + server.RegisterService(locking); +#endif // defined(PW_RPC_LOCKING_SERVICE) && PW_RPC_LOCKING_SERVICE + +#if defined(PW_RPC_OTCLI_SERVICE) && PW_RPC_OTCLI_SERVICE + server.RegisterService(ot_cli_service); +#endif // defined(PW_RPC_OTCLI_SERVICE) && PW_RPC_OTCLI_SERVICE + +#if defined(PW_RPC_THREAD_SERVICE) && PW_RPC_THREAD_SERVICE + server.RegisterService(thread); +#endif // defined(PW_RPC_THREAD_SERVICE) && PW_RPC_THREAD_SERVICE + +#if defined(PW_RPC_TRACING_SERVICE) && PW_RPC_TRACING_SERVICE + server.RegisterService(trace_service); + PW_TRACE_SET_ENABLED(true); +#endif // defined(PW_RPC_TRACING_SERVICE) && PW_RPC_TRACING_SERVICE +} + +} // namespace + +void RunRpcService(void *, void *, void *) +{ + Start(RegisterServices, &logger_mutex); +} + +k_tid_t Init() +{ + pw_sys_io_Init(); + k_tid_t tid = k_thread_create(&rpc_thread_data, rpc_stack_area, K_THREAD_STACK_SIZEOF(rpc_stack_area), RunRpcService, NULL, + NULL, NULL, kRpcPriority, 0, K_NO_WAIT); + return tid; +} + +} // namespace rpc +} // namespace chip diff --git a/examples/platform/telink/Rpc.h b/examples/platform/telink/Rpc.h new file mode 100644 index 00000000000000..82409b727cab26 --- /dev/null +++ b/examples/platform/telink/Rpc.h @@ -0,0 +1,33 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +#include + +namespace chip { +namespace rpc { + +class TelinkButton; + +void RunRpcService(void *, void *, void *); + +k_tid_t Init(); + +} // namespace rpc +} // namespace chip diff --git a/examples/platform/telink/pw_sys_io/BUILD.gn b/examples/platform/telink/pw_sys_io/BUILD.gn new file mode 100644 index 00000000000000..3bd1d4310d8f0e --- /dev/null +++ b/examples/platform/telink/pw_sys_io/BUILD.gn @@ -0,0 +1,32 @@ +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/pigweed.gni") + +import("$dir_pw_build/target_types.gni") + +config("default_config") { + include_dirs = [ "public" ] +} + +pw_source_set("pw_sys_io_telink") { + sources = [ "sys_io_telink.cc" ] + + deps = [ + "$dir_pw_sys_io:default_putget_bytes", + "$dir_pw_sys_io:facade", + ] + + public_configs = [ ":default_config" ] +} diff --git a/examples/platform/telink/pw_sys_io/CMakeLists.txt b/examples/platform/telink/pw_sys_io/CMakeLists.txt new file mode 100644 index 00000000000000..f8675a4ec1f05a --- /dev/null +++ b/examples/platform/telink/pw_sys_io/CMakeLists.txt @@ -0,0 +1,18 @@ +include($ENV{PW_ROOT}/pw_build/pigweed.cmake) + +add_library(suppress_zephyr_warnings INTERFACE) +target_compile_options(suppress_zephyr_warnings INTERFACE + -Wno-redundant-decls + -Wno-missing-field-initializers + -Wno-cast-qual + -Wno-undef +) + +pw_add_library(pw_sys_io.telink STATIC + SOURCES + sys_io_telink.cc + PRIVATE_DEPS + pw_sys_io + suppress_zephyr_warnings + pw_sys_io.default_putget_bytes +) diff --git a/examples/platform/telink/pw_sys_io/public/pw_sys_io_telink/init.h b/examples/platform/telink/pw_sys_io/public/pw_sys_io_telink/init.h new file mode 100644 index 00000000000000..9f375ed5fc2312 --- /dev/null +++ b/examples/platform/telink/pw_sys_io/public/pw_sys_io_telink/init.h @@ -0,0 +1,27 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +#include "pw_preprocessor/util.h" + +PW_EXTERN_C_START + +// The actual implement of PreMainInit() in sys_io_BACKEND. +void pw_sys_io_Init(); + +PW_EXTERN_C_END diff --git a/examples/platform/telink/pw_sys_io/sys_io_telink.cc b/examples/platform/telink/pw_sys_io/sys_io_telink.cc new file mode 100644 index 00000000000000..37af653075fdc6 --- /dev/null +++ b/examples/platform/telink/pw_sys_io/sys_io_telink.cc @@ -0,0 +1,78 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +#include "pw_sys_io/sys_io.h" +#include "zephyr/console/console.h" +#include +#include + +#ifdef CONFIG_USB +#include +#endif + +extern "C" void pw_sys_io_Init() +{ + int err; + +#ifdef CONFIG_USB + err = usb_enable(nullptr); + assert(err == 0); +#endif + + err = console_init(); + assert(err == 0); +} + +namespace pw::sys_io { + +Status ReadByte(std::byte * dest) +{ + if (!dest) + return Status::InvalidArgument(); + + const int c = console_getchar(); + *dest = static_cast(c); + + return c < 0 ? Status::FailedPrecondition() : OkStatus(); +} + +Status WriteByte(std::byte b) +{ + return console_putchar(static_cast(b)) < 0 ? Status::FailedPrecondition() : OkStatus(); +} + +// Writes a string using pw::sys_io, and add newline characters at the end. +StatusWithSize WriteLine(const std::string_view & s) +{ + size_t chars_written = 0; + StatusWithSize result = WriteBytes(pw::as_bytes(pw::span(s))); + if (!result.ok()) + { + return result; + } + chars_written += result.size(); + + // Write trailing newline. + result = WriteBytes(pw::as_bytes(pw::span("\r\n", 2))); + chars_written += result.size(); + + return StatusWithSize(result.status(), chars_written); +} + +} // namespace pw::sys_io diff --git a/examples/platform/telink/util/include/PigweedLogger.h b/examples/platform/telink/util/include/PigweedLogger.h new file mode 100644 index 00000000000000..ac106231802e50 --- /dev/null +++ b/examples/platform/telink/util/include/PigweedLogger.h @@ -0,0 +1,26 @@ +/* + * Copyright (c) 2021 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 + +namespace PigweedLogger { + +k_sem * GetSemaphore(); + +} // namespace PigweedLogger diff --git a/examples/platform/telink/util/src/PigweedLogger.cpp b/examples/platform/telink/util/src/PigweedLogger.cpp new file mode 100644 index 00000000000000..82b2d9f11fd9e2 --- /dev/null +++ b/examples/platform/telink/util/src/PigweedLogger.cpp @@ -0,0 +1,149 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/* + * @file PigweedLogger.cpp + * + * This file contains a backend of Zephyr logging system, based on Pigweed HDLC + * over UART transport. It allows to send log messages even if the application + * needs to use HDLC/UART for another purpose like the RPC server. + */ + +#include +#include +#include +#include +#include + +#include +#include +#include + +#include "pw_span/span.h" +#include +#include +#include + +namespace PigweedLogger { +namespace { + +#if CONFIG_LOG + +#if !CONFIG_LOG_MODE_IMMEDIATE +#error "Backend of Zephyr logger based on Pigweed HDLC requires LOG_MODE_IMMEDIATE=y" +#endif + +constexpr uint8_t kLogHdlcAddress = 1; // Send log messages to HDLC address 1 (other than RPC communication) +constexpr size_t kWriteBufferSize = 128; // Buffer for constructing HDLC frames + +// Exclusive access to the backend is needed to make sure that log messages coming +// from different threads are not interwoven. +K_SEM_DEFINE(sLoggerLock, 1, 1); +pw::stream::SysIoWriter sWriter; +size_t sWriteBufferPos; +uint8_t sWriteBuffer[kWriteBufferSize]; +bool sIsPanicMode; + +void flush() +{ + pw::hdlc::WriteUIFrame(kLogHdlcAddress, pw::as_bytes(pw::span(sWriteBuffer, sWriteBufferPos)), sWriter); + sWriteBufferPos = 0; +} + +int putString(uint8_t * buffer, size_t size, void * /* ctx */) +{ + assert(sWriteBufferPos < kWriteBufferSize); + + for (size_t i = 0; i < size; ++i) + { + // Send each line excluding "\r\n" in a separate frame + + if (buffer[i] == '\r') + continue; + + if (buffer[i] == '\n') + { + flush(); + continue; + } + + sWriteBuffer[sWriteBufferPos++] = buffer[i]; + + if (sWriteBufferPos == kWriteBufferSize) + flush(); + } + + return size; +} + +LOG_OUTPUT_DEFINE(pigweedLogOutput, putString, nullptr, 0); + +void init(const log_backend *) +{ + pw_sys_io_Init(); +} + +void processMessage(const struct log_backend * const backend, union log_msg_generic * msg) +{ + int ret = k_sem_take(&sLoggerLock, K_FOREVER); + assert(ret == 0); + + if (!sIsPanicMode) + { + log_format_func_t outputFunc = log_format_func_t_get(LOG_OUTPUT_TEXT); + + outputFunc(&pigweedLogOutput, &msg->log, log_backend_std_get_flags()); + } + + k_sem_give(&sLoggerLock); +} + +void panic(const log_backend *) +{ + int ret = k_sem_take(&sLoggerLock, K_FOREVER); + assert(ret == 0); + + log_backend_std_panic(&pigweedLogOutput); + flush(); + sIsPanicMode = true; + + k_sem_give(&sLoggerLock); +} + +const log_backend_api pigweedLogApi = { + .process = processMessage, + .panic = panic, + .init = init, +}; + +LOG_BACKEND_DEFINE(pigweedLogBackend, pigweedLogApi, /* autostart */ true); + +#endif // CONFIG_LOG + +} // namespace + +k_sem * GetSemaphore() +{ +#if CONFIG_LOG + return &sLoggerLock; +#else + return nullptr; +#endif +} + +} // namespace PigweedLogger diff --git a/examples/pump-app/cc13x2x7_26x2x7/main/DeviceCallbacks.cpp b/examples/pump-app/cc13x2x7_26x2x7/main/DeviceCallbacks.cpp index 5fc2be33ce6910..73c9e1621b46f0 100644 --- a/examples/pump-app/cc13x2x7_26x2x7/main/DeviceCallbacks.cpp +++ b/examples/pump-app/cc13x2x7_26x2x7/main/DeviceCallbacks.cpp @@ -28,7 +28,6 @@ #include "PumpManager.h" #include -#include #include #include #include diff --git a/examples/pump-app/nrfconnect/main/AppTask.cpp b/examples/pump-app/nrfconnect/main/AppTask.cpp index 209eaa0805b666..14ea81f628e2d6 100644 --- a/examples/pump-app/nrfconnect/main/AppTask.cpp +++ b/examples/pump-app/nrfconnect/main/AppTask.cpp @@ -26,7 +26,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/pump-app/pump-common/pump-app.matter b/examples/pump-app/pump-common/pump-app.matter index b1b48d30664b9f..8d670ca2600f03 100644 --- a/examples/pump-app/pump-common/pump-app.matter +++ b/examples/pump-app/pump-common/pump-app.matter @@ -1247,7 +1247,7 @@ client cluster OccupancySensing = 1030 { } endpoint 0 { - device type pump = 22; + device type pump = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Descriptor { @@ -1415,7 +1415,7 @@ endpoint 0 { } } endpoint 1 { - device type pump = 771; + device type pump = 771, version 1; binding cluster OccupancySensing; server cluster Identify { diff --git a/examples/pump-controller-app/nrfconnect/main/AppTask.cpp b/examples/pump-controller-app/nrfconnect/main/AppTask.cpp index 248b39255cbd51..1e59d9bd6affbe 100644 --- a/examples/pump-controller-app/nrfconnect/main/AppTask.cpp +++ b/examples/pump-controller-app/nrfconnect/main/AppTask.cpp @@ -26,7 +26,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter b/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter index b9096238a10a54..3fda4212f7a072 100644 --- a/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter +++ b/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter @@ -1103,7 +1103,7 @@ client cluster FlowMeasurement = 1028 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Descriptor { @@ -1271,7 +1271,7 @@ endpoint 0 { } } endpoint 1 { - device type pumpcontroller = 772; + device type pumpcontroller = 772, version 1; binding cluster OnOff; binding cluster PumpConfigurationAndControl; binding cluster TemperatureMeasurement; diff --git a/examples/shell/efr32/include/CHIPProjectConfig.h b/examples/shell/efr32/include/CHIPProjectConfig.h index bd5c6355cae55a..72a56579663289 100644 --- a/examples/shell/efr32/include/CHIPProjectConfig.h +++ b/examples/shell/efr32/include/CHIPProjectConfig.h @@ -66,17 +66,6 @@ */ #define CHIP_DEVICE_CONFIG_DEVICE_HARDWARE_VERSION 1 -/** - * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING - * - * A string identifying the software version running on the device. - * CHIP service currently expects the software version to be in the format - * {MAJOR_VERSION}.0d{MINOR_VERSION} - */ -#ifndef CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING -#define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING "0.1ALPHA" -#endif - /** * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION * diff --git a/examples/shell/nxp/k32w/k32w0/main/AppTask.cpp b/examples/shell/nxp/k32w/k32w0/main/AppTask.cpp index 0ceec53420993b..47c5f4d62b44b8 100644 --- a/examples/shell/nxp/k32w/k32w0/main/AppTask.cpp +++ b/examples/shell/nxp/k32w/k32w0/main/AppTask.cpp @@ -32,7 +32,6 @@ #include #include -#include #include #include "Keyboard.h" diff --git a/examples/shell/openiotsdk/.gitignore b/examples/shell/openiotsdk/.gitignore new file mode 100644 index 00000000000000..567609b1234a9b --- /dev/null +++ b/examples/shell/openiotsdk/.gitignore @@ -0,0 +1 @@ +build/ diff --git a/examples/shell/openiotsdk/CMakeLists.txt b/examples/shell/openiotsdk/CMakeLists.txt new file mode 100644 index 00000000000000..2d9cf86d9a95bb --- /dev/null +++ b/examples/shell/openiotsdk/CMakeLists.txt @@ -0,0 +1,77 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +cmake_minimum_required(VERSION 3.21) + +get_filename_component(CHIP_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/../../.. REALPATH) +get_filename_component(OPEN_IOT_SDK_CONFIG ${CHIP_ROOT}/config/openiotsdk REALPATH) +get_filename_component(OPEN_IOT_SDK_EXAMPLE_COMMON ${CHIP_ROOT}/examples/platform/openiotsdk REALPATH) +get_filename_component(SHELL_COMMON ${CHIP_ROOT}/examples/shell/shell_common REALPATH) + +list(APPEND CMAKE_MODULE_PATH ${OPEN_IOT_SDK_CONFIG}/cmake) + +set(APP_TARGET chip-openiotsdk-shell-example) + +# Toolchain files need to exist before first call to project +include(toolchain) + +project(${APP_TARGET} LANGUAGES C CXX ASM) + +include(sdk) + +# LwIP configuration +if(TARGET lwip-cmsis-port) + # lwip requires user_lwipopts.h, we use the custom settings + target_include_directories(lwipopts + INTERFACE + ${OPEN_IOT_SDK_CONFIG}/lwip + ) + + if (${CMAKE_BUILD_TYPE} STREQUAL "Debug") + target_compile_definitions(lwipopts + INTERFACE + LWIP_DEBUG + ) + endif() +endif() + +add_executable(${APP_TARGET}) + +# Application CHIP build configuration +set(CONFIG_CHIP_LIB_SHELL YES) +include(chip) + +add_subdirectory(${OPEN_IOT_SDK_EXAMPLE_COMMON}/app ./app_build) + +target_include_directories(${APP_TARGET} + PRIVATE + main/include + ${SHELL_COMMON}/include +) + +target_sources(${APP_TARGET} + PRIVATE + main/main.cpp + ${SHELL_COMMON}/cmd_misc.cpp + ${SHELL_COMMON}/globals.cpp +) + +target_link_libraries(${APP_TARGET} + openiotsdk-app +) + +include(linker) +set_target_link(${APP_TARGET}) diff --git a/examples/shell/openiotsdk/README.md b/examples/shell/openiotsdk/README.md new file mode 100644 index 00000000000000..5307edf1f86cd2 --- /dev/null +++ b/examples/shell/openiotsdk/README.md @@ -0,0 +1,45 @@ +# Matter Open IoT SDK Shell Example Application + +The example exposes configuration and management APIs via a command line +interface. It parses a command line and calls the corresponding service +execution. There is a set of common shell commands which perform basic device +operations. + +For more details see +[Common shell commands](../README.md#chip-shell-command-details). + +## Build and run + +For information on how to build and run this example and further information +about the platform it is run on see +[Open IoT SDK examples](../../../docs/examples/openiotsdk_examples.md). + +The example name to use in the scripts is `shell`. + +## Using the example + +Communication with the application goes through the active telnet session. When +the application runs these lines should be visible: + +``` +[INF] [SH] Open IoT SDK shell example application start +[INF] [SH] Open IoT SDK shell example application run +> +``` + +The shell application launched correctly. + +Pass commands to the terminal and wait for the response. The application +supports common Matter shell commands. They are used to control the basic +functionalities of the device. + +For more details read: +[Common shell commands](../README.md#chip-shell-command-details) + +Example: + +``` +> echo Hello +Hello +Done +``` diff --git a/examples/shell/openiotsdk/cmsis-config/RTE_Components.h b/examples/shell/openiotsdk/cmsis-config/RTE_Components.h new file mode 100644 index 00000000000000..e86df2b4e44e06 --- /dev/null +++ b/examples/shell/openiotsdk/cmsis-config/RTE_Components.h @@ -0,0 +1,22 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef RTE_COMPONENTS_H +#define RTE_COMPONENTS_H + +#endif // RTE_COMPONENTS_H diff --git a/examples/shell/openiotsdk/freertos-config/FreeRTOSConfig.h b/examples/shell/openiotsdk/freertos-config/FreeRTOSConfig.h new file mode 100644 index 00000000000000..6011c1e9d6bf79 --- /dev/null +++ b/examples/shell/openiotsdk/freertos-config/FreeRTOSConfig.h @@ -0,0 +1,257 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef FREERTOS_CONFIG_H +#define FREERTOS_CONFIG_H + +/*----------------------------------------------------------- + * Application specific definitions. + * + * These definitions should be adjusted for your particular hardware and + * application requirements. + * + * THESE PARAMETERS ARE DESCRIBED WITHIN THE 'CONFIGURATION' SECTION OF THE + * FreeRTOS API DOCUMENTATION AVAILABLE ON THE FreeRTOS.org WEB SITE. + * + * See http://www.freertos.org/a00110.html + *----------------------------------------------------------*/ + +#if (defined(__ARMCC_VERSION) || defined(__GNUC__) || defined(__ICCARM__)) +#include + +extern uint32_t SystemCoreClock; +#endif + +// Minimal stack size [words] <0-65535> +// Stack for idle task and default task stack in words. +// Default: 128 +#define configMINIMAL_STACK_SIZE ((uint16_t)(4 * 1024)) + +// Total heap size [bytes] <0-0xFFFFFFFF> +// Heap memory size in bytes. +// Default: 8192 +#define configTOTAL_HEAP_SIZE ((size_t) 8192) + +// Kernel tick frequency [Hz] <0-0xFFFFFFFF> +// Kernel tick rate in Hz. +// Default: 1000 +#define configTICK_RATE_HZ ((TickType_t) 1000) + +// Timer task stack depth [words] <0-65535> +// Stack for timer task in words. +// Default: 80 +#define configTIMER_TASK_STACK_DEPTH configMINIMAL_STACK_SIZE + +// Timer task priority <0-56> +// Timer task priority. +// Default: 40 (High) +#define configTIMER_TASK_PRIORITY 40 + +// Timer queue length <0-1024> +// Timer command queue length. +// Default: 5 +#define configTIMER_QUEUE_LENGTH 5 + +// Preemption interrupt priority +// Maximum priority of interrupts that are safe to call FreeRTOS API. +// Default: 16 +#define configMAX_SYSCALL_INTERRUPT_PRIORITY (5 << (8 - configPRIO_BITS)) + +// Use time slicing +// Enable setting to use timeslicing. +// Default: 1 +#define configUSE_TIME_SLICING 1 + +// Idle should yield +// Control Yield behaviour of the idle task. +// Default: 1 +#define configIDLE_SHOULD_YIELD 1 + +// Check for stack overflow +// <0=>Disable <1=>Method one <2=>Method two +// Enable or disable stack overflow checking. +// Callback function vApplicationStackOverflowHook implementation is required when stack checking is enabled. +// Default: 0 +#define configCHECK_FOR_STACK_OVERFLOW 2 + +// Use idle hook +// Enable callback function call on each idle task iteration. +// Callback function vApplicationIdleHook implementation is required when idle hook is enabled. +// Default: 0 +#define configUSE_IDLE_HOOK 0 + +// Use tick hook +// Enable callback function call during each tick interrupt. +// Callback function vApplicationTickHook implementation is required when tick hook is enabled. +// Default: 0 +#define configUSE_TICK_HOOK 0 + +// Use deamon task startup hook +// Enable callback function call when timer service starts. +// Callback function vApplicationDaemonTaskStartupHook implementation is required when deamon task startup hook is +// enabled. Default: 0 +#define configUSE_DAEMON_TASK_STARTUP_HOOK 0 + +// Use malloc failed hook +// Enable callback function call when out of dynamic memory. +// Callback function vApplicationMallocFailedHook implementation is required when malloc failed hook is enabled. +// Default: 0 +#define configUSE_MALLOC_FAILED_HOOK 0 + +// Queue registry size +// Define maximum number of queue objects registered for debug purposes. +// The queue registry is used by kernel aware debuggers to locate queue and semaphore structures and display +// associated text names. Default: 0 +#define configQUEUE_REGISTRY_SIZE 0 + +// Event Recorder configuration +// Initialize and setup Event Recorder level filtering. +// Settings have no effect when Event Recorder is not present. + +// Initialize Event Recorder +// Initialize Event Recorder before FreeRTOS kernel start. +// Default: 1 +#define configEVR_INITIALIZE 1 + +// Setup recording level filter +// Enable configuration of FreeRTOS events recording level +// Default: 1 +#define configEVR_SETUP_LEVEL 1 + +// Tasks functions +// Define event recording level bitmask for events generated from Tasks functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_TASKS 0x05 + +// Queue functions +// Define event recording level bitmask for events generated from Queue functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_QUEUE 0x05 + +// Timer functions +// Define event recording level bitmask for events generated from Timer functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_TIMERS 0x05 + +// Event Groups functions +// Define event recording level bitmask for events generated from Event Groups functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_EVENTGROUPS 0x05 + +// Heap functions +// Define event recording level bitmask for events generated from Heap functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_HEAP 0x05 + +// Stream Buffer functions +// Define event recording level bitmask for events generated from Stream Buffer functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_STREAMBUFFER 0x05 +// +// + +// Port Specific Features +// Enable and configure port specific features. +// Check FreeRTOS documentation for definitions that apply for the used port. + +// Use Floating Point Unit +// Using Floating Point Unit (FPU) affects context handling. +// Enable FPU when application uses floating point operations. +// Default: 1 +#define configENABLE_FPU 1 + +// Use Memory Protection Unit +// Using Memory Protection Unit (MPU) requires detailed memory map definition. +// This setting is only releavant for MPU enabled ports. +// Default: 0 +#define configENABLE_MPU 0 + +// Use TrustZone Secure Side Only +// This settings prevents FreeRTOS contex switch to Non-Secure side. +// Enable this setting when FreeRTOS runs on the Secure side only. +#define configRUN_FREERTOS_SECURE_ONLY 1 + +// Use TrustZone Security Extension +// Using TrustZone affects context handling. +// Enable TrustZone when FreeRTOS runs on the Non-Secure side and calls functions from the Secure side. +// Default: 1 +#define configENABLE_TRUSTZONE 0 + +// Minimal secure stack size [words] <0-65535> +// Stack for idle task Secure side context in words. +// This setting is only relevant when TrustZone extension is enabled. +// Default: 128 +#define configMINIMAL_SECURE_STACK_SIZE ((uint32_t) 128) +// + +#ifdef __NVIC_PRIO_BITS +#define configPRIO_BITS __NVIC_PRIO_BITS +#else +#define configPRIO_BITS 4 +#endif + +//------------- <<< end of configuration section >>> --------------------------- + +/* Defines needed by FreeRTOS to implement CMSIS RTOS2 API. Do not change! */ +#define configCPU_CLOCK_HZ (SystemCoreClock) +#define configSUPPORT_STATIC_ALLOCATION 1 +#define configSUPPORT_DYNAMIC_ALLOCATION 1 +#define configUSE_PREEMPTION 1 +#define configUSE_TIMERS 1 +#define configUSE_MUTEXES 1 +#define configUSE_RECURSIVE_MUTEXES 1 +#define configUSE_COUNTING_SEMAPHORES 1 +#define configUSE_TASK_NOTIFICATIONS 1 +#define configUSE_TRACE_FACILITY 1 +#define configUSE_16_BIT_TICKS 0 +#define configUSE_PORT_OPTIMISED_TASK_SELECTION 0 +#define configMAX_PRIORITIES 56 +#define configKERNEL_INTERRUPT_PRIORITY (0x07 << (8 - configPRIO_BITS)) + +/* Defines that include FreeRTOS functions which implement CMSIS RTOS2 API. Do not change! */ +#define INCLUDE_xEventGroupSetBitsFromISR 1 +#define INCLUDE_xSemaphoreGetMutexHolder 1 +#define INCLUDE_vTaskDelay 1 +#define INCLUDE_xTaskDelayUntil 1 +#define INCLUDE_vTaskDelete 1 +#define INCLUDE_xTaskGetCurrentTaskHandle 1 +#define INCLUDE_xTaskGetSchedulerState 1 +#define INCLUDE_uxTaskGetStackHighWaterMark 1 +#define INCLUDE_uxTaskPriorityGet 1 +#define INCLUDE_vTaskPrioritySet 1 +#define INCLUDE_eTaskGetState 1 +#define INCLUDE_vTaskSuspend 1 +#define INCLUDE_xTimerPendFunctionCall 1 + +/* Map the FreeRTOS port interrupt handlers to their CMSIS standard names. */ +#define xPortPendSVHandler PendSV_Handler +#define vPortSVCHandler SVC_Handler + +/* Ensure Cortex-M port compatibility. */ +#define SysTick_Handler xPortSysTickHandler + +#include "RTE_Components.h" +#include CMSIS_device_header + +#endif /* FREERTOS_CONFIG_H */ diff --git a/examples/shell/openiotsdk/main/include/CHIPProjectConfig.h b/examples/shell/openiotsdk/main/include/CHIPProjectConfig.h new file mode 100644 index 00000000000000..7089ae47a8038f --- /dev/null +++ b/examples/shell/openiotsdk/main/include/CHIPProjectConfig.h @@ -0,0 +1,30 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +#define CHIP_DEVICE_CONFIG_ENABLE_WIFI_STATION 0 +#define CHIP_DEVICE_CONFIG_ENABLE_WIFI_AP 0 + +#define CHIP_SHELL_MAX_MODULES 30 + +// Use a default pairing code if one hasn't been provisioned in flash. +#define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE 20202021 +#define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR 0xF00 + +#define CHIP_DISPATCH_EVENT_LONG_DISPATCH_TIME_WARNING_THRESHOLD_MS 500 diff --git a/examples/shell/openiotsdk/main/main.cpp b/examples/shell/openiotsdk/main/main.cpp new file mode 100644 index 00000000000000..c832b2df4e49cf --- /dev/null +++ b/examples/shell/openiotsdk/main/main.cpp @@ -0,0 +1,94 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +#include +#include + +#include + +#include "cmsis_os2.h" +#include "openiotsdk_platform.h" + +using namespace ::chip; +using namespace ::chip::Shell; + +static void app_thread(void * argument) +{ + int ret; + + if (openiotsdk_network_init(true)) + { + ChipLogError(Shell, "Network initialization failed"); + goto exit; + } + + // Initialize the default streamer that was linked. + ret = Engine::Root().Init(); + if (ret) + { + ChipLogError(Shell, "Streamer initialization failed [%d]", ret); + goto exit; + } + + cmd_misc_init(); + + ChipLogProgress(Shell, "Open IoT SDK shell example application run"); + + Engine::Root().RunMainLoop(); + +exit: + osThreadTerminate(osThreadGetId()); +} + +int main() +{ + ChipLogProgress(Shell, "Open IoT SDK shell example application start"); + + if (openiotsdk_platform_init()) + { + ChipLogError(Shell, "Open IoT SDK platform initialization failed"); + return EXIT_FAILURE; + } + + if (openiotsdk_chip_init()) + { + ChipLogError(Shell, "Open IoT SDK CHIP stack initialization failed"); + return EXIT_FAILURE; + } + + static const osThreadAttr_t thread_attr = { + .stack_size = 8 * 1024 // Allocate enough stack for app thread + }; + + osThreadId_t appThread = osThreadNew(app_thread, NULL, &thread_attr); + if (appThread == NULL) + { + ChipLogError(Shell, "Failed to create app thread"); + return EXIT_FAILURE; + } + + if (openiotsdk_platform_run()) + { + ChipLogError(Shell, "Open IoT SDK platform run failed"); + return EXIT_FAILURE; + } + + return EXIT_SUCCESS; +} diff --git a/examples/temperature-measurement-app/esp32/main/CMakeLists.txt b/examples/temperature-measurement-app/esp32/main/CMakeLists.txt index 68e49f160f79e0..dbf518ff18844a 100644 --- a/examples/temperature-measurement-app/esp32/main/CMakeLists.txt +++ b/examples/temperature-measurement-app/esp32/main/CMakeLists.txt @@ -168,6 +168,7 @@ target_link_libraries(${COMPONENT_LIB} PUBLIC pw_log pw_rpc.server pw_sys_io + pw_trace pw_trace_tokenized pw_trace_tokenized.trace_buffer pw_trace_tokenized.rpc_service diff --git a/examples/temperature-measurement-app/esp32/main/temperature-measurement.matter b/examples/temperature-measurement-app/esp32/main/temperature-measurement.matter index 800d4acaf2325f..99fee8ee46a6ac 100644 --- a/examples/temperature-measurement-app/esp32/main/temperature-measurement.matter +++ b/examples/temperature-measurement-app/esp32/main/temperature-measurement.matter @@ -837,7 +837,7 @@ server cluster TemperatureMeasurement = 1026 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; server cluster Descriptor { callback attribute deviceTypeList; @@ -1026,7 +1026,7 @@ endpoint 0 { } } endpoint 1 { - device type tempsensor = 770; + device type tempsensor = 770, version 1; server cluster Descriptor { callback attribute deviceTypeList; diff --git a/examples/thermostat/efr32/BUILD.gn b/examples/thermostat/efr32/BUILD.gn index 1e5deb78ef4f10..2322a2ae887ded 100644 --- a/examples/thermostat/efr32/BUILD.gn +++ b/examples/thermostat/efr32/BUILD.gn @@ -194,6 +194,7 @@ efr32_sdk("sdk") { efr32_executable("thermostat_app") { output_name = "chip-efr32-thermostat-example.out" + public_configs = [ "${efr32_sdk_build_root}:silabs_config" ] include_dirs = [ "include" ] defines = [] diff --git a/examples/thermostat/efr32/include/CHIPProjectConfig.h b/examples/thermostat/efr32/include/CHIPProjectConfig.h index 35f6d54e785c70..526cede60faa2a 100644 --- a/examples/thermostat/efr32/include/CHIPProjectConfig.h +++ b/examples/thermostat/efr32/include/CHIPProjectConfig.h @@ -69,17 +69,6 @@ */ #define CHIP_DEVICE_CONFIG_DEVICE_HARDWARE_VERSION 1 -/** - * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING - * - * A string identifying the software version running on the device. - * CHIP service currently expects the software version to be in the format - * {MAJOR_VERSION}.0d{MINOR_VERSION} - */ -#ifndef CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING -#define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING "0.1ALPHA" -#endif - /** * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION * diff --git a/examples/thermostat/efr32/src/AppTask.cpp b/examples/thermostat/efr32/src/AppTask.cpp index 073a52ba392001..40418341d8b697 100644 --- a/examples/thermostat/efr32/src/AppTask.cpp +++ b/examples/thermostat/efr32/src/AppTask.cpp @@ -42,7 +42,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/thermostat/genio/src/AppTask.cpp b/examples/thermostat/genio/src/AppTask.cpp index bc948d6a947743..8630aad9fbf2ba 100644 --- a/examples/thermostat/genio/src/AppTask.cpp +++ b/examples/thermostat/genio/src/AppTask.cpp @@ -26,7 +26,6 @@ #include #include -#include #include #include #include diff --git a/examples/thermostat/telink/CMakeLists.txt b/examples/thermostat/telink/CMakeLists.txt index 78b4f7c7dcf883..6d00c892a2ed72 100755 --- a/examples/thermostat/telink/CMakeLists.txt +++ b/examples/thermostat/telink/CMakeLists.txt @@ -18,7 +18,6 @@ cmake_minimum_required(VERSION 3.13.1) set(BOARD tlsr9518adk80d) get_filename_component(CHIP_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/third_party/connectedhomeip REALPATH) -get_filename_component(NLIO_ROOT ${CHIP_ROOT}/third_party/nlio/repo/include REALPATH) get_filename_component(TELINK_COMMON ${CHIP_ROOT}/examples/platform/telink REALPATH) get_filename_component(GEN_DIR ${CHIP_ROOT}/zzz_generated/ REALPATH) @@ -39,7 +38,6 @@ target_include_directories(app PRIVATE include ${GEN_DIR}/app-common ${GEN_DIR}/thermostat - ${NLIO_ROOT} ${TELINK_COMMON}/util/include ${TELINK_COMMON}/app/include) diff --git a/examples/thermostat/telink/include/CHIPProjectConfig.h b/examples/thermostat/telink/include/CHIPProjectConfig.h index ade0219ab5da91..2fda70c57da9dc 100755 --- a/examples/thermostat/telink/include/CHIPProjectConfig.h +++ b/examples/thermostat/telink/include/CHIPProjectConfig.h @@ -31,13 +31,6 @@ #define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE 20202021 #define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR 0xF00 -/** - * CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE - * - * Enable support for Chip-over-BLE (CHIPoBLE). - */ -#define CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE 1 - /** * CHIP_SYSTEM_CONFIG_PACKETBUFFER_POOL_SIZE * diff --git a/examples/thermostat/telink/prj.conf b/examples/thermostat/telink/prj.conf index ad1e20d32e9b78..0c37f49ea8f8c6 100755 --- a/examples/thermostat/telink/prj.conf +++ b/examples/thermostat/telink/prj.conf @@ -30,7 +30,6 @@ CONFIG_OPENTHREAD_PANID=4660 CONFIG_OPENTHREAD_CHANNEL=15 CONFIG_OPENTHREAD_NETWORK_NAME="OpenThreadDemo" CONFIG_OPENTHREAD_XPANID="11:11:11:11:22:22:22:22" -CONFIG_NET_CONFIG_IEEE802154_DEV_NAME="IEEE802154_b91" # Disable Matter OTA DFU CONFIG_CHIP_OTA_REQUESTOR=n @@ -55,4 +54,5 @@ CONFIG_CHIP_LIB_SHELL=n # Disable factory data support. CONFIG_CHIP_FACTORY_DATA=n -CONFIG_CHIP_FACTORY_DATA_BUILD=n \ No newline at end of file +CONFIG_CHIP_FACTORY_DATA_BUILD=n +CONFIG_CHIP_FACTORY_DATA_MERGE_WITH_FIRMWARE=n \ No newline at end of file diff --git a/examples/thermostat/telink/src/AppTask.cpp b/examples/thermostat/telink/src/AppTask.cpp index 40d78abb7ed402..df25ef8cfb4c19 100644 --- a/examples/thermostat/telink/src/AppTask.cpp +++ b/examples/thermostat/telink/src/AppTask.cpp @@ -28,7 +28,6 @@ #include #include #include -#include #include #include #include diff --git a/examples/thermostat/thermostat-common/thermostat.matter b/examples/thermostat/thermostat-common/thermostat.matter index 15933ed93c52d3..af30ee4f8ded66 100644 --- a/examples/thermostat/thermostat-common/thermostat.matter +++ b/examples/thermostat/thermostat-common/thermostat.matter @@ -1447,7 +1447,7 @@ server cluster ThermostatUserInterfaceConfiguration = 516 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Identify { @@ -1727,7 +1727,7 @@ endpoint 0 { } } endpoint 1 { - device type thermostat = 769; + device type thermostat = 769, version 1; binding cluster Identify; server cluster Identify { diff --git a/examples/thermostat/thermostat-common/thermostat.zap b/examples/thermostat/thermostat-common/thermostat.zap index 36f576ddfe0d50..f7e23ce844fd4e 100644 --- a/examples/thermostat/thermostat-common/thermostat.zap +++ b/examples/thermostat/thermostat-common/thermostat.zap @@ -1,5 +1,5 @@ { - "featureLevel": 85, + "featureLevel": 87, "creator": "zap", "keyValuePairs": [ { @@ -16,6 +16,12 @@ } ], "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.json", @@ -23,12 +29,6 @@ "category": "matter", "version": 1, "description": "Matter SDK ZCL data" - }, - { - "pathRelativity": "relativeToZap", - "path": "../../../src/app/zap-templates/app-templates.json", - "type": "gen-templates-json", - "version": "chip-v1" } ], "endpointTypes": [ @@ -7014,7 +7014,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "client", "enabled": 0, "commands": [ @@ -7066,7 +7066,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "server", "enabled": 0, "commands": [ @@ -8335,7 +8335,7 @@ "code": 15, "mfgCode": null, "side": "server", - "type": "bitmap8", + "type": "LevelControlOptions", "included": 1, "storageOption": "RAM", "singleton": 0, @@ -14132,7 +14132,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "client", "enabled": 0, "commands": [ @@ -14176,7 +14176,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "server", "enabled": 0, "commands": [ diff --git a/examples/tv-app/android/include/cluster-init.cpp b/examples/tv-app/android/include/cluster-init.cpp index 3c83bef42afd9c..45bc21a45f4ee8 100644 --- a/examples/tv-app/android/include/cluster-init.cpp +++ b/examples/tv-app/android/include/cluster-init.cpp @@ -22,7 +22,6 @@ #include "target-navigator/TargetNavigatorManager.h" #include -#include #include #include #include diff --git a/examples/tv-app/android/include/content-launcher/AppContentLauncherManager.cpp b/examples/tv-app/android/include/content-launcher/AppContentLauncherManager.cpp index d52b014b82e303..ac7bd3fb8285a2 100644 --- a/examples/tv-app/android/include/content-launcher/AppContentLauncherManager.cpp +++ b/examples/tv-app/android/include/content-launcher/AppContentLauncherManager.cpp @@ -85,25 +85,27 @@ CHIP_ERROR AppContentLauncherManager::HandleGetAcceptHeaderList(AttributeValueEn ChipLogProgress(Zcl, "AppContentLauncherManager::HandleGetAcceptHeaderList"); chip::app::ConcreteReadAttributePath aPath(mEndpointId, chip::app::Clusters::ContentLauncher::Id, chip::app::Clusters::ContentLauncher::Attributes::AcceptHeader::Id); - const char * resStr = mAttributeDelegate->Read(aPath); - ChipLogProgress(Zcl, "AppContentLauncherManager::HandleGetSupportedStreamingProtocols response %s", resStr); + std::string resStr = mAttributeDelegate->Read(aPath); + ChipLogProgress(Zcl, "AppContentLauncherManager::HandleGetAcceptHeaderList response %s", resStr.c_str()); - if (resStr != nullptr && *resStr != 0) + if (resStr.length() != 0) { Json::Reader reader; Json::Value value; if (reader.parse(resStr, value)) { std::string attrId = to_string(chip::app::Clusters::ContentLauncher::Attributes::AcceptHeader::Id); - ChipLogProgress( - Zcl, "AppContentLauncherManager::HandleGetSupportedStreamingProtocols response parsing done. reading attr %s", - attrId.c_str()); + ChipLogProgress(Zcl, "AppContentLauncherManager::HandleGetAcceptHeaderList response parsing done. reading attr %s", + attrId.c_str()); if (value[attrId].isArray()) { mAcceptHeaderList.clear(); for (Json::Value & entry : value[attrId]) { - mAcceptHeaderList.push_back(entry.asString()); + if (entry.isString()) + { + mAcceptHeaderList.push_back(entry.asString()); + } } } } @@ -124,10 +126,10 @@ uint32_t AppContentLauncherManager::HandleGetSupportedStreamingProtocols() ChipLogProgress(Zcl, "AppContentLauncherManager::HandleGetSupportedStreamingProtocols"); chip::app::ConcreteReadAttributePath aPath(mEndpointId, chip::app::Clusters::ContentLauncher::Id, chip::app::Clusters::ContentLauncher::Attributes::SupportedStreamingProtocols::Id); - const char * resStr = mAttributeDelegate->Read(aPath); - ChipLogProgress(Zcl, "AppContentLauncherManager::HandleGetSupportedStreamingProtocols response %s", resStr); + std::string resStr = mAttributeDelegate->Read(aPath); + ChipLogProgress(Zcl, "AppContentLauncherManager::HandleGetSupportedStreamingProtocols response %s", resStr.c_str()); - if (resStr == nullptr || *resStr == 0) + if (resStr.length() == 0) { return mSupportedStreamingProtocols; } @@ -141,7 +143,7 @@ uint32_t AppContentLauncherManager::HandleGetSupportedStreamingProtocols() std::string attrId = to_string(chip::app::Clusters::ContentLauncher::Attributes::SupportedStreamingProtocols::Id); ChipLogProgress(Zcl, "AppContentLauncherManager::HandleGetSupportedStreamingProtocols response parsing done. reading attr %s", attrId.c_str()); - if (!value[attrId].empty()) + if (!value[attrId].empty() && value[attrId].isInt()) { uint32_t supportedStreamingProtocols = static_cast(value[attrId].asInt()); mSupportedStreamingProtocols = supportedStreamingProtocols; diff --git a/examples/tv-app/android/include/media-playback/AppMediaPlaybackManager.cpp b/examples/tv-app/android/include/media-playback/AppMediaPlaybackManager.cpp index aae9ea1d8f609d..ba92b95e0ede64 100644 --- a/examples/tv-app/android/include/media-playback/AppMediaPlaybackManager.cpp +++ b/examples/tv-app/android/include/media-playback/AppMediaPlaybackManager.cpp @@ -130,11 +130,11 @@ uint64_t AppMediaPlaybackManager::HandleMediaRequestGetAttribute(chip::Attribute { ChipLogProgress(Zcl, "Received AppMediaPlaybackManager::HandleMediaRequestGetAttribute:%d", attributeId); chip::app::ConcreteReadAttributePath aPath(mEndpointId, chip::app::Clusters::MediaPlayback::Id, attributeId); - const char * resStr = mAttributeDelegate->Read(aPath); - ChipLogProgress(Zcl, "AppMediaPlaybackManager::HandleMediaRequestGetAttribute response %s", resStr); + std::string resStr = mAttributeDelegate->Read(aPath); + ChipLogProgress(Zcl, "AppMediaPlaybackManager::HandleMediaRequestGetAttribute response %s", resStr.c_str()); uint64_t ret = std::numeric_limits::max(); - if (resStr != nullptr && *resStr != 0) + if (resStr.length() != 0) { Json::Reader reader; Json::Value value; @@ -143,7 +143,7 @@ uint64_t AppMediaPlaybackManager::HandleMediaRequestGetAttribute(chip::Attribute std::string attrId = to_string(attributeId); ChipLogProgress(Zcl, "AppMediaPlaybackManager::HandleMediaRequestGetAttribute response parsing done. reading attr %s", attrId.c_str()); - if (!value[attrId].empty()) + if (!value[attrId].empty() && value[attrId].isUInt()) { ret = static_cast(value[attrId].asUInt()); return ret; @@ -177,9 +177,10 @@ CHIP_ERROR AppMediaPlaybackManager::HandleGetSampledPosition(AttributeValueEncod ChipLogProgress(Zcl, "AppMediaPlaybackManager::HandleGetSampledPosition"); chip::app::ConcreteReadAttributePath aPath(mEndpointId, chip::app::Clusters::MediaPlayback::Id, chip::app::Clusters::MediaPlayback::Attributes::SampledPosition::Id); - const char * resStr = mAttributeDelegate->Read(aPath); + std::string resStr = mAttributeDelegate->Read(aPath); + ChipLogProgress(Zcl, "AppMediaPlaybackManager::HandleGetSampledPosition response %s", resStr.c_str()); - if (resStr != nullptr && *resStr != 0) + if (resStr.length() != 0) { Json::Reader reader; Json::Value value; @@ -188,13 +189,14 @@ CHIP_ERROR AppMediaPlaybackManager::HandleGetSampledPosition(AttributeValueEncod std::string attrId = to_string(chip::app::Clusters::MediaPlayback::Attributes::SampledPosition::Id); ChipLogProgress(Zcl, "AppContentLauncherManager::HandleGetSampledPosition response parsing done. reading attr %s", attrId.c_str()); - if (!value[attrId].empty()) + if (!value[attrId].empty() && value[attrId].isObject()) { std::string updatedAt = to_string( static_cast(chip::app::Clusters::MediaPlayback::Structs::PlaybackPosition::Fields::kUpdatedAt)); std::string position = to_string( static_cast(chip::app::Clusters::MediaPlayback::Structs::PlaybackPosition::Fields::kPosition)); - if (!value[attrId][updatedAt].empty() && !value[attrId][position].empty()) + if (!value[attrId][updatedAt].empty() && !value[attrId][position].empty() && value[attrId][updatedAt].isUInt() && + value[attrId][position].isUInt()) { // valid response response.updatedAt = value[attrId][updatedAt].asUInt(); diff --git a/examples/tv-app/android/include/target-navigator/TargetNavigatorManager.cpp b/examples/tv-app/android/include/target-navigator/TargetNavigatorManager.cpp index 5bb39495b0a703..ca07c349ff432c 100644 --- a/examples/tv-app/android/include/target-navigator/TargetNavigatorManager.cpp +++ b/examples/tv-app/android/include/target-navigator/TargetNavigatorManager.cpp @@ -39,10 +39,10 @@ CHIP_ERROR TargetNavigatorManager::HandleGetTargetList(AttributeValueEncoder & a { chip::app::ConcreteReadAttributePath aPath(mEndpointId, chip::app::Clusters::TargetNavigator::Id, chip::app::Clusters::TargetNavigator::Attributes::TargetList::Id); - const char * resStr = mAttributeDelegate->Read(aPath); - ChipLogProgress(Zcl, "TargetNavigatorManager::HandleNavigateTarget response %s", resStr); + std::string resStr = mAttributeDelegate->Read(aPath); + ChipLogProgress(Zcl, "TargetNavigatorManager::HandleNavigateTarget response %s", resStr.c_str()); - if (resStr != nullptr && *resStr != 0) + if (resStr.length() != 0) { Json::Reader reader; Json::Value value; @@ -104,10 +104,10 @@ uint8_t TargetNavigatorManager::HandleGetCurrentTarget() { chip::app::ConcreteReadAttributePath aPath(mEndpointId, chip::app::Clusters::TargetNavigator::Id, chip::app::Clusters::TargetNavigator::Attributes::TargetList::Id); - const char * resStr = mAttributeDelegate->Read(aPath); - ChipLogProgress(Zcl, "TargetNavigatorManager::HandleGetCurrentTarget response %s", resStr); + std::string resStr = mAttributeDelegate->Read(aPath); + ChipLogProgress(Zcl, "TargetNavigatorManager::HandleGetCurrentTarget response %s", resStr.c_str()); - if (resStr != nullptr && *resStr != 0) + if (resStr.length() != 0) { Json::Reader reader; Json::Value value; diff --git a/examples/tv-app/android/java/AppImpl.cpp b/examples/tv-app/android/java/AppImpl.cpp index d03ebc2c908e52..90fc6b5d50d991 100644 --- a/examples/tv-app/android/java/AppImpl.cpp +++ b/examples/tv-app/android/java/AppImpl.cpp @@ -24,7 +24,6 @@ #include "ContentAppAttributeDelegate.h" #include "ContentAppCommandDelegate.h" #include -#include #include #include #include @@ -227,21 +226,21 @@ constexpr CommandId channelOutgoingCommands[] = { }; // Declare Cluster List for Content App endpoint DECLARE_DYNAMIC_CLUSTER_LIST_BEGIN(contentAppClusters) -DECLARE_DYNAMIC_CLUSTER(ZCL_DESCRIPTOR_CLUSTER_ID, descriptorAttrs, nullptr, nullptr), - DECLARE_DYNAMIC_CLUSTER(ZCL_APPLICATION_BASIC_CLUSTER_ID, applicationBasicAttrs, nullptr, nullptr), - DECLARE_DYNAMIC_CLUSTER(ZCL_KEYPAD_INPUT_CLUSTER_ID, keypadInputAttrs, keypadInputIncomingCommands, +DECLARE_DYNAMIC_CLUSTER(app::Clusters::Descriptor::Id, descriptorAttrs, nullptr, nullptr), + DECLARE_DYNAMIC_CLUSTER(app::Clusters::ApplicationBasic::Id, applicationBasicAttrs, nullptr, nullptr), + DECLARE_DYNAMIC_CLUSTER(app::Clusters::KeypadInput::Id, keypadInputAttrs, keypadInputIncomingCommands, keypadInputOutgoingCommands), - DECLARE_DYNAMIC_CLUSTER(ZCL_APPLICATION_LAUNCHER_CLUSTER_ID, applicationLauncherAttrs, applicationLauncherIncomingCommands, + DECLARE_DYNAMIC_CLUSTER(app::Clusters::ApplicationLauncher::Id, applicationLauncherAttrs, applicationLauncherIncomingCommands, applicationLauncherOutgoingCommands), - DECLARE_DYNAMIC_CLUSTER(ZCL_ACCOUNT_LOGIN_CLUSTER_ID, accountLoginAttrs, accountLoginIncomingCommands, + DECLARE_DYNAMIC_CLUSTER(app::Clusters::AccountLogin::Id, accountLoginAttrs, accountLoginIncomingCommands, accountLoginOutgoingCommands), - DECLARE_DYNAMIC_CLUSTER(ZCL_CONTENT_LAUNCHER_CLUSTER_ID, contentLauncherAttrs, contentLauncherIncomingCommands, + DECLARE_DYNAMIC_CLUSTER(app::Clusters::ContentLauncher::Id, contentLauncherAttrs, contentLauncherIncomingCommands, contentLauncherOutgoingCommands), - DECLARE_DYNAMIC_CLUSTER(ZCL_MEDIA_PLAYBACK_CLUSTER_ID, mediaPlaybackAttrs, mediaPlaybackIncomingCommands, + DECLARE_DYNAMIC_CLUSTER(app::Clusters::MediaPlayback::Id, mediaPlaybackAttrs, mediaPlaybackIncomingCommands, mediaPlaybackOutgoingCommands), - DECLARE_DYNAMIC_CLUSTER(ZCL_TARGET_NAVIGATOR_CLUSTER_ID, targetNavigatorAttrs, targetNavigatorIncomingCommands, + DECLARE_DYNAMIC_CLUSTER(app::Clusters::TargetNavigator::Id, targetNavigatorAttrs, targetNavigatorIncomingCommands, targetNavigatorOutgoingCommands), - DECLARE_DYNAMIC_CLUSTER(ZCL_CHANNEL_CLUSTER_ID, channelAttrs, channelIncomingCommands, channelOutgoingCommands), + DECLARE_DYNAMIC_CLUSTER(app::Clusters::Channel::Id, channelAttrs, channelIncomingCommands, channelOutgoingCommands), DECLARE_DYNAMIC_CLUSTER_LIST_END; // Declare Content App endpoint diff --git a/examples/tv-app/android/java/ContentAppAttributeDelegate.cpp b/examples/tv-app/android/java/ContentAppAttributeDelegate.cpp index 7fcf0b313a62a5..b05f20ae2a768e 100644 --- a/examples/tv-app/android/java/ContentAppAttributeDelegate.cpp +++ b/examples/tv-app/android/java/ContentAppAttributeDelegate.cpp @@ -34,14 +34,15 @@ namespace AppPlatform { using LaunchResponseType = chip::app::Clusters::ContentLauncher::Commands::LaunchResponse::Type; -const char * ContentAppAttributeDelegate::Read(const chip::app::ConcreteReadAttributePath & aPath) +std::string ContentAppAttributeDelegate::Read(const chip::app::ConcreteReadAttributePath & aPath) { if (aPath.mEndpointId < FIXED_ENDPOINT_COUNT) { + // returning blank string causes the caller to default to output required by the tests return ""; } - JNIEnv * env = JniReferences::GetInstance().GetEnvForCurrentThread(); + JNIEnv * env = JniReferences::GetInstance().GetEnvForCurrentThread(); ChipLogProgress(Zcl, "ContentAppAttributeDelegate::Read being called for endpoint %d cluster %d attribute %d", aPath.mEndpointId, aPath.mClusterId, aPath.mAttributeId); @@ -53,11 +54,15 @@ const char * ContentAppAttributeDelegate::Read(const chip::app::ConcreteReadAttr ChipLogError(Zcl, "Java exception in ContentAppAttributeDelegate::Read"); env->ExceptionDescribe(); env->ExceptionClear(); + // returning blank string causes the caller to default to output required by the tests return ""; } const char * respStr = env->GetStringUTFChars(resp, 0); + std::string retStr(respStr); + env->ReleaseStringUTFChars(resp, respStr); + env->DeleteLocalRef(resp); ChipLogProgress(Zcl, "ContentAppAttributeDelegate::Read got response %s", respStr); - return respStr; + return retStr; } } // namespace AppPlatform diff --git a/examples/tv-app/android/java/ContentAppAttributeDelegate.h b/examples/tv-app/android/java/ContentAppAttributeDelegate.h index b12312068fd132..4ec02712201d7b 100644 --- a/examples/tv-app/android/java/ContentAppAttributeDelegate.h +++ b/examples/tv-app/android/java/ContentAppAttributeDelegate.h @@ -51,7 +51,7 @@ class ContentAppAttributeDelegate env->DeleteGlobalRef(mContentAppEndpointManager); } - const char * Read(const chip::app::ConcreteReadAttributePath & aPath); + std::string Read(const chip::app::ConcreteReadAttributePath & aPath); private: void InitializeJNIObjects(jobject manager) diff --git a/examples/tv-app/android/java/ContentAppCommandDelegate.cpp b/examples/tv-app/android/java/ContentAppCommandDelegate.cpp index 0b406ab4237794..585c97baaea3c9 100644 --- a/examples/tv-app/android/java/ContentAppCommandDelegate.cpp +++ b/examples/tv-app/android/java/ContentAppCommandDelegate.cpp @@ -60,12 +60,12 @@ void ContentAppCommandDelegate::InvokeCommand(CommandHandlerInterface::HandlerCo return; } - JNIEnv * env = JniReferences::GetInstance().GetEnvForCurrentThread(); - Json::Value value = json["value"]; - UtfString jsonString(env, JsonToString(value).c_str()); + JNIEnv * env = JniReferences::GetInstance().GetEnvForCurrentThread(); + Json::Value value = json["value"]; + std::string payload = JsonToString(value); + UtfString jsonString(env, payload.c_str()); - ChipLogProgress(Zcl, "ContentAppCommandDelegate::InvokeCommand send command being called with payload %s", - JsonToString(json).c_str()); + ChipLogProgress(Zcl, "ContentAppCommandDelegate::InvokeCommand send command being called with payload %s", payload.c_str()); jstring resp = (jstring) env->CallObjectMethod( mContentAppEndpointManager, mSendCommandMethod, static_cast(handlerContext.mRequestPath.mEndpointId), @@ -82,6 +82,8 @@ void ContentAppCommandDelegate::InvokeCommand(CommandHandlerInterface::HandlerCo const char * respStr = env->GetStringUTFChars(resp, 0); ChipLogProgress(Zcl, "ContentAppCommandDelegate::InvokeCommand got response %s", respStr); FormatResponseData(handlerContext, respStr); + env->ReleaseStringUTFChars(resp, respStr); + env->DeleteLocalRef(resp); } else { diff --git a/examples/tv-app/android/java/DeviceCallbacks.cpp b/examples/tv-app/android/java/DeviceCallbacks.cpp index 07673ffae1acfa..cf61e191385317 100644 --- a/examples/tv-app/android/java/DeviceCallbacks.cpp +++ b/examples/tv-app/android/java/DeviceCallbacks.cpp @@ -25,7 +25,6 @@ #include "DeviceCallbacks.h" #include -#include #include #include #include diff --git a/examples/tv-app/linux/AppImpl.cpp b/examples/tv-app/linux/AppImpl.cpp index 544dbb8509e8f6..d6496acdb1ad9e 100644 --- a/examples/tv-app/linux/AppImpl.cpp +++ b/examples/tv-app/linux/AppImpl.cpp @@ -23,7 +23,6 @@ #include #include -#include #include #include #include @@ -386,21 +385,21 @@ constexpr CommandId channelOutgoingCommands[] = { }; // Declare Cluster List for Content App endpoint DECLARE_DYNAMIC_CLUSTER_LIST_BEGIN(contentAppClusters) -DECLARE_DYNAMIC_CLUSTER(ZCL_DESCRIPTOR_CLUSTER_ID, descriptorAttrs, nullptr, nullptr), - DECLARE_DYNAMIC_CLUSTER(ZCL_APPLICATION_BASIC_CLUSTER_ID, applicationBasicAttrs, nullptr, nullptr), - DECLARE_DYNAMIC_CLUSTER(ZCL_KEYPAD_INPUT_CLUSTER_ID, keypadInputAttrs, keypadInputIncomingCommands, +DECLARE_DYNAMIC_CLUSTER(app::Clusters::Descriptor::Id, descriptorAttrs, nullptr, nullptr), + DECLARE_DYNAMIC_CLUSTER(app::Clusters::ApplicationBasic::Id, applicationBasicAttrs, nullptr, nullptr), + DECLARE_DYNAMIC_CLUSTER(app::Clusters::KeypadInput::Id, keypadInputAttrs, keypadInputIncomingCommands, keypadInputOutgoingCommands), - DECLARE_DYNAMIC_CLUSTER(ZCL_APPLICATION_LAUNCHER_CLUSTER_ID, applicationLauncherAttrs, applicationLauncherIncomingCommands, + DECLARE_DYNAMIC_CLUSTER(app::Clusters::ApplicationLauncher::Id, applicationLauncherAttrs, applicationLauncherIncomingCommands, applicationLauncherOutgoingCommands), - DECLARE_DYNAMIC_CLUSTER(ZCL_ACCOUNT_LOGIN_CLUSTER_ID, accountLoginAttrs, accountLoginIncomingCommands, + DECLARE_DYNAMIC_CLUSTER(app::Clusters::AccountLogin::Id, accountLoginAttrs, accountLoginIncomingCommands, accountLoginOutgoingCommands), - DECLARE_DYNAMIC_CLUSTER(ZCL_CONTENT_LAUNCHER_CLUSTER_ID, contentLauncherAttrs, contentLauncherIncomingCommands, + DECLARE_DYNAMIC_CLUSTER(app::Clusters::ContentLauncher::Id, contentLauncherAttrs, contentLauncherIncomingCommands, contentLauncherOutgoingCommands), - DECLARE_DYNAMIC_CLUSTER(ZCL_MEDIA_PLAYBACK_CLUSTER_ID, mediaPlaybackAttrs, mediaPlaybackIncomingCommands, + DECLARE_DYNAMIC_CLUSTER(app::Clusters::MediaPlayback::Id, mediaPlaybackAttrs, mediaPlaybackIncomingCommands, mediaPlaybackOutgoingCommands), - DECLARE_DYNAMIC_CLUSTER(ZCL_TARGET_NAVIGATOR_CLUSTER_ID, targetNavigatorAttrs, targetNavigatorIncomingCommands, + DECLARE_DYNAMIC_CLUSTER(app::Clusters::TargetNavigator::Id, targetNavigatorAttrs, targetNavigatorIncomingCommands, targetNavigatorOutgoingCommands), - DECLARE_DYNAMIC_CLUSTER(ZCL_CHANNEL_CLUSTER_ID, channelAttrs, channelIncomingCommands, channelOutgoingCommands), + DECLARE_DYNAMIC_CLUSTER(app::Clusters::Channel::Id, channelAttrs, channelIncomingCommands, channelOutgoingCommands), DECLARE_DYNAMIC_CLUSTER_LIST_END; // Declare Content App endpoint diff --git a/examples/tv-app/linux/include/cluster-init.cpp b/examples/tv-app/linux/include/cluster-init.cpp index bbb889d264404d..ea56403a7df4c6 100644 --- a/examples/tv-app/linux/include/cluster-init.cpp +++ b/examples/tv-app/linux/include/cluster-init.cpp @@ -26,7 +26,6 @@ #include "wake-on-lan/WakeOnLanManager.h" #include -#include #include #include #include diff --git a/examples/tv-app/linux/include/level-control/LevelControl.cpp b/examples/tv-app/linux/include/level-control/LevelControl.cpp index 278c42f8737ed1..3147396e008b53 100644 --- a/examples/tv-app/linux/include/level-control/LevelControl.cpp +++ b/examples/tv-app/linux/include/level-control/LevelControl.cpp @@ -21,8 +21,8 @@ #include #include #include -#include #include +#include using namespace chip; using namespace chip::app::Clusters; @@ -40,7 +40,7 @@ static EmberAfLevelControlState stateTable[EMBER_AF_LEVEL_CONTROL_CLUSTER_SERVER static EmberAfLevelControlState * getState(EndpointId endpoint) { - uint8_t ep = emberAfFindClusterServerEndpointIndex(endpoint, ZCL_LEVEL_CONTROL_CLUSTER_ID); + uint8_t ep = emberAfFindClusterServerEndpointIndex(endpoint, LevelControl::Id); return (ep == 0xFF ? NULL : &stateTable[ep]); } @@ -89,7 +89,7 @@ static void stepHandler(CommandId commandId, uint8_t stepMode, uint8_t stepSize, } break; default: - status = EMBER_ZCL_STATUS_INVALID_FIELD; + status = EMBER_ZCL_STATUS_INVALID_COMMAND; goto send_default_response; } @@ -118,7 +118,7 @@ static void stepHandler(CommandId commandId, uint8_t stepMode, uint8_t stepSize, } send_default_response: - if (emberAfCurrentCommand()->apsFrame->clusterId == ZCL_LEVEL_CONTROL_CLUSTER_ID) + if (emberAfCurrentCommand()->apsFrame->clusterId == LevelControl::Id) { emberAfSendImmediateDefaultResponse(status); } diff --git a/examples/tv-app/tv-common/tv-app.matter b/examples/tv-app/tv-common/tv-app.matter index 0a8fa960cd62d3..afec0ee0c4a6b8 100644 --- a/examples/tv-app/tv-common/tv-app.matter +++ b/examples/tv-app/tv-common/tv-app.matter @@ -2131,7 +2131,7 @@ server cluster AccountLogin = 1294 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster Binding; binding cluster GeneralCommissioning; binding cluster NetworkCommissioning; @@ -2414,7 +2414,7 @@ endpoint 0 { } } endpoint 1 { - device type videoplayer = 35; + device type videoplayer = 35, version 1; server cluster OnOff { ram attribute onOff; @@ -2509,7 +2509,7 @@ endpoint 1 { } } endpoint 2 { - device type speaker = 34; + device type speaker = 34, version 1; server cluster OnOff { ram attribute onOff; @@ -2546,7 +2546,7 @@ endpoint 2 { } } endpoint 3 { - device type contentapplication = 36; + device type contentapplication = 36, version 1; server cluster Descriptor { callback attribute deviceTypeList; diff --git a/examples/tv-app/tv-common/tv-app.zap b/examples/tv-app/tv-common/tv-app.zap index cd1dd1a4086bc0..72f8bfe4df751b 100644 --- a/examples/tv-app/tv-common/tv-app.zap +++ b/examples/tv-app/tv-common/tv-app.zap @@ -1,5 +1,5 @@ { - "featureLevel": 81, + "featureLevel": 87, "creator": "zap", "keyValuePairs": [ { @@ -16,6 +16,12 @@ } ], "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.json", @@ -23,12 +29,6 @@ "category": "matter", "version": 1, "description": "Matter SDK ZCL data" - }, - { - "pathRelativity": "relativeToZap", - "path": "../../../src/app/zap-templates/app-templates.json", - "type": "gen-templates-json", - "version": "chip-v1" } ], "endpointTypes": [ @@ -6924,7 +6924,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "client", "enabled": 0, "commands": [ @@ -6976,7 +6976,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "server", "enabled": 0, "commands": [ @@ -9222,7 +9222,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "client", "enabled": 0, "commands": [ @@ -9274,7 +9274,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "server", "enabled": 0, "commands": [ @@ -9977,7 +9977,7 @@ "code": 15, "mfgCode": null, "side": "server", - "type": "bitmap8", + "type": "LevelControlOptions", "included": 1, "storageOption": "RAM", "singleton": 0, @@ -12364,5 +12364,6 @@ "endpointVersion": 1, "deviceIdentifier": 36 } - ] + ], + "log": [] } \ No newline at end of file diff --git a/examples/tv-casting-app/android/App/app/src/main/jni/com/chip/casting/NsdDiscoveryListener.java b/examples/tv-casting-app/android/App/app/src/main/jni/com/chip/casting/NsdDiscoveryListener.java index b0644c456cabe9..5fda64cbbba8ef 100644 --- a/examples/tv-casting-app/android/App/app/src/main/jni/com/chip/casting/NsdDiscoveryListener.java +++ b/examples/tv-casting-app/android/App/app/src/main/jni/com/chip/casting/NsdDiscoveryListener.java @@ -22,6 +22,8 @@ import android.util.Log; import chip.platform.NsdManagerServiceResolver; import java.util.List; +import java.util.concurrent.ExecutorService; +import java.util.concurrent.Executors; public class NsdDiscoveryListener implements NsdManager.DiscoveryListener { private static final String TAG = NsdDiscoveryListener.class.getSimpleName(); @@ -33,6 +35,7 @@ public class NsdDiscoveryListener implements NsdManager.DiscoveryListener { private final SuccessCallback successCallback; private final FailureCallback failureCallback; private final NsdManagerServiceResolver.NsdManagerResolverAvailState nsdManagerResolverAvailState; + private final ExecutorService resolutionExecutor; public NsdDiscoveryListener( NsdManager nsdManager, @@ -49,6 +52,7 @@ public NsdDiscoveryListener( this.successCallback = successCallback; this.failureCallback = failureCallback; this.nsdManagerResolverAvailState = nsdManagerResolverAvailState; + this.resolutionExecutor = Executors.newSingleThreadExecutor(); } @Override @@ -58,24 +62,32 @@ public void onDiscoveryStarted(String regType) { @Override public void onServiceFound(NsdServiceInfo service) { - Log.d(TAG, "Service discovery success. " + service); - if (service.getServiceType().equals(targetServiceType)) { - if (nsdManagerResolverAvailState != null) { - nsdManagerResolverAvailState.acquireResolver(); - } - nsdManager.resolveService( - service, - new NsdResolveListener( - nsdManager, - deviceTypeFilter, - preCommissionedVideoPlayers, - successCallback, - failureCallback, - nsdManagerResolverAvailState, - 1)); - } else { - Log.d(TAG, "Ignoring discovered service: " + service.toString()); - } + this.resolutionExecutor.execute( + new Runnable() { + @Override + public void run() { + Log.d(TAG, "Service discovery success. " + service); + if (service.getServiceType().equals(targetServiceType)) { + if (nsdManagerResolverAvailState != null) { + nsdManagerResolverAvailState.acquireResolver(); + } + + Log.d(TAG, "Calling NsdManager.resolveService for " + service); + nsdManager.resolveService( + service, + new NsdResolveListener( + nsdManager, + deviceTypeFilter, + preCommissionedVideoPlayers, + successCallback, + failureCallback, + nsdManagerResolverAvailState, + 1)); + } else { + Log.d(TAG, "Ignoring discovered service: " + service.toString()); + } + } + }); } @Override diff --git a/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/CommissionableDataProviderImpl.hpp b/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/CommissionableDataProviderImpl.hpp index 872feb587837d3..b05ce4aa89a4ef 100644 --- a/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/CommissionableDataProviderImpl.hpp +++ b/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/CommissionableDataProviderImpl.hpp @@ -74,7 +74,7 @@ class CommissionableDataProviderImpl : public CommissionableDataProvider CHIP_ERROR GetSpake2pIterationCount(uint32_t & iterationCount) override { - if (mSetupDiscriminator > 0) + if (mSpake2pIterationCount > 0) { iterationCount = mSpake2pIterationCount; } diff --git a/examples/tv-casting-app/darwin/TvCasting/TvCasting.xcodeproj/project.pbxproj b/examples/tv-casting-app/darwin/TvCasting/TvCasting.xcodeproj/project.pbxproj index dfaf0a6813066d..6252d2cb145612 100644 --- a/examples/tv-casting-app/darwin/TvCasting/TvCasting.xcodeproj/project.pbxproj +++ b/examples/tv-casting-app/darwin/TvCasting/TvCasting.xcodeproj/project.pbxproj @@ -420,7 +420,7 @@ CoreData, "-Wl,-unexported_symbol,\"__Z*\"", ); - PRODUCT_BUNDLE_IDENTIFIER = "com.matter.TvCasting-sharadb"; + PRODUCT_BUNDLE_IDENTIFIER = com.matter.TvCasting; PRODUCT_NAME = "$(TARGET_NAME)"; SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; SWIFT_EMIT_LOC_STRINGS = YES; @@ -467,7 +467,7 @@ "-Wformat-nonliteral", "-Wformat-security", ); - PRODUCT_BUNDLE_IDENTIFIER = "com.matter.TvCasting-sharadb"; + PRODUCT_BUNDLE_IDENTIFIER = com.matter.TvCasting; PRODUCT_NAME = "$(TARGET_NAME)"; SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; SWIFT_EMIT_LOC_STRINGS = YES; diff --git a/examples/tv-casting-app/darwin/TvCasting/TvCasting/TvCastingApp.swift b/examples/tv-casting-app/darwin/TvCasting/TvCasting/TvCastingApp.swift index 26e4768485d13e..daef2e730d5e3a 100644 --- a/examples/tv-casting-app/darwin/TvCasting/TvCasting/TvCastingApp.swift +++ b/examples/tv-casting-app/darwin/TvCasting/TvCasting/TvCastingApp.swift @@ -38,6 +38,12 @@ struct TvCastingApp: App { } appParameters.rotatingDeviceIdUniqueId = Data(rotatingDeviceIdUniqueId) + let onboardingParameters: OnboardingPayload = OnboardingPayload() + onboardingParameters.setupPasscode = 20202021 + onboardingParameters.setupDiscriminator = 3840 + + appParameters.onboardingPayload = onboardingParameters + castingServerBridge.initApp(appParameters, clientQueue: DispatchQueue.main, initAppStatusHandler: { (result: Bool) -> () in self.Log.info("initApp result \(result)") }) diff --git a/examples/tv-casting-app/tv-casting-common/tv-casting-app.matter b/examples/tv-casting-app/tv-casting-common/tv-casting-app.matter index 0c992d36f94001..b94bac44d601a1 100644 --- a/examples/tv-casting-app/tv-casting-common/tv-casting-app.matter +++ b/examples/tv-casting-app/tv-casting-common/tv-casting-app.matter @@ -1420,7 +1420,7 @@ server cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -2149,7 +2149,7 @@ client cluster AccountLogin = 1294 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; server cluster Descriptor { callback attribute deviceTypeList; @@ -2420,7 +2420,7 @@ endpoint 0 { } } endpoint 1 { - device type videoplayer = 35; + device type videoplayer = 35, version 1; binding cluster OnOff; binding cluster LevelControl; binding cluster Descriptor; @@ -2539,7 +2539,7 @@ endpoint 1 { } } endpoint 2 { - device type occupancysensor = 263; + device type occupancysensor = 263, version 1; server cluster OnOff { ram attribute onOff; diff --git a/examples/window-app/common/window-app.matter b/examples/window-app/common/window-app.matter index 59ec84ee40d482..29031ccc8ec6e0 100644 --- a/examples/window-app/common/window-app.matter +++ b/examples/window-app/common/window-app.matter @@ -1580,7 +1580,7 @@ server cluster WindowCovering = 258 { } endpoint 0 { - device type windowcovering = 22; + device type windowcovering = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Descriptor { @@ -1893,7 +1893,7 @@ endpoint 0 { } } endpoint 1 { - device type windowcovering = 514; + device type windowcovering = 514, version 2; server cluster Identify { ram attribute identifyTime; @@ -1970,7 +1970,7 @@ endpoint 1 { } } endpoint 2 { - device type windowcovering = 514; + device type windowcovering = 514, version 2; server cluster Identify { ram attribute identifyTime; diff --git a/examples/window-app/efr32/BUILD.gn b/examples/window-app/efr32/BUILD.gn index 142a4dc84146ab..93119f1b263aae 100644 --- a/examples/window-app/efr32/BUILD.gn +++ b/examples/window-app/efr32/BUILD.gn @@ -173,6 +173,7 @@ efr32_sdk("sdk") { efr32_executable("window_app") { output_name = "chip-efr32-window-example.out" + public_configs = [ "${efr32_sdk_build_root}:silabs_config" ] output_dir = root_out_dir include_dirs = [ "include", diff --git a/examples/window-app/efr32/include/CHIPProjectConfig.h b/examples/window-app/efr32/include/CHIPProjectConfig.h index 23c653c12b396e..6a12dbc3794c8f 100644 --- a/examples/window-app/efr32/include/CHIPProjectConfig.h +++ b/examples/window-app/efr32/include/CHIPProjectConfig.h @@ -68,17 +68,6 @@ */ #define CHIP_DEVICE_CONFIG_DEVICE_HARDWARE_VERSION 1 -/** - * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING - * - * A string identifying the software version running on the device. - * CHIP service currently expects the software version to be in the format - * {MAJOR_VERSION}.0d{MINOR_VERSION} - */ -#ifndef CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING -#define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING "0.1ALPHA" -#endif - /** * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION * diff --git a/examples/window-app/nrfconnect/main/AppTask.cpp b/examples/window-app/nrfconnect/main/AppTask.cpp index 311640093e35c0..212a3c8ce3e302 100644 --- a/examples/window-app/nrfconnect/main/AppTask.cpp +++ b/examples/window-app/nrfconnect/main/AppTask.cpp @@ -25,7 +25,6 @@ #include #include -#include #include #include #include diff --git a/integrations/cloudbuild/build-all.yaml b/integrations/cloudbuild/build-all.yaml index e0dbcfaa61467c..5a80129f54496b 100644 --- a/integrations/cloudbuild/build-all.yaml +++ b/integrations/cloudbuild/build-all.yaml @@ -6,7 +6,7 @@ steps: - "--init" - "--recursive" id: Submodules - - name: "connectedhomeip/chip-build-vscode:0.6.06" + - name: "connectedhomeip/chip-build-vscode:0.6.18" env: - PW_ENVIRONMENT_ROOT=/pwenv args: @@ -21,7 +21,7 @@ steps: path: /pwenv timeout: 900s - - name: "connectedhomeip/chip-build-vscode:0.6.06" + - name: "connectedhomeip/chip-build-vscode:0.6.18" env: - PW_ENVIRONMENT_ROOT=/pwenv args: @@ -76,7 +76,7 @@ steps: --target k32w-shell build --create-archives /workspace/artifacts/ - - name: "connectedhomeip/chip-build-vscode:0.6.03" + - name: "connectedhomeip/chip-build-vscode:0.6.18" env: - PW_ENVIRONMENT_ROOT=/pwenv args: diff --git a/integrations/cloudbuild/build-coverage.yaml b/integrations/cloudbuild/build-coverage.yaml index cc85632b50e7e5..3973c85147a623 100644 --- a/integrations/cloudbuild/build-coverage.yaml +++ b/integrations/cloudbuild/build-coverage.yaml @@ -7,7 +7,7 @@ steps: - "--recursive" id: Submodules - - name: "connectedhomeip/chip-build-vscode:0.6.06" + - name: "connectedhomeip/chip-build:0.6.18" env: - PW_ENVIRONMENT_ROOT=/pwenv args: @@ -22,7 +22,7 @@ steps: path: /pwenv timeout: 900s - - name: "connectedhomeip/chip-build-vscode:0.6.06" + - name: "connectedhomeip/chip-build:0.6.17" env: - PW_ENVIRONMENT_ROOT=/pwenv args: diff --git a/integrations/cloudbuild/chef.yaml b/integrations/cloudbuild/chef.yaml index dcab96539dc693..0cfebde9cf97ea 100644 --- a/integrations/cloudbuild/chef.yaml +++ b/integrations/cloudbuild/chef.yaml @@ -1,5 +1,5 @@ steps: - - name: "connectedhomeip/chip-build-vscode:0.6.06" + - name: "connectedhomeip/chip-build-vscode:0.6.18" env: - PW_ENVIRONMENT_ROOT=/pwenv args: @@ -12,7 +12,7 @@ steps: path: /pwenv timeout: 2700s - - name: "connectedhomeip/chip-build-vscode:0.6.06" + - name: "connectedhomeip/chip-build-vscode:0.6.18" env: - PW_ENVIRONMENT_ROOT=/pwenv args: @@ -26,7 +26,7 @@ steps: - name: pwenv path: /pwenv - - name: "connectedhomeip/chip-build-vscode:0.6.06" + - name: "connectedhomeip/chip-build-vscode:0.6.18" env: - PW_ENVIRONMENT_ROOT=/pwenv args: @@ -53,7 +53,7 @@ steps: logsBucket: matter-build-automation-build-logs # Global timeout for all steps -timeout: 14400s +timeout: 18000s queueTtl: 21600s artifacts: diff --git a/integrations/cloudbuild/smoke-test.yaml b/integrations/cloudbuild/smoke-test.yaml index a5d491519965b2..47145edfc2aabc 100644 --- a/integrations/cloudbuild/smoke-test.yaml +++ b/integrations/cloudbuild/smoke-test.yaml @@ -1,5 +1,5 @@ steps: - - name: "connectedhomeip/chip-build-vscode:0.6.06" + - name: "connectedhomeip/chip-build-vscode:0.6.18" entrypoint: "bash" args: - "-c" @@ -7,7 +7,7 @@ steps: git config --global --add safe.directory "*" git submodule update --init --recursive id: Submodules - - name: "connectedhomeip/chip-build-vscode:0.6.06" + - name: "connectedhomeip/chip-build-vscode:0.6.18" env: - PW_ENVIRONMENT_ROOT=/pwenv args: @@ -22,7 +22,7 @@ steps: path: /pwenv timeout: 900s - - name: "connectedhomeip/chip-build-vscode:0.6.06" + - name: "connectedhomeip/chip-build-vscode:0.6.18" id: ESP32 env: - PW_ENVIRONMENT_ROOT=/pwenv @@ -41,7 +41,7 @@ steps: - name: pwenv path: /pwenv - - name: "connectedhomeip/chip-build-vscode:0.6.06" + - name: "connectedhomeip/chip-build-vscode:0.6.18" id: NRFConnect env: - PW_ENVIRONMENT_ROOT=/pwenv @@ -62,7 +62,7 @@ steps: - name: pwenv path: /pwenv - - name: "connectedhomeip/chip-build-vscode:0.6.06" + - name: "connectedhomeip/chip-build-vscode:0.6.18" id: EFR32 env: - PW_ENVIRONMENT_ROOT=/pwenv @@ -84,7 +84,7 @@ steps: - name: pwenv path: /pwenv - - name: "connectedhomeip/chip-build-vscode:0.6.06" + - name: "connectedhomeip/chip-build-vscode:0.6.18" id: Linux env: - PW_ENVIRONMENT_ROOT=/pwenv @@ -142,7 +142,7 @@ steps: - name: pwenv path: /pwenv - - name: "connectedhomeip/chip-build-vscode:0.6.06" + - name: "connectedhomeip/chip-build-vscode:0.6.18" id: Android env: - PW_ENVIRONMENT_ROOT=/pwenv diff --git a/integrations/docker/build.sh b/integrations/docker/build.sh index cb52fe60746e89..8336b2689caf95 100755 --- a/integrations/docker/build.sh +++ b/integrations/docker/build.sh @@ -46,11 +46,12 @@ fi Build and (optionally tag as latest, push) a docker image from Dockerfile in CWD Options: - --no-cache passed as a docker build argument - --latest update latest to the current built version (\"$VERSION\") - --push push image(s) to docker.io (requires docker login for \"$ORG\") - --help get this message - --squash squash docker layers before push them to docker.io (requires docker-squash python module) + --no-cache passed as a docker build argument + --latest update latest to the current built version (\"$VERSION\") + --push push image(s) to docker.io (requires docker login for \"$ORG\") + --skip-build skip the build/prune step + --help get this message + --squash squash docker layers before push them to docker.io (requires docker-squash python module) " exit 0 @@ -65,7 +66,9 @@ set -ex [[ -n $VERSION ]] || die "version cannot be empty" -mb_space_before=$(df -m "$DOCKER_VOLUME_PATH" | awk 'FNR==2{print $3}') +if [ -f "$DOCKER_VOLUME_PATH" ]; then + mb_space_before=$(df -m "$DOCKER_VOLUME_PATH" | awk 'FNR==2{print $3}') +fi # go find and build any CHIP images this image is "FROM" awk -F/ '/^FROM connectedhomeip/ {print $2}' Dockerfile | while read -r dep; do @@ -78,8 +81,10 @@ if [[ ${*/--no-cache//} != "${*}" ]]; then BUILD_ARGS+=(--no-cache) fi -docker build "${BUILD_ARGS[@]}" --build-arg VERSION="$VERSION" -t "$ORG/$IMAGE:$VERSION" . -docker image prune --force +[[ ${*/--skip-build//} != "${*}" ]] || { + docker build "${BUILD_ARGS[@]}" --build-arg VERSION="$VERSION" -t "$ORG/$IMAGE:$VERSION" . + docker image prune --force +} [[ ${*/--latest//} != "${*}" ]] && { docker tag "$ORG"/"$IMAGE":"$VERSION" "$ORG"/"$IMAGE":latest @@ -98,9 +103,10 @@ docker image prune --force } docker images --filter=reference="$ORG/*" -df -h "$DOCKER_VOLUME_PATH" -mb_space_after=$(df -m "$DOCKER_VOLUME_PATH" | awk 'FNR==2{print $3}') - -printf "%'.f MB total used\n" "$((mb_space_before - mb_space_after))" +if [ -f "$DOCKER_VOLUME_PATH" ]; then + df -h "$DOCKER_VOLUME_PATH" + mb_space_after=$(df -m "$DOCKER_VOLUME_PATH" | awk 'FNR==2{print $3}') + printf "%'.f MB total used\n" "$((mb_space_before - mb_space_after))" +fi exit 0 diff --git a/integrations/docker/images/chip-build-ameba/Dockerfile b/integrations/docker/images/chip-build-ameba/Dockerfile index 3d3b055e820887..2a7f2b4574b65f 100644 --- a/integrations/docker/images/chip-build-ameba/Dockerfile +++ b/integrations/docker/images/chip-build-ameba/Dockerfile @@ -3,7 +3,7 @@ FROM connectedhomeip/chip-build:${VERSION} # Setup Ameba ARG AMEBA_DIR=/opt/ameba -ARG TAG_NAME=ameba_update_2022_10_03 +ARG TAG_NAME=ameba_update_2022_11_25 RUN set -x \ && apt-get update \ && mkdir ${AMEBA_DIR} \ diff --git a/integrations/docker/images/chip-build-nrf-platform/Dockerfile b/integrations/docker/images/chip-build-nrf-platform/Dockerfile index 4e8d66447c3a98..f7b3ced12025ec 100644 --- a/integrations/docker/images/chip-build-nrf-platform/Dockerfile +++ b/integrations/docker/images/chip-build-nrf-platform/Dockerfile @@ -19,7 +19,7 @@ RUN set -x \ SHELL ["/bin/bash", "-o", "pipefail", "-c"] RUN set -x \ && mkdir -p /opt/NordicSemiconductor/nRF5_tools/ \ - && curl --location https://www.nordicsemi.com/-/media/Software-and-other-downloads/Desktop-software/nRF-command-line-tools/sw/Versions-10-x-x/10-12-1/nRFCommandLineTools10121Linuxamd64.tar.gz \ + && curl --location https://nsscprodmedia.blob.core.windows.net/prod/software-and-other-downloads/desktop-software/nrf-command-line-tools/sw/versions-10-x-x/10-12-1/nrfcommandlinetools10121linuxamd64.tar.gz \ | tar zxvf - \ && tar xvf JLink_Linux_V688a_x86_64.tgz -C /opt/NordicSemiconductor/nRF5_tools/ \ && tar xvf nRF-Command-Line-Tools_10_12_1.tar -C /opt/NordicSemiconductor/nRF5_tools/ \ diff --git a/integrations/docker/images/chip-build-telink/Dockerfile b/integrations/docker/images/chip-build-telink/Dockerfile index 5f6b08c5b04ad8..1161d628aeaab2 100644 --- a/integrations/docker/images/chip-build-telink/Dockerfile +++ b/integrations/docker/images/chip-build-telink/Dockerfile @@ -11,13 +11,19 @@ RUN set -x \ # Setup toolchain RUN set -x \ - && wget https://github.com/zephyrproject-rtos/sdk-ng/releases/download/v0.13.2/zephyr-toolchain-riscv64-0.13.2-linux-x86_64-setup.run -O /tmp/zephyr-toolchain-riscv64-setup.run \ - && chmod +x /tmp/zephyr-toolchain-riscv64-setup.run \ - && /tmp/zephyr-toolchain-riscv64-setup.run -- -d /opt/telink/zephyr-sdk-0.13.2 \ + && mkdir /opt/telink \ + && cd /opt/telink \ + && wget https://github.com/zephyrproject-rtos/sdk-ng/releases/download/v0.15.2/zephyr-sdk-0.15.2_linux-x86_64.tar.gz \ + && wget -O - https://github.com/zephyrproject-rtos/sdk-ng/releases/download/v0.15.2/sha256.sum | shasum --check --ignore-missing \ + && tar xvf zephyr-sdk-0.15.2_linux-x86_64.tar.gz \ + && rm -rf zephyr-sdk-0.15.2_linux-x86_64.tar.gz \ + && cd zephyr-sdk-0.15.2 \ + && ./setup.sh -t riscv64-zephyr-elf -h -c \ + && cd / \ && : # last line # Setup Zephyr -ARG ZEPHYR_REVISION=dac17979d626bb820268660b4272a56d04d8083b +ARG ZEPHYR_REVISION=7e93d9eeb7d2796d678a069558c251cf94dd0c2e WORKDIR /opt/telink/zephyrproject RUN set -x \ && python3 -m pip install -U --no-cache-dir \ @@ -29,16 +35,17 @@ RUN set -x \ && west init -l \ && cd .. \ && west update -o=--depth=1 -n -f smart \ + && west blobs fetch hal_telink \ && west zephyr-export \ && : # last line FROM connectedhomeip/chip-build:${VERSION} -COPY --from=build /opt/telink/zephyr-sdk-0.13.2/ /opt/telink/zephyr-sdk-0.13.2/ +COPY --from=build /opt/telink/zephyr-sdk-0.15.2/ /opt/telink/zephyr-sdk-0.15.2/ COPY --from=build /opt/telink/zephyrproject/ /opt/telink/zephyrproject/ ENV ZEPHYR_TOOLCHAIN_VARIANT=zephyr -ENV ZEPHYR_SDK_INSTALL_DIR=/opt/telink/zephyr-sdk-0.13.2 +ENV ZEPHYR_SDK_INSTALL_DIR=/opt/telink/zephyr-sdk-0.15.2 RUN set -x \ && apt-get update \ diff --git a/integrations/docker/images/chip-build-tizen/tizen-sdk-installer/install.sh b/integrations/docker/images/chip-build-tizen/tizen-sdk-installer/install.sh index f4c3222cd5a599..99fd9c3334d153 100755 --- a/integrations/docker/images/chip-build-tizen/tizen-sdk-installer/install.sh +++ b/integrations/docker/images/chip-build-tizen/tizen-sdk-installer/install.sh @@ -44,17 +44,17 @@ function show_help() { echo "Example: $SCRIPT_NAME --tizen-sdk-path ~/tizen-sdk --tizen-version 6.0 --install-dependencies" echo echo "Options:" - echo " --help Display this information" + echo " -h, --help Display this information" echo " --tizen-sdk-path Set directory where Tizen will be installed. Default is $TIZEN_SDK_ROOT" echo " --tizen-sdk-data-path Set directory where Tizen have data. Default is $TIZEN_SDK_DATA_PATH" echo " --install-dependencies This options install all dependencies." echo " --tizen-version Select Tizen version. Default is $TIZEN_VERSION" - echo " --override-secret-tool Without password manager circumvents the requirement of having functional D-Bus Secrets service" + echo " --override-secret-tool Circumvent the requirement of having functional D-Bus Secrets service." echo echo "Note:" echo "The script should run fully with ubuntu. For other distributions you may have to manually" echo "install all needed dependencies. Use the script specifying --tizen-sdk-path with or" - echo "without --tizen-version. The script will only install the tizen platform for Matter." + echo "without --tizen-version. The script will only install Tizen platform for Matter." } # ------------------------------------------------------------------------------ @@ -66,7 +66,7 @@ function error() { # ------------------------------------------------------------------------------ # Info print function function info() { - echo "$COLOR_GREEN$1$COLOR_NONE" + echo "$COLOR_GREEN[INFO]: $1$COLOR_NONE" } # ------------------------------------------------------------------------------ @@ -78,7 +78,7 @@ function warning() { # ------------------------------------------------------------------------------ # Show dependencies function show_dependencies() { - warning "Need dependencies for use this script installation SDK: cpio wget unzip unrpm" + warning "Need dependencies for use this script installation SDK: cpio unrpm unzip wget" warning "Need dependencies for Tizen SDK: JAVA JRE >=8.0" } @@ -135,10 +135,11 @@ function install_tizen_sdk() { TIZEN_SDK_SYSROOT="$TIZEN_SDK_ROOT/platforms/tizen-$TIZEN_VERSION/mobile/rootstraps/mobile-$TIZEN_VERSION-device.core" - # Get tizen studio CLI - info "Get tizen studio CLI [...]" cd "$TMP_DIR" || return + # Get Tizen Studio CLI + info "Downloading Tizen Studio CLI..." + # Download URL="http://download.tizen.org/sdk/tizenstudio/official/binary/" PKG_ARR=( @@ -150,7 +151,7 @@ function install_tizen_sdk() { download "$URL" "${PKG_ARR[@]}" # Get toolchain - info "Get toolchain" + info "Downloading Tizen toolchain..." # Download URL="http://download.tizen.org/sdk/tizenstudio/official/binary/" @@ -159,11 +160,11 @@ function install_tizen_sdk() { "sbi-toolchain-gcc-9.2.cpp.app_2.2.16_ubuntu-64.zip") download "$URL" "${PKG_ARR[@]}" - # Get tizen sysroot - info "Get tizen sysroot" + # Get Tizen sysroot + info "Downloading Tizen sysroot..." # Base sysroot - # Different versions of tizen have different rootstrap versions + # Different versions of Tizen have different rootstrap versions URL="http://download.tizen.org/sdk/tizenstudio/official/binary/" PKG_ARR=( "mobile-$TIZEN_VERSION-core-add-ons_*_ubuntu-64.zip" @@ -224,7 +225,7 @@ function install_tizen_sdk() { download "$URL" "${PKG_ARR[@]}" # Install all - info "Installation Tizen SDK [...]" + info "Installing Tizen SDK..." unzip -o '*.zip' cp -rf data/* "$TIZEN_SDK_ROOT" @@ -234,12 +235,12 @@ function install_tizen_sdk() { # Install secret tool or not if ("$SECRET_TOOL"); then - info "Override secret tool" + info "Overriding secret tool..." cp "$SCRIPT_DIR/secret-tool.py" "$TIZEN_SDK_ROOT/tools/certificate-encryptor/secret-tool" chmod 0755 "$TIZEN_SDK_ROOT/tools/certificate-encryptor/secret-tool" fi - # Configure tizen cli + # Configure Tizen CLI echo "TIZEN_SDK_INSTALLED_PATH=$TIZEN_SDK_ROOT" >"$TIZEN_SDK_ROOT/sdk.info" echo "TIZEN_SDK_DATA_PATH=$TIZEN_SDK_DATA_PATH" >>"$TIZEN_SDK_ROOT/sdk.info" ln -sf "$TIZEN_SDK_DATA_PATH/.tizen-cli-config" "$TIZEN_SDK_ROOT/tools/.tizen-cli-config" @@ -251,9 +252,12 @@ function install_tizen_sdk() { ln -sf ../../lib/libcap.so.2 "$TIZEN_SDK_SYSROOT/usr/lib/libcap.so" ln -sf openssl1.1.pc "$TIZEN_SDK_SYSROOT/usr/lib/pkgconfig/openssl.pc" + info "Done." + echo + # Information on necessary environment variables - warning "You must add the appropriate environment variables before proceeding with matter." - echo "$COLOR_YELLOW" + warning "Before proceeding with Matter export environment variables as follows:" + echo -n "$COLOR_YELLOW" echo "export TIZEN_VESRSION=\"$TIZEN_VERSION\"" echo "export TIZEN_SDK_ROOT=\"$(realpath "$TIZEN_SDK_ROOT")\"" echo "export TIZEN_SDK_TOOLCHAIN=\"\$TIZEN_SDK_ROOT/tools/arm-linux-gnueabi-gcc-9.2\"" @@ -264,7 +268,7 @@ function install_tizen_sdk() { while (($#)); do case $1 in - --help) + -h | --help) show_help exit 0 ;; @@ -308,20 +312,19 @@ if [ "$INSTALL_DEPENDENCIES" = true ]; then show_dependencies exit 1 fi -else - show_dependencies fi # ------------------------------------------------------------------------------ -# Checking dependencies needed to install the tizen platform -for PKG in 'cpio' 'unzip' 'wget' 'unrpm'; do +# Checking dependencies needed to install Tizen platform +info "Checking required tools: cpio, java, unrpm, unzip, wget" +for PKG in 'cpio' 'java' 'unrpm' 'unzip' 'wget'; do if ! command -v "$PKG" &>/dev/null; then - warning "Not found $PKG" + error "Required tool not found: $PKG" dep_lost=1 fi done if [[ $dep_lost ]]; then - error "You need install dependencies before [HINT]: On Ubuntu-like distro run: sudo apt install ${DEPENDENCIES[@]}" + echo "[HINT]: sudo apt-get install ${DEPENDENCIES[*]}" exit 1 fi diff --git a/integrations/docker/images/chip-build-vscode/Dockerfile b/integrations/docker/images/chip-build-vscode/Dockerfile index eb49bab5f87f7c..f1c7eda65965ed 100644 --- a/integrations/docker/images/chip-build-vscode/Dockerfile +++ b/integrations/docker/images/chip-build-vscode/Dockerfile @@ -34,7 +34,7 @@ COPY --from=mbedos /opt/openocd/ /opt/openocd/ COPY --from=p6 /opt/ModusToolbox /opt/ModusToolbox COPY --from=telink /opt/telink/zephyrproject /opt/telink/zephyrproject -COPY --from=telink /opt/telink/zephyr-sdk-0.13.2 /opt/telink/zephyr-sdk-0.13.2 +COPY --from=telink /opt/telink/zephyr-sdk-0.15.2 /opt/telink/zephyr-sdk-0.15.2 COPY --from=tizen /opt/tizen-sdk /opt/tizen-sdk @@ -102,13 +102,14 @@ ENV QEMU_ESP32=/opt/espressif/qemu/xtensa-softmmu/qemu-system-xtensa ENV QEMU_ESP32_DIR=/opt/espressif/qemu ENV SYSROOT_AARCH64=/opt/ubuntu-21.04-aarch64-sysroot ENV TELINK_ZEPHYR_BASE=/opt/telink/zephyrproject/zephyr -ENV TELINK_ZEPHYR_SDK_DIR=/opt/telink/zephyr-sdk-0.13.2 +ENV TELINK_ZEPHYR_SDK_DIR=/opt/telink/zephyr-sdk-0.15.2 ENV TI_SYSCONFIG_ROOT=/opt/ti/sysconfig_1.13.0 ENV ZEPHYR_BASE=/opt/NordicSemiconductor/nrfconnect/zephyr ENV ZEPHYR_TOOLCHAIN_VARIANT=gnuarmemb ENV TIZEN_VERSION 6.0 ENV TIZEN_SDK_ROOT /opt/tizen-sdk +ENV TIZEN_SDK_TOOLCHAIN $TIZEN_SDK_ROOT/tools/arm-linux-gnueabi-gcc-9.2 ENV TIZEN_SDK_SYSROOT $TIZEN_SDK_ROOT/platforms/tizen-$TIZEN_VERSION/mobile/rootstraps/mobile-$TIZEN_VERSION-device.core ENV FVP_CORSTONE_300_PATH=/opt/FVP_Corstone_SSE-300 diff --git a/integrations/docker/images/chip-build/Dockerfile b/integrations/docker/images/chip-build/Dockerfile index 41e3687bea317a..267ea5998403f3 100644 --- a/integrations/docker/images/chip-build/Dockerfile +++ b/integrations/docker/images/chip-build/Dockerfile @@ -57,6 +57,7 @@ RUN set -x \ ninja-build \ openjdk-8-jdk \ pkg-config \ + python-is-python3 \ python3.9 \ python3.9-dev \ python3.9-venv \ @@ -120,6 +121,30 @@ RUN set -x \ && rm -rf bloaty \ && : # last line +# Need newer version of include-what-you-use +RUN set -x \ + && apt-get update \ + # Install build and runtime requirements for IWYU + && DEBIAN_FRONTEND=noninteractive apt-get install -fy --fix-missing clang-12 libclang-12-dev \ + # Build and install IWYU + && git clone --depth=1 --branch=clang_12 https://github.com/include-what-you-use/include-what-you-use.git \ + && mkdir -p include-what-you-use/build \ + && cd include-what-you-use/build \ + && cmake -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_PREFIX_PATH=/usr/lib/llvm-12 -DIWYU_LINK_CLANG_DYLIB=OFF .. \ + && make -j8 \ + && make install \ + # Save clang-12 files, so we can restore them after build dependencies cleanup + && tar -cf clang-12-files.tar $(dpkg -L libclang-common-12-dev |grep /include) /usr/lib/llvm-12/lib/libLLVM-12.so.1 \ + # Cleanup build dependencies + && apt autoremove -fy clang-12 libclang-12-dev \ + && rm -rf /var/lib/apt/lists/ \ + # Restore clang-12 files + && tar -xf clang-12-files.tar -C / \ + # Cleanup + && cd ../.. \ + && rm -rf include-what-you-use \ + && : # last line + # Build glib-2.0 from source with enabled thread sanitizer. This is needed for # running CHIP tests with TSAN enabled. When running applications with TSAN # all shared libraries should be built with TSAN enabled, otherwise TSAN might @@ -138,7 +163,7 @@ RUN set -x \ # Install a known ZAP release # Only keep the cli version, since `zap` is 143MB and not usable (UI) -ENV ZAP_VERSION=v2022.11.23 +ENV ZAP_VERSION=v2022.11.29-nightly RUN set -x \ && mkdir -p /opt/zap-${ZAP_VERSION} \ && cd /opt/zap-${ZAP_VERSION} \ diff --git a/integrations/docker/images/chip-build/version b/integrations/docker/images/chip-build/version index c20ee11baccd68..271edd38959978 100644 --- a/integrations/docker/images/chip-build/version +++ b/integrations/docker/images/chip-build/version @@ -1 +1 @@ -0.6.13 Version bump reason: Update zap to latest release +0.6.19 Version bump reason: [Ameba] Support reading and decoding factory data from flash diff --git a/integrations/docker/images/chip-cert-bins/Dockerfile b/integrations/docker/images/chip-cert-bins/Dockerfile index 14fce86b771cd8..386775acf0a1b1 100644 --- a/integrations/docker/images/chip-cert-bins/Dockerfile +++ b/integrations/docker/images/chip-cert-bins/Dockerfile @@ -2,26 +2,26 @@ FROM ubuntu:22.04 as chip-build-cert ARG TARGETPLATFORM # COMMITHASH defines the target commit to build from. May be passed in using --build-arg. -ARG COMMITHASH=e556daac2e1ed3a141034a6dcc7e410e4cd1f8f6 +ARG COMMITHASH=1e06479f412b78eea0dfbeacf7cad51d005b649b # Ensure TARGETPLATFORM is set RUN case ${TARGETPLATFORM} in \ "linux/amd64") \ echo "Building for linux/amd64" \ - ;; \ + ;; \ "linux/arm64") \ echo "Building for linux/arm64" \ - ;; \ + ;; \ *) \ - if [ -z "$TARGETPLATFORM" ] ;\ - then \ - echo "TARGETPLATFORM not defined! Please run from buildkit (buildx)." \ - && return 1 ;\ - else \ - echo "Unsupported platform ${TARGETPLATFORM}." \ - && return 1 ;\ - fi \ - ;; \ + if [ -z "$TARGETPLATFORM" ] ;\ + then \ + echo "TARGETPLATFORM not defined! Please run from buildkit (buildx)." \ + && return 1 ;\ + else \ + echo "Unsupported platform ${TARGETPLATFORM}." \ + && return 1 ;\ + fi \ + ;; \ esac # Below should be the same as chip-build except arm64 logic for cmake and node. @@ -108,9 +108,9 @@ RUN case ${TARGETPLATFORM} in \ && exec bash \ ;; \ *) \ - test -n "$TARGETPLATFORM" \ - echo "Unsupported platform ${TARGETPLATFORM}" \ - ;; \ + test -n "$TARGETPLATFORM" \ + echo "Unsupported platform ${TARGETPLATFORM}" \ + ;; \ esac # Python 3 and PIP @@ -156,28 +156,28 @@ RUN set -x \ RUN case ${TARGETPLATFORM} in \ "linux/amd64") \ set -x \ - && mkdir node_js \ - && cd node_js \ - && wget https://nodejs.org/dist/v12.19.0/node-v12.19.0-linux-x64.tar.xz \ - && tar xfvJ node-v12.19.0-linux-x64.tar.xz \ - && mv node-v12.19.0-linux-x64 /opt/ \ - && ln -s /opt/node-v12.19.0-linux-x64 /opt/node \ - && ln -s /opt/node/bin/* /usr/bin \ - && cd .. \ - && rm -rf node_js \ - ;; \ + && mkdir node_js \ + && cd node_js \ + && wget https://nodejs.org/dist/v12.19.0/node-v12.19.0-linux-x64.tar.xz \ + && tar xfvJ node-v12.19.0-linux-x64.tar.xz \ + && mv node-v12.19.0-linux-x64 /opt/ \ + && ln -s /opt/node-v12.19.0-linux-x64 /opt/node \ + && ln -s /opt/node/bin/* /usr/bin \ + && cd .. \ + && rm -rf node_js \ + ;; \ "linux/arm64")\ set -x \ - && mkdir node_js \ - && cd node_js \ - && wget https://nodejs.org/dist/v12.19.0/node-v12.19.0-linux-arm64.tar.xz \ - && tar xfvJ node-v12.19.0-linux-arm64.tar.xz \ - && mv node-v12.19.0-linux-arm64 /opt/ \ - && ln -s /opt/node-v12.19.0-linux-arm64 /opt/node \ - && ln -s /opt/node/bin/* /usr/bin \ - && cd .. \ - && rm -rf node_js \ - ;; \ + && mkdir node_js \ + && cd node_js \ + && wget https://nodejs.org/dist/v12.19.0/node-v12.19.0-linux-arm64.tar.xz \ + && tar xfvJ node-v12.19.0-linux-arm64.tar.xz \ + && mv node-v12.19.0-linux-arm64 /opt/ \ + && ln -s /opt/node-v12.19.0-linux-arm64 /opt/node \ + && ln -s /opt/node/bin/* /usr/bin \ + && cd .. \ + && rm -rf node_js \ + ;; \ *) ;; \ esac @@ -186,71 +186,86 @@ RUN mkdir /root/connectedhomeip RUN git clone https://github.com/project-chip/connectedhomeip.git /root/connectedhomeip WORKDIR /root/connectedhomeip/ RUN git checkout ${COMMITHASH} +RUN ./scripts/checkout_submodules.py --shallow --platform linux RUN scripts/build/gn_bootstrap.sh -RUN gn gen out/debug --args='chip_mdns="platform" chip_inet_config_enable_ipv4=false' -RUN ninja -C out/debug +SHELL ["/bin/bash", "-c"] +RUN set -x && \ + source scripts/activate.sh \ + && gn gen out/debug --args='chip_mdns="platform" chip_inet_config_enable_ipv4=false' \ + && ninja -C out/debug # Stage 2: Build. from chip-build-cert as chip-build-cert-bins SHELL ["/bin/bash", "-c"] # Records Matter SDK commit hash to include in the image. RUN git rev-parse HEAD > /root/.sdk-sha-version + RUN case ${TARGETPLATFORM} in \ "linux/amd64") \ set -x \ - && source scripts/activate.sh \ - && scripts/build/build_examples.py \ - --target linux-x64-all-clusters-ipv6only \ - --target linux-x64-all-clusters-minimal-ipv6only \ - --target linux-x64-bridge-ipv6only \ - --target linux-x64-tv-app-ipv6only \ - --target linux-x64-tv-casting-app-ipv6only \ - --target linux-x64-light-ipv6only \ - --target linux-x64-thermostat-ipv6only \ - --target linux-x64-ota-provider-ipv6only \ - --target linux-x64-ota-requestor-ipv6only \ - --target linux-x64-lock-ipv6only \ - build \ - && mv out/linux-x64-all-clusters-ipv6only/chip-all-clusters-app out/chip-all-clusters-app \ - && mv out/linux-x64-all-clusters-minimal-ipv6only/chip-all-clusters-minimal-app out/chip-all-clusters-minimal-app \ - && mv out/linux-x64-bridge-ipv6only/chip-bridge-app out/chip-bridge-app \ - && mv out/linux-x64-tv-app-ipv6only/chip-tv-app out/chip-tv-app \ - && mv out/linux-x64-tv-casting-app-ipv6only/chip-tv-casting-app out/chip-tv-casting-app \ - && mv out/linux-x64-light-ipv6only/chip-lighting-app out/chip-lighting-app \ - && mv out/linux-x64-thermostat-ipv6only/thermostat-app out/thermostat-app \ - && mv out/linux-x64-ota-provider-ipv6only/chip-ota-provider-app out/chip-ota-provider-app \ - && mv out/linux-x64-ota-requestor-ipv6only/chip-ota-requestor-app out/chip-ota-requestor-app \ - && mv out/linux-x64-lock-ipv6only/chip-lock-app out/chip-lock-app \ - ;; \ + && source scripts/activate.sh \ + && scripts/build/build_examples.py \ + --target linux-x64-all-clusters-ipv6only \ + --target linux-x64-all-clusters-minimal-ipv6only \ + --target linux-x64-bridge-ipv6only \ + --target linux-x64-tv-app-ipv6only \ + --target linux-x64-tv-casting-app-ipv6only \ + --target linux-x64-light-ipv6only \ + --target linux-x64-thermostat-ipv6only \ + --target linux-x64-ota-provider-ipv6only \ + --target linux-x64-ota-requestor-ipv6only \ + --target linux-x64-lock-ipv6only \ + build \ + && mv out/linux-x64-all-clusters-ipv6only/chip-all-clusters-app out/chip-all-clusters-app \ + && mv out/linux-x64-all-clusters-minimal-ipv6only/chip-all-clusters-minimal-app out/chip-all-clusters-minimal-app \ + && mv out/linux-x64-bridge-ipv6only/chip-bridge-app out/chip-bridge-app \ + && mv out/linux-x64-tv-app-ipv6only/chip-tv-app out/chip-tv-app \ + && mv out/linux-x64-tv-casting-app-ipv6only/chip-tv-casting-app out/chip-tv-casting-app \ + && mv out/linux-x64-light-ipv6only/chip-lighting-app out/chip-lighting-app \ + && mv out/linux-x64-thermostat-ipv6only/thermostat-app out/thermostat-app \ + && mv out/linux-x64-ota-provider-ipv6only/chip-ota-provider-app out/chip-ota-provider-app \ + && mv out/linux-x64-ota-requestor-ipv6only/chip-ota-requestor-app out/chip-ota-requestor-app \ + && mv out/linux-x64-lock-ipv6only/chip-lock-app out/chip-lock-app \ + ;; \ "linux/arm64")\ set -x \ - && source scripts/activate.sh \ - && scripts/build/build_examples.py \ - --target linux-arm64-all-clusters-ipv6only \ - --target linux-arm64-all-clusters-minimal-ipv6only \ - --target linux-arm64-bridge-ipv6only \ - --target linux-arm64-tv-app-ipv6only \ - --target linux-arm64-tv-casting-app-ipv6only \ - --target linux-arm64-light-ipv6only \ - --target linux-arm64-thermostat-ipv6only \ - --target linux-arm64-ota-provider-ipv6only \ - --target linux-arm64-ota-requestor-ipv6only \ - --target linux-arm64-lock-ipv6only \ - build \ - && mv out/linux-arm64-all-clusters-ipv6only/chip-all-clusters-app out/chip-all-clusters-app \ - && mv out/linux-arm64-all-clusters-minimal-ipv6only/chip-all-clusters-minimal-app out/chip-all-clusters-minimal-app \ - && mv out/linux-arm64-bridge-ipv6only/chip-bridge-app out/chip-bridge-app \ - && mv out/linux-arm64-tv-app-ipv6only/chip-tv-app out/chip-tv-app \ - && mv out/linux-arm64-tv-casting-app-ipv6only/chip-tv-casting-app out/chip-tv-casting-app \ - && mv out/linux-arm64-light-ipv6only/chip-lighting-app out/chip-lighting-app \ - && mv out/linux-arm64-thermostat-ipv6only/thermostat-app out/thermostat-app \ - && mv out/linux-arm64-ota-provider-ipv6only/chip-ota-provider-app out/chip-ota-provider-app \ - && mv out/linux-arm64-ota-requestor-ipv6only/chip-ota-requestor-app out/chip-ota-requestor-app \ - && mv out/linux-arm64-lock-ipv6only/chip-lock-app out/chip-lock-app \ - ;; \ + && source scripts/activate.sh \ + && scripts/build/build_examples.py \ + --target linux-arm64-all-clusters-ipv6only \ + --target linux-arm64-all-clusters-minimal-ipv6only \ + --target linux-arm64-bridge-ipv6only \ + --target linux-arm64-tv-app-ipv6only \ + --target linux-arm64-tv-casting-app-ipv6only \ + --target linux-arm64-light-ipv6only \ + --target linux-arm64-thermostat-ipv6only \ + --target linux-arm64-ota-provider-ipv6only \ + --target linux-arm64-ota-requestor-ipv6only \ + --target linux-arm64-lock-ipv6only \ + build \ + && mv out/linux-arm64-all-clusters-ipv6only/chip-all-clusters-app out/chip-all-clusters-app \ + && mv out/linux-arm64-all-clusters-minimal-ipv6only/chip-all-clusters-minimal-app out/chip-all-clusters-minimal-app \ + && mv out/linux-arm64-bridge-ipv6only/chip-bridge-app out/chip-bridge-app \ + && mv out/linux-arm64-tv-app-ipv6only/chip-tv-app out/chip-tv-app \ + && mv out/linux-arm64-tv-casting-app-ipv6only/chip-tv-casting-app out/chip-tv-casting-app \ + && mv out/linux-arm64-light-ipv6only/chip-lighting-app out/chip-lighting-app \ + && mv out/linux-arm64-thermostat-ipv6only/thermostat-app out/thermostat-app \ + && mv out/linux-arm64-ota-provider-ipv6only/chip-ota-provider-app out/chip-ota-provider-app \ + && mv out/linux-arm64-ota-requestor-ipv6only/chip-ota-requestor-app out/chip-ota-requestor-app \ + && mv out/linux-arm64-lock-ipv6only/chip-lock-app out/chip-lock-app \ + ;; \ *) ;; \ esac +# ZAP Development install, so that it runs on both x64 and arm64 +ENV ZAP_VERSION=v2022.11.29-nightly +RUN set -x \ + && mkdir -p /opt/zap-${ZAP_VERSION} \ + && git clone https://github.com/project-chip/zap.git /opt/zap-${ZAP_VERSION} \ + && cd /opt/zap-${ZAP_VERSION} \ + && git checkout ${ZAP_VERSION} \ + && npm config set user 0 \ + && npm ci +ENV ZAP_DEVELOPMENT_PATH=/opt/zap-${ZAP_VERSION} RUN scripts/examples/gn_build_test_example.sh app1 RUN source scripts/activate.sh && scripts/build_python.sh -m platform -d true -i no diff --git a/scripts/build/BUILD.gn b/scripts/build/BUILD.gn index 60356666c0f6ae..b19ffcd8d78a7f 100644 --- a/scripts/build/BUILD.gn +++ b/scripts/build/BUILD.gn @@ -24,13 +24,15 @@ pw_python_package("build_examples") { # Dependency for the unit test "testdata/all_targets_linux_x64.txt", "testdata/dry_run_android-arm64-chip-tool.txt", - "testdata/dry_run_efr32-brd4161a-light-rpc.txt", + "testdata/dry_run_efr32-brd4161a-light-rpc-no-version.txt", "testdata/dry_run_esp32-devkitc-light-rpc.txt", "testdata/dry_run_esp32-m5stack-all-clusters-minimal-rpc-ipv6only.txt", "testdata/dry_run_linux-arm64-chip-tool-ipv6only-clang.txt", "testdata/dry_run_linux-arm64-ota-requestor-nodeps-ipv6only.txt", "testdata/dry_run_linux-x64-all-clusters-coverage.txt", "testdata/dry_run_nrf-nrf52840dk-pump.txt", + "testdata/dry_run_openiotsdk-lock.txt", + "testdata/dry_run_openiotsdk-shell.txt", ] sources = [ @@ -54,6 +56,7 @@ pw_python_package("build_examples") { "builders/mbed.py", "builders/mw320.py", "builders/nrf.py", + "builders/openiotsdk.py", "builders/qpg.py", "builders/telink.py", "builders/tizen.py", diff --git a/scripts/build/build/targets.py b/scripts/build/build/targets.py index 3c424d3f175f18..bb0a41cd08636c 100755 --- a/scripts/build/build/targets.py +++ b/scripts/build/build/targets.py @@ -37,6 +37,7 @@ from builders.bouffalolab import BouffalolabApp, BouffalolabBoard, BouffalolabBuilder from builders.imx import IMXApp, IMXBuilder from builders.genio import GenioApp, GenioBuilder +from builders.openiotsdk import OpenIotSdkApp, OpenIotSdkBuilder def BuildHostTestRunnerTarget(): @@ -70,6 +71,7 @@ def BuildHostFakeTarget(): target.AppendModifier("boringssl", crypto_library=HostCryptoLibrary.BORINGSSL).ExceptIfRe('-boringssl') target.AppendModifier("asan", use_asan=True).ExceptIfRe("-tsan") target.AppendModifier("tsan", use_tsan=True).ExceptIfRe("-asan") + target.AppendModifier("ubsan", use_ubsan=True) target.AppendModifier("libfuzzer", use_tsan=True).OnlyIfRe("-clang") target.AppendModifier('coverage', use_coverage=True).OnlyIfRe('-(chip-tool|all-clusters)') target.AppendModifier('dmalloc', use_dmalloc=True) @@ -97,7 +99,7 @@ def BuildHostTarget(): app_parts = [ TargetPart('rpc-console', app=HostApp.RPC_CONSOLE).OnlyIfRe(f'{native_board_name}-'), TargetPart('all-clusters', app=HostApp.ALL_CLUSTERS), - TargetPart('all-clusters-minimal', app=HostApp.ALL_CLUSTERS), + TargetPart('all-clusters-minimal', app=HostApp.ALL_CLUSTERS_MINIMAL), TargetPart('chip-tool', app=HostApp.CHIP_TOOL), TargetPart('thermostat', app=HostApp.THERMOSTAT), TargetPart('java-matter-controller', app=HostApp.JAVA_MATTER_CONTROLLER), @@ -125,6 +127,7 @@ def BuildHostTarget(): target.AppendModifier('nodeps', enable_ble=False, enable_wifi=False, enable_thread=False, crypto_library=HostCryptoLibrary.MBEDTLS, use_clang=True).ExceptIfRe('-(clang|noble|boringssl|mbedtls)') + target.AppendModifier('platform-mdns', use_platform_mdns=True) target.AppendModifier('minmdns-verbose', minmdns_high_verbosity=True) target.AppendModifier('libnl', minmdns_address_policy="libnl") target.AppendModifier('same-event-loop', separate_event_loop=False).OnlyIfRe('-(chip-tool|darwin-framework-tool)') @@ -137,6 +140,7 @@ def BuildHostTarget(): target.AppendModifier("boringssl", crypto_library=HostCryptoLibrary.BORINGSSL).ExceptIfRe('-boringssl') target.AppendModifier("asan", use_asan=True).ExceptIfRe("-tsan") target.AppendModifier("tsan", use_tsan=True).ExceptIfRe("-asan") + target.AppendModifier("ubsan", use_ubsan=True) target.AppendModifier("libfuzzer", use_tsan=True).OnlyIfRe("-clang") target.AppendModifier('coverage', use_coverage=True).OnlyIfRe('-(chip-tool|all-clusters)') target.AppendModifier('dmalloc', use_dmalloc=True) @@ -162,7 +166,7 @@ def BuildEsp32Target(): target.AppendFixedTargets([ TargetPart('all-clusters', app=Esp32App.ALL_CLUSTERS), TargetPart('all-clusters-minimal', app=Esp32App.ALL_CLUSTERS_MINIMAL), - TargetPart('ota-requestor', app=Esp32App.OTA_REQUESTOR), + TargetPart('ota-provider', app=Esp32App.OTA_PROVIDER), TargetPart('ota-requestor', app=Esp32App.OTA_REQUESTOR), TargetPart('shell', app=Esp32App.SHELL), TargetPart('light', app=Esp32App.LIGHT), @@ -207,7 +211,21 @@ def BuildEfr32Target(): target.AppendModifier('rpc', enable_rpcs=True) target.AppendModifier('with-ota-requestor', enable_ota_requestor=True) target.AppendModifier('sed', enable_sed=True) - target.AppendModifier('low-power', enable_low_power=True) + target.AppendModifier('low-power', enable_low_power=True).OnlyIfRe('-sed') + target.AppendModifier('shell', chip_build_libshell=True) + target.AppendModifier('no_logging', chip_logging=False) + target.AppendModifier('openthread_mtd', chip_openthread_ftd=False) + target.AppendModifier('enable_heap_monitoring', enable_heap_monitoring=True) + target.AppendModifier('no_openthread_cli', enable_openthread_cli=False) + target.AppendModifier('show_qr_code', show_qr_code=True).ExceptIfRe('-low-power') + target.AppendModifier('wifi', enable_wifi=True) + target.AppendModifier('rs911x', enable_rs911x=True).OnlyIfRe('-wifi') + target.AppendModifier('wf200', enable_wf200=True).OnlyIfRe('-wifi') + target.AppendModifier('wifi_ipv4', enable_wifi_ipv4=True).OnlyIfRe('-wifi') + target.AppendModifier('additional_data_advertising', enable_additional_data_advertising=True) + target.AppendModifier('use_ot_lib', enable_ot_lib=True).ExceptIfRe('-(wifi|use_ot_coap_lib)') + target.AppendModifier('use_ot_coap_lib', enable_ot_coap_lib=True).ExceptIfRe('-(wifi|use_ot_lib)') + target.AppendModifier('no-version', no_version=True) return target @@ -238,9 +256,11 @@ def BuildNrfTarget(): TargetPart('all-clusters-minimal', app=NrfApp.ALL_CLUSTERS_MINIMAL), TargetPart('lock', app=NrfApp.LOCK), TargetPart('light', app=NrfApp.LIGHT), + TargetPart('light-switch', app=NrfApp.SWITCH), TargetPart('shell', app=NrfApp.SHELL), TargetPart('pump', app=NrfApp.PUMP), TargetPart('pump-controller', app=NrfApp.PUMP_CONTROLLER), + TargetPart('window-covering', app=NrfApp.WINDOW_COVERING), ]) target.AppendModifier('rpc', enable_rpcs=True) @@ -337,6 +357,7 @@ def BuildAmebaTarget(): TargetPart('all-clusters', app=AmebaApp.ALL_CLUSTERS), TargetPart('all-clusters-minimal', app=AmebaApp.ALL_CLUSTERS_MINIMAL), TargetPart('light', app=AmebaApp.LIGHT), + TargetPart('light-switch', app=AmebaApp.LIGHT_SWITCH), TargetPart('pigweed', app=AmebaApp.PIGWEED), ]) @@ -440,6 +461,7 @@ def BuildTizenTarget(): target.AppendModifier(name="no-ble", enable_ble=False) target.AppendModifier(name="no-wifi", enable_wifi=False) target.AppendModifier(name="asan", use_asan=True) + target.AppendModifier(name="ubsan", use_ubsan=True) return target @@ -514,6 +536,17 @@ def BuildTelinkTarget(): return target +def BuildOpenIotSdkTargets(): + target = BuildTarget('openiotsdk', OpenIotSdkBuilder) + + target.AppendFixedTargets([ + TargetPart('shell', app=OpenIotSdkApp.SHELL), + TargetPart('lock', app=OpenIotSdkApp.LOCK), + ]) + + return target + + BUILD_TARGETS = [ BuildAmebaTarget(), BuildAndroidTarget(), @@ -536,4 +569,5 @@ def BuildTelinkTarget(): BuildQorvoTarget(), BuildTizenTarget(), BuildTelinkTarget(), + BuildOpenIotSdkTargets(), ] diff --git a/scripts/build/build_darwin_framework.py b/scripts/build/build_darwin_framework.py index d84ea53cf20837..7d638bdd2c708e 100644 --- a/scripts/build/build_darwin_framework.py +++ b/scripts/build/build_darwin_framework.py @@ -65,6 +65,15 @@ def build_darwin_framework(args): # Build Matter.framework as a static library "SUPPORTS_TEXT_BASED_API=NO", "MACH_O_TYPE=staticlib", + # Change visibility flags such that both darwin-framework-tool and Matter.framework + # are built with the same flags. + "GCC_INLINES_ARE_PRIVATE_EXTERN=NO", + "GCC_SYMBOLS_PRIVATE_EXTERN=NO", + ] + + if not args.ipv4: + command += [ + "CHIP_INET_CONFIG_ENABLE_IPV4=NO", ] command_result = run_command(command) @@ -104,6 +113,7 @@ def build_darwin_framework(args): parser.add_argument("--log_path", help="Output log file destination", required=True) + parser.add_argument('--ipv4', action=argparse.BooleanOptionalAction) args = parser.parse_args() build_darwin_framework(args) diff --git a/scripts/build/build_examples.py b/scripts/build/build_examples.py index 5792bfaec64274..14439f32289376 100755 --- a/scripts/build/build_examples.py +++ b/scripts/build/build_examples.py @@ -87,6 +87,11 @@ def ValidateRepoPath(context, parameter, value): default='./out', type=click.Path(file_okay=False, resolve_path=True), help='Prefix for the generated file output.') +@click.option( + '--pregen-dir', + default=None, + type=click.Path(file_okay=False, resolve_path=True), + help='Directory where generated files have been pre-generated.') @click.option( '--clean', default=False, @@ -114,7 +119,7 @@ def ValidateRepoPath(context, parameter, value): 'for using ccache when building examples.')) @click.pass_context def main(context, log_level, target, repo, - out_prefix, clean, dry_run, dry_run_output, enable_flashbundle, + out_prefix, pregen_dir, clean, dry_run, dry_run_output, enable_flashbundle, no_log_timestamps, pw_command_launcher): # Ensures somewhat pretty logging of what is going on log_fmt = '%(asctime)s %(levelname)-7s %(message)s' @@ -143,6 +148,7 @@ def main(context, log_level, target, repo, context.obj.SetupBuilders(targets=requested_targets, options=BuilderOptions( enable_flashbundle=enable_flashbundle, pw_command_launcher=pw_command_launcher, + pregen_dir=pregen_dir, )) if clean: @@ -199,4 +205,4 @@ def cmd_build(context, copy_artifacts_to, create_archives): if __name__ == '__main__': - main() + main(auto_envvar_prefix='CHIP') diff --git a/scripts/build/builders/ameba.py b/scripts/build/builders/ameba.py index bb743407bada4e..677b47bbd43a01 100644 --- a/scripts/build/builders/ameba.py +++ b/scripts/build/builders/ameba.py @@ -27,6 +27,7 @@ class AmebaApp(Enum): ALL_CLUSTERS_MINIMAL = auto() LIGHT = auto() PIGWEED = auto() + LIGHT_SWITCH = auto() @property def ExampleName(self): @@ -36,6 +37,8 @@ def ExampleName(self): return 'all-clusters-minimal-app' elif self == AmebaApp.LIGHT: return 'lighting-app' + elif self == AmebaApp.LIGHT_SWITCH: + return 'light-switch-app' elif self == AmebaApp.PIGWEED: return 'pigweed-app' else: @@ -49,6 +52,8 @@ def AppNamePrefix(self): return 'chip-ameba-all-clusters-minimal-app' elif self == AmebaApp.LIGHT: return 'chip-ameba-lighting-app' + elif self == AmebaApp.LIGHT_SWITCH: + return 'chip-ameba-light-switch-app' elif self == AmebaApp.PIGWEED: return 'chip-ameba-pigweed-app' else: diff --git a/scripts/build/builders/bouffalolab.py b/scripts/build/builders/bouffalolab.py index 00a9315d705928..ed22de8ad88bb5 100644 --- a/scripts/build/builders/bouffalolab.py +++ b/scripts/build/builders/bouffalolab.py @@ -14,6 +14,7 @@ import os import platform +import logging from enum import Enum, auto from .gn import GnBuilder @@ -28,9 +29,9 @@ def ExampleName(self): else: raise Exception('Unknown app type: %r' % self) - def AppNamePrefix(self): + def AppNamePrefix(self, chip_name): if self == BouffalolabApp.LIGHT: - return 'chip-bl702-lighting-example' + return ('chip-%s-lighting-example' % chip_name) else: raise Exception('Unknown app type: %r' % self) @@ -87,7 +88,7 @@ def __init__(self, ) self.argsOpt = [] - + self.chip_name = bouffalo_chip toolchain = os.path.join(root, '../../examples/platform/bouffalolab/common/toolchain') toolchain = 'custom_toolchain="{}:riscv_gcc"'.format(toolchain) if toolchain: @@ -107,17 +108,29 @@ def __init__(self, elif enable_shell: self.argsOpt.append('chip_build_libshell=true') + try: + self.argsOpt.append('bouffalolab_sdk_root="%s"' % os.environ['BOUFFALOLAB_SDK_ROOT']) + except KeyError as err: + logging.fatal('Please make sure Bouffalo Lab SDK installs as below:') + logging.fatal('\tcd third_party/bouffalolab/repo') + logging.fatal('\tsudo bash scripts/setup.sh') + + logging.fatal('Please make sure BOUFFALOLAB_SDK_ROOT exports before building as below:') + logging.fatal('\texport BOUFFALOLAB_SDK_ROOT=/opt/bouffalolab_sdk') + + raise err + def GnBuildArgs(self): return self.argsOpt def build_outputs(self): items = { - '%s.out' % self.app.AppNamePrefix(): + '%s.out' % self.app.AppNamePrefix(self.chip_name): os.path.join(self.output_dir, '%s.out' % - self.app.AppNamePrefix()), - '%s.out.map' % self.app.AppNamePrefix(): + self.app.AppNamePrefix(self.chip_name)), + '%s.out.map' % self.app.AppNamePrefix(self.chip_name): os.path.join(self.output_dir, - '%s.out.map' % self.app.AppNamePrefix()), + '%s.out.map' % self.app.AppNamePrefix(self.chip_name)), } return items diff --git a/scripts/build/builders/builder.py b/scripts/build/builders/builder.py index 99bc9255ee5ef9..dc420fce5e6b41 100644 --- a/scripts/build/builders/builder.py +++ b/scripts/build/builders/builder.py @@ -24,9 +24,13 @@ class BuilderOptions: # Enable flashbundle generation stage enable_flashbundle: bool = False + # Allow to wrap default build command pw_command_launcher: str = None + # Locations where files are pre-generated + pregen_dir: str = None + class Builder(ABC): """Generic builder base class for CHIP. diff --git a/scripts/build/builders/efr32.py b/scripts/build/builders/efr32.py index d622a9bd6eab3f..cd99b7a29eab1a 100644 --- a/scripts/build/builders/efr32.py +++ b/scripts/build/builders/efr32.py @@ -14,6 +14,8 @@ import os from enum import Enum, auto +import shlex +import subprocess from .gn import GnBuilder @@ -115,16 +117,31 @@ def __init__(self, runner, app: Efr32App = Efr32App.LIGHT, board: Efr32Board = Efr32Board.BRD4161A, + chip_build_libshell: bool = False, + chip_logging: bool = True, + chip_openthread_ftd: bool = True, + enable_heap_monitoring: bool = False, + enable_openthread_cli: bool = True, + show_qr_code: bool = False, enable_rpcs: bool = False, enable_ota_requestor: bool = False, enable_sed: bool = False, - enable_low_power: bool = False + enable_low_power: bool = False, + enable_wifi: bool = False, + enable_rs911x: bool = False, + enable_wf200: bool = False, + enable_wifi_ipv4: bool = False, + enable_additional_data_advertising: bool = False, + enable_ot_lib: bool = False, + enable_ot_coap_lib: bool = False, + no_version: bool = False ): super(Efr32Builder, self).__init__( root=app.BuildRoot(root), runner=runner) self.app = app self.extra_gn_options = ['silabs_board="%s"' % board.GnArgName()] + self.dotfile = '' if enable_rpcs: self.extra_gn_options.append('is_debug=false import("//with_pw_rpc.gni")') @@ -139,6 +156,58 @@ def __init__(self, self.extra_gn_options.append( 'chip_build_libshell=false enable_openthread_cli=false show_qr_code=false disable_lcd=true') + if chip_build_libshell: + self.extra_gn_options.append('chip_build_libshell=true') + + if chip_logging == False: + self.extra_gn_options.append('chip_logging=false') + + if chip_openthread_ftd == False: + self.extra_gn_options.append('chip_openthread_ftd=false') + + if enable_heap_monitoring: + self.extra_gn_options.append('enable_heap_monitoring=true') + + if enable_openthread_cli == False: + self.extra_gn_options.append('enable_openthread_cli=false') + + if show_qr_code: + self.extra_gn_options.append('show_qr_code=true') + + if enable_wifi: + self.dotfile += self.root + '/build_for_wifi_gnfile.gn' + if board == Efr32Board.BRD4161A: + self.extra_gn_options.append('is_debug=false chip_logging=false') + else: + self.extra_gn_options.append('disable_lcd=true use_external_flash=false') + + if enable_rs911x: + self.extra_gn_options.append('use_rs911x=true') + elif enable_wf200: + self.extra_gn_options.append('use_wf200=true') + else: + raise Exception('Wifi usage: ...-wifi-[rs911x|wf200]-...') + + if enable_wifi_ipv4: + self.extra_gn_options.append('chip_enable_wifi_ipv4=true') + + if enable_additional_data_advertising: + self.extra_gn_options.append('chip_enable_additional_data_advertising=true chip_enable_rotating_device_id=true') + + if enable_ot_lib: + self.extra_gn_options.append( + 'use_silabs_thread_lib=true chip_openthread_target="../silabs:ot-efr32-cert" openthread_external_platform=""') + + if enable_ot_coap_lib: + self.extra_gn_options.append( + 'use_silabs_thread_lib=true chip_openthread_target="../silabs:ot-efr32-cert" use_thread_coap_lib=true openthread_external_platform=""') + + if not no_version: + shortCommitSha = subprocess.check_output(['git', 'describe', '--always', '--dirty']).decode('ascii').strip() + branchName = subprocess.check_output(['git', 'rev-parse', '--abbrev-ref', 'HEAD']).decode('ascii').strip() + self.extra_gn_options.append( + 'sl_matter_version_str="v1.0-%s-%s"' % (branchName, shortCommitSha)) + def GnBuildArgs(self): return self.extra_gn_options @@ -163,3 +232,33 @@ def build_outputs(self): name] = os.path.join(self.output_dir, name) return items + + def generate(self): + cmd = [ + 'gn', 'gen', '--check', '--fail-on-unused-args', + '--export-compile-commands', + '--root=%s' % self.root + ] + if self.dotfile: + cmd += ['--dotfile=%s' % self.dotfile] + + extra_args = self.GnBuildArgs() + if extra_args: + cmd += ['--args=%s' % ' '.join(extra_args)] + + cmd += [self.output_dir] + + title = 'Generating ' + self.identifier + extra_env = self.GnBuildEnv() + + if extra_env: + # convert the command into a bash command that includes + # setting environment variables + cmd = [ + 'bash', '-c', '\n' + ' '.join( + ['%s="%s" \\\n' % (key, value) for key, value in extra_env.items()] + + [shlex.join(cmd)] + ) + ] + + self._Execute(cmd, title=title) diff --git a/scripts/build/builders/esp32.py b/scripts/build/builders/esp32.py index d84e8f56e8edbc..456ebc09c7f0c2 100644 --- a/scripts/build/builders/esp32.py +++ b/scripts/build/builders/esp32.py @@ -37,6 +37,7 @@ class Esp32App(Enum): TEMPERATURE_MEASUREMENT = auto() TESTS = auto() OTA_REQUESTOR = auto() + OTA_PROVIDER = auto() @property def ExamplePath(self): @@ -56,6 +57,8 @@ def ExamplePath(self): return 'examples/temperature-measurement-app' elif self == Esp32App.OTA_REQUESTOR: return 'examples/ota-requestor-app' + elif self == Esp32App.OTA_PROVIDER: + return 'examples/ota-provider-app' elif self == Esp32App.TESTS: return 'src/test_driver' else: @@ -79,6 +82,8 @@ def AppNamePrefix(self): return 'chip-temperature-measurement-app' elif self == Esp32App.OTA_REQUESTOR: return 'chip-ota-requestor-app' + elif self == Esp32App.OTA_PROVIDER: + return 'chip-ota-provider-app' elif self == Esp32App.TESTS: return None else: @@ -95,7 +100,7 @@ def IsCompatible(self, board: Esp32Board): if board == Esp32Board.QEMU: return self == Esp32App.TESTS elif board == Esp32Board.M5Stack: - return self == Esp32App.ALL_CLUSTERS or self == Esp32App.ALL_CLUSTERS_MINIMAL or self == Esp32App.OTA_REQUESTOR + return self == Esp32App.ALL_CLUSTERS or self == Esp32App.ALL_CLUSTERS_MINIMAL or self == Esp32App.OTA_REQUESTOR or self == Esp32App.OTA_PROVIDER elif board == Esp32Board.C3DevKit: return self == Esp32App.ALL_CLUSTERS or self == Esp32App.ALL_CLUSTERS_MINIMAL else: @@ -107,6 +112,7 @@ def DefaultsFileName(board: Esp32Board, app: Esp32App, enable_rpcs: bool): Esp32App.ALL_CLUSTERS_MINIMAL, Esp32App.LIGHT, Esp32App.OTA_REQUESTOR, + Esp32App.OTA_PROVIDER, Esp32App.TEMPERATURE_MEASUREMENT] if app == Esp32App.TESTS: return 'sdkconfig_qemu.defaults' @@ -176,11 +182,19 @@ def generate(self): self._Execute( ['bash', '-c', 'echo -e "\\nCONFIG_DISABLE_IPV4=y\\n" >>%s' % shlex.quote(defaults_out)]) - cmd = "\nexport SDKCONFIG_DEFAULTS={defaults}\nidf.py -C {example_path} -B {out} reconfigure".format( - defaults=shlex.quote(defaults_out), - example_path=self.ExamplePath, - out=shlex.quote(self.output_dir) - ) + cmake_flags = [] + + if self.options.pregen_dir: + cmake_flags.append( + f"-DCHIP_CODEGEN_PREGEN_DIR={shlex.quote(self.options.pregen_dir)}") + + cmake_args = ['-C', self.ExamplePath, '-B', + shlex.quote(self.output_dir)] + cmake_flags + + cmake_args = " ".join(cmake_args) + defaults = shlex.quote(defaults_out) + + cmd = f"\nexport SDKCONFIG_DEFAULTS={defaults}\nidf.py {cmake_args} reconfigure" # This will do a 'cmake reconfigure' which will create ninja files without rebuilding self._IdfEnvExecute(cmd) diff --git a/scripts/build/builders/gn.py b/scripts/build/builders/gn.py index bacd87d2399e02..9e859f6025a5a7 100644 --- a/scripts/build/builders/gn.py +++ b/scripts/build/builders/gn.py @@ -61,8 +61,13 @@ def generate(self): ] extra_args = [] + if self.options.pw_command_launcher: extra_args.append('pw_command_launcher="%s"' % self.options.pw_command_launcher) + + if self.options.pregen_dir: + extra_args.append('chip_code_pre_generated_directory="%s"' % self.options.pregen_dir) + extra_args.extend(self.GnBuildArgs() or []) if extra_args: cmd += ['--args=%s' % ' '.join(extra_args)] diff --git a/scripts/build/builders/host.py b/scripts/build/builders/host.py index 07bd62a9850884..b05a034e41b6d0 100644 --- a/scripts/build/builders/host.py +++ b/scripts/build/builders/host.py @@ -222,7 +222,7 @@ class HostBuilder(GnBuilder): def __init__(self, root, runner, app: HostApp, board=HostBoard.NATIVE, enable_ipv4=True, enable_ble=True, enable_wifi=True, - enable_thread=True, use_tsan=False, use_asan=False, + enable_thread=True, use_tsan=False, use_asan=False, use_ubsan=False, separate_event_loop=True, use_libfuzzer=False, use_clang=False, interactive_mode=True, extra_tests=False, use_platform_mdns=False, enable_rpcs=False, @@ -260,6 +260,9 @@ def __init__(self, root, runner, app: HostApp, board=HostBoard.NATIVE, if use_asan: self.extra_gn_options.append('is_asan=true') + if use_ubsan: + self.extra_gn_options.append('is_ubsan=true') + if use_dmalloc: self.extra_gn_options.append('chip_config_memory_debug_checks=true') self.extra_gn_options.append('chip_config_memory_debug_dmalloc=true') diff --git a/scripts/build/builders/mbed.py b/scripts/build/builders/mbed.py index 73fc802386207f..46b3ead610bb72 100644 --- a/scripts/build/builders/mbed.py +++ b/scripts/build/builders/mbed.py @@ -121,14 +121,16 @@ def generate(self): '--mbed-os-path', self.mbed_os_path, ], title='Generating config ' + self.identifier) - self._Execute(['cmake', '-S', shlex.quote(self.ExamplePath), '-B', shlex.quote(self.output_dir), '-GNinja', - '-DCMAKE_BUILD_TYPE={}'.format( - self.profile.ProfileName.lower()), - '-DMBED_OS_PATH={}'.format( - shlex.quote(self.mbed_os_path)), - '-DMBED_OS_POSIX_SOCKET_PATH={}'.format( - shlex.quote(self.mbed_os_posix_socket_path)), - ], title='Generating ' + self.identifier) + flags = [] + flags.append(f"-DMBED_OS_PATH={shlex.quote(self.mbed_os_path)}") + flags.append(f"-DMBED_OS_PATH={shlex.quote(self.mbed_os_path)}") + flags.append(f"-DMBED_OS_POSIX_SOCKET_PATH={shlex.quote(self.mbed_os_posix_socket_path)}") + + if self.options.pregen_dir: + flags.append(f"-DCHIP_CODEGEN_PREGEN_DIR={shlex.quote(self.options.pregen_dir)}") + + self._Execute(['cmake', '-S', shlex.quote(self.ExamplePath), '-B', shlex.quote(self.output_dir), + '-GNinja'] + flags, title='Generating ' + self.identifier) def _build(self): # Remove old artifacts to force linking diff --git a/scripts/build/builders/nrf.py b/scripts/build/builders/nrf.py index 39c93946b9b27d..4f3b895f638c47 100644 --- a/scripts/build/builders/nrf.py +++ b/scripts/build/builders/nrf.py @@ -28,6 +28,7 @@ class NrfApp(Enum): SHELL = auto() PUMP = auto() PUMP_CONTROLLER = auto() + SWITCH = auto() WINDOW_COVERING = auto() UNIT_TESTS = auto() @@ -38,6 +39,8 @@ def AppPath(self): return 'examples/all-clusters-minimal-app' elif self == NrfApp.LIGHT: return 'examples/lighting-app' + elif self == NrfApp.SWITCH: + return 'examples/light-switch-app' elif self == NrfApp.LOCK: return 'examples/lock-app' elif self == NrfApp.SHELL: @@ -60,6 +63,8 @@ def AppNamePrefix(self): return 'chip-nrf-all-clusters-minimal-example' elif self == NrfApp.LIGHT: return 'chip-nrf-lighting-example' + elif self == NrfApp.SWITCH: + return 'chip-nrf-light-switch-example' elif self == NrfApp.LOCK: return 'chip-nrf-lock-example' elif self == NrfApp.SHELL: @@ -82,6 +87,8 @@ def _FlashBundlePrefix(self): return 'chip-nrfconnect-all-clusters-minimal-app-example' elif self == NrfApp.LIGHT: return 'chip-nrfconnect-lighting-example' + elif self == NrfApp.SWITCH: + return 'chip-nrfconnect-switch-example' elif self == NrfApp.LOCK: return 'chip-nrfconnect-lock-example' elif self == NrfApp.SHELL: @@ -172,6 +179,9 @@ def generate(self): if self.board == NrfBoard.NRF52840DONGLE and self.app != NrfApp.ALL_CLUSTERS and self.app != NrfApp.ALL_CLUSTERS_MINIMAL: flags.append("-DCONF_FILE=prj_no_dfu.conf") + if self.options.pregen_dir: + flags.append(f"-DCHIP_CODEGEN_PREGEN_DIR={shlex.quote(self.options.pregen_dir)}") + build_flags = " -- " + " ".join(flags) if len(flags) > 0 else "" cmd = ''' diff --git a/scripts/build/builders/openiotsdk.py b/scripts/build/builders/openiotsdk.py new file mode 100644 index 00000000000000..dd24618e11e00e --- /dev/null +++ b/scripts/build/builders/openiotsdk.py @@ -0,0 +1,85 @@ +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import os +import shlex +from enum import Enum, auto + +from .builder import Builder + + +class OpenIotSdkApp(Enum): + SHELL = auto() + LOCK = auto() + + @property + def ExampleName(self): + if self == OpenIotSdkApp.SHELL: + return 'shell' + elif self == OpenIotSdkApp.LOCK: + return 'lock-app' + else: + raise Exception('Unknown app type: %r' % self) + + @property + def AppNamePrefix(self): + if self == OpenIotSdkApp.SHELL: + return 'chip-openiotsdk-shell-example' + elif self == OpenIotSdkApp.LOCK: + return 'chip-openiotsdk-lock-app-example' + else: + raise Exception('Unknown app type: %r' % self) + + +class OpenIotSdkBuilder(Builder): + def __init__(self, + root, + runner, + app: OpenIotSdkApp = OpenIotSdkApp.SHELL): + super(OpenIotSdkBuilder, self).__init__(root, runner) + self.app = app + self.toolchain_path = os.path.join( + 'toolchains', 'toolchain-arm-none-eabi-gcc.cmake') + self.system_processor = 'cortex-m55' + + @property + def ExamplePath(self): + return os.path.join(self.root, 'examples', self.app.ExampleName, 'openiotsdk') + + def generate(self): + if not os.path.exists(self.output_dir): + self._Execute(['cmake', '-GNinja', '-S', shlex.quote(self.ExamplePath), '-B', shlex.quote(self.output_dir), + '--toolchain={}'.format( + shlex.quote(self.toolchain_path)), + '-DCMAKE_SYSTEM_PROCESSOR={}'.format( + self.system_processor), + ], title='Generating ' + self.identifier) + + def _build(self): + # Remove old artifacts to force linking + cmd = 'rm -rf {}/chip-*'.format(self.output_dir) + self._Execute(['bash', '-c', cmd], + title='Remove old artifacts ' + self.identifier) + + self._Execute(['cmake', '--build', shlex.quote(self.output_dir)], + title='Building ' + self.identifier) + + def build_outputs(self): + return { + self.app.AppNamePrefix + '.elf': + os.path.join(self.output_dir, self.app.AppNamePrefix + '.elf'), + self.app.AppNamePrefix + '.map': + os.path.join(self.output_dir, + self.app.AppNamePrefix + '.map'), + } diff --git a/scripts/build/builders/telink.py b/scripts/build/builders/telink.py index a85ec7c9fe58d6..32a9bf85c3187e 100644 --- a/scripts/build/builders/telink.py +++ b/scripts/build/builders/telink.py @@ -100,15 +100,21 @@ def generate(self): if os.path.exists(self.output_dir): return + flags = [] + if self.options.pregen_dir: + flags.append(f"-DCHIP_CODEGEN_PREGEN_DIR={shlex.quote(self.options.pregen_dir)}") + + build_flags = " -- " + " ".join(flags) if len(flags) > 0 else "" + cmd = self.get_cmd_prefixes() cmd += ''' source "$ZEPHYR_BASE/zephyr-env.sh"; -west build --cmake-only -d {outdir} -b {board} {sourcedir} +west build --cmake-only -d {outdir} -b {board} {sourcedir}{build_flags} '''.format( - outdir=shlex.quote( - self.output_dir), board=self.board.GnArgName(), sourcedir=shlex.quote( - os.path.join( - self.root, 'examples', self.app.ExampleName(), 'telink'))).strip() + outdir=shlex.quote(self.output_dir), + board=self.board.GnArgName(), + sourcedir=shlex.quote(os.path.join(self.root, 'examples', self.app.ExampleName(), 'telink')), + build_flags=build_flags).strip() self._Execute(['bash', '-c', cmd], title='Generating ' + self.identifier) diff --git a/scripts/build/builders/tizen.py b/scripts/build/builders/tizen.py index 28d91ee7faf218..71ae18e9f1cce6 100644 --- a/scripts/build/builders/tizen.py +++ b/scripts/build/builders/tizen.py @@ -82,6 +82,7 @@ def __init__(self, enable_wifi: bool = True, use_asan: bool = False, use_tsan: bool = False, + use_ubsan: bool = False, ): super(TizenBuilder, self).__init__( root=os.path.join(root, app.value.source), @@ -110,6 +111,8 @@ def __init__(self, self.extra_gn_options.append('is_asan=true') if use_tsan: raise Exception("TSAN sanitizer not supported by Tizen toolchain") + if use_ubsan: + self.extra_gn_options.append('is_ubsan=true') def GnBuildArgs(self): # Make sure that required ENV variables are defined diff --git a/scripts/build/gn_gen_cirque.sh b/scripts/build/gn_gen_cirque.sh index f65525bd6dfb7b..85da0c232745c5 100755 --- a/scripts/build/gn_gen_cirque.sh +++ b/scripts/build/gn_gen_cirque.sh @@ -27,10 +27,16 @@ set -x env -echo "Build: GN configure" +cd "$ROOT_PATH" -gn --root="$CHIP_ROOT" gen --check --fail-on-unused-args "$CHIP_ROOT/out/debug" --args='target_os="all"'"chip_build_tests=false chip_enable_wifi=false chip_im_force_fabric_quota_check=true enable_default_builds=false enable_host_gcc_build=true enable_standalone_chip_tool_build=true enable_linux_all_clusters_app_build=true enable_linux_lighting_app_build=true" +echo "Ensure submodules for Linux builds are checked out" +./scripts/checkout_submodules.py --shallow --platform linux -echo "Build: Ninja build" +echo "Setup build environment" +source "./scripts/activate.sh" -time ninja -C "$CHIP_ROOT/out/debug" all check +echo "Build: GN configure" +gn --root="$CHIP_ROOT" gen --check --fail-on-unused-args out/debug --args='target_os="all"'"chip_build_tests=false chip_enable_wifi=false chip_im_force_fabric_quota_check=true enable_default_builds=false enable_host_gcc_build=true enable_standalone_chip_tool_build=true enable_linux_all_clusters_app_build=true enable_linux_lighting_app_build=true" + +echo "Build: Ninja build" +time ninja -C out/debug all check diff --git a/scripts/build/test.py b/scripts/build/test.py index b0ba8a0d685c38..8cf88b0571c44e 100644 --- a/scripts/build/test.py +++ b/scripts/build/test.py @@ -107,7 +107,9 @@ def test_general_dry_runs(self): 'esp32-m5stack-all-clusters-minimal-rpc-ipv6only', 'android-arm64-chip-tool', 'nrf-nrf52840dk-pump', - 'efr32-brd4161a-light-rpc' + 'efr32-brd4161a-light-rpc-no-version', + 'openiotsdk-lock', + 'openiotsdk-shell' ] for target in TARGETS: diff --git a/scripts/build/testdata/all_targets_linux_x64.txt b/scripts/build/testdata/all_targets_linux_x64.txt index dcb2963b1177ee..2fbf8d8813520f 100644 --- a/scripts/build/testdata/all_targets_linux_x64.txt +++ b/scripts/build/testdata/all_targets_linux_x64.txt @@ -1,21 +1,22 @@ -ameba-amebad-{all-clusters,all-clusters-minimal,light,pigweed} +ameba-amebad-{all-clusters,all-clusters-minimal,light,light-switch,pigweed} android-{arm,arm64,x86,x64,androidstudio-arm,androidstudio-arm64,androidstudio-x86,androidstudio-x64}-{chip-tool,chip-test,tv-server,tv-casting-app,java-matter-controller} bouffalolab-{bl602-iot-matter-v1,bl602-iot-dvk-3s,bl602-night-light,xt-zb6-devkit,bl706-iot-dvk,bl706-night-light}-light[-shell][-115200][-rpc] cc13x2x7_26x2x7-{all-clusters,all-clusters-minimal,lock,pump,pump-controller,shell}[-ftd][-mtd] cyw30739-cyw930739m2evb_01-{light,lock,ota-requestor}[-no-progress-logging] -efr32-{brd4161a,brd4187c,brd4163a,brd4164a,brd4166a,brd4170a,brd4186a,brd4187a,brd4304a}-{window-covering,switch,unit-test,light,lock}[-rpc][-with-ota-requestor][-sed][-low-power] -esp32-{m5stack,c3devkit,devkitc,qemu}-{all-clusters,all-clusters-minimal,ota-requestor,ota-requestor,shell,light,lock,bridge,temperature-measurement,ota-requestor,tests}[-rpc][-ipv6only] +efr32-{brd4161a,brd4187c,brd4163a,brd4164a,brd4166a,brd4170a,brd4186a,brd4187a,brd4304a}-{window-covering,switch,unit-test,light,lock}[-rpc][-with-ota-requestor][-sed][-low-power][-shell][-no_logging][-openthread_mtd][-enable_heap_monitoring][-no_openthread_cli][-show_qr_code][-wifi][-rs911x][-wf200][-wifi_ipv4][-additional_data_advertising][-use_ot_lib][-use_ot_coap_lib][-no-version] +esp32-{m5stack,c3devkit,devkitc,qemu}-{all-clusters,all-clusters-minimal,ota-provider,ota-requestor,shell,light,lock,bridge,temperature-measurement,ota-requestor,tests}[-rpc][-ipv6only] genio-lighting-app -linux-fake-tests[-mbedtls][-boringssl][-asan][-tsan][-libfuzzer][-coverage][-dmalloc][-clang] -linux-{x64,arm64}-{rpc-console,all-clusters,all-clusters-minimal,chip-tool,thermostat,java-matter-controller,minmdns,light,lock,shell,ota-provider,ota-requestor,python-bindings,tv-app,tv-casting-app,bridge,dynamic-bridge,tests,chip-cert,address-resolve-tool}[-nodeps][-minmdns-verbose][-libnl][-same-event-loop][-no-interactive][-ipv6only][-no-ble][-no-wifi][-no-thread][-mbedtls][-boringssl][-asan][-tsan][-libfuzzer][-coverage][-dmalloc][-clang][-test][-rpc] +linux-fake-tests[-mbedtls][-boringssl][-asan][-tsan][-ubsan][-libfuzzer][-coverage][-dmalloc][-clang] +linux-{x64,arm64}-{rpc-console,all-clusters,all-clusters-minimal,chip-tool,thermostat,java-matter-controller,minmdns,light,lock,shell,ota-provider,ota-requestor,python-bindings,tv-app,tv-casting-app,bridge,dynamic-bridge,tests,chip-cert,address-resolve-tool}[-nodeps][-platform-mdns][-minmdns-verbose][-libnl][-same-event-loop][-no-interactive][-ipv6only][-no-ble][-no-wifi][-no-thread][-mbedtls][-boringssl][-asan][-tsan][-ubsan][-libfuzzer][-coverage][-dmalloc][-clang][-test][-rpc] linux-x64-efr32-test-runner[-clang] imx-{chip-tool,lighting-app,thermostat,all-clusters-app,all-clusters-minimal-app,ota-provider-app}[-release] infineon-psoc6-{lock,light,all-clusters,all-clusters-minimal}[-ota][-updateimage] k32w-{light,shell,lock,contact}[-se05x][-no-ble][-no-ota][-low-power][-nologs] mbed-cy8cproto_062_4343w-{lock,light,all-clusters,all-clusters-minimal,pigweed,shell}[-release][-develop][-debug] mw320-all-clusters-app -nrf-{nrf5340dk,nrf52840dk,nrf52840dongle}-{all-clusters,all-clusters-minimal,lock,light,shell,pump,pump-controller}[-rpc] +nrf-{nrf5340dk,nrf52840dk,nrf52840dongle}-{all-clusters,all-clusters-minimal,lock,light,light-switch,shell,pump,pump-controller,window-covering}[-rpc] nrf-native-posix-64-tests qpg-qpg6105-{lock,light,shell,persistent-storage} -tizen-arm-{all-clusters,all-clusters-minimal,chip-tool,light}[-no-ble][-no-wifi][-asan] +tizen-arm-{all-clusters,all-clusters-minimal,chip-tool,light}[-no-ble][-no-wifi][-asan][-ubsan] telink-tlsr9518adk80d-{all-clusters,all-clusters-minimal,light,light-switch,ota-requestor,thermostat} +openiotsdk-{shell,lock} diff --git a/scripts/build/testdata/dry_run_efr32-brd4161a-light-rpc.txt b/scripts/build/testdata/dry_run_efr32-brd4161a-light-rpc-no-version.txt similarity index 57% rename from scripts/build/testdata/dry_run_efr32-brd4161a-light-rpc.txt rename to scripts/build/testdata/dry_run_efr32-brd4161a-light-rpc-no-version.txt index 4a241682b02f49..d48088b2048379 100644 --- a/scripts/build/testdata/dry_run_efr32-brd4161a-light-rpc.txt +++ b/scripts/build/testdata/dry_run_efr32-brd4161a-light-rpc-no-version.txt @@ -1,8 +1,8 @@ # Commands will be run in CHIP project root. cd "{root}" -# Generating efr32-brd4161a-light-rpc -gn gen --check --fail-on-unused-args --export-compile-commands --root={root}/examples/lighting-app/silabs/efr32 '--args=silabs_board="BRD4161A" is_debug=false import("//with_pw_rpc.gni")' {out}/efr32-brd4161a-light-rpc +# Generating efr32-brd4161a-light-rpc-no-version +gn gen --check --fail-on-unused-args --export-compile-commands --root={root}/examples/lighting-app/silabs/efr32 '--args=silabs_board="BRD4161A" is_debug=false import("//with_pw_rpc.gni")' {out}/efr32-brd4161a-light-rpc-no-version -# Building efr32-brd4161a-light-rpc -ninja -C {out}/efr32-brd4161a-light-rpc +# Building efr32-brd4161a-light-rpc-no-version +ninja -C {out}/efr32-brd4161a-light-rpc-no-version diff --git a/scripts/build/testdata/dry_run_openiotsdk-lock.txt b/scripts/build/testdata/dry_run_openiotsdk-lock.txt new file mode 100644 index 00000000000000..d00bdae66c6358 --- /dev/null +++ b/scripts/build/testdata/dry_run_openiotsdk-lock.txt @@ -0,0 +1,11 @@ +# Commands will be run in CHIP project root. +cd "{root}" + +# Generating openiotsdk-lock +cmake -GNinja -S {root}/examples/lock-app/openiotsdk -B {out}/openiotsdk-lock --toolchain=toolchains/toolchain-arm-none-eabi-gcc.cmake -DCMAKE_SYSTEM_PROCESSOR=cortex-m55 + +# Remove old artifacts openiotsdk-lock +bash -c 'rm -rf {out}/openiotsdk-lock/chip-*' + +# Building openiotsdk-lock +cmake --build {out}/openiotsdk-lock diff --git a/scripts/build/testdata/dry_run_openiotsdk-shell.txt b/scripts/build/testdata/dry_run_openiotsdk-shell.txt new file mode 100644 index 00000000000000..f93c6a3201b591 --- /dev/null +++ b/scripts/build/testdata/dry_run_openiotsdk-shell.txt @@ -0,0 +1,11 @@ +# Commands will be run in CHIP project root. +cd "{root}" + +# Generating openiotsdk-shell +cmake -GNinja -S {root}/examples/shell/openiotsdk -B {out}/openiotsdk-shell --toolchain=toolchains/toolchain-arm-none-eabi-gcc.cmake -DCMAKE_SYSTEM_PROCESSOR=cortex-m55 + +# Remove old artifacts openiotsdk-shell +bash -c 'rm -rf {out}/openiotsdk-shell/chip-*' + +# Building openiotsdk-shell +cmake --build {out}/openiotsdk-shell diff --git a/scripts/codegen.py b/scripts/codegen.py index ef228cb0486abc..67898af6ebce5f 100755 --- a/scripts/codegen.py +++ b/scripts/codegen.py @@ -147,4 +147,4 @@ def main(log_level, generator, output_dir, dry_run, name_only, expected_outputs, if __name__ == '__main__': - main() + main(auto_envvar_prefix='CHIP') diff --git a/scripts/codepregen.py b/scripts/codepregen.py new file mode 100755 index 00000000000000..13ca9a60d972c7 --- /dev/null +++ b/scripts/codepregen.py @@ -0,0 +1,114 @@ +#!/usr/bin/env python + +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import click +import logging +import multiprocessing +import itertools +import enum +import os +import sys + + +try: + from pregenerate import FindPregenerationTargets +except: + import os + sys.path.append(os.path.abspath(os.path.dirname(__file__))) + from pregenerate import FindPregenerationTargets + +try: + import coloredlogs + _has_coloredlogs = True +except: + _has_coloredlogs = False + +# Supported log levels, mapping string values required for argument +# parsing into logging constants +__LOG_LEVELS__ = { + 'debug': logging.DEBUG, + 'info': logging.INFO, + 'warn': logging.WARN, + 'fatal': logging.FATAL, +} + + +def _ParallelGenerateOne(arg): + """ + Helper method to be passed to multiprocessing parallel generation of + items. + """ + arg[0].Generate(arg[1]) + + +@click.command() +@click.option( + '--log-level', + default='INFO', + type=click.Choice(__LOG_LEVELS__.keys(), case_sensitive=False), + help='Determines the verbosity of script output') +@click.option( + '--parallel/--no-parallel', + default=True, + help='Do parallel/multiprocessing codegen.') +@click.option( + '--sdk-root', + default=None, + help='Path to the SDK root (where .zap/.matter files exist).') +@click.argument('output_dir') +def main(log_level, parallel, sdk_root, output_dir): + if _has_coloredlogs: + coloredlogs.install(level=__LOG_LEVELS__[ + log_level], fmt='%(asctime)s %(levelname)-7s %(message)s') + else: + logging.basicConfig( + level=__LOG_LEVELS__[log_level], + format='%(asctime)s %(levelname)-7s %(message)s', + datefmt='%Y-%m-%d %H:%M:%S' + ) + + if not sdk_root: + sdk_root = os.path.join(os.path.dirname( + os.path.realpath(__file__)), '..') + + sdk_root = os.path.abspath(sdk_root) + + if not output_dir: + raise Exception("Missing output directory") + + output_dir = os.path.abspath(output_dir) + + logging.info(f"Pre-generating {sdk_root} data into {output_dir}") + + if not os.path.exists(output_dir): + os.makedirs(output_dir) + + targets = FindPregenerationTargets(sdk_root) + + if parallel: + target_and_dir = zip(targets, itertools.repeat(output_dir)) + with multiprocessing.Pool() as pool: + for _ in pool.imap_unordered(_ParallelGenerateOne, target_and_dir): + pass + else: + for target in targets: + target.Generate(output_dir) + + logging.info("Done") + + +if __name__ == '__main__': + main() diff --git a/scripts/examples/gn_bouffalolab_example.sh b/scripts/examples/gn_bouffalolab_example.sh index a719563f38cb03..7c40790619fed4 100755 --- a/scripts/examples/gn_bouffalolab_example.sh +++ b/scripts/examples/gn_bouffalolab_example.sh @@ -141,6 +141,19 @@ else exit 1 fi + if [[ "$BOUFFALOLAB_SDK_ROOT" == "" ]]; then + + echo -e "\e[31mPlease make sure Bouffalo Lab SDK installs as below:\e[0m" + echo -e "\e[31m\tcd third_party/bouffalolab/repo\e[0m" + echo -e "\e[31m\tsudo bash scripts/setup.sh\e[0m" + + echo -e "\e[31mPlease make sure BOUFFALOLAB_SDK_ROOT exports before building as below:\e[0m" + echo -e "\e[31m\texport BOUFFALOLAB_SDK_ROOT=/opt/bouffalolab_sdk\e[0m" + + exit 1 + fi + optArgs=$optArgs' bouffalolab_sdk_root="'$BOUFFALOLAB_SDK_ROOT'"' + example_dir=$MATTER_ROOT/examples/$example_name/bouffalolab/$bouffalo_chip output_dir=$MATTER_ROOT/$output_folder diff --git a/scripts/examples/gn_efr32_example.sh b/scripts/examples/gn_efr32_example.sh index 2062c079ac391c..d577b074539b90 100755 --- a/scripts/examples/gn_efr32_example.sh +++ b/scripts/examples/gn_efr32_example.sh @@ -16,7 +16,7 @@ # limitations under the License. # -# Build script for GN EFT32 examples GitHub workflow. +# Build script for GN EFR32 examples GitHub workflow. set -e @@ -33,6 +33,7 @@ source "$CHIP_ROOT/scripts/activate.sh" set -x env USE_WIFI=false +USE_GIT_SHA_FOR_VERSION=true SILABS_THREAD_TARGET=\""../silabs:ot-efr32-cert"\" USAGE="./scripts/examples/gn_efr32_example.sh []" @@ -81,6 +82,10 @@ if [ "$#" == "0" ]; then enable_sleepy_device Enable Sleepy end device. (Default false) Must also set chip_openthread_ftd=false + sl_matter_version_str + Set a Matter sotfware version string for the Silabs examples + Used and formatted by default in this script. + To skip that formatting or use your own version string use --no-version use_rs911x Build wifi example with extension board rs911x. (Default false) use_wf200 @@ -104,6 +109,9 @@ if [ "$#" == "0" ]; then enable Addition data advertissing and rotating device ID --use_ot_lib use the silabs openthread library + --no-version + Skip the silabs formating for the Matter software version string + Currently : v1.0-- " elif [ "$#" -lt "2" ]; then echo "Invalid number of arguments @@ -128,9 +136,9 @@ else exit 1 fi if [ "$2" = "rs911x" ]; then - optArgs+="use_rs911x=true" + optArgs+="use_rs911x=true " elif [ "$2" = "wf200" ]; then - optArgs+="use_wf200=true" + optArgs+="use_wf200=true " else echo "Wifi usage: --wifi rs911x|wf200" exit 1 @@ -163,6 +171,10 @@ else optArgs+="use_silabs_thread_lib=true chip_openthread_target=$SILABS_THREAD_TARGET openthread_external_platform=\"""\" use_thread_coap_lib=true " shift ;; + --no-version) + USE_GIT_SHA_FOR_VERSION=false + shift + ;; *) if [ "$1" =~ *"use_rs911x=true"* ] || [ "$1" =~ *"use_wf200=true"* ]; then USE_WIFI=true @@ -179,6 +191,14 @@ else exit 1 fi + if [ "$USE_GIT_SHA_FOR_VERSION" == true ]; then + { + ShortCommitSha=$(git describe --always --dirty) + branchName=$(git rev-parse --abbrev-ref HEAD) + optArgs+="sl_matter_version_str=\"v1.0-$branchName-$ShortCommitSha\" " + } &>/dev/null + fi + BUILD_DIR=$OUTDIR/$SILABS_BOARD echo BUILD_DIR="$BUILD_DIR" if [ "$USE_WIFI" == true ]; then diff --git a/scripts/examples/gn_psoc6_example.sh b/scripts/examples/gn_psoc6_example.sh index 403063ff575f0d..04f47e6b2f0b5a 100755 --- a/scripts/examples/gn_psoc6_example.sh +++ b/scripts/examples/gn_psoc6_example.sh @@ -28,7 +28,7 @@ elif [ -d "$HOME/ModusToolbox" ]; then export CY_TOOLS_PATHS="$HOME/ModusToolbox/tools_2.4" else # Install Modustoolbox - curl --fail --location --silent --show-error https://download.cypress.com/downloadmanager/software/ModusToolbox/ModusToolbox_2.4/ModusToolbox_2.4.0.5972-linux-install.tar.gz -o /tmp/ModusToolbox_2.4.0.5972-linux-install.tar.gz -o /tmp/ModusToolbox_2.4.0.5972-linux-install.tar.gz && + curl --fail --location --silent --show-error https://itoolspriv.infineon.com/itbhs/api/packages/com.ifx.tb.tool.modustoolbox/Versions/2.4.0.5972-public/artifacts/ModusToolbox_2.4.0.5972-linux-install.tar.gz/download?noredirect -o /tmp/ModusToolbox_2.4.0.5972-linux-install.tar.gz && tar -C "$HOME" -zxf /tmp/ModusToolbox_2.4.0.5972-linux-install.tar.gz && rm /tmp/ModusToolbox_2.4.0.5972-linux-install.tar.gz diff --git a/scripts/examples/openiotsdk_example.sh b/scripts/examples/openiotsdk_example.sh new file mode 100755 index 00000000000000..d700a227d0b767 --- /dev/null +++ b/scripts/examples/openiotsdk_example.sh @@ -0,0 +1,383 @@ +#!/bin/bash + +# +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# Build and/or run Open IoT SDK examples. + +IS_TEST=0 +NAME="$(basename "$0")" +HERE="$(dirname "$0")" +CHIP_ROOT="$(realpath "$HERE"/../..)" +COMMAND=build +PLATFORM=corstone300 +CLEAN=0 +SCRATCH=0 +EXAMPLE_PATH="" +BUILD_PATH="" +TOOLCHAIN=arm-none-eabi-gcc +DEBUG=false +EXAMPLE="" +FVP_BIN=FVP_Corstone_SSE-300_Ethos-U55 +GDB_PLUGIN="$FAST_MODEL_PLUGINS_PATH/GDBRemoteConnection.so" +OIS_CONFIG="$CHIP_ROOT/config/openiotsdk" +FVP_CONFIG_FILE="$OIS_CONFIG/fvp/cs300.conf" +EXAMPLE_TEST_PATH="$CHIP_ROOT/src/test_driver/openiotsdk/integration-tests" +TELNET_TERMINAL_PORT=5000 +FAILED_TESTS=0 +FVP_NETWORK="user" + +readarray -t TEST_NAMES <"$CHIP_ROOT"/src/test_driver/openiotsdk/unit-tests/testnames.txt + +function show_usage() { + cat < Action to execute + -d,--debug Build in debug mode + -p,--path Build path + -n,--network FVP network interface name + +Examples: + shell + lock-app + unit-tests + +You can run individual test suites of unit tests by using their names [test_name] with the run command: + +EOF + cat "$CHIP_ROOT"/src/test_driver/openiotsdk/unit-tests/testnames.txt + echo "" + cat < parameter as [test_name] + +The "test" command can be used for all supported examples expect the unit-tests. + +EOF +} + +function build_with_cmake() { + CMAKE="$(which cmake)" + if [[ ! -f "$CMAKE" ]]; then + echo "$NAME: cmake is not in PATH" >&2 + exit 1 + fi + + set -e + + mkdir -p "$BUILD_PATH" + + if [[ $CLEAN -ne 0 ]]; then + echo "Clean build" >&2 + if compgen -G "$BUILD_PATH/CMake*" >/dev/null; then + cmake --build "$BUILD_PATH" --target clean + find "$BUILD_PATH" -name 'CMakeCache.txt' -delete + fi + fi + + if [[ $SCRATCH -ne 0 ]]; then + echo "Remove building directory" >&2 + rm -rf "$BUILD_PATH" + fi + + BUILD_OPTIONS=(-DCMAKE_SYSTEM_PROCESSOR=cortex-m55) + if "$DEBUG"; then + BUILD_OPTIONS+=(-DCMAKE_BUILD_TYPE=Debug) + fi + + # Remove old artifacts to force linking + rm -rf "$BUILD_PATH/chip-"* + + # Activate Matter environment + source "$CHIP_ROOT"/scripts/activate.sh + # Remove access to ARM GCC toolchain from Matter environment, use higher version from OIS environment + PATH=$(echo "$PATH" | sed 's/:/\n/g' | grep -v "$PW_ARM_CIPD_INSTALL_DIR" | xargs | tr ' ' ':') + + cmake -G Ninja -S "$EXAMPLE_PATH" -B "$BUILD_PATH" --toolchain="$TOOLCHAIN_PATH" "${BUILD_OPTIONS[@]}" + cmake --build "$BUILD_PATH" +} + +function run_fvp() { + + set -e + + # Check if FVP exists + if ! [ -x "$(command -v "$FVP_BIN")" ]; then + echo "Error: $FVP_BIN not installed." >&2 + exit 1 + fi + + if [[ $IS_TEST -eq 0 ]]; then + EXAMPLE_EXE_PATH="$BUILD_PATH/chip-openiotsdk-$EXAMPLE-example.elf" + else + EXAMPLE_EXE_PATH="$BUILD_PATH/$EXAMPLE.elf" + fi + + # Check if executable file exists + if ! [ -f "$EXAMPLE_EXE_PATH" ]; then + echo "Error: $EXAMPLE_EXE_PATH does not exist." >&2 + exit 1 + fi + + RUN_OPTIONS=(-C mps3_board.telnetterminal0.start_port="$TELNET_TERMINAL_PORT") + RUN_OPTIONS+=(--quantum=25) + + if "$DEBUG"; then + RUN_OPTIONS+=(--allow-debug-plugin --plugin "$GDB_PLUGIN") + fi + + if [[ $FVP_NETWORK == "user" ]]; then + RUN_OPTIONS+=(-C mps3_board.hostbridge.userNetworking=1) + else + RUN_OPTIONS+=(-C mps3_board.hostbridge.interfaceName="$FVP_NETWORK") + fi + + echo "Running $EXAMPLE_EXE_PATH with options: ${RUN_OPTIONS[@]}" + + "$FVP_BIN" "${RUN_OPTIONS[@]}" -f "$FVP_CONFIG_FILE" --application "$EXAMPLE_EXE_PATH" >/dev/null 2>&1 & + FVP_PID=$! + sleep 1 + + if [[ $IS_TEST -eq 1 ]]; then + set +e + expect <"$EXAMPLE_PATH"/test_report.json + else + telnet localhost "$TELNET_TERMINAL_PORT" + fi + + # stop the fvp + kill -9 "$FVP_PID" || true + set -e + sleep 1 +} + +function run_test() { + + EXAMPLE_EXE_PATH="$BUILD_PATH/chip-openiotsdk-$EXAMPLE-example.elf" + # Check if executable file exists + if ! [ -f "$EXAMPLE_EXE_PATH" ]; then + echo "Error: $EXAMPLE_EXE_PATH does not exist." >&2 + exit 1 + fi + + # Check if FVP exists + if ! [ -x "$(command -v "$FVP_BIN")" ]; then + echo "Error: $FVP_BIN not installed." >&2 + exit 1 + fi + + # Activate Matter environment with pytest + source "$CHIP_ROOT"/scripts/activate.sh + + # Check if pytest exists + if ! [ -x "$(command -v pytest)" ]; then + echo "Error: pytest not installed." >&2 + exit 1 + fi + + TEST_OPTIONS=() + + if [[ $FVP_NETWORK ]]; then + TEST_OPTIONS+=(--networkInterface="$FVP_NETWORK") + fi + + if [[ -f $EXAMPLE_TEST_PATH/$EXAMPLE/test_report.json ]]; then + rm -rf "$EXAMPLE_TEST_PATH/$EXAMPLE"/test_report.json + fi + + set +e + pytest --json-report --json-report-summary --json-report-file="$EXAMPLE_TEST_PATH/$EXAMPLE"/test_report.json --binaryPath="$EXAMPLE_EXE_PATH" --fvp="$FVP_BIN" --fvpConfig="$FVP_CONFIG_FILE" "${TEST_OPTIONS[@]}" "$EXAMPLE_TEST_PATH/$EXAMPLE"/test_app.py + set -e + + if [[ ! -f $EXAMPLE_TEST_PATH/$EXAMPLE/test_report.json ]]; then + exit 1 + else + if [[ $(jq '.summary | has("failed")' $EXAMPLE_TEST_PATH/$EXAMPLE/test_report.json) == true ]]; then + FAILED_TESTS=$(jq '.summary.failed' "$EXAMPLE_TEST_PATH/$EXAMPLE"/test_report.json) + fi + fi +} + +SHORT=C:,p:,d:.n:,c,s,h +LONG=command:,path:,debug:.network:,clean,scratch,help +OPTS=$(getopt -n build --options "$SHORT" --longoptions "$LONG" -- "$@") + +eval set -- "$OPTS" + +while :; do + case "$1" in + -h | --help) + show_usage + exit 0 + ;; + -c | --clean) + CLEAN=1 + shift + ;; + -s | --scratch) + SCRATCH=1 + shift + ;; + -C | --command) + COMMAND=$2 + shift 2 + ;; + -d | --debug) + DEBUG=$2 + shift 2 + ;; + -p | --path) + BUILD_PATH=$CHIP_ROOT/$2 + shift 2 + ;; + -n | --network) + FVP_NETWORK=$2 + shift 2 + ;; + -* | --*) + shift + break + ;; + *) + echo "Unexpected option: $1" + show_usage + exit 2 + ;; + esac +done + +if [[ $# -lt 1 ]]; then + show_usage >&2 + exit 1 +fi + +case "$1" in + shell | unit-tests | lock-app) + EXAMPLE=$1 + ;; + *) + echo "Wrong example name" + show_usage + exit 2 + ;; +esac + +if [[ "$EXAMPLE" == "unit-tests" ]]; then + if [ ! -z "$2" ]; then + if [[ " ${TEST_NAMES[*]} " =~ " $2 " ]]; then + if [[ "$COMMAND" != *"run"* ]]; then + echo "Test suites can only accept --command run" + show_usage + exit 2 + fi + EXAMPLE=$2 + echo "Run specific unit test $EXAMPLE" + elif [[ "$2" == "all" ]]; then + echo "Use all unit tests" + else + echo " Wrong unit test name" + show_usage + exit 2 + fi + else + echo "Use all unit tests" + fi + IS_TEST=1 +fi + +case "$COMMAND" in + build | run | test | build-run) ;; + *) + echo "Wrong command definition" + show_usage + exit 2 + ;; +esac + +TOOLCHAIN_PATH="toolchains/toolchain-$TOOLCHAIN.cmake" + +if [[ $IS_TEST -eq 0 ]]; then + EXAMPLE_PATH="$CHIP_ROOT/examples/$EXAMPLE/openiotsdk" +else + EXAMPLE_PATH="$CHIP_ROOT/src/test_driver/openiotsdk/unit-tests" + if [[ -f $EXAMPLE_PATH/test_report.json ]]; then + rm -rf "$EXAMPLE_PATH"/test_report.json + fi + echo "{}" >"$EXAMPLE_PATH"/test_report.json +fi + +if [ -z "$BUILD_PATH" ]; then + BUILD_PATH="$EXAMPLE_PATH/build" +fi + +if [[ "$COMMAND" == *"build"* ]]; then + build_with_cmake +fi + +if [[ "$COMMAND" == *"run"* ]]; then + # If user wants to run unit-tests we need to loop through all test names + if [[ "$EXAMPLE" == "unit-tests" ]]; then + if "$DEBUG"; then + echo "You have to specify the test suites to run in debug mode" + show_usage + exit 2 + else + for NAME in "${TEST_NAMES[@]}"; do + EXAMPLE=$NAME + echo "$EXAMPLE_PATH" + echo "Run specific unit test $EXAMPLE" + run_fvp + done + echo "Failed tests total: $FAILED_TESTS" + fi + else + run_fvp + fi +fi + +if [[ "$COMMAND" == *"test"* ]]; then + if [[ "$EXAMPLE" == "unit-tests" ]]; then + echo "The test command can not be applied to the unit-tests example" + show_usage + exit 2 + else + IS_TEST=1 + run_test + fi +fi + +if [[ $IS_TEST -eq 1 ]]; then + exit "$FAILED_TESTS" +fi diff --git a/scripts/helpers/iwyu-check.py b/scripts/helpers/iwyu-check.py new file mode 100755 index 00000000000000..f4419ccd99ff10 --- /dev/null +++ b/scripts/helpers/iwyu-check.py @@ -0,0 +1,200 @@ +#!/usr/bin/env -S python3 -B + +# Copyright (c) 2021 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import contextlib +import glob +import json +import logging +import os +import re +import shutil +import subprocess +import sys +from pathlib import Path + +import click +import coloredlogs + +# Supported log levels, mapping string values required for argument +# parsing into logging constants +__LOG_LEVELS__ = { + 'debug': logging.DEBUG, + 'info': logging.INFO, + 'warn': logging.WARN, + 'fatal': logging.FATAL, +} + +root_dir = os.path.dirname(os.path.realpath(__file__)) +proj_root_dir = os.path.join(Path(root_dir).parent.parent) + + +def find_program(names): + for name in names: + found = shutil.which(name) + if found is not None: + return found + + +@click.command() +@click.option( + '--log-level', + default='INFO', + type=click.Choice(__LOG_LEVELS__.keys(), case_sensitive=False), + help='Determines the verbosity of script output.') +@click.option( + '--no-log-timestamps', + default=False, + is_flag=True, + help='Skip timestamps in log output') +@click.option( + '--compile-commands-glob', + show_default=True, + default=os.path.join(proj_root_dir, "out", "debug", "compile_commands*.json"), + help='Set global pattern for compile_commands.json files' +) +@click.option( + '--scanning-destination', + show_default=True, + default=os.path.join(proj_root_dir, "src", "platform"), + help='Set scanning destination file(s) or directory /ies in project' +) +@click.option( + '--mapping-file-dir', + help='Set mapping file directory /ies manually. File should have name iwyu.imp' +) +@click.option( + '--iwyu-args', + show_default=True, + default="-Xiwyu --no_fwd_decls", + help='Set custom arg(s) for include what you use' +) +@click.option( + '--clang-args', + default="", + help='Set custom arg(s) for clang' +) +def main(compile_commands_glob, scanning_destination, mapping_file_dir, + iwyu_args, clang_args, log_level, no_log_timestamps): + # Ensures somewhat pretty logging of what is going on + log_fmt = '%(asctime)s %(levelname)-7s %(message)s' + if no_log_timestamps: + log_fmt = '%(levelname)-7s %(message)s' + coloredlogs.install(level=__LOG_LEVELS__[log_level], fmt=log_fmt) + + # checking if a program IWYU exists + iwyu = find_program(('iwyu_tool', 'iwyu_tool.py')) + + if iwyu is None: + logging.error("Can't find IWYU") + sys.exit(1) + + # For iterating how many files had problems with includes + warning_in_files = 0 + + platform = "" + compile_commands_glob = glob.glob(compile_commands_glob) + + if not compile_commands_glob: + logging.error("Can't find compile_commands.json file(s)") + sys.exit(1) + + for compile_commands in compile_commands_glob: + + compile_commands_path = os.path.dirname(compile_commands) + compile_commands_file = os.path.join(compile_commands_path, "compile_commands.json") + logging.debug("Copy compile command file %s to %s", compile_commands, compile_commands_file) + + with contextlib.suppress(shutil.SameFileError): + shutil.copyfile(compile_commands, compile_commands_file) + + # Prase json file for find target name + with open(compile_commands, 'r') as json_data: + json_data = json.load(json_data) + + for key in json_data: + find_re = re.search(r'^.*/src/platform*?\/(.*)/.*$', key['file']) + if find_re is not None: + platform = find_re.group(1) + break + if not platform: + logging.error("Can't find platform") + sys.exit(1) + + if not mapping_file_dir: + mapping_file_dir = os.path.join(root_dir, "platforms", platform) + + # Platform specific clang arguments, as some platform + # may needed some hacks for clang compiler for work properly. + platform_clang_args = [] + + if platform == "Tizen": + platform_clang_args = [ + "--target=arm-linux-gnueabi", + "-I$TIZEN_SDK_TOOLCHAIN/arm-tizen-linux-gnueabi/include/c++/9.2.0", + "-I$TIZEN_SDK_TOOLCHAIN/arm-tizen-linux-gnueabi/include/c++/9.2.0/arm-tizen-linux-gnueabi", + "-I$TIZEN_SDK_TOOLCHAIN/lib/gcc/arm-tizen-linux-gnueabi/9.2.0/include", + ] + + # TODO: Add another platform for easy scanning + # Actually works scanning for platform: tizen, darwin, linux other not tested yet. + + command_arr = [ + iwyu, + "-p", compile_commands_path, scanning_destination, + "--", iwyu_args, + "-Xiwyu", "--mapping_file=" + mapping_file_dir + "/iwyu.imp", + ] + platform_clang_args + [clang_args] + + logging.info("Used compile commands: %s", compile_commands) + logging.info("Scanning includes for platform: %s", platform) + logging.info("Scanning destination: %s", scanning_destination) + + logging.debug("Command: %s", " ".join(command_arr)) + status = subprocess.Popen(" ".join(command_arr), + shell=True, + text=True, + stdout=subprocess.PIPE, + stderr=subprocess.STDOUT) + + logging.info("============== IWYU output start ================") + + logger = logging.info + while status.poll() is None: + line = status.stdout.readline().rstrip() + + if re.match(r"^warning:.*$", line): + logger = logging.warning + elif re.match(r"^.*([A-Za-z0-9]+(/[A-Za-z0-9]+)+)\.cpp should [a-zA-Z]+ these lines:$", line): + logger = logging.warning + elif re.match(r"^.*([A-Za-z0-9]+(/[A-Za-z0-9]+)+)\.[a-zA-Z]+ has correct #includes/fwd-decls\)$", line): + logger = logging.info + elif re.match(r"^The full include-list for .*$", line): + logger = logging.warning + warning_in_files += 1 + + logger("%s", line) + + logging.info("============== IWYU output end ================") + + if warning_in_files: + logging.error("Number of files with include issues: %d", warning_in_files) + sys.exit(2) + else: + logging.info("Every include looks good!") + + +if __name__ == '__main__': + main(auto_envvar_prefix='CHIP') diff --git a/scripts/helpers/platforms/Darwin/iwyu.imp b/scripts/helpers/platforms/Darwin/iwyu.imp new file mode 100644 index 00000000000000..0364fe5e198361 --- /dev/null +++ b/scripts/helpers/platforms/Darwin/iwyu.imp @@ -0,0 +1,3 @@ +[ + { ref: "../iwyu.imp" }, +] diff --git a/scripts/helpers/platforms/EFR32/iwyu.imp b/scripts/helpers/platforms/EFR32/iwyu.imp new file mode 100644 index 00000000000000..0364fe5e198361 --- /dev/null +++ b/scripts/helpers/platforms/EFR32/iwyu.imp @@ -0,0 +1,3 @@ +[ + { ref: "../iwyu.imp" }, +] diff --git a/scripts/helpers/platforms/Linux/iwyu.imp b/scripts/helpers/platforms/Linux/iwyu.imp new file mode 100644 index 00000000000000..0364fe5e198361 --- /dev/null +++ b/scripts/helpers/platforms/Linux/iwyu.imp @@ -0,0 +1,3 @@ +[ + { ref: "../iwyu.imp" }, +] diff --git a/scripts/helpers/platforms/Tizen/iwyu.imp b/scripts/helpers/platforms/Tizen/iwyu.imp new file mode 100644 index 00000000000000..f314087060e005 --- /dev/null +++ b/scripts/helpers/platforms/Tizen/iwyu.imp @@ -0,0 +1,10 @@ +[ + { ref: "../iwyu.imp" }, + + { include: [ '"bluetooth_type.h"', private, '', public ] }, + { include: [ '"dns-sd.h"', private, '', public ] }, + { include: [ '"thread-type.h"', private, '', public ] }, + { include: [ '"thread.h"', private, '', public ] }, + { include: [ '', private, '', public ] }, + { include: [ '', private, '', public ] }, +] diff --git a/scripts/helpers/platforms/android/iwyu.imp b/scripts/helpers/platforms/android/iwyu.imp new file mode 100644 index 00000000000000..0364fe5e198361 --- /dev/null +++ b/scripts/helpers/platforms/android/iwyu.imp @@ -0,0 +1,3 @@ +[ + { ref: "../iwyu.imp" }, +] diff --git a/scripts/helpers/platforms/iwyu.imp b/scripts/helpers/platforms/iwyu.imp new file mode 100644 index 00000000000000..5a863b3f3a6208 --- /dev/null +++ b/scripts/helpers/platforms/iwyu.imp @@ -0,0 +1,42 @@ +[ + ## C/C++/* + { include: [ '"bits/shared_ptr.h"', private, '', public ] }, + { include: [ '"cstdlib"', private, '', public ] }, + { include: [ '"iosfwd"', private, '', public ] }, + { include: [ '"ostream"', private, '', public ] }, + { include: [ '"stdlib.h"', private, '', public ] }, + { include: [ '"thread"', private, '', public ] }, + { include: [ '"type_traits"', private, '', public ] }, + { include: [ '', private, '', public ] }, + { symbol: [ 'declval', private, '', public ] }, + { symbol: [ 'tm', private, '', public ] }, + + ## ble/* + { include: [ '"ble/CHIPBleServiceData.h"', private, '', public ] }, + { include: [ '@"ble/Ble.*.h"', private, '', public ] }, + + ## inet/* + { include: [ '"inet/InetInterface.h"', private, '', public ] }, + { include: [ '"inet/IPAddress.h"', private, '', public ] }, + + ## lib/* + { include: [ '"lib/core/CHIPError.h"', private, '', public ] }, + { include: [ '"lib/dnssd/ServiceNaming.h"', private, '', public ] }, + { include: [ '"lib/support/logging/CHIPLogging.h"', private, '', public ] }, + + ## platform/* + { include: [ '"platform/NetworkCommissioning.h"', private, '', public ] }, + { include: [ '"platform/PersistedStorage.h"', private, '', public ] }, + + ## Do not include some Impl headers directly + { include: [ '@"platform/.*/BLEManagerImpl.h"', private, '"platform/internal/BLEManager.h"', private ] }, + { include: [ '@"platform/.*/ConnectivityManagerImpl.h"', private, '', public ] }, + { include: [ '@"platform/.*/KeyValueStoreManagerImpl.h"', private, '', public ] }, + { include: [ '@"platform/.*/PlatformManagerImpl.h"', private, '', public ] }, + { include: [ '@', private, '', public ] }, + + ## Config + { include: [ '@"platform/.*/CHIPDevicePlatformConfig.h"', private, '', public ] }, + { include: [ '@"platform/.*/SystemPlatformConfig.h"', private, '', public ] }, + +] diff --git a/scripts/helpers/platforms/mbed/iwyu.imp b/scripts/helpers/platforms/mbed/iwyu.imp new file mode 100644 index 00000000000000..0364fe5e198361 --- /dev/null +++ b/scripts/helpers/platforms/mbed/iwyu.imp @@ -0,0 +1,3 @@ +[ + { ref: "../iwyu.imp" }, +] diff --git a/scripts/helpers/restyle-diff.sh b/scripts/helpers/restyle-diff.sh index 4701b0a7e7710a..bf428dc1ea7a17 100755 --- a/scripts/helpers/restyle-diff.sh +++ b/scripts/helpers/restyle-diff.sh @@ -33,9 +33,12 @@ set -e CHIP_ROOT=$(cd "$here/../.." && pwd) restyle-paths() { - url=https://github.com/restyled-io/restyler/raw/main/bin/restyle-path - - sh <(curl --location --proto "=https" --tlsv1.2 "$url" -sSf) "$@" + if hash restyle-path 2>/dev/null; then + command restyle-path "$@" + else + url=https://github.com/restyled-io/restyler/raw/main/bin/restyle-path + sh <(curl --location --proto "=https" --tlsv1.2 "$url" -sSf) "$@" + fi } cd "$CHIP_ROOT" diff --git a/scripts/idl/BUILD.gn b/scripts/idl/BUILD.gn index 359f50e89d4159..324ed3a737bbf0 100644 --- a/scripts/idl/BUILD.gn +++ b/scripts/idl/BUILD.gn @@ -18,20 +18,15 @@ import("//build_overrides/chip.gni") import("//build_overrides/pigweed.gni") import("$dir_pw_build/python.gni") +import("${chip_root}/scripts/idl/files.gni") + pw_python_package("idl") { setup = [ "setup.py" ] - inputs = [ + inputs = matter_idl_generator_templates + inputs += [ # Dependency grammar "matter_grammar.lark", - # Templates used for generation - "generators/bridge/BridgeClustersCpp.jinja", - "generators/bridge/BridgeClustersCommon.jinja", - "generators/bridge/BridgeClustersGlobalStructs.jinja", - "generators/java/ChipClustersCpp.jinja", - "generators/java/ChipClustersRead.jinja", - "generators/cpp/application/PluginApplicationCallbacksHeader.jinja", - # Unit test data "tests/available_tests.yaml", "tests/inputs/cluster_struct_attribute.matter", @@ -70,25 +65,7 @@ pw_python_package("idl") { "tests/outputs/simple_attribute/jni/MyClusterClient-InvokeSubscribeImpl.cpp", ] - sources = [ - "__init__.py", - "generators/__init__.py", - "generators/bridge/__init__.py", - "generators/cpp/__init__.py", - "generators/cpp/application/__init__.py", - "generators/filters.py", - "generators/java/__init__.py", - "generators/types.py", - "matter_idl_parser.py", - "matter_idl_types.py", - "xml_parser.py", - "zapxml/__init__.py", - "zapxml/handlers/__init__.py", - "zapxml/handlers/base.py", - "zapxml/handlers/context.py", - "zapxml/handlers/handlers.py", - "zapxml/handlers/parsing.py", - ] + sources = matter_idl_generator_sources tests = [ "test_matter_idl_parser.py", diff --git a/scripts/idl/files.gni b/scripts/idl/files.gni new file mode 100644 index 00000000000000..997f1eab8b06c5 --- /dev/null +++ b/scripts/idl/files.gni @@ -0,0 +1,37 @@ +import("//build_overrides/build.gni") +import("//build_overrides/chip.gni") + +# Templates used for generation +matter_idl_generator_templates = [ + "${chip_root}/scripts/idl/generators/bridge/BridgeClustersCpp.jinja", + "${chip_root}/scripts/idl/generators/bridge/BridgeClustersCommon.jinja", + "${chip_root}/scripts/idl/generators/bridge/BridgeClustersGlobalStructs.jinja", + "${chip_root}/scripts/idl/generators/java/ChipClustersCpp.jinja", + "${chip_root}/scripts/idl/generators/java/ChipClustersRead.jinja", + "${chip_root}/scripts/idl/generators/cpp/application/CallbackStubSource.jinja", + "${chip_root}/scripts/idl/generators/cpp/application/PluginApplicationCallbacksHeader.jinja", +] + +matter_idl_generator_sources = [ + "${chip_root}/scripts/idl/__init__.py", + "${chip_root}/scripts/idl/generators/__init__.py", + "${chip_root}/scripts/idl/generators/bridge/__init__.py", + "${chip_root}/scripts/idl/generators/cpp/__init__.py", + "${chip_root}/scripts/idl/generators/cpp/application/__init__.py", + "${chip_root}/scripts/idl/generators/filters.py", + "${chip_root}/scripts/idl/generators/java/__init__.py", + "${chip_root}/scripts/idl/generators/types.py", + "${chip_root}/scripts/idl/matter_idl_parser.py", + "${chip_root}/scripts/idl/matter_idl_types.py", + "${chip_root}/scripts/idl/xml_parser.py", + "${chip_root}/scripts/idl/zapxml/__init__.py", + "${chip_root}/scripts/idl/zapxml/handlers/__init__.py", + "${chip_root}/scripts/idl/zapxml/handlers/base.py", + "${chip_root}/scripts/idl/zapxml/handlers/context.py", + "${chip_root}/scripts/idl/zapxml/handlers/handlers.py", + "${chip_root}/scripts/idl/zapxml/handlers/parsing.py", +] + +# All the files that the matter idl infrastructure will use +matter_idl_generator_files = + matter_idl_generator_templates + matter_idl_generator_sources diff --git a/scripts/idl/generators/bridge/BridgeClustersGlobalStructs.jinja b/scripts/idl/generators/bridge/BridgeClustersGlobalStructs.jinja index 26a8dfa2ec4d81..0fcee9b1efe45d 100644 --- a/scripts/idl/generators/bridge/BridgeClustersGlobalStructs.jinja +++ b/scripts/idl/generators/bridge/BridgeClustersGlobalStructs.jinja @@ -1,6 +1,5 @@ #pragma once -#include #include #include diff --git a/scripts/idl/generators/bridge/BridgeClustersHeader.jinja b/scripts/idl/generators/bridge/BridgeClustersHeader.jinja index 3ad37a63ed5821..66aebf7d9d02cd 100644 --- a/scripts/idl/generators/bridge/BridgeClustersHeader.jinja +++ b/scripts/idl/generators/bridge/BridgeClustersHeader.jinja @@ -1,4 +1,3 @@ -#include #include #include diff --git a/scripts/idl/generators/cpp/application/CallbackStubSource.jinja b/scripts/idl/generators/cpp/application/CallbackStubSource.jinja index e17cb3b6fca286..cd800400dc4d10 100644 --- a/scripts/idl/generators/cpp/application/CallbackStubSource.jinja +++ b/scripts/idl/generators/cpp/application/CallbackStubSource.jinja @@ -1,5 +1,5 @@ #include -#include +#include #include #include @@ -11,7 +11,7 @@ void emberAfClusterInitCallback(EndpointId endpoint, ClusterId clusterId) switch (clusterId) { {%- for name in clusters | sort(attribute='name') | map(attribute='name') | unique %} - case ZCL_{{name | normalize_acronyms | constcase}}_CLUSTER_ID: + case app::Clusters::{{name}}::Id: emberAf{{name}}ClusterInitCallback(endpoint); break; {%- endfor %} diff --git a/scripts/idl/lint/lint_rules_parser.py b/scripts/idl/lint/lint_rules_parser.py index 9af6b8c0f05724..fdd507cdbc383e 100755 --- a/scripts/idl/lint/lint_rules_parser.py +++ b/scripts/idl/lint/lint_rules_parser.py @@ -306,4 +306,4 @@ def main(log_level, filename=None): logging.info("Data:") logging.info("%r" % data) - main() + main(auto_envvar_prefix='CHIP') diff --git a/scripts/idl/matter_grammar.lark b/scripts/idl/matter_grammar.lark index 020283cfbdd807..a63f97e385bb5b 100644 --- a/scripts/idl/matter_grammar.lark +++ b/scripts/idl/matter_grammar.lark @@ -59,7 +59,7 @@ cluster: cluster_side "cluster"i id "=" positive_integer "{" (enum|bitmap|event| endpoint: "endpoint"i positive_integer "{" endpoint_content* "}" ?endpoint_content: endpoint_cluster_binding | endpoint_server_cluster | endpoint_device_type -endpoint_device_type: "device" "type" id "=" positive_integer ";" +endpoint_device_type: "device" "type" id "=" positive_integer "," "version" positive_integer ";" endpoint_cluster_binding: "binding"i "cluster"i id ";" endpoint_server_cluster: "server"i "cluster"i id "{" endpoint_attribute_instantiation* "}" diff --git a/scripts/idl/matter_idl_parser.py b/scripts/idl/matter_idl_parser.py index e694a7a7aec7c9..0864db3fe6f578 100755 --- a/scripts/idl/matter_idl_parser.py +++ b/scripts/idl/matter_idl_parser.py @@ -1,8 +1,8 @@ #!/usr/bin/env python -import enum import functools import logging +from enum import Enum from lark import Lark from lark.visitors import Transformer, v_args @@ -61,7 +61,7 @@ def apply(self, endpoint): class MatterIdlTransformer(Transformer): """ - A transformer capable to transform data parsed by Lark according to + A transformer capable to transform data parsed by Lark according to matter_grammar.lark. Generally transforms a ".matter" file into an Abstract Syntax Tree (AST). @@ -72,7 +72,7 @@ class MatterIdlTransformer(Transformer): purpose is to convert LARK tokens (that ar generally inputted by name) into underlying python types. - Some documentation to get started is available at + Some documentation to get started is available at https://lark-parser.readthedocs.io/en/latest/visitors.html#transformer TLDR would be: @@ -299,7 +299,8 @@ def attribute_with_access(self, args): elif operation == AttributeOperation.WRITE: acl['writeacl'] = access else: - raise Exception("Unknown attribute operation: %r" % operation) + raise Exception( + "Unknown attribute operation: %r" % operation) return (args[-1], acl) @@ -357,8 +358,8 @@ def endpoint(self, number, *transforms): return endpoint @v_args(inline=True) - def endpoint_device_type(self, name, code): - return AddDeviceTypeToEndpointTransform(DeviceType(name=name, code=code)) + def endpoint_device_type(self, name, code, version): + return AddDeviceTypeToEndpointTransform(DeviceType(name=name, code=code, version=version)) @v_args(inline=True) def endpoint_cluster_binding(self, id): @@ -417,7 +418,8 @@ def __init__(self, parser, skip_meta: bool): self.skip_meta = skip_meta def parse(self, file, file_name: str = None): - idl = MatterIdlTransformer(self.skip_meta).transform(self.parser.parse(file)) + idl = MatterIdlTransformer(self.skip_meta).transform( + self.parser.parse(file)) idl.parse_file_name = file_name return idl @@ -438,9 +440,10 @@ def CreateParser(skip_meta: bool = False): if __name__ == '__main__': # This Parser is generally not intended to be run as a stand-alone binary. # The ability to run is for debug and to print out the parsed AST. + import pprint + import click import coloredlogs - import pprint # Supported log levels, mapping string values required for argument # parsing into logging constants @@ -469,4 +472,4 @@ def main(log_level, filename=None): logging.info("Data:") pprint.pp(data) - main() + main(auto_envvar_prefix='CHIP') diff --git a/scripts/idl/matter_idl_types.py b/scripts/idl/matter_idl_types.py index ba66e4cad643ad..0971867ab3c82a 100644 --- a/scripts/idl/matter_idl_types.py +++ b/scripts/idl/matter_idl_types.py @@ -232,6 +232,7 @@ class ServerClusterInstantiation: class DeviceType: name: str code: int + version: int @dataclass diff --git a/scripts/idl/test_matter_idl_parser.py b/scripts/idl/test_matter_idl_parser.py index d200c3914b616f..8b7d24a22355ac 100755 --- a/scripts/idl/test_matter_idl_parser.py +++ b/scripts/idl/test_matter_idl_parser.py @@ -81,7 +81,8 @@ def test_global_struct(self): data_type=DataType(name="CHAR_STRING"), code=1, name="astring", ), Field(data_type=DataType(name="CLUSTER_ID"), code=2, name="idlist", is_list=True, qualities=FieldQuality.OPTIONAL), - Field(data_type=DataType(name="int"), code=0x123, name="valueThatIsNullable", qualities=FieldQuality.NULLABLE), + Field(data_type=DataType(name="int"), code=0x123, + name="valueThatIsNullable", qualities=FieldQuality.NULLABLE), Field(data_type=DataType(name="char_string", max_length=123), code=222, name="sized_string"), ])] @@ -224,7 +225,8 @@ def test_cluster_commands(self): Struct(name="FreeStruct", fields=[]), Struct(name="InParam", fields=[], tag=StructTag.REQUEST), - Struct(name="OutParam", fields=[], tag=StructTag.RESPONSE, code=223), + Struct(name="OutParam", fields=[], + tag=StructTag.RESPONSE, code=223), ], commands=[ Command(name="WithoutArg", code=123, @@ -262,7 +264,8 @@ def test_cluster_command_access(self): structs=[ Struct(name="InParam", fields=[], tag=StructTag.REQUEST), - Struct(name="OutParam", fields=[], tag=StructTag.RESPONSE, code=4), + Struct(name="OutParam", fields=[], + tag=StructTag.RESPONSE, code=4), ], commands=[ Command(name="WithoutArg", code=1, @@ -403,8 +406,10 @@ def test_parsing_metadata_for_cluster(self): """) expected = Idl(clusters=[ - Cluster(parse_meta=ParseMetaData(line=2, column=1), side=ClusterSide.SERVER, name="A", code=1), - Cluster(parse_meta=ParseMetaData(line=5, column=4), side=ClusterSide.CLIENT, name="B", code=2), + Cluster(parse_meta=ParseMetaData(line=2, column=1), + side=ClusterSide.SERVER, name="A", code=1), + Cluster(parse_meta=ParseMetaData(line=5, column=4), + side=ClusterSide.CLIENT, name="B", code=2), ]) self.assertEqual(actual, expected) @@ -425,8 +430,8 @@ def test_multiple_clusters(self): def test_endpoints(self): actual = parseText(""" endpoint 12 { - device type foo = 123; - device type bar = 0xFF; + device type foo = 123, version 1; + device type bar = 0xFF, version 2; server cluster Foo { } server cluster Bar { } @@ -437,12 +442,16 @@ def test_endpoints(self): expected = Idl(endpoints=[Endpoint(number=12, device_types=[ - DeviceType(name="foo", code=123), - DeviceType(name="bar", code=0xFF), + DeviceType( + name="foo", code=123, version=1), + DeviceType( + name="bar", code=0xFF, version=2), ], server_clusters=[ - ServerClusterInstantiation(name="Foo"), - ServerClusterInstantiation(name="Bar"), + ServerClusterInstantiation( + name="Foo"), + ServerClusterInstantiation( + name="Bar"), ], client_bindings=["Bar", "Test"],) ]) @@ -465,10 +474,12 @@ def test_cluster_instantiation(self): expected = Idl(endpoints=[Endpoint(number=3, server_clusters=[ ServerClusterInstantiation(name="Example", attributes=[ - AttributeInstantiation(name='inRamZero', storage=AttributeStorage.RAM), + AttributeInstantiation( + name='inRamZero', storage=AttributeStorage.RAM), AttributeInstantiation(name='inRamWithDefault', storage=AttributeStorage.RAM, default=123), - AttributeInstantiation(name='inNVMNoDef', storage=AttributeStorage.PERSIST), + AttributeInstantiation( + name='inNVMNoDef', storage=AttributeStorage.PERSIST), AttributeInstantiation( name='inNVMStr', storage=AttributeStorage.PERSIST, default="abc"), AttributeInstantiation(name='inNVMWithDefault', diff --git a/scripts/idl/test_xml_parser.py b/scripts/idl/test_xml_parser.py index 4a43d3fea717b3..932a5731d59268 100755 --- a/scripts/idl/test_xml_parser.py +++ b/scripts/idl/test_xml_parser.py @@ -97,15 +97,15 @@ def testCluster(self): structs=[ Struct(name='GetSomeDataRequest', fields=[ - Field(data_type=DataType(name='INT8U'), code=1, name='firstInput'), - Field(data_type=DataType(name='INT16U'), code=2, name='secondInput') + Field(data_type=DataType(name='INT8U'), code=0, name='firstInput'), + Field(data_type=DataType(name='INT16U'), code=1, name='secondInput') ], tag=StructTag.REQUEST), Struct(name='GetSomeDataResponse', fields=[ - Field(data_type=DataType(name='INT8U'), code=1, + Field(data_type=DataType(name='INT8U'), code=0, name='dataPoint1'), - Field(data_type=DataType(name='INT8U'), code=2, name='dataPoint2', + Field(data_type=DataType(name='INT8U'), code=1, name='dataPoint2', qualities=FieldQuality.OPTIONAL) ], tag=StructTag.RESPONSE, code=0x44) @@ -226,8 +226,8 @@ def testStruct(self): name='SomeStruct', qualities=StructQuality.FABRIC_SCOPED, fields=[ - Field(data_type=DataType(name='int16u'), code=1, name='FirstMember'), - Field(data_type=DataType(name='int32u'), code=2, name='SecondMember') + Field(data_type=DataType(name='int16u'), code=0, name='FirstMember'), + Field(data_type=DataType(name='int32u'), code=1, name='SecondMember') ] ) self.assertEqual(idl, diff --git a/scripts/idl/tests/inputs/large_all_clusters_app.matter b/scripts/idl/tests/inputs/large_all_clusters_app.matter index 62cf85754d8560..6cadd621bc383b 100644 --- a/scripts/idl/tests/inputs/large_all_clusters_app.matter +++ b/scripts/idl/tests/inputs/large_all_clusters_app.matter @@ -3875,7 +3875,7 @@ server cluster FaultInjection = 4294048774 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Identify { @@ -4202,7 +4202,7 @@ endpoint 0 { } } endpoint 1 { - device type onofflight = 256; + device type onofflight = 256, version 1; server cluster Identify { ram attribute identifyTime; @@ -4792,7 +4792,7 @@ endpoint 1 { } } endpoint 2 { - device type onofflight = 256; + device type onofflight = 256, version 1; server cluster Groups { ram attribute nameSupport; @@ -4839,7 +4839,7 @@ endpoint 2 { } } endpoint 65534 { - device type anonymousEndpointType = 61442; + device type anonymousEndpointType = 61442, version 1; server cluster NetworkCommissioning { callback attribute maxNetworks; diff --git a/scripts/idl/tests/inputs/large_lighting_app.matter b/scripts/idl/tests/inputs/large_lighting_app.matter index d685bdd9abf0e8..b4097981369589 100644 --- a/scripts/idl/tests/inputs/large_lighting_app.matter +++ b/scripts/idl/tests/inputs/large_lighting_app.matter @@ -1701,7 +1701,7 @@ server cluster OccupancySensing = 1030 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster OtaSoftwareUpdateProvider; server cluster Groups { @@ -1976,7 +1976,7 @@ endpoint 0 { } } endpoint 1 { - device type dimmablelight = 257; + device type dimmablelight = 257, version 1; server cluster Identify { ram attribute identifyTime; diff --git a/scripts/idl/tests/inputs/several_clusters.matter b/scripts/idl/tests/inputs/several_clusters.matter index 48832dd150a945..4451abbe828d69 100644 --- a/scripts/idl/tests/inputs/several_clusters.matter +++ b/scripts/idl/tests/inputs/several_clusters.matter @@ -32,7 +32,7 @@ server cluster Third = 3 { } endpoint 0 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster Second; server cluster Third { diff --git a/scripts/idl/tests/outputs/cluster_struct_attribute/bridge/BridgeGlobalStructs.h b/scripts/idl/tests/outputs/cluster_struct_attribute/bridge/BridgeGlobalStructs.h index d2a3def71c2189..3b56a6f868b109 100644 --- a/scripts/idl/tests/outputs/cluster_struct_attribute/bridge/BridgeGlobalStructs.h +++ b/scripts/idl/tests/outputs/cluster_struct_attribute/bridge/BridgeGlobalStructs.h @@ -1,6 +1,5 @@ #pragma once -#include #include #include diff --git a/scripts/idl/tests/outputs/global_struct_attribute/bridge/BridgeGlobalStructs.h b/scripts/idl/tests/outputs/global_struct_attribute/bridge/BridgeGlobalStructs.h index a85ccfa9ad2cd4..4b67ca9cbaeefe 100644 --- a/scripts/idl/tests/outputs/global_struct_attribute/bridge/BridgeGlobalStructs.h +++ b/scripts/idl/tests/outputs/global_struct_attribute/bridge/BridgeGlobalStructs.h @@ -1,6 +1,5 @@ #pragma once -#include #include #include diff --git a/scripts/idl/tests/outputs/large_all_clusters_app/cpp-app/callback-stub.cpp b/scripts/idl/tests/outputs/large_all_clusters_app/cpp-app/callback-stub.cpp index 7ed6c62053575d..a0bc3f39be80be 100644 --- a/scripts/idl/tests/outputs/large_all_clusters_app/cpp-app/callback-stub.cpp +++ b/scripts/idl/tests/outputs/large_all_clusters_app/cpp-app/callback-stub.cpp @@ -1,5 +1,5 @@ #include -#include +#include #include #include @@ -10,196 +10,196 @@ void emberAfClusterInitCallback(EndpointId endpoint, ClusterId clusterId) { switch (clusterId) { - case ZCL_ACCESS_CONTROL_CLUSTER_ID: + case app::Clusters::AccessControl::Id: emberAfAccessControlClusterInitCallback(endpoint); break; - case ZCL_ACCOUNT_LOGIN_CLUSTER_ID: + case app::Clusters::AccountLogin::Id: emberAfAccountLoginClusterInitCallback(endpoint); break; - case ZCL_ACTIONS_CLUSTER_ID: + case app::Clusters::Actions::Id: emberAfActionsClusterInitCallback(endpoint); break; - case ZCL_ADMINISTRATOR_COMMISSIONING_CLUSTER_ID: + case app::Clusters::AdministratorCommissioning::Id: emberAfAdministratorCommissioningClusterInitCallback(endpoint); break; - case ZCL_APPLICATION_BASIC_CLUSTER_ID: + case app::Clusters::ApplicationBasic::Id: emberAfApplicationBasicClusterInitCallback(endpoint); break; - case ZCL_APPLICATION_LAUNCHER_CLUSTER_ID: + case app::Clusters::ApplicationLauncher::Id: emberAfApplicationLauncherClusterInitCallback(endpoint); break; - case ZCL_AUDIO_OUTPUT_CLUSTER_ID: + case app::Clusters::AudioOutput::Id: emberAfAudioOutputClusterInitCallback(endpoint); break; - case ZCL_BARRIER_CONTROL_CLUSTER_ID: + case app::Clusters::BarrierControl::Id: emberAfBarrierControlClusterInitCallback(endpoint); break; - case ZCL_BASIC_CLUSTER_ID: + case app::Clusters::Basic::Id: emberAfBasicClusterInitCallback(endpoint); break; - case ZCL_BINARY_INPUT_BASIC_CLUSTER_ID: + case app::Clusters::BinaryInputBasic::Id: emberAfBinaryInputBasicClusterInitCallback(endpoint); break; - case ZCL_BINDING_CLUSTER_ID: + case app::Clusters::Binding::Id: emberAfBindingClusterInitCallback(endpoint); break; - case ZCL_BOOLEAN_STATE_CLUSTER_ID: + case app::Clusters::BooleanState::Id: emberAfBooleanStateClusterInitCallback(endpoint); break; - case ZCL_CHANNEL_CLUSTER_ID: + case app::Clusters::Channel::Id: emberAfChannelClusterInitCallback(endpoint); break; - case ZCL_COLOR_CONTROL_CLUSTER_ID: + case app::Clusters::ColorControl::Id: emberAfColorControlClusterInitCallback(endpoint); break; - case ZCL_CONTENT_LAUNCHER_CLUSTER_ID: + case app::Clusters::ContentLauncher::Id: emberAfContentLauncherClusterInitCallback(endpoint); break; - case ZCL_DESCRIPTOR_CLUSTER_ID: + case app::Clusters::Descriptor::Id: emberAfDescriptorClusterInitCallback(endpoint); break; - case ZCL_DIAGNOSTIC_LOGS_CLUSTER_ID: + case app::Clusters::DiagnosticLogs::Id: emberAfDiagnosticLogsClusterInitCallback(endpoint); break; - case ZCL_DOOR_LOCK_CLUSTER_ID: + case app::Clusters::DoorLock::Id: emberAfDoorLockClusterInitCallback(endpoint); break; - case ZCL_ELECTRICAL_MEASUREMENT_CLUSTER_ID: + case app::Clusters::ElectricalMeasurement::Id: emberAfElectricalMeasurementClusterInitCallback(endpoint); break; - case ZCL_ETHERNET_NETWORK_DIAGNOSTICS_CLUSTER_ID: + case app::Clusters::EthernetNetworkDiagnostics::Id: emberAfEthernetNetworkDiagnosticsClusterInitCallback(endpoint); break; - case ZCL_FAN_CONTROL_CLUSTER_ID: + case app::Clusters::FanControl::Id: emberAfFanControlClusterInitCallback(endpoint); break; - case ZCL_FAULT_INJECTION_CLUSTER_ID: + case app::Clusters::FaultInjection::Id: emberAfFaultInjectionClusterInitCallback(endpoint); break; - case ZCL_FIXED_LABEL_CLUSTER_ID: + case app::Clusters::FixedLabel::Id: emberAfFixedLabelClusterInitCallback(endpoint); break; - case ZCL_FLOW_MEASUREMENT_CLUSTER_ID: + case app::Clusters::FlowMeasurement::Id: emberAfFlowMeasurementClusterInitCallback(endpoint); break; - case ZCL_GENERAL_COMMISSIONING_CLUSTER_ID: + case app::Clusters::GeneralCommissioning::Id: emberAfGeneralCommissioningClusterInitCallback(endpoint); break; - case ZCL_GENERAL_DIAGNOSTICS_CLUSTER_ID: + case app::Clusters::GeneralDiagnostics::Id: emberAfGeneralDiagnosticsClusterInitCallback(endpoint); break; - case ZCL_GROUP_KEY_MANAGEMENT_CLUSTER_ID: + case app::Clusters::GroupKeyManagement::Id: emberAfGroupKeyManagementClusterInitCallback(endpoint); break; - case ZCL_GROUPS_CLUSTER_ID: + case app::Clusters::Groups::Id: emberAfGroupsClusterInitCallback(endpoint); break; - case ZCL_IDENTIFY_CLUSTER_ID: + case app::Clusters::Identify::Id: emberAfIdentifyClusterInitCallback(endpoint); break; - case ZCL_ILLUMINANCE_MEASUREMENT_CLUSTER_ID: + case app::Clusters::IlluminanceMeasurement::Id: emberAfIlluminanceMeasurementClusterInitCallback(endpoint); break; - case ZCL_KEYPAD_INPUT_CLUSTER_ID: + case app::Clusters::KeypadInput::Id: emberAfKeypadInputClusterInitCallback(endpoint); break; - case ZCL_LEVEL_CONTROL_CLUSTER_ID: + case app::Clusters::LevelControl::Id: emberAfLevelControlClusterInitCallback(endpoint); break; - case ZCL_LOCALIZATION_CONFIGURATION_CLUSTER_ID: + case app::Clusters::LocalizationConfiguration::Id: emberAfLocalizationConfigurationClusterInitCallback(endpoint); break; - case ZCL_LOW_POWER_CLUSTER_ID: + case app::Clusters::LowPower::Id: emberAfLowPowerClusterInitCallback(endpoint); break; - case ZCL_MEDIA_INPUT_CLUSTER_ID: + case app::Clusters::MediaInput::Id: emberAfMediaInputClusterInitCallback(endpoint); break; - case ZCL_MEDIA_PLAYBACK_CLUSTER_ID: + case app::Clusters::MediaPlayback::Id: emberAfMediaPlaybackClusterInitCallback(endpoint); break; - case ZCL_MODE_SELECT_CLUSTER_ID: + case app::Clusters::ModeSelect::Id: emberAfModeSelectClusterInitCallback(endpoint); break; - case ZCL_NETWORK_COMMISSIONING_CLUSTER_ID: + case app::Clusters::NetworkCommissioning::Id: emberAfNetworkCommissioningClusterInitCallback(endpoint); break; - case ZCL_OCCUPANCY_SENSING_CLUSTER_ID: + case app::Clusters::OccupancySensing::Id: emberAfOccupancySensingClusterInitCallback(endpoint); break; - case ZCL_ON_OFF_CLUSTER_ID: + case app::Clusters::OnOff::Id: emberAfOnOffClusterInitCallback(endpoint); break; - case ZCL_ON_OFF_SWITCH_CONFIGURATION_CLUSTER_ID: + case app::Clusters::OnOffSwitchConfiguration::Id: emberAfOnOffSwitchConfigurationClusterInitCallback(endpoint); break; - case ZCL_OPERATIONAL_CREDENTIALS_CLUSTER_ID: + case app::Clusters::OperationalCredentials::Id: emberAfOperationalCredentialsClusterInitCallback(endpoint); break; - case ZCL_OTA_SOFTWARE_UPDATE_PROVIDER_CLUSTER_ID: + case app::Clusters::OtaSoftwareUpdateProvider::Id: emberAfOtaSoftwareUpdateProviderClusterInitCallback(endpoint); break; - case ZCL_OTA_SOFTWARE_UPDATE_REQUESTOR_CLUSTER_ID: + case app::Clusters::OtaSoftwareUpdateRequestor::Id: emberAfOtaSoftwareUpdateRequestorClusterInitCallback(endpoint); break; - case ZCL_POWER_SOURCE_CLUSTER_ID: + case app::Clusters::PowerSource::Id: emberAfPowerSourceClusterInitCallback(endpoint); break; - case ZCL_POWER_SOURCE_CONFIGURATION_CLUSTER_ID: + case app::Clusters::PowerSourceConfiguration::Id: emberAfPowerSourceConfigurationClusterInitCallback(endpoint); break; - case ZCL_PRESSURE_MEASUREMENT_CLUSTER_ID: + case app::Clusters::PressureMeasurement::Id: emberAfPressureMeasurementClusterInitCallback(endpoint); break; - case ZCL_PUMP_CONFIGURATION_AND_CONTROL_CLUSTER_ID: + case app::Clusters::PumpConfigurationAndControl::Id: emberAfPumpConfigurationAndControlClusterInitCallback(endpoint); break; - case ZCL_RELATIVE_HUMIDITY_MEASUREMENT_CLUSTER_ID: + case app::Clusters::RelativeHumidityMeasurement::Id: emberAfRelativeHumidityMeasurementClusterInitCallback(endpoint); break; - case ZCL_SCENES_CLUSTER_ID: + case app::Clusters::Scenes::Id: emberAfScenesClusterInitCallback(endpoint); break; - case ZCL_SOFTWARE_DIAGNOSTICS_CLUSTER_ID: + case app::Clusters::SoftwareDiagnostics::Id: emberAfSoftwareDiagnosticsClusterInitCallback(endpoint); break; - case ZCL_SWITCH_CLUSTER_ID: + case app::Clusters::Switch::Id: emberAfSwitchClusterInitCallback(endpoint); break; - case ZCL_TARGET_NAVIGATOR_CLUSTER_ID: + case app::Clusters::TargetNavigator::Id: emberAfTargetNavigatorClusterInitCallback(endpoint); break; - case ZCL_TEMPERATURE_MEASUREMENT_CLUSTER_ID: + case app::Clusters::TemperatureMeasurement::Id: emberAfTemperatureMeasurementClusterInitCallback(endpoint); break; - case ZCL_THERMOSTAT_CLUSTER_ID: + case app::Clusters::Thermostat::Id: emberAfThermostatClusterInitCallback(endpoint); break; - case ZCL_THERMOSTAT_USER_INTERFACE_CONFIGURATION_CLUSTER_ID: + case app::Clusters::ThermostatUserInterfaceConfiguration::Id: emberAfThermostatUserInterfaceConfigurationClusterInitCallback(endpoint); break; - case ZCL_THREAD_NETWORK_DIAGNOSTICS_CLUSTER_ID: + case app::Clusters::ThreadNetworkDiagnostics::Id: emberAfThreadNetworkDiagnosticsClusterInitCallback(endpoint); break; - case ZCL_TIME_FORMAT_LOCALIZATION_CLUSTER_ID: + case app::Clusters::TimeFormatLocalization::Id: emberAfTimeFormatLocalizationClusterInitCallback(endpoint); break; - case ZCL_UNIT_LOCALIZATION_CLUSTER_ID: + case app::Clusters::UnitLocalization::Id: emberAfUnitLocalizationClusterInitCallback(endpoint); break; - case ZCL_UNIT_TESTING_CLUSTER_ID: + case app::Clusters::UnitTesting::Id: emberAfUnitTestingClusterInitCallback(endpoint); break; - case ZCL_USER_LABEL_CLUSTER_ID: + case app::Clusters::UserLabel::Id: emberAfUserLabelClusterInitCallback(endpoint); break; - case ZCL_WAKE_ON_LAN_CLUSTER_ID: + case app::Clusters::WakeOnLan::Id: emberAfWakeOnLanClusterInitCallback(endpoint); break; - case ZCL_WIFI_NETWORK_DIAGNOSTICS_CLUSTER_ID: + case app::Clusters::WiFiNetworkDiagnostics::Id: emberAfWiFiNetworkDiagnosticsClusterInitCallback(endpoint); break; - case ZCL_WINDOW_COVERING_CLUSTER_ID: + case app::Clusters::WindowCovering::Id: emberAfWindowCoveringClusterInitCallback(endpoint); break; default: diff --git a/scripts/idl/tests/outputs/large_lighting_app/cpp-app/callback-stub.cpp b/scripts/idl/tests/outputs/large_lighting_app/cpp-app/callback-stub.cpp index 57934f7f40ec20..54955e5a834a06 100644 --- a/scripts/idl/tests/outputs/large_lighting_app/cpp-app/callback-stub.cpp +++ b/scripts/idl/tests/outputs/large_lighting_app/cpp-app/callback-stub.cpp @@ -1,5 +1,5 @@ #include -#include +#include #include #include @@ -10,85 +10,85 @@ void emberAfClusterInitCallback(EndpointId endpoint, ClusterId clusterId) { switch (clusterId) { - case ZCL_ACCESS_CONTROL_CLUSTER_ID: + case app::Clusters::AccessControl::Id: emberAfAccessControlClusterInitCallback(endpoint); break; - case ZCL_ADMINISTRATOR_COMMISSIONING_CLUSTER_ID: + case app::Clusters::AdministratorCommissioning::Id: emberAfAdministratorCommissioningClusterInitCallback(endpoint); break; - case ZCL_BASIC_CLUSTER_ID: + case app::Clusters::Basic::Id: emberAfBasicClusterInitCallback(endpoint); break; - case ZCL_COLOR_CONTROL_CLUSTER_ID: + case app::Clusters::ColorControl::Id: emberAfColorControlClusterInitCallback(endpoint); break; - case ZCL_DESCRIPTOR_CLUSTER_ID: + case app::Clusters::Descriptor::Id: emberAfDescriptorClusterInitCallback(endpoint); break; - case ZCL_DIAGNOSTIC_LOGS_CLUSTER_ID: + case app::Clusters::DiagnosticLogs::Id: emberAfDiagnosticLogsClusterInitCallback(endpoint); break; - case ZCL_ETHERNET_NETWORK_DIAGNOSTICS_CLUSTER_ID: + case app::Clusters::EthernetNetworkDiagnostics::Id: emberAfEthernetNetworkDiagnosticsClusterInitCallback(endpoint); break; - case ZCL_FIXED_LABEL_CLUSTER_ID: + case app::Clusters::FixedLabel::Id: emberAfFixedLabelClusterInitCallback(endpoint); break; - case ZCL_GENERAL_COMMISSIONING_CLUSTER_ID: + case app::Clusters::GeneralCommissioning::Id: emberAfGeneralCommissioningClusterInitCallback(endpoint); break; - case ZCL_GENERAL_DIAGNOSTICS_CLUSTER_ID: + case app::Clusters::GeneralDiagnostics::Id: emberAfGeneralDiagnosticsClusterInitCallback(endpoint); break; - case ZCL_GROUP_KEY_MANAGEMENT_CLUSTER_ID: + case app::Clusters::GroupKeyManagement::Id: emberAfGroupKeyManagementClusterInitCallback(endpoint); break; - case ZCL_GROUPS_CLUSTER_ID: + case app::Clusters::Groups::Id: emberAfGroupsClusterInitCallback(endpoint); break; - case ZCL_IDENTIFY_CLUSTER_ID: + case app::Clusters::Identify::Id: emberAfIdentifyClusterInitCallback(endpoint); break; - case ZCL_LEVEL_CONTROL_CLUSTER_ID: + case app::Clusters::LevelControl::Id: emberAfLevelControlClusterInitCallback(endpoint); break; - case ZCL_LOCALIZATION_CONFIGURATION_CLUSTER_ID: + case app::Clusters::LocalizationConfiguration::Id: emberAfLocalizationConfigurationClusterInitCallback(endpoint); break; - case ZCL_NETWORK_COMMISSIONING_CLUSTER_ID: + case app::Clusters::NetworkCommissioning::Id: emberAfNetworkCommissioningClusterInitCallback(endpoint); break; - case ZCL_OCCUPANCY_SENSING_CLUSTER_ID: + case app::Clusters::OccupancySensing::Id: emberAfOccupancySensingClusterInitCallback(endpoint); break; - case ZCL_ON_OFF_CLUSTER_ID: + case app::Clusters::OnOff::Id: emberAfOnOffClusterInitCallback(endpoint); break; - case ZCL_OPERATIONAL_CREDENTIALS_CLUSTER_ID: + case app::Clusters::OperationalCredentials::Id: emberAfOperationalCredentialsClusterInitCallback(endpoint); break; - case ZCL_OTA_SOFTWARE_UPDATE_PROVIDER_CLUSTER_ID: + case app::Clusters::OtaSoftwareUpdateProvider::Id: emberAfOtaSoftwareUpdateProviderClusterInitCallback(endpoint); break; - case ZCL_OTA_SOFTWARE_UPDATE_REQUESTOR_CLUSTER_ID: + case app::Clusters::OtaSoftwareUpdateRequestor::Id: emberAfOtaSoftwareUpdateRequestorClusterInitCallback(endpoint); break; - case ZCL_SOFTWARE_DIAGNOSTICS_CLUSTER_ID: + case app::Clusters::SoftwareDiagnostics::Id: emberAfSoftwareDiagnosticsClusterInitCallback(endpoint); break; - case ZCL_SWITCH_CLUSTER_ID: + case app::Clusters::Switch::Id: emberAfSwitchClusterInitCallback(endpoint); break; - case ZCL_THREAD_NETWORK_DIAGNOSTICS_CLUSTER_ID: + case app::Clusters::ThreadNetworkDiagnostics::Id: emberAfThreadNetworkDiagnosticsClusterInitCallback(endpoint); break; - case ZCL_TIME_FORMAT_LOCALIZATION_CLUSTER_ID: + case app::Clusters::TimeFormatLocalization::Id: emberAfTimeFormatLocalizationClusterInitCallback(endpoint); break; - case ZCL_USER_LABEL_CLUSTER_ID: + case app::Clusters::UserLabel::Id: emberAfUserLabelClusterInitCallback(endpoint); break; - case ZCL_WIFI_NETWORK_DIAGNOSTICS_CLUSTER_ID: + case app::Clusters::WiFiNetworkDiagnostics::Id: emberAfWiFiNetworkDiagnosticsClusterInitCallback(endpoint); break; default: diff --git a/scripts/idl/tests/outputs/several_clusters/bridge/BridgeGlobalStructs.h b/scripts/idl/tests/outputs/several_clusters/bridge/BridgeGlobalStructs.h index d2a3def71c2189..3b56a6f868b109 100644 --- a/scripts/idl/tests/outputs/several_clusters/bridge/BridgeGlobalStructs.h +++ b/scripts/idl/tests/outputs/several_clusters/bridge/BridgeGlobalStructs.h @@ -1,6 +1,5 @@ #pragma once -#include #include #include diff --git a/scripts/idl/tests/outputs/several_clusters/cpp-app/callback-stub.cpp b/scripts/idl/tests/outputs/several_clusters/cpp-app/callback-stub.cpp index 4b92f0e3989ca6..d603013606d835 100644 --- a/scripts/idl/tests/outputs/several_clusters/cpp-app/callback-stub.cpp +++ b/scripts/idl/tests/outputs/several_clusters/cpp-app/callback-stub.cpp @@ -1,5 +1,5 @@ #include -#include +#include #include #include @@ -10,13 +10,13 @@ void emberAfClusterInitCallback(EndpointId endpoint, ClusterId clusterId) { switch (clusterId) { - case ZCL_FIRST_CLUSTER_ID: + case app::Clusters::First::Id: emberAfFirstClusterInitCallback(endpoint); break; - case ZCL_SECOND_CLUSTER_ID: + case app::Clusters::Second::Id: emberAfSecondClusterInitCallback(endpoint); break; - case ZCL_THIRD_CLUSTER_ID: + case app::Clusters::Third::Id: emberAfThirdClusterInitCallback(endpoint); break; default: diff --git a/scripts/idl/tests/outputs/simple_attribute/bridge/BridgeGlobalStructs.h b/scripts/idl/tests/outputs/simple_attribute/bridge/BridgeGlobalStructs.h index d2a3def71c2189..3b56a6f868b109 100644 --- a/scripts/idl/tests/outputs/simple_attribute/bridge/BridgeGlobalStructs.h +++ b/scripts/idl/tests/outputs/simple_attribute/bridge/BridgeGlobalStructs.h @@ -1,6 +1,5 @@ #pragma once -#include #include #include diff --git a/scripts/idl/xml_parser.py b/scripts/idl/xml_parser.py index 979167ca11b156..f2955c973ef632 100755 --- a/scripts/idl/xml_parser.py +++ b/scripts/idl/xml_parser.py @@ -76,4 +76,4 @@ def main(log_level, no_print, filenames): print("Data:") pprint.pp(data) - main() + main(auto_envvar_prefix='CHIP') diff --git a/scripts/idl/zapxml/handlers/handlers.py b/scripts/idl/zapxml/handlers/handlers.py index 6048b271ecf3ac..313fc61e8cdbb7 100644 --- a/scripts/idl/zapxml/handlers/handlers.py +++ b/scripts/idl/zapxml/handlers/handlers.py @@ -183,18 +183,19 @@ def GetNextProcessor(self, name: str, attrs): ) if 'fieldId' in attrs: - self._field_index = ParseInt(attrs['fieldId']) + field_index = ParseInt(attrs['fieldId']) else: # NOTE: code does NOT exist, so the number is incremental here # this seems a defficiency in XML format. - self._field_index += 1 + field_index = self._field_index + self._field_index = field_index + 1 if 'length' in attrs: data_type.max_length = ParseInt(attrs['length']) field = Field( data_type=data_type, - code=self._field_index, + code=field_index, name=attrs['name'], is_list=(attrs.get('array', 'false').lower() == 'true'), ) @@ -384,8 +385,6 @@ def GetArgumentField(self, attrs): if 'length' in attrs: data_type.max_length = ParseInt(attrs['length']) - self._field_index += 1 - field = Field( data_type=data_type, code=self._field_index, @@ -393,6 +392,8 @@ def GetArgumentField(self, attrs): is_list=(attrs.get('array', 'false') == 'true') ) + self._field_index += 1 + if attrs.get('optional', "false").lower() == 'true': field.qualities |= FieldQuality.OPTIONAL diff --git a/scripts/idl_lint.py b/scripts/idl_lint.py index 01b8413d8c9fd6..83f606201f8bac 100755 --- a/scripts/idl_lint.py +++ b/scripts/idl_lint.py @@ -86,4 +86,4 @@ def main(log_level, rules, idl_path): if __name__ == "__main__": - main() + main(auto_envvar_prefix='CHIP') diff --git a/scripts/pregenerate/__init__.py b/scripts/pregenerate/__init__.py new file mode 100644 index 00000000000000..eab3205dc9d981 --- /dev/null +++ b/scripts/pregenerate/__init__.py @@ -0,0 +1,69 @@ +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + + +import logging +import os + +from typing import Iterator + +from .types import InputIdlFile, IdlFileType + + +from .pregenerators import CodegenJavaPregenerator +from .pregenerators import CodegenBridgePregenerator +from .pregenerators import CodegenCppAppPregenerator + + +def FindAllIdls(sdk_root: str) -> Iterator[InputIdlFile]: + relevant_subdirs = [ + 'examples', # all example apps + 'src', # realistically only controller/data_model + ] + + while sdk_root.endswith('/'): + sdk_root = sdk_root[:-1] + sdk_root_length = len(sdk_root) + + for subdir_name in relevant_subdirs: + top_directory_name = os.path.join(sdk_root, subdir_name) + logging.debug(f"Searching {top_directory_name}") + for root, dirs, files in os.walk(top_directory_name): + for file in files: + if file.endswith('.zap'): + yield InputIdlFile(file_type=IdlFileType.ZAP, + relative_path=os.path.join(root[sdk_root_length+1:], file)) + if file.endswith('.matter'): + yield InputIdlFile(file_type=IdlFileType.MATTER, + relative_path=os.path.join(root[sdk_root_length+1:], file)) + + +def FindPregenerationTargets(sdk_root: str): + """Finds all relevand pre-generation targets in the given + SDK root. + + Pre-generation targets are based on zap and matter files with options + on what rules to pregenerate and how. + """ + + generators = [ + CodegenBridgePregenerator(sdk_root), + CodegenJavaPregenerator(sdk_root), + CodegenCppAppPregenerator(sdk_root), + ] + + for idl in FindAllIdls(sdk_root): + for generator in generators: + if generator.Accept(idl): + yield generator.CreateTarget(idl) diff --git a/scripts/pregenerate/pregenerators.py b/scripts/pregenerate/pregenerators.py new file mode 100644 index 00000000000000..3d6658dd3bb7b1 --- /dev/null +++ b/scripts/pregenerate/pregenerators.py @@ -0,0 +1,102 @@ +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import logging +import os +import shlex +import subprocess + +from .types import InputIdlFile, IdlFileType + +CODEGEN_PY_PATH = os.path.join(os.path.dirname(__file__), '..', 'codegen.py') + + +class CodegenTarget: + """A target that uses `scripts/codegen.py` to generate files.""" + + def __init__(self, idl: InputIdlFile, generator: str, sdk_root: str): + self.idl = idl + self.generator = generator + self.sdk_root = sdk_root + + if idl.file_type != IdlFileType.MATTER: + raise Exception(f"Can only code generate for `*.matter` input files, not for {idl}") + + def Generate(self, output_root: str): + '''Runs codegen.py to generate in the specified directory''' + + output_dir = os.path.join(output_root, self.idl.pregen_subdir, self.generator) + + logging.info(f"Generating: {self.generator}:{self.idl.relative_path} into {output_dir}") + + cmd = [ + CODEGEN_PY_PATH, + '--log-level', 'fatal', + '--generator', self.generator, + '--output-dir', output_dir, + os.path.join(self.sdk_root, self.idl.relative_path) + ] + + logging.debug(f"Executing {cmd}") + subprocess.check_call(cmd) + + +class CodegenBridgePregenerator: + """Pregeneration logic for "bridge" codegen.py outputs""" + + def __init__(self, sdk_root): + self.sdk_root = sdk_root + + def Accept(self, idl: InputIdlFile): + # Bridge is highly specific, a single path is acceptable for dynamic + # bridge codegen + return idl.relative_path == "examples/dynamic-bridge-app/bridge-common/bridge-app.matter" + + def CreateTarget(self, idl: InputIdlFile): + return CodegenTarget(sdk_root=self.sdk_root, idl=idl, generator="bridge") + + +class CodegenJavaPregenerator: + """Pregeneration logic for "java" codegen.py outputs""" + + def __init__(self, sdk_root): + self.sdk_root = sdk_root + + def Accept(self, idl: InputIdlFile): + # Java is highly specific, a single path is acceptable for dynamic + # bridge codegen + return idl.relative_path == "src/controller/data_model/controller-clusters.matter" + + def CreateTarget(self, idl: InputIdlFile): + return CodegenTarget(sdk_root=self.sdk_root, idl=idl, generator="java") + + +class CodegenCppAppPregenerator: + """Pregeneration logic for "cpp-app" codegen.py outputs""" + + def __init__(self, sdk_root): + self.sdk_root = sdk_root + + def Accept(self, idl: InputIdlFile): + if idl.file_type != IdlFileType.MATTER: + return False + + # we should not be checked for these, but verify just in case + if '/tests/' in idl.relative_path: + return False + + return True + + def CreateTarget(self, idl: InputIdlFile): + return CodegenTarget(sdk_root=self.sdk_root, idl=idl, generator="cpp-app") diff --git a/scripts/pregenerate/types.py b/scripts/pregenerate/types.py new file mode 100644 index 00000000000000..3d8c0bca3034d8 --- /dev/null +++ b/scripts/pregenerate/types.py @@ -0,0 +1,44 @@ +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import os + +from dataclasses import dataclass +from enum import Enum, auto + + +class IdlFileType(Enum): + ZAP = auto() + MATTER = auto() + + +@dataclass +class InputIdlFile: + file_type: IdlFileType + relative_path: str + + @property + def pregen_subdir(self): + ''' + Returns the relative path inside the pregenerate directory where + data for this IDL file should be pregenerated. + ''' + top_dir = os.path.splitext(self.relative_path)[0] + + if self.file_type == IdlFileType.MATTER: + return os.path.join(top_dir, "codegen") + elif self.file_type == IdlFileType.ZAP: + return os.path.join(top_dir, "zap") + else: + raise Exception("Unknown file type for self") diff --git a/scripts/requirements.ti.txt b/scripts/requirements.ti.txt new file mode 100644 index 00000000000000..14ea26e1ba9fd7 --- /dev/null +++ b/scripts/requirements.ti.txt @@ -0,0 +1 @@ +ecdsa>=0.17.0 diff --git a/scripts/requirements.txt b/scripts/requirements.txt index 4bb21d20d64c23..6fec358caf1986 100644 --- a/scripts/requirements.txt +++ b/scripts/requirements.txt @@ -17,6 +17,9 @@ virtualenv # Infineon -r requirements.infineon.txt +# TI +-r requirements.ti.txt + # cirque tests requests>=2.24.0 diff --git a/scripts/run-clang-tidy-on-compile-commands.py b/scripts/run-clang-tidy-on-compile-commands.py index 728cd44b7c8f8c..90ca9ed6cf9fac 100755 --- a/scripts/run-clang-tidy-on-compile-commands.py +++ b/scripts/run-clang-tidy-on-compile-commands.py @@ -27,9 +27,6 @@ """ -import build -import click -import coloredlogs import glob import json import logging @@ -43,6 +40,9 @@ import tempfile import threading import traceback + +import click +import coloredlogs import yaml @@ -483,4 +483,4 @@ def cmd_fix(context): if __name__ == "__main__": - main() + main(auto_envvar_prefix='CHIP') diff --git a/scripts/run_in_build_env.sh b/scripts/run_in_build_env.sh index 890f86fc5b6025..0d515bfe5b7ecc 100755 --- a/scripts/run_in_build_env.sh +++ b/scripts/run_in_build_env.sh @@ -26,5 +26,5 @@ fi set -e -echo "Executing in build environment: $@" +echo "Executing in build environment: $*" bash -c -- "$@" diff --git a/scripts/run_in_ns.sh b/scripts/run_in_ns.sh new file mode 100755 index 00000000000000..33d4f6661f432d --- /dev/null +++ b/scripts/run_in_ns.sh @@ -0,0 +1,61 @@ +#!/bin/bash + +# +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# This script executes the command given as an argument within +# CHIP_ROOT in a specific network namespace. + +NETWORK_NAMESPACE="default" + +function show_usage() { + cat <&2 + exit 1 +fi + +NETWORK_NAMESPACE=$1 +shift + +if [[ $NETWORK_NAMESPACE == "default" ]]; then + "$@" +else + if [ ! -f /var/run/netns/"$NETWORK_NAMESPACE" ]; then + echo "$NETWORK_NAMESPACE network namespace does not exist" + show_usage >&2 + exit 1 + fi + echo "Run command: $@ in $NETWORK_NAMESPACE namespace" + if [ "$EUID" -ne 0 ]; then + sudo env PATH="$PATH" ip netns exec "$NETWORK_NAMESPACE" "$@" + else + ip netns exec "$NETWORK_NAMESPACE" "$@" + fi +fi diff --git a/scripts/setup/openiotsdk/connect_if.sh b/scripts/setup/openiotsdk/connect_if.sh new file mode 100755 index 00000000000000..21c7460a01fb79 --- /dev/null +++ b/scripts/setup/openiotsdk/connect_if.sh @@ -0,0 +1,72 @@ +#!/bin/bash + +# +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# Enable/disable/restart TAP/TUN Open IoT SDK networking environment. + +HOST_BRIDGE="ARMhbr" +DEFAULT_ROUTE_IF="" +USER="$(id -u -n)" +INTERFACES=() + +declare -A default_if_info + +if [ "$EUID" -ne 0 ]; then + echo "Run a script with root permissions" + exit 1 +fi + +function show_usage() { + cat < ... + +Connect specific network interfaces with the default route interface. Create a bridge and link all interfaces to it. +Keep the default route of network traffic. + +EOF +} + +function get_default_if_info() { + default_if_info[ip]="$(ifconfig "$DEFAULT_ROUTE_IF" | grep -w inet | awk '{print $2}' | cut -d ":" -f 2)" + default_if_info[netmask]="$(ifconfig "$DEFAULT_ROUTE_IF" | grep -w inet | awk '{print $4}' | cut -d ":" -f 2)" + default_if_info[broadcast]="$(ifconfig "$DEFAULT_ROUTE_IF" | grep -w inet | awk '{print $6}' | cut -d ":" -f 2)" + default_if_info[gateway]="$(ip route show 0.0.0.0/0 dev "$DEFAULT_ROUTE_IF" | cut -d\ -f3)" +} + +function connect_with_host() { + ip link add name "$HOST_BRIDGE" type bridge + ip link set "$DEFAULT_ROUTE_IF" master "$HOST_BRIDGE" + ip addr flush dev "$DEFAULT_ROUTE_IF" + for interface in "${INTERFACES[@]}"; do + ip link set "$interface" master "$HOST_BRIDGE" + ip addr flush dev "$interface" + done + ifconfig "$HOST_BRIDGE" "${default_if_info[ip]}" netmask "${default_if_info[netmask]}" broadcast "${default_if_info[broadcast]}" + route add default gw "${default_if_info[gateway]}" "$HOST_BRIDGE" +} + +if [[ $# -lt 1 ]]; then + show_usage >&2 + exit 1 +fi + +INTERFACES=("$*") +DEFAULT_ROUTE_IF=$(route | grep '^default' | grep -o '[^ ]*$') +echo "Default route interface $DEFAULT_ROUTE_IF" +get_default_if_info +echo "Connect $INTERFACES to $DEFAULT_ROUTE_IF via bridge" +connect_with_host diff --git a/scripts/setup/openiotsdk/network_setup.sh b/scripts/setup/openiotsdk/network_setup.sh new file mode 100755 index 00000000000000..e5d5739ac129e1 --- /dev/null +++ b/scripts/setup/openiotsdk/network_setup.sh @@ -0,0 +1,189 @@ +#!/bin/bash + +# +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# Enable/disable/restart Open IoT SDK networking environment. + +NAMESPACE_NAME="ns" +HOST_SIDE_IF_NAME="hveth" +NAMESPACE_SIDE_IF_NAME="nveth" +TAP_TUN_INTERFACE_NAME="tap" +BRIDGE_INTERFACE_NAME="br" +HOST_IPV6_ADDR="fe00::1" +NAMESPACE_IPV6_ADDR="fe00::2" +HOST_IPV4_ADDR="10.200.1.1" +NAMESPACE_IPV4_ADDR="10.200.1.2" +NAME="ARM" +INTERNET_ENABLE=false +USER="$(id -u -n)" + +if [ "$EUID" -ne 0 ]; then + echo "Run a script with root permissions" + exit 1 +fi + +function show_usage() { + cat < Open IoT SDK network base name + -u,--user Network user + -I,--Internet Add Internet connection support to network namespace + +command: + up + down + restart + +EOF +} + +function net_ns_up() { + # Enable IPv6 and IP-forwarding + sysctl net.ipv6.conf.all.disable_ipv6=0 net.ipv4.conf.all.forwarding=1 net.ipv6.conf.all.forwarding=1 + + echo "Create $NAMESPACE_NAME network namespace" + # Create namespace. + ip netns add "$NAMESPACE_NAME" + + # Enable lo interface in namespace + ip netns exec "$NAMESPACE_NAME" ip link set dev lo up + + echo "Adding $HOST_SIDE_IF_NAME veth with peer $NAMESPACE_SIDE_IF_NAME" + # Create two virtual interfaces and link them - one on host side, one on namespace side. + ip link add "$HOST_SIDE_IF_NAME" type veth peer name "$NAMESPACE_SIDE_IF_NAME" + + # Give the host a known IPv6 addr and set the host side up + echo "Set IP addresses $HOST_IPV4_ADDR/24 $HOST_IPV6_ADDR/64 to $HOST_SIDE_IF_NAME interface" + ip addr add "$HOST_IPV4_ADDR"/24 dev "$HOST_SIDE_IF_NAME" + ip -6 addr add "$HOST_IPV6_ADDR"/64 dev "$HOST_SIDE_IF_NAME" + ip link set "$HOST_SIDE_IF_NAME" up + + echo "Adding $NAMESPACE_SIDE_IF_NAME veth to namespace $NAMESPACE_NAME" + # Associate namespace IF with the namespace + ip link set "$NAMESPACE_SIDE_IF_NAME" netns "$NAMESPACE_NAME" + ip netns exec "$NAMESPACE_NAME" ip link set dev "$NAMESPACE_SIDE_IF_NAME" up + + echo "Create $TAP_TUN_INTERFACE_NAME TAP device" + ip netns exec "$NAMESPACE_NAME" ip tuntap add dev "$TAP_TUN_INTERFACE_NAME" mode tap user "$USER" + ip netns exec "$NAMESPACE_NAME" ifconfig "$TAP_TUN_INTERFACE_NAME" 0.0.0.0 promisc + + echo "Create $BRIDGE_INTERFACE_NAME bridge interface between $NAMESPACE_SIDE_IF_NAME and $TAP_TUN_INTERFACE_NAME" + ip netns exec "$NAMESPACE_NAME" ip link add "$BRIDGE_INTERFACE_NAME" type bridge + echo "Set IP addresses $NAMESPACE_IPV4_ADDR/24 $NAMESPACE_IPV6_ADDR/64 to $BRIDGE_INTERFACE_NAME bridge interface" + ip netns exec "$NAMESPACE_NAME" ip -6 addr add "$NAMESPACE_IPV6_ADDR"/64 dev "$BRIDGE_INTERFACE_NAME" + ip netns exec "$NAMESPACE_NAME" ip addr add "$NAMESPACE_IPV4_ADDR"/24 dev "$BRIDGE_INTERFACE_NAME" + ip netns exec "$NAMESPACE_NAME" ip addr flush dev "$NAMESPACE_SIDE_IF_NAME" + ip netns exec "$NAMESPACE_NAME" ip link set "$TAP_TUN_INTERFACE_NAME" master "$BRIDGE_INTERFACE_NAME" + ip netns exec "$NAMESPACE_NAME" ip link set "$NAMESPACE_SIDE_IF_NAME" master "$BRIDGE_INTERFACE_NAME" + ip netns exec "$NAMESPACE_NAME" ip link set dev "$BRIDGE_INTERFACE_NAME" up + + ip netns exec "$NAMESPACE_NAME" ip route add default via "$HOST_IPV4_ADDR" + + if "$INTERNET_ENABLE"; then + echo "Set Internet connection to $NAMESPACE_NAME namespace" + DEFAULT_ROUTE=$(route | grep '^default' | grep -o '[^ ]*$') + echo "Default route interface $DEFAULT_ROUTE" + # Enable masquerading of namespace IP address + iptables -t nat -A POSTROUTING -s "$NAMESPACE_IPV4_ADDR"/24 -o "$DEFAULT_ROUTE" -j MASQUERADE + + iptables -A FORWARD -i "$DEFAULT_ROUTE" -o "$HOST_SIDE_IF_NAME" -j ACCEPT + iptables -A FORWARD -o "$DEFAULT_ROUTE" -i "$HOST_SIDE_IF_NAME" -j ACCEPT + fi + + echo "$NAMESPACE_NAME namespace configuration" + ip netns exec "$NAMESPACE_NAME" ifconfig + echo "Host configuration" + ifconfig +} + +function net_ns_down() { + ip netns delete "$NAMESPACE_NAME" + ip link delete dev "$HOST_SIDE_IF_NAME" + echo "Host configuration" + ifconfig +} + +SHORT=n:,u:,I,h, +LONG=name:,user:,Internet,help +OPTS=$(getopt -n build --options "$SHORT" --longoptions "$LONG" -- "$@") + +eval set -- "$OPTS" + +while :; do + case "$1" in + -h | --help) + show_usage + exit 0 + ;; + -n | --name) + NAME=$2 + shift 2 + ;; + -u | --user) + USER=$2 + shift 2 + ;; + -I | --Internet) + INTERNET_ENABLE=true + shift + ;; + -* | --*) + shift + break + ;; + *) + echo "Unexpected option: $1" + show_usage + exit 2 + ;; + esac +done + +if [[ $# -lt 1 ]]; then + show_usage >&2 + exit 1 +fi + +case "$1" in + up | down | restart) + COMMAND=$1 + ;; + *) + echo "ERROR: Command $COMMAND not supported" + show_usage + exit 1 + ;; +esac + +NAMESPACE_NAME="$NAME$NAMESPACE_NAME" +HOST_SIDE_IF_NAME="$NAME$HOST_SIDE_IF_NAME" +NAMESPACE_SIDE_IF_NAME="$NAME$NAMESPACE_SIDE_IF_NAME" +TAP_TUN_INTERFACE_NAME="$NAME$TAP_TUN_INTERFACE_NAME" +BRIDGE_INTERFACE_NAME="$NAME$BRIDGE_INTERFACE_NAME" + +if [[ "$COMMAND" == *"down"* || "$COMMAND" == *"restart"* ]]; then + net_ns_down +fi + +if [[ "$COMMAND" == *"up"* || "$COMMAND" == *"restart"* ]]; then + net_ns_up +fi diff --git a/scripts/tests/gn_tests.sh b/scripts/tests/gn_tests.sh index 13eae351bfb55a..165ae47bd2ff8e 100755 --- a/scripts/tests/gn_tests.sh +++ b/scripts/tests/gn_tests.sh @@ -25,11 +25,20 @@ CHIP_ROOT="$(dirname "$0")/../.." source "$CHIP_ROOT/scripts/activate.sh" dmalloc=$(gn --root="$CHIP_ROOT" args "$CHIP_ROOT/out/$BUILD_TYPE" --short --list=chip_config_memory_debug_dmalloc) -if [ "x$dmalloc" == "xchip_config_memory_debug_dmalloc = true" ]; then - eval "$(dmalloc -b -l DMALLOC_LOG -i 1 high)" - export G_SLICE - G_SLICE=always-malloc # required for dmalloc compatibility -fi + +case "$dmalloc" in + "chip_config_memory_debug_dmalloc = true") + eval "$(dmalloc -b -i 1 high)" + export G_SLICE + G_SLICE=always-malloc # required for dmalloc compatibility + ;; + "chip_config_memory_debug_dmalloc = false") ;; + + *) + echo >&2 "Invalid output: \"$dmalloc\"" + exit 1 + ;; +esac env diff --git a/scripts/tests/java/base.py b/scripts/tests/java/base.py new file mode 100755 index 00000000000000..1417db0a7e981a --- /dev/null +++ b/scripts/tests/java/base.py @@ -0,0 +1,60 @@ +#!/usr/bin/env python3 + +# +# Copyright (c) 2022 Project CHIP Authors +# All rights reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# Commissioning test. +import logging +import os +import sys +import queue +import datetime +import asyncio +import threading +import typing +import time +import subprocess +from colorama import Fore, Style + + +def EnqueueLogOutput(fp, tag, q): + for line in iter(fp.readline, b''): + timestamp = time.time() + if len(line) > len('[1646290606.901990]') and line[0:1] == b'[': + try: + timestamp = float(line[1:18].decode()) + line = line[19:] + except Exception as ex: + pass + sys.stdout.buffer.write( + (f"[{datetime.datetime.fromtimestamp(timestamp).isoformat(sep=' ')}]").encode() + tag + line) + sys.stdout.flush() + fp.close() + + +def RedirectQueueThread(fp, tag, queue) -> threading.Thread: + log_queue_thread = threading.Thread(target=EnqueueLogOutput, args=( + fp, tag, queue)) + log_queue_thread.start() + return log_queue_thread + + +def DumpProgramOutputToQueue(thread_list: typing.List[threading.Thread], tag: str, process: subprocess.Popen, queue: queue.Queue): + thread_list.append(RedirectQueueThread(process.stdout, + (f"[{tag}][{Fore.YELLOW}STDOUT{Style.RESET_ALL}]").encode(), queue)) + thread_list.append(RedirectQueueThread(process.stderr, + (f"[{tag}][{Fore.RED}STDERR{Style.RESET_ALL}]").encode(), queue)) diff --git a/scripts/tests/java/commissioning_test.py b/scripts/tests/java/commissioning_test.py new file mode 100755 index 00000000000000..afd132c575b4e7 --- /dev/null +++ b/scripts/tests/java/commissioning_test.py @@ -0,0 +1,125 @@ +#!/usr/bin/env python3 + +# +# Copyright (c) 2022 Project CHIP Authors +# All rights reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# Commissioning test. +import logging +import os +import sys +import asyncio +import queue +import subprocess +import threading +import typing +from optparse import OptionParser +from colorama import Fore, Style +from java.base import DumpProgramOutputToQueue + + +class CommissioningTest: + def __init__(self, thread_list: typing.List[threading.Thread], queue: queue.Queue, cmd: [], args: str): + self.thread_list = thread_list + self.queue = queue + self.command = cmd + + optParser = OptionParser() + optParser.add_option( + "-t", + "--timeout", + action="store", + dest="testTimeout", + default='200', + type='str', + help="The program will return with timeout after specified seconds.", + metavar="", + ) + optParser.add_option( + "-a", + "--address", + action="store", + dest="deviceAddress", + default='', + type='str', + help="Address of the device", + metavar="", + ) + optParser.add_option( + "--setup-payload", + action="store", + dest="setupPayload", + default='', + type='str', + help="Setup Payload (manual pairing code or QR code content)", + metavar="" + ) + optParser.add_option( + "--nodeid", + action="store", + dest="nodeid", + default='1', + type='str', + help="The Node ID issued to the device", + metavar="" + ) + optParser.add_option( + "--discriminator", + action="store", + dest="discriminator", + default='3840', + type='str', + help="Discriminator of the device", + metavar="" + ) + optParser.add_option( + "-p", + "--paa-trust-store-path", + action="store", + dest="paaTrustStorePath", + default='', + type='str', + help="Path that contains valid and trusted PAA Root Certificates.", + metavar="" + ) + + (options, remainingArgs) = optParser.parse_args(args.split()) + + self.nodeid = options.nodeid + self.setupPayload = options.setupPayload + self.discriminator = options.discriminator + self.testTimeout = options.testTimeout + + logging.basicConfig(level=logging.INFO) + + def TestOnnetworkLong(self, nodeid, setuppin, discriminator, timeout): + java_command = self.command + ['pairing', 'onnetwork-long', nodeid, setuppin, discriminator, timeout] + print(java_command) + logging.info(f"Execute: {java_command}") + java_process = subprocess.Popen( + java_command, stdout=subprocess.PIPE, stderr=subprocess.PIPE) + DumpProgramOutputToQueue(self.thread_list, Fore.GREEN + "JAVA " + Style.RESET_ALL, java_process, self.queue) + return java_process.wait() + + def RunTest(self): + logging.info("Testing onnetwork-long pairing") + java_exit_code = self.TestOnnetworkLong(self.nodeid, self.setupPayload, self.discriminator, self.testTimeout) + if java_exit_code != 0: + logging.error("Testing onnetwork-long pairing failed with error %r" % java_exit_code) + return java_exit_code + + # Testing complete without errors + return 0 diff --git a/scripts/tests/run_java_test.py b/scripts/tests/run_java_test.py new file mode 100755 index 00000000000000..4ca163a7eb4790 --- /dev/null +++ b/scripts/tests/run_java_test.py @@ -0,0 +1,114 @@ +#!/usr/bin/env -S python3 -B + +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import click +import coloredlogs +import logging +import os +import pathlib +import pty +import queue +import re +import shlex +import signal +import subprocess +import sys +from java.base import DumpProgramOutputToQueue +from java.commissioning_test import CommissioningTest +from colorama import Fore, Style + + +@click.command() +@click.option("--app", type=click.Path(exists=True), default=None, help='Path to local application to use, omit to use external apps.') +@click.option("--app-args", type=str, default='', help='The extra arguments passed to the device.') +@click.option("--tool-path", type=click.Path(exists=True), default=None, help='Path to java-matter-controller.') +@click.option("--tool-cluster", type=str, default='pairing', help='The cluster name passed to the java-matter-controller.') +@click.option("--tool-args", type=str, default='', help='The arguments passed to the java-matter-controller.') +@click.option("--factoryreset", is_flag=True, help='Remove app configs (/tmp/chip*) before running the tests.') +def main(app: str, app_args: str, tool_path: str, tool_cluster: str, tool_args: str, factoryreset: bool): + logging.info("Execute: {script_command}") + + if factoryreset: + # Remove native app config + retcode = subprocess.call("rm -rf /tmp/chip*", shell=True) + if retcode != 0: + raise Exception("Failed to remove /tmp/chip* for factory reset.") + + print("Contents of test directory: %s" % os.getcwd()) + print(subprocess.check_output(["ls -l"], shell=True).decode('us-ascii')) + + # Remove native app KVS if that was used + kvs_match = re.search(r"--KVS (?P[^ ]+)", app_args) + if kvs_match: + kvs_path_to_remove = kvs_match.group("kvs_path") + retcode = subprocess.call("rm -f %s" % kvs_path_to_remove, shell=True) + print("Trying to remove KVS path %s" % kvs_path_to_remove) + if retcode != 0: + raise Exception("Failed to remove %s for factory reset." % kvs_path_to_remove) + + coloredlogs.install(level='INFO') + + log_queue = queue.Queue() + log_cooking_threads = [] + + if tool_path: + if not os.path.exists(tool_path): + if tool_path is None: + raise FileNotFoundError(f"{tool_path} not found") + + app_process = None + if app: + if not os.path.exists(app): + if app is None: + raise FileNotFoundError(f"{app} not found") + app_args = [app] + shlex.split(app_args) + logging.info(f"Execute: {app_args}") + app_process = subprocess.Popen( + app_args, stdout=subprocess.PIPE, stderr=subprocess.PIPE, bufsize=0) + DumpProgramOutputToQueue( + log_cooking_threads, Fore.GREEN + "APP " + Style.RESET_ALL, app_process, log_queue) + + command = ['java', '-Djava.library.path=' + tool_path + '/lib/jni', '-jar', tool_path + '/bin/java-matter-controller'] + + if tool_cluster == 'pairing': + logging.info("Testing pairing cluster") + + test = CommissioningTest(log_cooking_threads, log_queue, command, tool_args) + controller_exit_code = test.RunTest() + + if controller_exit_code != 0: + logging.error("Test script exited with error %r" % test_script_exit_code) + + app_exit_code = 0 + if app_process: + logging.warning("Stopping app with SIGINT") + app_process.send_signal(signal.SIGINT.value) + app_exit_code = app_process.wait() + + # There are some logs not cooked, so we wait until we have processed all logs. + # This procedure should be very fast since the related processes are finished. + for thread in log_cooking_threads: + thread.join() + + if controller_exit_code != 0: + sys.exit(controller_exit_code) + else: + # We expect both app and controller should exit with 0 + sys.exit(app_exit_code) + + +if __name__ == '__main__': + main() diff --git a/scripts/tests/run_python_test.py b/scripts/tests/run_python_test.py index e13d9b5edcd905..4318ee1221da35 100755 --- a/scripts/tests/run_python_test.py +++ b/scripts/tests/run_python_test.py @@ -14,13 +14,9 @@ # See the License for the specific language governing permissions and # limitations under the License. -import click -import coloredlogs import datetime import logging import os -import pathlib -import pty import queue import re import shlex @@ -31,6 +27,8 @@ import time import typing +import click +import coloredlogs from colorama import Fore, Style DEFAULT_CHIP_ROOT = os.path.abspath( @@ -164,4 +162,4 @@ def main(app: str, factoryreset: bool, app_args: str, script: str, script_args: if __name__ == '__main__': - main() + main(auto_envvar_prefix='CHIP') diff --git a/scripts/tests/run_test_suite.py b/scripts/tests/run_test_suite.py index dbbda2a3863da2..1aac9d5ad9a442 100755 --- a/scripts/tests/run_test_suite.py +++ b/scripts/tests/run_test_suite.py @@ -16,7 +16,6 @@ import logging import os -import shutil import sys import time import typing @@ -281,4 +280,4 @@ def cmd_shell(context): if __name__ == '__main__': - main() + main(auto_envvar_prefix='CHIP') diff --git a/scripts/tools/check_includes_config.py b/scripts/tools/check_includes_config.py index 81b2a481c472f9..cbf0b405c720dd 100644 --- a/scripts/tools/check_includes_config.py +++ b/scripts/tools/check_includes_config.py @@ -149,9 +149,9 @@ # Uses platform-define to switch between list and array 'src/lib/dnssd/minimal_mdns/ResponseSender.h': {'list'}, - # Not really for embedded consumers; uses std::queue to keep track + # Not really for embedded consumers; uses std::deque to keep track # of a list of discovered things. - 'src/controller/SetUpCodePairer.h': {'queue'}, + 'src/controller/SetUpCodePairer.h': {'deque'}, 'src/controller/ExamplePersistentStorage.cpp': {'fstream'} } diff --git a/scripts/tools/convert_ini.py b/scripts/tools/convert_ini.py index d1abd22c4498df..35b43fb02cc8d0 100755 --- a/scripts/tools/convert_ini.py +++ b/scripts/tools/convert_ini.py @@ -17,12 +17,13 @@ # limitations under the License. # import json -from configparser import ConfigParser -import click -import typing +import logging import re +import typing +from configparser import ConfigParser from os.path import exists -import logging + +import click def convert_ini_to_json(ini_dir: str, json_path: str): @@ -106,4 +107,4 @@ def main(ini_dir: str, json_path: str): if __name__ == '__main__': - main() + main(auto_envvar_prefix='CHIP') diff --git a/build_overrides/telink.gni b/scripts/tools/memory/platform/openiotsdk.cfg similarity index 64% rename from build_overrides/telink.gni rename to scripts/tools/memory/platform/openiotsdk.cfg index 528fdc1c892f0c..4717f1278044dd 100644 --- a/build_overrides/telink.gni +++ b/scripts/tools/memory/platform/openiotsdk.cfg @@ -1,4 +1,4 @@ -# Copyright (c) 2020-2021 Project CHIP Authors +# Copyright (c) 2022 Project CHIP Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -12,7 +12,12 @@ # See the License for the specific language governing permissions and # limitations under the License. -declare_args() { - # Root directory for Telink SDK. - telink_sdk_build_root = "//third_party/telink_sdk" +# Memory tools default configuation for Open IoT SDK platform. + +{ + 'section': { + # By default, only these sections will be included + # when operating by sections. + 'default': ['.text', '.data', '.bss', '.stack', '.heap'], + }, } diff --git a/scripts/tools/nrfconnect/generate_nrfconnect_chip_factory_data.py b/scripts/tools/nrfconnect/generate_nrfconnect_chip_factory_data.py index e69bbc0be91fd1..ff4f64e3d82b25 100644 --- a/scripts/tools/nrfconnect/generate_nrfconnect_chip_factory_data.py +++ b/scripts/tools/nrfconnect/generate_nrfconnect_chip_factory_data.py @@ -19,7 +19,6 @@ import os import sys import json -import jsonschema import secrets import argparse import subprocess @@ -29,6 +28,13 @@ from cryptography.hazmat.backends import default_backend from cryptography.hazmat.primitives.serialization import load_der_private_key +try: + import jsonschema +except ImportError: + no_jsonschema_module = True +else: + no_jsonschema_module = False + # A user can not change the factory data version and must be coherent with # the factory data version set in the nRF Connect platform Kconfig file (CHIP_FACTORY_DATA_VERSION). FACTORY_DATA_VERSION = 1 @@ -485,6 +491,12 @@ def base64_str(s): return base64.b64decode(s) log.error("Output file: {} already exist, to create a new one add argument '--overwrite'. By default overwriting is disabled".format(args.output)) return + if args.schema and no_jsonschema_module: + log.error("Requested verification of the JSON file using jsonschema, but the module is not installed. \n \ + Install only the module by invoking: pip3 install jsonschema \n \ + Alternatively, install it with all dependencies for Matter by invoking: pip3 install -r ./scripts/requirements.nrfconnect.txt from the Matter root directory.") + return + generator = FactoryDataGenerator(args) generator.generate_json() diff --git a/scripts/tools/zap/generate.py b/scripts/tools/zap/generate.py index 5c48a41619d1aa..bd120752164895 100755 --- a/scripts/tools/zap/generate.py +++ b/scripts/tools/zap/generate.py @@ -19,6 +19,7 @@ import json import os from pathlib import Path +import tempfile import subprocess import sys import urllib.request @@ -32,6 +33,7 @@ class CmdLineArgs: templateFile: str outputDir: str runBootstrap: bool + parallel: bool = True CHIP_ROOT_DIR = os.path.realpath( @@ -103,6 +105,9 @@ def runArgumentsParser() -> CmdLineArgs: help='Output directory for the generated files (default: automatically selected)') parser.add_argument('--run-bootstrap', default=None, action='store_true', help='Automatically run ZAP bootstrap. By default the bootstrap is not triggered') + parser.add_argument('--parallel', action='store_true') + parser.add_argument('--no-parallel', action='store_false', dest='parallel') + parser.set_defaults(parallel=True) args = parser.parse_args() # By default, this script assumes that the global CHIP template is used with @@ -259,7 +264,23 @@ def main(): # The maximum memory usage is over 4GB (#15620) os.environ["NODE_OPTIONS"] = "--max-old-space-size=8192" - runGeneration(cmdLineArgs.zapFile, cmdLineArgs.zclFile, cmdLineArgs.templateFile, cmdLineArgs.outputDir) + + if cmdLineArgs.parallel: + # Parallel-compatible runs will need separate state + os.environ["ZAP_TEMPSTATE"] = "1" + + # `zap-cli` may extract things into a temporary directory. ensure extraction + # does not conflict. + with tempfile.TemporaryDirectory(prefix='zap') as temp_dir: + old_temp = os.environ['TEMP'] if 'TEMP' in os.environ else None + os.environ['TEMP'] = temp_dir + + runGeneration(cmdLineArgs.zapFile, cmdLineArgs.zclFile, cmdLineArgs.templateFile, cmdLineArgs.outputDir) + + if old_temp: + os.environ['TEMP'] = old_temp + else: + del os.environ['TEMP'] prettifiers = [ runClangPrettifier, diff --git a/scripts/tools/zap_regen_all.py b/scripts/tools/zap_regen_all.py index 18de729f16b3a8..e9483084c56019 100755 --- a/scripts/tools/zap_regen_all.py +++ b/scripts/tools/zap_regen_all.py @@ -21,6 +21,8 @@ import sys import subprocess import logging +import multiprocessing + from dataclasses import dataclass CHIP_ROOT_DIR = os.path.realpath( @@ -113,6 +115,11 @@ def setupArgumentsParser(): help="Don't do any generation, just log what targets would be generated (default: False)") parser.add_argument('--run-bootstrap', default=None, action='store_true', help='Automatically run ZAP bootstrap. By default the bootstrap is not triggered') + + parser.add_argument('--parallel', action='store_true') + parser.add_argument('--no-parallel', action='store_false', dest='parallel') + parser.set_defaults(parallel=True) + return parser.parse_args() @@ -253,6 +260,14 @@ def getTargets(type, test_target): return targets +def _ParallelGenerateOne(target): + """ + Helper method to be passed to multiprocessing parallel generation of + items. + """ + target.generate() + + def main(): logging.basicConfig( level=logging.INFO, @@ -269,8 +284,15 @@ def main(): if args.run_bootstrap: subprocess.check_call(os.path.join(CHIP_ROOT_DIR, "scripts/tools/zap/zap_bootstrap.sh"), shell=True) - for target in targets: - target.generate() + if args.parallel: + # Ensure each zap run is independent + os.environ['ZAP_TEMPSTATE'] = '1' + with multiprocessing.Pool() as pool: + for _ in pool.imap_unordered(_ParallelGenerateOne, targets): + pass + else: + for target in targets: + target.generate() if __name__ == '__main__': diff --git a/src/BUILD.gn b/src/BUILD.gn index c495ca83d1d908..2a24d53c8fce01 100644 --- a/src/BUILD.gn +++ b/src/BUILD.gn @@ -107,10 +107,13 @@ if (chip_build_tests) { if (chip_device_platform != "nrfconnect" && chip_device_platform != "efr32") { # TODO(#10447): Controller test has HF on EFR32. - deps += [ - "${chip_root}/src/controller/tests", - "${chip_root}/src/controller/tests/data_model", - ] + deps += [ "${chip_root}/src/controller/tests/data_model" ] + + # Skip controller test for Open IoT SDK + # https://github.com/project-chip/connectedhomeip/issues/23747 + if (chip_device_platform != "openiotsdk") { + deps += [ "${chip_root}/src/controller/tests" ] + } } if (current_os != "zephyr" && current_os != "mbed" && diff --git a/src/access/AccessControl.cpp b/src/access/AccessControl.cpp index 0f6c80c9f38e21..20b58ee0be39f3 100644 --- a/src/access/AccessControl.cpp +++ b/src/access/AccessControl.cpp @@ -549,11 +549,11 @@ bool AccessControl::IsValid(const Entry & entry) const char * log = "unexpected error"; IgnoreUnusedVariable(log); // logging may be disabled - AuthMode authMode; - FabricIndex fabricIndex; - Privilege privilege; - size_t subjectCount = 0; - size_t targetCount = 0; + AuthMode authMode = AuthMode::kNone; + FabricIndex fabricIndex = kUndefinedFabricIndex; + Privilege privilege = static_cast(0); + size_t subjectCount = 0; + size_t targetCount = 0; SuccessOrExit(entry.GetAuthMode(authMode)); SuccessOrExit(entry.GetFabricIndex(fabricIndex)); diff --git a/src/app/AttributePathExpandIterator.cpp b/src/app/AttributePathExpandIterator.cpp index bd3e717cb46964..cfa84dd7e30be9 100644 --- a/src/app/AttributePathExpandIterator.cpp +++ b/src/app/AttributePathExpandIterator.cpp @@ -36,7 +36,7 @@ using namespace chip; // Note: Some of the generated files that depended by af.h are gen_config.h and gen_tokens.h typedef uint8_t EmberAfClusterMask; -extern uint16_t emberAfEndpointCount(void); +extern uint16_t emberAfEndpointCount(); extern uint16_t emberAfIndexFromEndpoint(EndpointId endpoint); extern uint8_t emberAfClusterCount(EndpointId endpoint, bool server); extern uint16_t emberAfGetServerAttributeCount(chip::EndpointId endpoint, chip::ClusterId cluster); diff --git a/src/app/EventManagement.cpp b/src/app/EventManagement.cpp index f7ca6fa6a2a929..f3d84481d884c9 100644 --- a/src/app/EventManagement.cpp +++ b/src/app/EventManagement.cpp @@ -58,7 +58,7 @@ class CircularEventReader : public TLV::TLVReader virtual ~CircularEventReader() = default; }; -EventManagement & EventManagement::GetInstance(void) +EventManagement & EventManagement::GetInstance() { return sInstance; } diff --git a/src/app/MessageDef/AttributeStatusIBs.cpp b/src/app/MessageDef/AttributeStatusIBs.cpp index 795c2805027a4c..88484fd28eb02f 100644 --- a/src/app/MessageDef/AttributeStatusIBs.cpp +++ b/src/app/MessageDef/AttributeStatusIBs.cpp @@ -47,8 +47,7 @@ AttributeStatusIBs::Builder & AttributeStatusIBs::Builder::EndOfAttributeStatuse #if CHIP_CONFIG_IM_PRETTY_PRINT CHIP_ERROR AttributeStatusIBs::Parser::PrettyPrint() const { - CHIP_ERROR err = CHIP_NO_ERROR; - size_t NumAttributeStatus = 0; + CHIP_ERROR err = CHIP_NO_ERROR; TLV::TLVReader reader; PRETTY_PRINT("AttributeStatusIBs ="); @@ -68,8 +67,6 @@ CHIP_ERROR AttributeStatusIBs::Parser::PrettyPrint() const ReturnErrorOnFailure(status.PrettyPrint()); PRETTY_PRINT_DECDEPTH(); } - - ++NumAttributeStatus; } PRETTY_PRINT("],"); diff --git a/src/app/MessageDef/EventPathIBs.cpp b/src/app/MessageDef/EventPathIBs.cpp index 40736baf97988b..0a6277e2e22ae3 100644 --- a/src/app/MessageDef/EventPathIBs.cpp +++ b/src/app/MessageDef/EventPathIBs.cpp @@ -32,7 +32,6 @@ namespace app { CHIP_ERROR EventPathIBs::Parser::PrettyPrint() const { CHIP_ERROR err = CHIP_NO_ERROR; - size_t NumPath = 0; TLV::TLVReader reader; PRETTY_PRINT("EventPathIBs ="); @@ -54,8 +53,6 @@ CHIP_ERROR EventPathIBs::Parser::PrettyPrint() const ReturnErrorOnFailure(path.PrettyPrint()); PRETTY_PRINT_DECDEPTH(); } - - ++NumPath; } PRETTY_PRINT("],"); diff --git a/src/app/app-platform/ContentApp.cpp b/src/app/app-platform/ContentApp.cpp index cd7e8bdd0d4cd3..571561454162ac 100644 --- a/src/app/app-platform/ContentApp.cpp +++ b/src/app/app-platform/ContentApp.cpp @@ -19,8 +19,6 @@ * @file Contains functions relating to Content App of the Video Player. */ -#include -#include #include #include #include diff --git a/src/app/app-platform/ContentAppPlatform.cpp b/src/app/app-platform/ContentAppPlatform.cpp index 736cf164fdfede..0b03dc22f8e262 100644 --- a/src/app/app-platform/ContentAppPlatform.cpp +++ b/src/app/app-platform/ContentAppPlatform.cpp @@ -19,8 +19,6 @@ * @file Contains functions relating to Content App platform of the Video Player. */ -#include -#include #include #include #include diff --git a/src/app/chip_data_model.gni b/src/app/chip_data_model.gni index 68aabd7463dda8..a7627cb678ebff 100644 --- a/src/app/chip_data_model.gni +++ b/src/app/chip_data_model.gni @@ -47,25 +47,33 @@ template("chip_data_model") { # Assume that IDL name is the same as the zap file name, but instead of # '.zap' use '.matter' as extension. This is currently the case in the # sample apps, but may change in the future - print("AUTO-DETECTING input matter IDL file.") _idl = string_replace(invoker.zap_file, ".zap", ".matter") } + config("${_data_model_name}_config") { + include_dirs = [] + + if (defined(invoker.zap_pregenerated_dir)) { + include_dirs += [ "${invoker.zap_pregenerated_dir}/.." ] + } + } + chip_codegen("${_data_model_name}_codegen") { input = _idl generator = "cpp-app" + outputs = [ "app/PluginApplicationCallbacks.h", "app/callback-stub.cpp", ] - } - config("${_data_model_name}_config") { - include_dirs = [] + public_configs = [ ":${_data_model_name}_config" ] - if (defined(invoker.zap_pregenerated_dir)) { - include_dirs += [ "${invoker.zap_pregenerated_dir}/.." ] + if (!defined(deps)) { + deps = [] } + + deps += [ "${chip_root}/src/app/common:cluster-objects" ] } _use_default_im_dispatch = !defined(invoker.use_default_im_dispatch) || @@ -84,11 +92,15 @@ template("chip_data_model") { sources = [] } - sources += get_target_outputs(":${_data_model_name}_codegen") + if (!defined(deps)) { + deps = [] + } + deps += [ ":${_data_model_name}_codegen" ] sources += [ "${_app_root}/clusters/barrier-control-server/barrier-control-server.h", "${_app_root}/clusters/basic/basic.h", + "${_app_root}/clusters/client-monitoring-server/client-monitoring-server.h", "${_app_root}/clusters/color-control-server/color-control-server.h", "${_app_root}/clusters/door-lock-server/door-lock-server.h", "${_app_root}/clusters/groups-server/groups-server.h", diff --git a/src/app/clusters/account-login-server/account-login-server.cpp b/src/app/clusters/account-login-server/account-login-server.cpp index b269f028014335..da53ea15e87315 100644 --- a/src/app/clusters/account-login-server/account-login-server.cpp +++ b/src/app/clusters/account-login-server/account-login-server.cpp @@ -145,7 +145,7 @@ bool emberAfAccountLoginClusterLoginCallback(app::CommandHandler * command, cons if (!delegate->HandleLogin(tempAccountIdentifier, setupPin)) { - status = EMBER_ZCL_STATUS_NOT_AUTHORIZED; + status = EMBER_ZCL_STATUS_UNSUPPORTED_ACCESS; } exit: diff --git a/src/app/clusters/application-launcher-server/application-launcher-server.cpp b/src/app/clusters/application-launcher-server/application-launcher-server.cpp index 39d9d0c8a21a0a..775d8a6210b6f8 100644 --- a/src/app/clusters/application-launcher-server/application-launcher-server.cpp +++ b/src/app/clusters/application-launcher-server/application-launcher-server.cpp @@ -471,7 +471,7 @@ bool emberAfApplicationLauncherClusterHideAppCallback(app::CommandHandler * comm // ----------------------------------------------------------------------------- // Plugin initialization -void MatterApplicationLauncherPluginServerInitCallback(void) +void MatterApplicationLauncherPluginServerInitCallback() { registerAttributeAccessOverride(&gApplicationLauncherAttrAccess); } diff --git a/src/app/clusters/barrier-control-server/barrier-control-server.cpp b/src/app/clusters/barrier-control-server/barrier-control-server.cpp index bb7d65d29a0aa9..e310d7ba541061 100644 --- a/src/app/clusters/barrier-control-server/barrier-control-server.cpp +++ b/src/app/clusters/barrier-control-server/barrier-control-server.cpp @@ -286,7 +286,7 @@ bool emberAfBarrierControlClusterBarrierControlGoToPercentCallback( percentOpen != EMBER_ZCL_BARRIER_CONTROL_BARRIER_POSITION_CLOSED && percentOpen != EMBER_ZCL_BARRIER_CONTROL_BARRIER_POSITION_OPEN)) { - status = EMBER_ZCL_STATUS_INVALID_VALUE; + status = EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } else { diff --git a/src/app/clusters/client-monitoring-server/client-monitoring-server.cpp b/src/app/clusters/client-monitoring-server/client-monitoring-server.cpp new file mode 100644 index 00000000000000..02cc4bfcb9ae85 --- /dev/null +++ b/src/app/clusters/client-monitoring-server/client-monitoring-server.cpp @@ -0,0 +1,52 @@ +/** + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include "client-monitoring-server.h" + +#include +#include +#include +#include +#include +#include + +using namespace chip; +using namespace chip::app::Clusters; +using namespace chip::app::Clusters::ClientMonitoring; + +/** + * @brief Client Monitoring Cluster RegisterClientMonitoring Command callback (from client) + */ +bool emberAfClientMonitoringClusterRegisterClientMonitoringCallback( + app::CommandHandler * commandObj, const app::ConcreteCommandPath & commandPath, + const Commands::RegisterClientMonitoring::DecodableType & commandData) +{ + emberAfSendImmediateDefaultResponse(EMBER_ZCL_STATUS_UNSUPPORTED_COMMAND); + return false; +} +/** + * @brief Client Monitoring Cluster StayAwakeRequest Command callback (from client) + */ +bool emberAfClientMonitoringClusterStayAwakeRequestCallback(app::CommandHandler * commandObj, + const chip::app::ConcreteCommandPath & commandPath, + const Commands::StayAwakeRequest::DecodableType & commandData) +{ + emberAfSendImmediateDefaultResponse(EMBER_ZCL_STATUS_UNSUPPORTED_COMMAND); + return false; +} + +void MatterClientMonitoringPluginServerInitCallback() {} diff --git a/src/app/clusters/client-monitoring-server/client-monitoring-server.h b/src/app/clusters/client-monitoring-server/client-monitoring-server.h new file mode 100644 index 00000000000000..68a536760f3990 --- /dev/null +++ b/src/app/clusters/client-monitoring-server/client-monitoring-server.h @@ -0,0 +1,23 @@ +/** + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +#include +#include +#include +#include diff --git a/src/app/clusters/color-control-server/color-control-server.cpp b/src/app/clusters/color-control-server/color-control-server.cpp index 486126fb9ddab6..8d6230e6ede743 100644 --- a/src/app/clusters/color-control-server/color-control-server.cpp +++ b/src/app/clusters/color-control-server/color-control-server.cpp @@ -2207,7 +2207,7 @@ bool ColorControlServer::moveColorTempCommand(const app::ConcreteCommandPath & c if (rate == 0) { - emberAfSendImmediateDefaultResponse(EMBER_ZCL_STATUS_INVALID_FIELD); + emberAfSendImmediateDefaultResponse(EMBER_ZCL_STATUS_INVALID_COMMAND); return true; } diff --git a/src/app/clusters/content-launch-server/content-launch-server.cpp b/src/app/clusters/content-launch-server/content-launch-server.cpp index f248a3d37adda9..e22b91760370f5 100644 --- a/src/app/clusters/content-launch-server/content-launch-server.cpp +++ b/src/app/clusters/content-launch-server/content-launch-server.cpp @@ -265,7 +265,7 @@ bool emberAfContentLauncherClusterLaunchURLCallback(CommandHandler * commandObj, // ----------------------------------------------------------------------------- // Plugin initialization -void MatterContentLauncherPluginServerInitCallback(void) +void MatterContentLauncherPluginServerInitCallback() { registerAttributeAccessOverride(&gContentLauncherAttrAccess); } diff --git a/src/app/clusters/descriptor/descriptor.cpp b/src/app/clusters/descriptor/descriptor.cpp index 14f455413a21b0..e14ea6daf40462 100644 --- a/src/app/clusters/descriptor/descriptor.cpp +++ b/src/app/clusters/descriptor/descriptor.cpp @@ -184,7 +184,7 @@ CHIP_ERROR DescriptorAttrAccess::Read(const ConcreteReadAttributePath & aPath, A } } // anonymous namespace -void MatterDescriptorPluginServerInitCallback(void) +void MatterDescriptorPluginServerInitCallback() { registerAttributeAccessOverride(&gAttrAccess); } diff --git a/src/app/clusters/diagnostic-logs-server/diagnostic-logs-server.cpp b/src/app/clusters/diagnostic-logs-server/diagnostic-logs-server.cpp index c3d59d66db159d..40b8e84443ce4e 100644 --- a/src/app/clusters/diagnostic-logs-server/diagnostic-logs-server.cpp +++ b/src/app/clusters/diagnostic-logs-server/diagnostic-logs-server.cpp @@ -15,7 +15,6 @@ * limitations under the License. */ -#include #include #include #include diff --git a/src/app/clusters/diagnostic-logs-server/diagnostic-logs-server.h b/src/app/clusters/diagnostic-logs-server/diagnostic-logs-server.h index beb7721d5d66d5..91348717c481c5 100644 --- a/src/app/clusters/diagnostic-logs-server/diagnostic-logs-server.h +++ b/src/app/clusters/diagnostic-logs-server/diagnostic-logs-server.h @@ -18,7 +18,6 @@ #pragma once -#include #include #include #include diff --git a/src/app/clusters/door-lock-server/door-lock-server-callback.cpp b/src/app/clusters/door-lock-server/door-lock-server-callback.cpp index c9c38f3fb23b5d..77c38d1f9d5d9f 100644 --- a/src/app/clusters/door-lock-server/door-lock-server-callback.cpp +++ b/src/app/clusters/door-lock-server/door-lock-server-callback.cpp @@ -24,7 +24,6 @@ #include "door-lock-server.h" #include #include -#include #include #include #include diff --git a/src/app/clusters/door-lock-server/door-lock-server.cpp b/src/app/clusters/door-lock-server/door-lock-server.cpp index a1e5307b66169d..a3c75c4818ff9c 100644 --- a/src/app/clusters/door-lock-server/door-lock-server.cpp +++ b/src/app/clusters/door-lock-server/door-lock-server.cpp @@ -24,7 +24,7 @@ #include "door-lock-server.h" #include #include -#include +#include #include #include #include diff --git a/src/app/clusters/fixed-label-server/fixed-label-server.cpp b/src/app/clusters/fixed-label-server/fixed-label-server.cpp index 45bb4c32092070..129b40d9896c0f 100644 --- a/src/app/clusters/fixed-label-server/fixed-label-server.cpp +++ b/src/app/clusters/fixed-label-server/fixed-label-server.cpp @@ -108,7 +108,7 @@ CHIP_ERROR FixedLabelAttrAccess::Read(const ConcreteReadAttributePath & aPath, A } } // anonymous namespace -void MatterFixedLabelPluginServerInitCallback(void) +void MatterFixedLabelPluginServerInitCallback() { registerAttributeAccessOverride(&gAttrAccess); } diff --git a/src/app/clusters/group-key-mgmt-server/group-key-mgmt-server.cpp b/src/app/clusters/group-key-mgmt-server/group-key-mgmt-server.cpp index e14e8fd3af7f0c..6d35ea2512a1bd 100644 --- a/src/app/clusters/group-key-mgmt-server/group-key-mgmt-server.cpp +++ b/src/app/clusters/group-key-mgmt-server/group-key-mgmt-server.cpp @@ -19,7 +19,6 @@ #include #include #include -#include #include #include #include diff --git a/src/app/clusters/groups-server/groups-server.cpp b/src/app/clusters/groups-server/groups-server.cpp index 4912062aa9c516..588220e0dc371f 100644 --- a/src/app/clusters/groups-server/groups-server.cpp +++ b/src/app/clusters/groups-server/groups-server.cpp @@ -21,9 +21,9 @@ #include #include #include -#include #include #include +#include #include #include #include @@ -160,7 +160,7 @@ bool emberAfGroupsClusterViewGroupCallback(app::CommandHandler * commandObj, con CHIP_ERROR err = CHIP_NO_ERROR; EmberAfStatus status = EMBER_ZCL_STATUS_NOT_FOUND; - VerifyOrExit(IsFabricGroupId(groupId), status = EMBER_ZCL_STATUS_INVALID_VALUE); + VerifyOrExit(IsFabricGroupId(groupId), status = EMBER_ZCL_STATUS_CONSTRAINT_ERROR); VerifyOrExit(nullptr != provider, status = EMBER_ZCL_STATUS_FAILURE); VerifyOrExit(provider->HasEndpoint(fabricIndex, groupId, commandPath.mEndpointId), status = EMBER_ZCL_STATUS_NOT_FOUND); @@ -211,7 +211,6 @@ struct GroupMembershipResponse { GroupDataProvider::GroupEndpoint mapping; size_t requestedCount = 0; - size_t matchCount = 0; ReturnErrorOnFailure(mCommandData.groupList.ComputeSize(&requestedCount)); if (0 == requestedCount) @@ -223,7 +222,6 @@ struct GroupMembershipResponse if (mapping.endpoint_id == mEndpoint) { ReturnErrorOnFailure(app::DataModel::Encode(writer, TLV::AnonymousTag(), mapping.group_id)); - matchCount++; ChipLogDetail(Zcl, " 0x%02x", mapping.group_id); } } @@ -238,7 +236,6 @@ struct GroupMembershipResponse if (mapping.endpoint_id == mEndpoint && mapping.group_id == iter.GetValue()) { ReturnErrorOnFailure(app::DataModel::Encode(writer, TLV::AnonymousTag(), mapping.group_id)); - matchCount++; ChipLogDetail(Zcl, " 0x%02x", mapping.group_id); break; } diff --git a/src/app/clusters/ias-zone-client/ias-zone-client.cpp b/src/app/clusters/ias-zone-client/ias-zone-client.cpp index 58eb813316a99e..7619a983986fb6 100644 --- a/src/app/clusters/ias-zone-client/ias-zone-client.cpp +++ b/src/app/clusters/ias-zone-client/ias-zone-client.cpp @@ -16,6 +16,7 @@ */ #include "ias-zone-client.h" +#include #include #include @@ -280,7 +281,7 @@ bool emberAfIasZoneClusterZoneEnrollRequestCallback(app::CommandHandler * comman zoneId = serverIndex; setServerZoneId(serverIndex, zoneId); } - emberAfFillExternalBuffer((ZCL_CLUSTER_SPECIFIC_COMMAND | ZCL_FRAME_CONTROL_CLIENT_TO_SERVER), ZCL_IAS_ZONE_CLUSTER_ID, + emberAfFillExternalBuffer((ZCL_CLUSTER_SPECIFIC_COMMAND | ZCL_FRAME_CONTROL_CLIENT_TO_SERVER), app::Clusters::IasZone::Id, ZCL_ZONE_ENROLL_RESPONSE_COMMAND_ID, "uu", responseCode, zoneId); // Need to send this command with our source EUI because the server will // check our EUI64 against his CIE Address to see if we're his CIE. @@ -355,7 +356,7 @@ static void setCieAddress(EmberNodeId destAddress) 0, // ieee (filled in later) }; emberAfGetEui64(&writeAttributes[3]); - emberAfFillExternalBuffer((ZCL_GLOBAL_COMMAND | ZCL_FRAME_CONTROL_CLIENT_TO_SERVER), ZCL_IAS_ZONE_CLUSTER_ID, + emberAfFillExternalBuffer((ZCL_GLOBAL_COMMAND | ZCL_FRAME_CONTROL_CLIENT_TO_SERVER), app::Clusters::IasZone::Id, ZCL_WRITE_ATTRIBUTES_COMMAND_ID, "b", writeAttributes, sizeof(writeAttributes)); emberAfIasZoneClusterPrintln("Writing CIE Address to IAS Zone Server"); if (EMBER_SUCCESS == sendCommand(destAddress)) @@ -404,7 +405,7 @@ static void checkForIasZoneServer(EmberNodeId emberNodeId, uint8_t * ieeeAddress return; } - EmberStatus status = emberAfFindDevicesByCluster(emberNodeId, ZCL_IAS_ZONE_CLUSTER_ID, + EmberStatus status = emberAfFindDevicesByCluster(emberNodeId, app::Clusters::IasZone::Id, true, // server cluster? iasZoneClientServiceDiscoveryCallback); @@ -434,7 +435,7 @@ void readIasZoneServerAttributes(EmberNodeId nodeId) EMBER_LOW_BYTE(ZCL_ZONE_STATUS_ATTRIBUTE_ID), EMBER_HIGH_BYTE(ZCL_ZONE_STATUS_ATTRIBUTE_ID), }; - emberAfFillExternalBuffer((ZCL_GLOBAL_COMMAND | ZCL_FRAME_CONTROL_CLIENT_TO_SERVER), ZCL_IAS_ZONE_CLUSTER_ID, + emberAfFillExternalBuffer((ZCL_GLOBAL_COMMAND | ZCL_FRAME_CONTROL_CLIENT_TO_SERVER), app::Clusters::IasZone::Id, ZCL_READ_ATTRIBUTES_COMMAND_ID, "b", iasZoneAttributeIds, sizeof(iasZoneAttributeIds)); if (EMBER_SUCCESS == sendCommand(nodeId)) { @@ -448,7 +449,7 @@ void readIasZoneServerCieAddress(EmberNodeId nodeId) EMBER_LOW_BYTE(ZCL_IAS_CIE_ADDRESS_ATTRIBUTE_ID), EMBER_HIGH_BYTE(ZCL_IAS_CIE_ADDRESS_ATTRIBUTE_ID), }; - emberAfFillExternalBuffer((ZCL_GLOBAL_COMMAND | ZCL_FRAME_CONTROL_CLIENT_TO_SERVER), ZCL_IAS_ZONE_CLUSTER_ID, + emberAfFillExternalBuffer((ZCL_GLOBAL_COMMAND | ZCL_FRAME_CONTROL_CLIENT_TO_SERVER), app::Clusters::IasZone::Id, ZCL_READ_ATTRIBUTES_COMMAND_ID, "b", iasZoneAttributeIds, sizeof(iasZoneAttributeIds)); if (EMBER_SUCCESS == sendCommand(nodeId)) { @@ -458,7 +459,7 @@ void readIasZoneServerCieAddress(EmberNodeId nodeId) void emberAfPluginIasZoneClientWriteAttributesResponseCallback(ClusterId clusterId, uint8_t * buffer, uint16_t bufLen) { - if (clusterId == ZCL_IAS_ZONE_CLUSTER_ID && iasZoneClientState == IAS_ZONE_CLIENT_STATE_SET_CIE_ADDRESS && + if (clusterId == app::Clusters::IasZone::Id && iasZoneClientState == IAS_ZONE_CLIENT_STATE_SET_CIE_ADDRESS && buffer[0] == EMBER_ZCL_STATUS_SUCCESS) { readIasZoneServerCieAddress(emberAfCurrentCommand()->source); @@ -470,7 +471,7 @@ void emberAfPluginIasZoneClientWriteAttributesResponseCallback(ClusterId cluster void emberAfPluginIasZoneClientReadAttributesResponseCallback(ClusterId clusterId, uint8_t * buffer, uint16_t bufLen) { uint8_t zoneStatus, zoneType, zoneState; - if (clusterId == ZCL_IAS_ZONE_CLUSTER_ID && + if (clusterId == app::Clusters::IasZone::Id && (iasZoneClientState == IAS_ZONE_CLIENT_STATE_READ_ATTRIBUTES || iasZoneClientState == IAS_ZONE_CLIENT_STATE_READ_CIE_ADDRESS)) { diff --git a/src/app/clusters/ias-zone-server/ias-zone-server.cpp b/src/app/clusters/ias-zone-server/ias-zone-server.cpp index fa774254801edd..3b08d92d45d977 100644 --- a/src/app/clusters/ias-zone-server/ias-zone-server.cpp +++ b/src/app/clusters/ias-zone-server/ias-zone-server.cpp @@ -20,9 +20,9 @@ #include #include #include -#include #include #include +#include #include #include #include @@ -170,7 +170,7 @@ static EmberStatus sendToClient(EndpointId endpoint) static void enrollWithClient(EndpointId endpoint) { EmberStatus status; - emberAfFillExternalBuffer((ZCL_CLUSTER_SPECIFIC_COMMAND | ZCL_FRAME_CONTROL_SERVER_TO_CLIENT), ZCL_IAS_ZONE_CLUSTER_ID, + emberAfFillExternalBuffer((ZCL_CLUSTER_SPECIFIC_COMMAND | ZCL_FRAME_CONTROL_SERVER_TO_CLIENT), IasZone::Id, ZCL_ZONE_ENROLL_REQUEST_COMMAND_ID, "vv", EMBER_AF_PLUGIN_IAS_ZONE_SERVER_ZONE_TYPE, EMBER_AF_MANUFACTURER_CODE); status = sendToClient(endpoint); @@ -213,7 +213,7 @@ MatterIasZoneClusterServerPreAttributeChangedCallback(const app::ConcreteAttribu // currently existing in the field. bindingEntry.type = EMBER_UNICAST_BINDING; bindingEntry.local = endpoint; - bindingEntry.clusterId = MakeOptional(ZCL_IAS_ZONE_CLUSTER_ID); + bindingEntry.clusterId = MakeOptional(IasZone::Id); bindingEntry.remote = emberAfCurrentCommand()->apsFrame->sourceEndpoint; bindingEntry.nodeId = destNodeId; @@ -238,7 +238,7 @@ MatterIasZoneClusterServerPreAttributeChangedCallback(const app::ConcreteAttribu } zeroAddress = true; - emberAfReadServerAttribute(endpoint, ZCL_IAS_ZONE_CLUSTER_ID, ZCL_IAS_CIE_ADDRESS_ATTRIBUTE_ID, (uint8_t *) ieeeAddress, 8); + emberAfReadServerAttribute(endpoint, IasZone::Id, ZCL_IAS_CIE_ADDRESS_ATTRIBUTE_ID, (uint8_t *) ieeeAddress, 8); for (i = 0; i < 8; i++) { if (ieeeAddress[i] != 0) @@ -255,8 +255,7 @@ MatterIasZoneClusterServerPreAttributeChangedCallback(const app::ConcreteAttribu // at this point because then the Write Attributes response will not // be sent. But we also delay to give the client time to configure us. emberAfIasZoneClusterPrintln("Sending enrollment after %d ms", DELAY_TIMER_MS); - emberAfScheduleServerTickExtended(endpoint, ZCL_IAS_ZONE_CLUSTER_ID, DELAY_TIMER_MS, EMBER_AF_SHORT_POLL, - EMBER_AF_STAY_AWAKE); + emberAfScheduleServerTickExtended(endpoint, IasZone::Id, DELAY_TIMER_MS, EMBER_AF_SHORT_POLL, EMBER_AF_STAY_AWAKE); } return Protocols::InteractionModel::Status::Success; @@ -269,12 +268,12 @@ EmberAfStatus emberAfPluginIasZoneClusterSetEnrollmentMethod(EndpointId endpoint if (emberAfIasZoneClusterAmIEnrolled(endpoint)) { emberAfIasZoneClusterPrintln("Error: Already enrolled"); - status = EMBER_ZCL_STATUS_NOT_AUTHORIZED; + status = EMBER_ZCL_STATUS_UNSUPPORTED_ACCESS; } else if (!isValidEnrollmentMode(method)) { emberAfIasZoneClusterPrintln("Invalid IAS Zone Server Enrollment Mode: %d", method); - status = EMBER_ZCL_STATUS_INVALID_VALUE; + status = EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } else { @@ -299,9 +298,8 @@ bool emberAfIasZoneClusterAmIEnrolled(EndpointId endpoint) { EmberAfIasZoneState zoneState = EMBER_ZCL_IAS_ZONE_STATE_NOT_ENROLLED; // Clear this out completely. EmberAfStatus status; - status = - emberAfReadServerAttribute(endpoint, ZCL_IAS_ZONE_CLUSTER_ID, ZCL_ZONE_STATE_ATTRIBUTE_ID, (unsigned char *) &zoneState, - 1); // uint8_t size + status = emberAfReadServerAttribute(endpoint, IasZone::Id, ZCL_ZONE_STATE_ATTRIBUTE_ID, (unsigned char *) &zoneState, + 1); // uint8_t size return (status == EMBER_ZCL_STATUS_SUCCESS && zoneState == EMBER_ZCL_IAS_ZONE_STATE_ENROLLED); } @@ -310,7 +308,7 @@ static void updateEnrollState(EndpointId endpoint, bool enrolled) { EmberAfIasZoneState zoneState = (enrolled ? EMBER_ZCL_IAS_ZONE_STATE_ENROLLED : EMBER_ZCL_IAS_ZONE_STATE_NOT_ENROLLED); - emberAfWriteServerAttribute(endpoint, ZCL_IAS_ZONE_CLUSTER_ID, ZCL_ZONE_STATE_ATTRIBUTE_ID, (uint8_t *) &zoneState, + emberAfWriteServerAttribute(endpoint, IasZone::Id, ZCL_ZONE_STATE_ATTRIBUTE_ID, (uint8_t *) &zoneState, ZCL_INT8U_ATTRIBUTE_TYPE); emberAfIasZoneClusterPrintln("IAS Zone Server State: %pEnrolled", (enrolled ? "" : "NOT ")); } @@ -326,7 +324,7 @@ bool emberAfIasZoneClusterZoneEnrollResponseCallback(app::CommandHandler * comma EmberAfStatus status; endpoint = emberAfCurrentEndpoint(); - status = emberAfReadServerAttribute(endpoint, ZCL_IAS_ZONE_CLUSTER_ID, ZCL_ZONE_ID_ATTRIBUTE_ID, &epZoneId, sizeof(uint8_t)); + status = emberAfReadServerAttribute(endpoint, IasZone::Id, ZCL_ZONE_ID_ATTRIBUTE_ID, &epZoneId, sizeof(uint8_t)); if (status == EMBER_ZCL_STATUS_SUCCESS) { if (enrollResponseCode == EMBER_ZCL_IAS_ENROLL_RESPONSE_CODE_SUCCESS) @@ -355,7 +353,7 @@ static EmberStatus sendZoneUpdate(uint16_t zoneStatus, uint16_t timeSinceStatusO { return EMBER_INVALID_CALL; } - emberAfFillExternalBuffer((ZCL_CLUSTER_SPECIFIC_COMMAND | ZCL_FRAME_CONTROL_SERVER_TO_CLIENT), ZCL_IAS_ZONE_CLUSTER_ID, + emberAfFillExternalBuffer((ZCL_CLUSTER_SPECIFIC_COMMAND | ZCL_FRAME_CONTROL_SERVER_TO_CLIENT), IasZone::Id, ZCL_ZONE_STATUS_CHANGE_NOTIFICATION_COMMAND_ID, "vuuv", zoneStatus, 0 /*extended status, must be zero per spec*/, emberAfPluginIasZoneServerGetZoneId(endpoint), timeSinceStatusOccurredQs /* called "delay" in the spec */); @@ -382,7 +380,7 @@ EmberStatus emberAfPluginIasZoneServerUpdateZoneStatus(EndpointId endpoint, uint #endif EmberStatus sendStatus = EMBER_SUCCESS; - emberAfWriteServerAttribute(endpoint, ZCL_IAS_ZONE_CLUSTER_ID, ZCL_ZONE_STATUS_ATTRIBUTE_ID, (uint8_t *) &newStatus, + emberAfWriteServerAttribute(endpoint, IasZone::Id, ZCL_ZONE_STATUS_ATTRIBUTE_ID, (uint8_t *) &newStatus, ZCL_INT16U_ATTRIBUTE_TYPE); if (enrollmentMethod == EMBER_ZCL_IAS_ZONE_ENROLLMENT_MODE_TRIP_TO_PAIR) @@ -390,7 +388,7 @@ EmberStatus emberAfPluginIasZoneServerUpdateZoneStatus(EndpointId endpoint, uint // If unenrolled, send Zone Enroll Request command. if (!emberAfIasZoneClusterAmIEnrolled(endpoint)) { - emberAfScheduleServerTick(endpoint, ZCL_IAS_ZONE_CLUSTER_ID, DELAY_TIMER_MS); + emberAfScheduleServerTick(endpoint, IasZone::Id, DELAY_TIMER_MS); // Don't send the zone status update since not enrolled. return EMBER_SUCCESS; } @@ -525,8 +523,7 @@ void emberAfIasZoneClusterServerInitCallback(EndpointId endpoint) #endif zoneType = (EmberAfIasZoneType) EMBER_AF_PLUGIN_IAS_ZONE_SERVER_ZONE_TYPE; - emberAfWriteAttribute(endpoint, ZCL_IAS_ZONE_CLUSTER_ID, ZCL_ZONE_TYPE_ATTRIBUTE_ID, (uint8_t *) &zoneType, - ZCL_INT16U_ATTRIBUTE_TYPE); + emberAfWriteAttribute(endpoint, IasZone::Id, ZCL_ZONE_TYPE_ATTRIBUTE_ID, (uint8_t *) &zoneType, ZCL_INT16U_ATTRIBUTE_TYPE); emberAfPluginIasZoneServerUpdateZoneStatus(endpoint, 0, // status: All alarms cleared @@ -541,7 +538,7 @@ void emberAfIasZoneClusterServerTickCallback(EndpointId endpoint) uint8_t emberAfPluginIasZoneServerGetZoneId(EndpointId endpoint) { uint8_t zoneId = UNDEFINED_ZONE_ID; - emberAfReadServerAttribute(endpoint, ZCL_IAS_ZONE_CLUSTER_ID, ZCL_ZONE_ID_ATTRIBUTE_ID, &zoneId, + emberAfReadServerAttribute(endpoint, IasZone::Id, ZCL_ZONE_ID_ATTRIBUTE_ID, &zoneId, emberAfGetDataSize(ZCL_INT8U_ATTRIBUTE_TYPE)); return zoneId; } @@ -569,7 +566,7 @@ static bool areZoneServerAttributesNonVolatile(EndpointId endpoint) static void setZoneId(EndpointId endpoint, uint8_t zoneId) { emberAfIasZoneClusterPrintln("IAS Zone Server Zone ID: 0x%X", zoneId); - emberAfWriteServerAttribute(endpoint, ZCL_IAS_ZONE_CLUSTER_ID, ZCL_ZONE_ID_ATTRIBUTE_ID, &zoneId, ZCL_INT8U_ATTRIBUTE_TYPE); + emberAfWriteServerAttribute(endpoint, IasZone::Id, ZCL_ZONE_ID_ATTRIBUTE_ID, &zoneId, ZCL_INT8U_ATTRIBUTE_TYPE); } static void unenrollSecurityDevice(EndpointId endpoint) @@ -577,10 +574,10 @@ static void unenrollSecurityDevice(EndpointId endpoint) uint8_t ieeeAddress[] = { 0, 0, 0, 0, 0, 0, 0, 0 }; uint16_t zoneType = EMBER_AF_PLUGIN_IAS_ZONE_SERVER_ZONE_TYPE; - emberAfWriteServerAttribute(endpoint, ZCL_IAS_ZONE_CLUSTER_ID, ZCL_IAS_CIE_ADDRESS_ATTRIBUTE_ID, (uint8_t *) ieeeAddress, + emberAfWriteServerAttribute(endpoint, IasZone::Id, ZCL_IAS_CIE_ADDRESS_ATTRIBUTE_ID, (uint8_t *) ieeeAddress, ZCL_NODE_ID_ATTRIBUTE_TYPE); - emberAfWriteServerAttribute(endpoint, ZCL_IAS_ZONE_CLUSTER_ID, ZCL_ZONE_TYPE_ATTRIBUTE_ID, (uint8_t *) &zoneType, + emberAfWriteServerAttribute(endpoint, IasZone::Id, ZCL_ZONE_TYPE_ATTRIBUTE_ID, (uint8_t *) &zoneType, ZCL_INT16U_ATTRIBUTE_TYPE); setZoneId(endpoint, UNDEFINED_ZONE_ID); @@ -601,7 +598,7 @@ void emberAfPluginIasZoneServerStackStatusCallback(EmberStatus status) for (uint16_t i = 0; i < emberAfEndpointCount(); i++) { endpoint = emberAfEndpointFromIndex(i); - if (emberAfContainsServer(endpoint, ZCL_IAS_ZONE_CLUSTER_ID)) + if (emberAfContainsServer(endpoint, IasZone::Id)) { unenrollSecurityDevice(endpoint); } diff --git a/src/app/clusters/identify-server/identify-server.cpp b/src/app/clusters/identify-server/identify-server.cpp index 89720ad41fb502..5d749c951a7a85 100644 --- a/src/app/clusters/identify-server/identify-server.cpp +++ b/src/app/clusters/identify-server/identify-server.cpp @@ -21,7 +21,6 @@ #include #include #include -#include #include #include #include diff --git a/src/app/clusters/level-control/level-control.cpp b/src/app/clusters/level-control/level-control.cpp index 22db98f75f2a0a..c97fad07a2fae3 100644 --- a/src/app/clusters/level-control/level-control.cpp +++ b/src/app/clusters/level-control/level-control.cpp @@ -830,7 +830,7 @@ static void moveHandler(EndpointId endpoint, CommandId commandId, uint8_t moveMo difference = static_cast(currentLevel.Value() - state->minLevel); break; default: - status = EMBER_ZCL_STATUS_INVALID_FIELD; + status = EMBER_ZCL_STATUS_INVALID_COMMAND; goto send_default_response; } @@ -972,7 +972,7 @@ static void stepHandler(EndpointId endpoint, CommandId commandId, uint8_t stepMo } break; default: - status = EMBER_ZCL_STATUS_INVALID_FIELD; + status = EMBER_ZCL_STATUS_INVALID_COMMAND; goto send_default_response; } @@ -1084,20 +1084,6 @@ void emberAfOnOffClusterLevelControlEffectCallback(EndpointId endpoint, bool new return; } - // if the OnOff feature is not supported, the effect on LevelControl is ignored - if (!HasFeature(endpoint, chip::app::Clusters::LevelControl::LevelControlFeature::kOnOff)) - { - emberAfLevelControlClusterPrintln("OnOff feature not supported, ignore LevelControlEffect"); - if (!newValue) - { - // OnOff server expects LevelControl to handle the OnOff attribute change, - // when going to off state. The attribute is set directly rather - // than using setOnOff function to avoid misleading comments in log. - OnOff::Attributes::OnOff::Set(endpoint, OnOff::Commands::Off::Id); - } - return; - } - uint8_t minimumLevelAllowedForTheDevice = state->minLevel; // "Temporarily store CurrentLevel." @@ -1312,7 +1298,7 @@ static bool areStartUpLevelControlServerAttributesNonVolatile(EndpointId endpoin void emberAfPluginLevelControlClusterServerPostInitCallback(EndpointId endpoint) {} -bool HasFeature(chip::EndpointId endpoint, chip::app::Clusters::LevelControl::LevelControlFeature feature) +bool LevelControlHasFeature(EndpointId endpoint, LevelControlFeature feature) { bool success; uint32_t featureMap; diff --git a/src/app/clusters/level-control/level-control.h b/src/app/clusters/level-control/level-control.h index d87d41d6ee7482..0ae5105d93a841 100644 --- a/src/app/clusters/level-control/level-control.h +++ b/src/app/clusters/level-control/level-control.h @@ -26,16 +26,21 @@ #include -#include +#include #include -/** @brief On/off Cluster Server Post Init +/** @brief Level Control Cluster Server Post Init * - * Following resolution of the On/Off state at startup for this endpoint, perform any + * Following resolution of the Level Control state at startup for this endpoint, perform any * additional initialization needed; e.g., synchronize hardware state. * * @param endpoint Endpoint that is being initialized Ver.: always */ void emberAfPluginLevelControlClusterServerPostInitCallback(chip::EndpointId endpoint); -bool HasFeature(chip::EndpointId endpoint, chip::app::Clusters::LevelControl::LevelControlFeature feature); +/** + * Check whether the instance of the Level Control cluster on the given endpoint + * has the given feature. The implementation is allowed to assume there is in + * fact an instance of Level Control on the given endpoint. + */ +bool LevelControlHasFeature(chip::EndpointId endpoint, chip::app::Clusters::LevelControl::LevelControlFeature feature); diff --git a/src/app/clusters/localization-configuration-server/localization-configuration-server.cpp b/src/app/clusters/localization-configuration-server/localization-configuration-server.cpp index 9679a7aee6ae05..0776016f686ae0 100644 --- a/src/app/clusters/localization-configuration-server/localization-configuration-server.cpp +++ b/src/app/clusters/localization-configuration-server/localization-configuration-server.cpp @@ -215,7 +215,7 @@ void emberAfLocalizationConfigurationClusterServerInitCallback(EndpointId endpoi } } -void MatterLocalizationConfigurationPluginServerInitCallback(void) +void MatterLocalizationConfigurationPluginServerInitCallback() { registerAttributeAccessOverride(&gAttrAccess); } diff --git a/src/app/clusters/mode-select-server/mode-select-server.cpp b/src/app/clusters/mode-select-server/mode-select-server.cpp index 01979fcb32c521..14b388445f2621 100644 --- a/src/app/clusters/mode-select-server/mode-select-server.cpp +++ b/src/app/clusters/mode-select-server/mode-select-server.cpp @@ -215,7 +215,7 @@ inline bool areStartUpModeAndCurrentModeNonVolatile(EndpointId endpointId) } // namespace -void MatterModeSelectPluginServerInitCallback(void) +void MatterModeSelectPluginServerInitCallback() { registerAttributeAccessOverride(&gModeSelectAttrAccess); } diff --git a/src/app/clusters/on-off-server/on-off-server.cpp b/src/app/clusters/on-off-server/on-off-server.cpp index 8c96c153c7c5b2..260051d636a78c 100644 --- a/src/app/clusters/on-off-server/on-off-server.cpp +++ b/src/app/clusters/on-off-server/on-off-server.cpp @@ -28,6 +28,10 @@ #include #endif // EMBER_AF_PLUGIN_SCENES +#ifdef EMBER_AF_PLUGIN_LEVEL_CONTROL +#include +#endif // EMBER_AF_PLUGIN_LEVEL_CONTROL + using namespace chip; using namespace chip::app::Clusters; using namespace chip::app::Clusters::OnOff; @@ -77,6 +81,18 @@ EmberAfStatus OnOffServer::getOnOffValue(chip::EndpointId endpoint, bool * curre return status; } +#ifdef EMBER_AF_PLUGIN_LEVEL_CONTROL +static bool LevelControlWithOnOffFeaturePresent(EndpointId endpoint) +{ + if (!emberAfContainsServer(endpoint, LevelControl::Id)) + { + return false; + } + + return LevelControlHasFeature(endpoint, LevelControl::LevelControlFeature::kOnOff); +} +#endif // EMBER_AF_PLUGIN_LEVEL_CONTROL + /** @brief On/off Cluster Set Value * * This function is called when the on/off value needs to be set, either through @@ -153,7 +169,7 @@ EmberAfStatus OnOffServer::setOnOffValue(chip::EndpointId endpoint, chip::Comman #ifdef EMBER_AF_PLUGIN_LEVEL_CONTROL // If initiatedByLevelChange is false, then we assume that the level change // ZCL stuff has not happened and we do it here - if (!initiatedByLevelChange && emberAfContainsServer(endpoint, LevelControl::Id)) + if (!initiatedByLevelChange && LevelControlWithOnOffFeaturePresent(endpoint)) { emberAfOnOffClusterLevelControlEffectCallback(endpoint, newValue); } @@ -183,7 +199,7 @@ EmberAfStatus OnOffServer::setOnOffValue(chip::EndpointId endpoint, chip::Comman #ifdef EMBER_AF_PLUGIN_LEVEL_CONTROL // If initiatedByLevelChange is false, then we assume that the level change // ZCL stuff has not happened and we do it here - if (!initiatedByLevelChange && emberAfContainsServer(endpoint, LevelControl::Id)) + if (!initiatedByLevelChange && LevelControlWithOnOffFeaturePresent(endpoint)) { emberAfOnOffClusterLevelControlEffectCallback(endpoint, newValue); } @@ -433,7 +449,7 @@ bool OnOffServer::OnWithRecallGlobalSceneCommand(app::CommandHandler * commandOb return true; } -uint32_t OnOffServer::calculateNextWaitTimeMS(void) +uint32_t OnOffServer::calculateNextWaitTimeMS() { const chip::System::Clock::Timestamp currentTime = chip::System::SystemClock().GetMonotonicTimestamp(); chip::System::Clock::Timestamp waitTime = UPDATE_TIME_MS; diff --git a/src/app/clusters/operational-credentials-server/operational-credentials-server.cpp b/src/app/clusters/operational-credentials-server/operational-credentials-server.cpp index d25beb3c58af8f..bfcdc9c7339947 100644 --- a/src/app/clusters/operational-credentials-server/operational-credentials-server.cpp +++ b/src/app/clusters/operational-credentials-server/operational-credentials-server.cpp @@ -395,7 +395,7 @@ class OpCredsFabricTableDelegate : public chip::FabricTable::Delegate OpCredsFabricTableDelegate gFabricDelegate; -void MatterOperationalCredentialsPluginServerInitCallback(void) +void MatterOperationalCredentialsPluginServerInitCallback() { registerAttributeAccessOverride(&gAttrAccess); diff --git a/src/app/clusters/ota-requestor/DefaultOTARequestorDriver.cpp b/src/app/clusters/ota-requestor/DefaultOTARequestorDriver.cpp index f2e4f6870c4db4..412ce1573d763d 100644 --- a/src/app/clusters/ota-requestor/DefaultOTARequestorDriver.cpp +++ b/src/app/clusters/ota-requestor/DefaultOTARequestorDriver.cpp @@ -388,7 +388,7 @@ void DefaultOTARequestorDriver::StopPeriodicQueryTimer() CancelDelayedAction(PeriodicQueryTimerHandler, this); } -void DefaultOTARequestorDriver::RekickPeriodicQueryTimer(void) +void DefaultOTARequestorDriver::RekickPeriodicQueryTimer() { ChipLogProgress(SoftwareUpdate, "Rekicking the Periodic Query timer"); StopPeriodicQueryTimer(); diff --git a/src/app/clusters/ota-requestor/ota-requestor-server.cpp b/src/app/clusters/ota-requestor/ota-requestor-server.cpp index 4010598c295a85..06adf80e4de07f 100644 --- a/src/app/clusters/ota-requestor/ota-requestor-server.cpp +++ b/src/app/clusters/ota-requestor/ota-requestor-server.cpp @@ -287,7 +287,7 @@ bool emberAfOtaSoftwareUpdateRequestorClusterAnnounceOtaProviderCallback( // ----------------------------------------------------------------------------- // Plugin initialization -void MatterOtaSoftwareUpdateRequestorPluginServerInitCallback(void) +void MatterOtaSoftwareUpdateRequestorPluginServerInitCallback() { registerAttributeAccessOverride(&gAttrAccess); } diff --git a/src/app/clusters/power-source-configuration-server/power-source-configuration-server.cpp b/src/app/clusters/power-source-configuration-server/power-source-configuration-server.cpp index 326e7f6b37bdaf..cc5df0e278bef1 100644 --- a/src/app/clusters/power-source-configuration-server/power-source-configuration-server.cpp +++ b/src/app/clusters/power-source-configuration-server/power-source-configuration-server.cpp @@ -98,7 +98,7 @@ CHIP_ERROR PowerSourceConfigurationAttrAccess::Read(const ConcreteReadAttributeP } // anonymous namespace -void MatterPowerSourceConfigurationPluginServerInitCallback(void) +void MatterPowerSourceConfigurationPluginServerInitCallback() { registerAttributeAccessOverride(&gAttrAccess); } diff --git a/src/app/clusters/power-source-server/power-source-server.cpp b/src/app/clusters/power-source-server/power-source-server.cpp index d813e568f64fc3..58e21cd9907e69 100644 --- a/src/app/clusters/power-source-server/power-source-server.cpp +++ b/src/app/clusters/power-source-server/power-source-server.cpp @@ -64,7 +64,7 @@ CHIP_ERROR PowerSourceAttrAccess::Read(const ConcreteReadAttributePath & aPath, } // anonymous namespace -void MatterPowerSourcePluginServerInitCallback(void) +void MatterPowerSourcePluginServerInitCallback() { registerAttributeAccessOverride(&gAttrAccess); } diff --git a/src/app/clusters/pump-configuration-and-control-server/pump-configuration-and-control-server.cpp b/src/app/clusters/pump-configuration-and-control-server/pump-configuration-and-control-server.cpp index 09f0fb4f88881b..ae3552eaef68dc 100644 --- a/src/app/clusters/pump-configuration-and-control-server/pump-configuration-and-control-server.cpp +++ b/src/app/clusters/pump-configuration-and-control-server/pump-configuration-and-control-server.cpp @@ -60,7 +60,7 @@ enum class RemoteSensorType : uint8_t kTemperatureSensor = 0x03, }; -static RemoteSensorType detectRemoteSensorConnected(void) +static RemoteSensorType detectRemoteSensorConnected() { // TODO: Detect the sensor types attached to the pump control cluster // this could be pressure, flow or temperature sensors. @@ -462,7 +462,7 @@ void MatterPumpConfigurationAndControlClusterServerAttributeChangedCallback(cons } } -void MatterPumpConfigurationAndControlPluginServerInitCallback(void) +void MatterPumpConfigurationAndControlPluginServerInitCallback() { emberAfDebugPrintln("Initialize PCC Plugin Server Cluster."); diff --git a/src/app/clusters/scenes/scenes.cpp b/src/app/clusters/scenes/scenes.cpp index 644f47e8a02b27..ed039229b4e57a 100644 --- a/src/app/clusters/scenes/scenes.cpp +++ b/src/app/clusters/scenes/scenes.cpp @@ -19,9 +19,9 @@ #include "app/util/common.h" #include #include -#include #include #include +#include #include #include #include @@ -35,6 +35,7 @@ #endif using namespace chip; +using namespace chip::app::Clusters; using namespace chip::app::Clusters::Scenes; uint8_t emberAfPluginScenesServerEntriesInUse = 0; @@ -88,8 +89,8 @@ void emberAfScenesClusterServerInitCallback(EndpointId endpoint) { // The high bit of Name Support indicates whether scene names are supported. uint8_t nameSupport = EMBER_BIT(7); - writeServerAttribute(endpoint, ZCL_SCENES_CLUSTER_ID, ZCL_SCENE_NAME_SUPPORT_ATTRIBUTE_ID, "name support", - (uint8_t *) &nameSupport, ZCL_BITMAP8_ATTRIBUTE_TYPE); + writeServerAttribute(endpoint, Scenes::Id, ZCL_SCENE_NAME_SUPPORT_ATTRIBUTE_ID, "name support", (uint8_t *) &nameSupport, + ZCL_BITMAP8_ATTRIBUTE_TYPE); } #endif #if !defined(EMBER_AF_PLUGIN_SCENES_USE_TOKENS) || defined(EZSP_HOST) @@ -110,7 +111,7 @@ void emberAfScenesClusterServerInitCallback(EndpointId endpoint) EmberAfStatus emberAfScenesSetSceneCountAttribute(EndpointId endpoint, uint8_t newCount) { - return writeServerAttribute(endpoint, ZCL_SCENES_CLUSTER_ID, ZCL_SCENE_COUNT_ATTRIBUTE_ID, "scene count", (uint8_t *) &newCount, + return writeServerAttribute(endpoint, Scenes::Id, ZCL_SCENE_COUNT_ATTRIBUTE_ID, "scene count", (uint8_t *) &newCount, ZCL_INT8U_ATTRIBUTE_TYPE); } @@ -120,22 +121,22 @@ EmberAfStatus emberAfScenesMakeValid(EndpointId endpoint, uint8_t sceneId, Group bool valid = true; // scene ID - status = writeServerAttribute(endpoint, ZCL_SCENES_CLUSTER_ID, ZCL_CURRENT_SCENE_ATTRIBUTE_ID, "current scene", - (uint8_t *) &sceneId, ZCL_INT8U_ATTRIBUTE_TYPE); + status = writeServerAttribute(endpoint, Scenes::Id, ZCL_CURRENT_SCENE_ATTRIBUTE_ID, "current scene", (uint8_t *) &sceneId, + ZCL_INT8U_ATTRIBUTE_TYPE); if (status != EMBER_ZCL_STATUS_SUCCESS) { return status; } // group ID - status = writeServerAttribute(endpoint, ZCL_SCENES_CLUSTER_ID, ZCL_CURRENT_GROUP_ATTRIBUTE_ID, "current group", - (uint8_t *) &groupId, ZCL_INT16U_ATTRIBUTE_TYPE); + status = writeServerAttribute(endpoint, Scenes::Id, ZCL_CURRENT_GROUP_ATTRIBUTE_ID, "current group", (uint8_t *) &groupId, + ZCL_INT16U_ATTRIBUTE_TYPE); if (status != EMBER_ZCL_STATUS_SUCCESS) { return status; } - status = writeServerAttribute(endpoint, ZCL_SCENES_CLUSTER_ID, ZCL_SCENE_VALID_ATTRIBUTE_ID, "scene valid", (uint8_t *) &valid, + status = writeServerAttribute(endpoint, Scenes::Id, ZCL_SCENE_VALID_ATTRIBUTE_ID, "scene valid", (uint8_t *) &valid, ZCL_BOOLEAN_ATTRIBUTE_TYPE); return status; } @@ -143,11 +144,11 @@ EmberAfStatus emberAfScenesMakeValid(EndpointId endpoint, uint8_t sceneId, Group EmberAfStatus emberAfScenesClusterMakeInvalidCallback(EndpointId endpoint) { bool valid = false; - return writeServerAttribute(endpoint, ZCL_SCENES_CLUSTER_ID, ZCL_SCENE_VALID_ATTRIBUTE_ID, "scene valid", (uint8_t *) &valid, + return writeServerAttribute(endpoint, Scenes::Id, ZCL_SCENE_VALID_ATTRIBUTE_ID, "scene valid", (uint8_t *) &valid, ZCL_BOOLEAN_ATTRIBUTE_TYPE); } -void emAfPluginScenesServerPrintInfo(void) +void emAfPluginScenesServerPrintInfo() { uint8_t i; EmberAfSceneTableEntry entry; @@ -233,7 +234,7 @@ bool emberAfScenesClusterRemoveSceneCallback(app::CommandHandler * commandObj, c if (!isEndpointInGroup(fabricIndex, emberAfCurrentEndpoint(), groupId)) { - status = EMBER_ZCL_STATUS_INVALID_FIELD; + status = EMBER_ZCL_STATUS_INVALID_COMMAND; } else { @@ -259,8 +260,7 @@ bool emberAfScenesClusterRemoveSceneCallback(app::CommandHandler * commandObj, c if (emberAfCurrentCommand()->type == EMBER_INCOMING_UNICAST || emberAfCurrentCommand()->type == EMBER_INCOMING_UNICAST_REPLY) { { - app::ConcreteCommandPath path = { emberAfCurrentEndpoint(), ZCL_SCENES_CLUSTER_ID, - ZCL_REMOVE_SCENE_RESPONSE_COMMAND_ID }; + app::ConcreteCommandPath path = { emberAfCurrentEndpoint(), Scenes::Id, ZCL_REMOVE_SCENE_RESPONSE_COMMAND_ID }; TLV::TLVWriter * writer = nullptr; SuccessOrExit(err = commandObj->PrepareCommand(path)); VerifyOrExit((writer = commandObj->GetCommandDataIBTLVWriter()) != nullptr, err = CHIP_ERROR_INCORRECT_STATE); @@ -284,7 +284,7 @@ bool emberAfScenesClusterRemoveAllScenesCallback(app::CommandHandler * commandOb auto fabricIndex = commandObj->GetAccessingFabricIndex(); auto & groupId = commandData.groupId; - EmberAfStatus status = EMBER_ZCL_STATUS_INVALID_FIELD; + EmberAfStatus status = EMBER_ZCL_STATUS_INVALID_COMMAND; CHIP_ERROR err = CHIP_NO_ERROR; emberAfScenesClusterPrintln("RX: RemoveAllScenes 0x%2x", groupId); @@ -312,8 +312,7 @@ bool emberAfScenesClusterRemoveAllScenesCallback(app::CommandHandler * commandOb if (emberAfCurrentCommand()->type == EMBER_INCOMING_UNICAST || emberAfCurrentCommand()->type == EMBER_INCOMING_UNICAST_REPLY) { { - app::ConcreteCommandPath path = { emberAfCurrentEndpoint(), ZCL_SCENES_CLUSTER_ID, - ZCL_REMOVE_ALL_SCENES_RESPONSE_COMMAND_ID }; + app::ConcreteCommandPath path = { emberAfCurrentEndpoint(), Scenes::Id, ZCL_REMOVE_ALL_SCENES_RESPONSE_COMMAND_ID }; TLV::TLVWriter * writer = nullptr; SuccessOrExit(err = commandObj->PrepareCommand(path)); VerifyOrExit((writer = commandObj->GetCommandDataIBTLVWriter()) != nullptr, err = CHIP_ERROR_INCORRECT_STATE); @@ -347,8 +346,7 @@ bool emberAfScenesClusterStoreSceneCallback(app::CommandHandler * commandObj, co if (emberAfCurrentCommand()->type == EMBER_INCOMING_UNICAST || emberAfCurrentCommand()->type == EMBER_INCOMING_UNICAST_REPLY) { { - app::ConcreteCommandPath path = { emberAfCurrentEndpoint(), ZCL_SCENES_CLUSTER_ID, - ZCL_STORE_SCENE_RESPONSE_COMMAND_ID }; + app::ConcreteCommandPath path = { emberAfCurrentEndpoint(), Scenes::Id, ZCL_STORE_SCENE_RESPONSE_COMMAND_ID }; TLV::TLVWriter * writer = nullptr; SuccessOrExit(err = commandObj->PrepareCommand(path)); VerifyOrExit((writer = commandObj->GetCommandDataIBTLVWriter()) != nullptr, err = CHIP_ERROR_INCORRECT_STATE); @@ -419,7 +417,7 @@ bool emberAfScenesClusterGetSceneMembershipCallback(app::CommandHandler * comman if (!isEndpointInGroup(fabricIndex, emberAfCurrentEndpoint(), groupId)) { - status = EMBER_ZCL_STATUS_INVALID_FIELD; + status = EMBER_ZCL_STATUS_INVALID_COMMAND; } if (status == EMBER_ZCL_STATUS_SUCCESS) @@ -443,8 +441,7 @@ bool emberAfScenesClusterGetSceneMembershipCallback(app::CommandHandler * comman } { - app::ConcreteCommandPath path = { emberAfCurrentEndpoint(), ZCL_SCENES_CLUSTER_ID, - ZCL_GET_SCENE_MEMBERSHIP_RESPONSE_COMMAND_ID }; + app::ConcreteCommandPath path = { emberAfCurrentEndpoint(), Scenes::Id, ZCL_GET_SCENE_MEMBERSHIP_RESPONSE_COMMAND_ID }; TLV::TLVWriter * writer = nullptr; SuccessOrExit(err = commandObj->PrepareCommand(path)); VerifyOrExit((writer = commandObj->GetCommandDataIBTLVWriter()) != nullptr, err = CHIP_ERROR_INCORRECT_STATE); @@ -474,7 +471,7 @@ EmberAfStatus emberAfScenesClusterStoreCurrentSceneCallback(chip::FabricIndex fa if (!isEndpointInGroup(fabricIndex, endpoint, groupId)) { - return EMBER_ZCL_STATUS_INVALID_FIELD; + return EMBER_ZCL_STATUS_INVALID_COMMAND; } for (i = 0; i < MATTER_SCENES_TABLE_SIZE; i++) @@ -494,7 +491,7 @@ EmberAfStatus emberAfScenesClusterStoreCurrentSceneCallback(chip::FabricIndex fa // If the target index is still zero, the table is full. if (index == EMBER_AF_SCENE_TABLE_NULL_INDEX) { - return EMBER_ZCL_STATUS_INSUFFICIENT_SPACE; + return EMBER_ZCL_STATUS_RESOURCE_EXHAUSTED; } emberAfPluginScenesServerRetrieveSceneEntry(entry, index); @@ -502,69 +499,64 @@ EmberAfStatus emberAfScenesClusterStoreCurrentSceneCallback(chip::FabricIndex fa // When creating a new entry or refreshing an existing one, the extension // fields are updated with the current state of other clusters on the device. #ifdef ZCL_USING_ON_OFF_CLUSTER_SERVER - entry.hasOnOffValue = readServerAttribute(endpoint, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, "on/off", - (uint8_t *) &entry.onOffValue, sizeof(entry.onOffValue)); + entry.hasOnOffValue = readServerAttribute(endpoint, OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, "on/off", (uint8_t *) &entry.onOffValue, + sizeof(entry.onOffValue)); #endif #ifdef ZCL_USING_LEVEL_CONTROL_CLUSTER_SERVER - entry.hasCurrentLevelValue = - readServerAttribute(endpoint, ZCL_LEVEL_CONTROL_CLUSTER_ID, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, "current level", - (uint8_t *) &entry.currentLevelValue, sizeof(entry.currentLevelValue)); + entry.hasCurrentLevelValue = readServerAttribute(endpoint, LevelControl::Id, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, "current level", + (uint8_t *) &entry.currentLevelValue, sizeof(entry.currentLevelValue)); #endif #ifdef ZCL_USING_THERMOSTAT_CLUSTER_SERVER - entry.hasOccupiedCoolingSetpointValue = readServerAttribute( - endpoint, ZCL_THERMOSTAT_CLUSTER_ID, ZCL_OCCUPIED_COOLING_SETPOINT_ATTRIBUTE_ID, "occupied cooling setpoint", - (uint8_t *) &entry.occupiedCoolingSetpointValue, sizeof(entry.occupiedCoolingSetpointValue)); - entry.hasOccupiedHeatingSetpointValue = readServerAttribute( - endpoint, ZCL_THERMOSTAT_CLUSTER_ID, ZCL_OCCUPIED_HEATING_SETPOINT_ATTRIBUTE_ID, "occupied heating setpoint", - (uint8_t *) &entry.occupiedHeatingSetpointValue, sizeof(entry.occupiedHeatingSetpointValue)); - entry.hasSystemModeValue = readServerAttribute(endpoint, ZCL_THERMOSTAT_CLUSTER_ID, ZCL_SYSTEM_MODE_ATTRIBUTE_ID, "system mode", + entry.hasOccupiedCoolingSetpointValue = + readServerAttribute(endpoint, Thermostat::Id, ZCL_OCCUPIED_COOLING_SETPOINT_ATTRIBUTE_ID, "occupied cooling setpoint", + (uint8_t *) &entry.occupiedCoolingSetpointValue, sizeof(entry.occupiedCoolingSetpointValue)); + entry.hasOccupiedHeatingSetpointValue = + readServerAttribute(endpoint, Thermostat::Id, ZCL_OCCUPIED_HEATING_SETPOINT_ATTRIBUTE_ID, "occupied heating setpoint", + (uint8_t *) &entry.occupiedHeatingSetpointValue, sizeof(entry.occupiedHeatingSetpointValue)); + entry.hasSystemModeValue = readServerAttribute(endpoint, Thermostat::Id, ZCL_SYSTEM_MODE_ATTRIBUTE_ID, "system mode", (uint8_t *) &entry.systemModeValue, sizeof(entry.systemModeValue)); #endif #ifdef ZCL_USING_COLOR_CONTROL_CLUSTER_SERVER - entry.hasCurrentXValue = readServerAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_X_ATTRIBUTE_ID, - "current x", (uint8_t *) &entry.currentXValue, sizeof(entry.currentXValue)); - entry.hasCurrentYValue = readServerAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_Y_ATTRIBUTE_ID, - "current y", (uint8_t *) &entry.currentYValue, sizeof(entry.currentYValue)); - entry.hasEnhancedCurrentHueValue = readServerAttribute( - endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_ENHANCED_CURRENT_HUE_ATTRIBUTE_ID, "enhanced current hue", - (uint8_t *) &entry.enhancedCurrentHueValue, sizeof(entry.enhancedCurrentHueValue)); + entry.hasCurrentXValue = readServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_X_ATTRIBUTE_ID, "current x", + (uint8_t *) &entry.currentXValue, sizeof(entry.currentXValue)); + entry.hasCurrentYValue = readServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_Y_ATTRIBUTE_ID, "current y", + (uint8_t *) &entry.currentYValue, sizeof(entry.currentYValue)); + entry.hasEnhancedCurrentHueValue = + readServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_ENHANCED_CURRENT_HUE_ATTRIBUTE_ID, "enhanced current hue", + (uint8_t *) &entry.enhancedCurrentHueValue, sizeof(entry.enhancedCurrentHueValue)); entry.hasCurrentSaturationValue = - readServerAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, - "current saturation", (uint8_t *) &entry.currentSaturationValue, sizeof(entry.currentSaturationValue)); + readServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, "current saturation", + (uint8_t *) &entry.currentSaturationValue, sizeof(entry.currentSaturationValue)); entry.hasColorLoopActiveValue = - readServerAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_COLOR_LOOP_ACTIVE_ATTRIBUTE_ID, - "color loop active", (uint8_t *) &entry.colorLoopActiveValue, sizeof(entry.colorLoopActiveValue)); - entry.hasColorLoopDirectionValue = readServerAttribute( - endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_COLOR_LOOP_DIRECTION_ATTRIBUTE_ID, "color loop direction", - (uint8_t *) &entry.colorLoopDirectionValue, sizeof(entry.colorLoopDirectionValue)); + readServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_COLOR_LOOP_ACTIVE_ATTRIBUTE_ID, "color loop active", + (uint8_t *) &entry.colorLoopActiveValue, sizeof(entry.colorLoopActiveValue)); + entry.hasColorLoopDirectionValue = + readServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_COLOR_LOOP_DIRECTION_ATTRIBUTE_ID, "color loop direction", + (uint8_t *) &entry.colorLoopDirectionValue, sizeof(entry.colorLoopDirectionValue)); entry.hasColorLoopTimeValue = - readServerAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_COLOR_LOOP_TIME_ATTRIBUTE_ID, - "color loop time", (uint8_t *) &entry.colorLoopTimeValue, sizeof(entry.colorLoopTimeValue)); - entry.hasColorTemperatureMiredsValue = readServerAttribute( - endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_COLOR_TEMPERATURE_ATTRIBUTE_ID, "color temp mireds", - (uint8_t *) &entry.colorTemperatureMiredsValue, sizeof(entry.colorTemperatureMiredsValue)); + readServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_COLOR_LOOP_TIME_ATTRIBUTE_ID, "color loop time", + (uint8_t *) &entry.colorLoopTimeValue, sizeof(entry.colorLoopTimeValue)); + entry.hasColorTemperatureMiredsValue = + readServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_COLOR_TEMPERATURE_ATTRIBUTE_ID, "color temp mireds", + (uint8_t *) &entry.colorTemperatureMiredsValue, sizeof(entry.colorTemperatureMiredsValue)); #endif // ZCL_USING_COLOR_CONTROL_CLUSTER_SERVER #ifdef ZCL_USING_DOOR_LOCK_CLUSTER_SERVER - entry.hasLockStateValue = readServerAttribute(endpoint, ZCL_DOOR_LOCK_CLUSTER_ID, ZCL_LOCK_STATE_ATTRIBUTE_ID, "lock state", + entry.hasLockStateValue = readServerAttribute(endpoint, DoorLock::Id, ZCL_LOCK_STATE_ATTRIBUTE_ID, "lock state", (uint8_t *) &entry.lockStateValue, sizeof(entry.lockStateValue)); #endif #ifdef ZCL_USING_WINDOW_COVERING_CLUSTER_SERVER - entry.hasCurrentPositionLiftPercentageValue = - readServerAttribute(endpoint, ZCL_WINDOW_COVERING_CLUSTER_ID, ZCL_WC_CURRENT_POSITION_LIFT_PERCENTAGE_ATTRIBUTE_ID, - "currentPositionLiftPercentage", (uint8_t *) &entry.currentPositionLiftPercentageValue, - sizeof(entry.currentPositionLiftPercentageValue)); - entry.hasCurrentPositionTiltPercentageValue = - readServerAttribute(endpoint, ZCL_WINDOW_COVERING_CLUSTER_ID, ZCL_WC_CURRENT_POSITION_TILT_PERCENTAGE_ATTRIBUTE_ID, - "currentPositionTiltPercentage", (uint8_t *) &entry.currentPositionTiltPercentageValue, - sizeof(entry.currentPositionTiltPercentageValue)); - entry.hasTargetPositionLiftPercent100thsValue = - readServerAttribute(endpoint, ZCL_WINDOW_COVERING_CLUSTER_ID, ZCL_WC_TARGET_POSITION_LIFT_PERCENT100_THS_ATTRIBUTE_ID, - "targetPositionLiftPercent100ths", (uint8_t *) &entry.targetPositionLiftPercent100thsValue, - sizeof(entry.targetPositionLiftPercent100thsValue)); - entry.hasTargetPositionTiltPercent100thsValue = - readServerAttribute(endpoint, ZCL_WINDOW_COVERING_CLUSTER_ID, ZCL_WC_TARGET_POSITION_TILT_PERCENT100_THS_ATTRIBUTE_ID, - "targetPositionTiltPercent100ths", (uint8_t *) &entry.targetPositionTiltPercent100thsValue, - sizeof(entry.targetPositionTiltPercent100thsValue)); + entry.hasCurrentPositionLiftPercentageValue = readServerAttribute( + endpoint, WindowCovering::Id, ZCL_WC_CURRENT_POSITION_LIFT_PERCENTAGE_ATTRIBUTE_ID, "currentPositionLiftPercentage", + (uint8_t *) &entry.currentPositionLiftPercentageValue, sizeof(entry.currentPositionLiftPercentageValue)); + entry.hasCurrentPositionTiltPercentageValue = readServerAttribute( + endpoint, WindowCovering::Id, ZCL_WC_CURRENT_POSITION_TILT_PERCENTAGE_ATTRIBUTE_ID, "currentPositionTiltPercentage", + (uint8_t *) &entry.currentPositionTiltPercentageValue, sizeof(entry.currentPositionTiltPercentageValue)); + entry.hasTargetPositionLiftPercent100thsValue = readServerAttribute( + endpoint, WindowCovering::Id, ZCL_WC_TARGET_POSITION_LIFT_PERCENT100_THS_ATTRIBUTE_ID, "targetPositionLiftPercent100ths", + (uint8_t *) &entry.targetPositionLiftPercent100thsValue, sizeof(entry.targetPositionLiftPercent100thsValue)); + entry.hasTargetPositionTiltPercent100thsValue = readServerAttribute( + endpoint, WindowCovering::Id, ZCL_WC_TARGET_POSITION_TILT_PERCENT100_THS_ATTRIBUTE_ID, "targetPositionTiltPercent100ths", + (uint8_t *) &entry.targetPositionTiltPercent100thsValue, sizeof(entry.targetPositionTiltPercent100thsValue)); #endif // When creating a new entry, the name is set to the null string (i.e., the @@ -597,7 +589,7 @@ EmberAfStatus emberAfScenesClusterRecallSavedSceneCallback(chip::FabricIndex fab { if (!isEndpointInGroup(fabricIndex, endpoint, groupId)) { - return EMBER_ZCL_STATUS_INVALID_FIELD; + return EMBER_ZCL_STATUS_INVALID_COMMAND; } uint8_t i; @@ -610,76 +602,76 @@ EmberAfStatus emberAfScenesClusterRecallSavedSceneCallback(chip::FabricIndex fab #ifdef ZCL_USING_ON_OFF_CLUSTER_SERVER if (entry.hasOnOffValue) { - writeServerAttribute(endpoint, ZCL_ON_OFF_CLUSTER_ID, ZCL_ON_OFF_ATTRIBUTE_ID, "on/off", - (uint8_t *) &entry.onOffValue, ZCL_BOOLEAN_ATTRIBUTE_TYPE); + writeServerAttribute(endpoint, OnOff::Id, ZCL_ON_OFF_ATTRIBUTE_ID, "on/off", (uint8_t *) &entry.onOffValue, + ZCL_BOOLEAN_ATTRIBUTE_TYPE); } #endif #ifdef ZCL_USING_LEVEL_CONTROL_CLUSTER_SERVER if (entry.hasCurrentLevelValue) { - writeServerAttribute(endpoint, ZCL_LEVEL_CONTROL_CLUSTER_ID, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, "current level", + writeServerAttribute(endpoint, LevelControl::Id, ZCL_CURRENT_LEVEL_ATTRIBUTE_ID, "current level", (uint8_t *) &entry.currentLevelValue, ZCL_INT8U_ATTRIBUTE_TYPE); } #endif #ifdef ZCL_USING_THERMOSTAT_CLUSTER_SERVER if (entry.hasOccupiedCoolingSetpointValue) { - writeServerAttribute(endpoint, ZCL_THERMOSTAT_CLUSTER_ID, ZCL_OCCUPIED_COOLING_SETPOINT_ATTRIBUTE_ID, + writeServerAttribute(endpoint, Thermostat::Id, ZCL_OCCUPIED_COOLING_SETPOINT_ATTRIBUTE_ID, "occupied cooling setpoint", (uint8_t *) &entry.occupiedCoolingSetpointValue, ZCL_INT16S_ATTRIBUTE_TYPE); } if (entry.hasOccupiedHeatingSetpointValue) { - writeServerAttribute(endpoint, ZCL_THERMOSTAT_CLUSTER_ID, ZCL_OCCUPIED_HEATING_SETPOINT_ATTRIBUTE_ID, + writeServerAttribute(endpoint, Thermostat::Id, ZCL_OCCUPIED_HEATING_SETPOINT_ATTRIBUTE_ID, "occupied heating setpoint", (uint8_t *) &entry.occupiedHeatingSetpointValue, ZCL_INT16S_ATTRIBUTE_TYPE); } if (entry.hasSystemModeValue) { - writeServerAttribute(endpoint, ZCL_THERMOSTAT_CLUSTER_ID, ZCL_SYSTEM_MODE_ATTRIBUTE_ID, "system mode", + writeServerAttribute(endpoint, Thermostat::Id, ZCL_SYSTEM_MODE_ATTRIBUTE_ID, "system mode", (uint8_t *) &entry.systemModeValue, ZCL_INT8U_ATTRIBUTE_TYPE); } #endif #ifdef ZCL_USING_COLOR_CONTROL_CLUSTER_SERVER if (entry.hasCurrentXValue) { - writeServerAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_X_ATTRIBUTE_ID, "current x", + writeServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_X_ATTRIBUTE_ID, "current x", (uint8_t *) &entry.currentXValue, ZCL_INT16U_ATTRIBUTE_TYPE); } if (entry.hasCurrentYValue) { - writeServerAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_Y_ATTRIBUTE_ID, "current y", + writeServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_Y_ATTRIBUTE_ID, "current y", (uint8_t *) &entry.currentYValue, ZCL_INT16U_ATTRIBUTE_TYPE); } if (entry.hasEnhancedCurrentHueValue) { - writeServerAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_ENHANCED_CURRENT_HUE_ATTRIBUTE_ID, + writeServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_ENHANCED_CURRENT_HUE_ATTRIBUTE_ID, "enhanced current hue", (uint8_t *) &entry.enhancedCurrentHueValue, ZCL_INT16U_ATTRIBUTE_TYPE); } if (entry.hasCurrentSaturationValue) { - writeServerAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, + writeServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_CURRENT_SATURATION_ATTRIBUTE_ID, "current saturation", (uint8_t *) &entry.currentSaturationValue, ZCL_INT8U_ATTRIBUTE_TYPE); } if (entry.hasColorLoopActiveValue) { - writeServerAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_COLOR_LOOP_ACTIVE_ATTRIBUTE_ID, + writeServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_COLOR_LOOP_ACTIVE_ATTRIBUTE_ID, "color loop active", (uint8_t *) &entry.colorLoopActiveValue, ZCL_INT8U_ATTRIBUTE_TYPE); } if (entry.hasColorLoopDirectionValue) { - writeServerAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_COLOR_LOOP_DIRECTION_ATTRIBUTE_ID, + writeServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_COLOR_LOOP_DIRECTION_ATTRIBUTE_ID, "color loop direction", (uint8_t *) &entry.colorLoopDirectionValue, ZCL_INT8U_ATTRIBUTE_TYPE); } if (entry.hasColorLoopTimeValue) { - writeServerAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_COLOR_LOOP_TIME_ATTRIBUTE_ID, - "color loop time", (uint8_t *) &entry.colorLoopTimeValue, ZCL_INT16U_ATTRIBUTE_TYPE); + writeServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_COLOR_LOOP_TIME_ATTRIBUTE_ID, "color loop time", + (uint8_t *) &entry.colorLoopTimeValue, ZCL_INT16U_ATTRIBUTE_TYPE); } if (entry.hasColorTemperatureMiredsValue) { - writeServerAttribute(endpoint, ZCL_COLOR_CONTROL_CLUSTER_ID, ZCL_COLOR_CONTROL_COLOR_TEMPERATURE_ATTRIBUTE_ID, + writeServerAttribute(endpoint, ColorControl::Id, ZCL_COLOR_CONTROL_COLOR_TEMPERATURE_ATTRIBUTE_ID, "color temp mireds", (uint8_t *) &entry.colorTemperatureMiredsValue, ZCL_INT16U_ATTRIBUTE_TYPE); } @@ -687,34 +679,34 @@ EmberAfStatus emberAfScenesClusterRecallSavedSceneCallback(chip::FabricIndex fab #ifdef ZCL_USING_DOOR_LOCK_CLUSTER_SERVER if (entry.hasLockStateValue) { - writeServerAttribute(endpoint, ZCL_DOOR_LOCK_CLUSTER_ID, ZCL_LOCK_STATE_ATTRIBUTE_ID, "lock state", + writeServerAttribute(endpoint, DoorLock::Id, ZCL_LOCK_STATE_ATTRIBUTE_ID, "lock state", (uint8_t *) &entry.lockStateValue, ZCL_INT8U_ATTRIBUTE_TYPE); } #endif #ifdef ZCL_USING_WINDOW_COVERING_CLUSTER_SERVER if (entry.hasCurrentPositionLiftPercentageValue) { - writeServerAttribute(endpoint, ZCL_WINDOW_COVERING_CLUSTER_ID, ZCL_WC_CURRENT_POSITION_LIFT_PERCENTAGE_ATTRIBUTE_ID, + writeServerAttribute(endpoint, WindowCovering::Id, ZCL_WC_CURRENT_POSITION_LIFT_PERCENTAGE_ATTRIBUTE_ID, "CurrentPositionLiftPercentage", (uint8_t *) &entry.currentPositionLiftPercentageValue, ZCL_INT8U_ATTRIBUTE_TYPE); } if (entry.hasCurrentPositionTiltPercentageValue) { - writeServerAttribute(endpoint, ZCL_WINDOW_COVERING_CLUSTER_ID, ZCL_WC_CURRENT_POSITION_TILT_PERCENTAGE_ATTRIBUTE_ID, + writeServerAttribute(endpoint, WindowCovering::Id, ZCL_WC_CURRENT_POSITION_TILT_PERCENTAGE_ATTRIBUTE_ID, "CurrentPositionTiltPercentage", (uint8_t *) &entry.currentPositionTiltPercentageValue, ZCL_INT8U_ATTRIBUTE_TYPE); } if (entry.hasTargetPositionLiftPercent100thsValue) { - writeServerAttribute(endpoint, ZCL_WINDOW_COVERING_CLUSTER_ID, - ZCL_WC_TARGET_POSITION_LIFT_PERCENT100_THS_ATTRIBUTE_ID, "TargetPositionLiftPercent100ths", - (uint8_t *) &entry.targetPositionLiftPercent100thsValue, ZCL_INT16U_ATTRIBUTE_TYPE); + writeServerAttribute(endpoint, WindowCovering::Id, ZCL_WC_TARGET_POSITION_LIFT_PERCENT100_THS_ATTRIBUTE_ID, + "TargetPositionLiftPercent100ths", (uint8_t *) &entry.targetPositionLiftPercent100thsValue, + ZCL_INT16U_ATTRIBUTE_TYPE); } if (entry.hasTargetPositionTiltPercent100thsValue) { - writeServerAttribute(endpoint, ZCL_WINDOW_COVERING_CLUSTER_ID, - ZCL_WC_TARGET_POSITION_TILT_PERCENT100_THS_ATTRIBUTE_ID, "TargetPositionTiltPercent100ths", - (uint8_t *) &entry.targetPositionTiltPercent100thsValue, ZCL_INT16U_ATTRIBUTE_TYPE); + writeServerAttribute(endpoint, WindowCovering::Id, ZCL_WC_TARGET_POSITION_TILT_PERCENT100_THS_ATTRIBUTE_ID, + "TargetPositionTiltPercent100ths", (uint8_t *) &entry.targetPositionTiltPercent100thsValue, + ZCL_INT16U_ATTRIBUTE_TYPE); } #endif emberAfScenesMakeValid(endpoint, sceneId, groupId); @@ -745,7 +737,7 @@ bool emberAfPluginScenesServerParseAddScene( // Add Scene commands can only reference groups to which we belong. if (!isEndpointInGroup(fabricIndex, endpoint, groupId)) { - status = EMBER_ZCL_STATUS_INVALID_FIELD; + status = EMBER_ZCL_STATUS_INVALID_COMMAND; goto kickout; } @@ -766,7 +758,7 @@ bool emberAfPluginScenesServerParseAddScene( // If the target index is still zero, the table is full. if (index == EMBER_AF_SCENE_TABLE_NULL_INDEX) { - status = EMBER_ZCL_STATUS_INSUFFICIENT_SPACE; + status = EMBER_ZCL_STATUS_RESOURCE_EXHAUSTED; goto kickout; } @@ -837,7 +829,7 @@ bool emberAfPluginScenesServerParseAddScene( { #if 0 #ifdef ZCL_USING_ON_OFF_CLUSTER_SERVER - case ZCL_ON_OFF_CLUSTER_ID: + case OnOff::Id: // We only know of one extension for the On/Off cluster and it is just one // byte, which means we can skip some logic for this cluster. If other // extensions are added in this cluster, more logic will be needed here. @@ -846,7 +838,7 @@ bool emberAfPluginScenesServerParseAddScene( break; #endif #ifdef ZCL_USING_LEVEL_CONTROL_CLUSTER_SERVER - case ZCL_LEVEL_CONTROL_CLUSTER_ID: + case LevelControl::Id: // We only know of one extension for the Level Control cluster and it is // just one byte, which means we can skip some logic for this cluster. If // other extensions are added in this cluster, more logic will be needed @@ -856,7 +848,7 @@ bool emberAfPluginScenesServerParseAddScene( break; #endif #ifdef ZCL_USING_THERMOSTAT_CLUSTER_SERVER - case ZCL_THERMOSTAT_CLUSTER_ID: + case Thermostat::Id: if (length < 2) { break; @@ -886,7 +878,7 @@ bool emberAfPluginScenesServerParseAddScene( break; #endif #ifdef ZCL_USING_COLOR_CONTROL_CLUSTER_SERVER - case ZCL_COLOR_CONTROL_CLUSTER_ID: + case ColorControl::Id: if (length < 2) { break; @@ -960,7 +952,7 @@ bool emberAfPluginScenesServerParseAddScene( break; #endif // ZCL_USING_COLOR_CONTROL_CLUSTER_SERVER #ifdef ZCL_USING_DOOR_LOCK_CLUSTER_SERVER - case ZCL_DOOR_LOCK_CLUSTER_ID: + case DoorLock::Id: // We only know of one extension for the Door Lock cluster and it is just // one byte, which means we can skip some logic for this cluster. If // other extensions are added in this cluster, more logic will be needed @@ -970,7 +962,7 @@ bool emberAfPluginScenesServerParseAddScene( break; #endif #ifdef ZCL_USING_WINDOW_COVERING_CLUSTER_SERVER - case ZCL_WINDOW_COVERING_CLUSTER_ID: + case WindowCovering::Id: // If we're here, we know we have at least one byte, so we can skip the // length check for the first field. entry.hasCurrentPositionLiftPercentageValue = true; @@ -1041,10 +1033,10 @@ bool emberAfPluginScenesServerParseAddScene( return true; } { - app::ConcreteCommandPath path = { emberAfCurrentEndpoint(), ZCL_SCENES_CLUSTER_ID, ZCL_ADD_SCENE_RESPONSE_COMMAND_ID }; + app::ConcreteCommandPath path = { emberAfCurrentEndpoint(), Scenes::Id, ZCL_ADD_SCENE_RESPONSE_COMMAND_ID }; if (enhanced) { - path = { emberAfCurrentEndpoint(), ZCL_SCENES_CLUSTER_ID, ZCL_ENHANCED_ADD_SCENE_RESPONSE_COMMAND_ID }; + path = { emberAfCurrentEndpoint(), Scenes::Id, ZCL_ENHANCED_ADD_SCENE_RESPONSE_COMMAND_ID }; } TLV::TLVWriter * writer = nullptr; SuccessOrExit(err = commandObj->PrepareCommand(path)); @@ -1078,7 +1070,7 @@ bool emberAfPluginScenesServerParseViewScene(app::CommandHandler * commandObj, c // View Scene commands can only reference groups which we belong to. if (!isEndpointInGroup(fabricIndex, endpoint, groupId)) { - status = EMBER_ZCL_STATUS_INVALID_FIELD; + status = EMBER_ZCL_STATUS_INVALID_COMMAND; } else { @@ -1097,10 +1089,10 @@ bool emberAfPluginScenesServerParseViewScene(app::CommandHandler * commandObj, c // The status, group id, and scene id are always included in the response, but // the transition time, name, and extension fields are only included if the // scene was found. - app::ConcreteCommandPath path = { emberAfCurrentEndpoint(), ZCL_SCENES_CLUSTER_ID, ZCL_VIEW_SCENE_RESPONSE_COMMAND_ID }; + app::ConcreteCommandPath path = { emberAfCurrentEndpoint(), Scenes::Id, ZCL_VIEW_SCENE_RESPONSE_COMMAND_ID }; if (enhanced) { - path = { emberAfCurrentEndpoint(), ZCL_SCENES_CLUSTER_ID, ZCL_ENHANCED_VIEW_SCENE_RESPONSE_COMMAND_ID }; + path = { emberAfCurrentEndpoint(), Scenes::Id, ZCL_ENHANCED_VIEW_SCENE_RESPONSE_COMMAND_ID }; } TLV::TLVWriter * writer = nullptr; SuccessOrExit(err = commandObj->PrepareCommand(path)); @@ -1135,7 +1127,7 @@ bool emberAfPluginScenesServerParseViewScene(app::CommandHandler * commandObj, c #ifdef ZCL_USING_ON_OFF_CLUSTER_SERVER if (entry.hasOnOffValue) { - emberAfPutInt16uInResp(ZCL_ON_OFF_CLUSTER_ID); + emberAfPutInt16uInResp(OnOff::Id); emberAfPutInt8uInResp(1); // length emberAfPutInt8uInResp(entry.onOffValue); } @@ -1143,7 +1135,7 @@ bool emberAfPluginScenesServerParseViewScene(app::CommandHandler * commandObj, c #ifdef ZCL_USING_LEVEL_CONTROL_CLUSTER_SERVER if (entry.hasCurrentLevelValue) { - emberAfPutInt16uInResp(ZCL_LEVEL_CONTROL_CLUSTER_ID); + emberAfPutInt16uInResp(LevelControl::Id); emberAfPutInt8uInResp(1); // length emberAfPutInt8uInResp(entry.currentLevelValue); } @@ -1152,7 +1144,7 @@ bool emberAfPluginScenesServerParseViewScene(app::CommandHandler * commandObj, c if (entry.hasOccupiedCoolingSetpointValue) { uint8_t * length; - emberAfPutInt16uInResp(ZCL_THERMOSTAT_CLUSTER_ID); + emberAfPutInt16uInResp(Thermostat::Id); length = &appResponseData[appResponseLength]; emberAfPutInt8uInResp(0); // temporary length emberAfPutInt16sInResp(entry.occupiedCoolingSetpointValue); @@ -1173,7 +1165,7 @@ bool emberAfPluginScenesServerParseViewScene(app::CommandHandler * commandObj, c if (entry.hasCurrentXValue) { uint8_t * length; - emberAfPutInt16uInResp(ZCL_COLOR_CONTROL_CLUSTER_ID); + emberAfPutInt16uInResp(ColorControl::Id); length = &appResponseData[appResponseLength]; emberAfPutInt8uInResp(0); // temporary length emberAfPutInt16uInResp(entry.currentXValue); @@ -1221,7 +1213,7 @@ bool emberAfPluginScenesServerParseViewScene(app::CommandHandler * commandObj, c #ifdef ZCL_USING_DOOR_LOCK_CLUSTER_SERVER if (entry.hasLockStateValue) { - emberAfPutInt16uInResp(ZCL_DOOR_LOCK_CLUSTER_ID); + emberAfPutInt16uInResp(DoorLock::Id); emberAfPutInt8uInResp(1); // length emberAfPutInt8uInResp(entry.lockStateValue); } @@ -1230,7 +1222,7 @@ bool emberAfPluginScenesServerParseViewScene(app::CommandHandler * commandObj, c if (entry.hasCurrentPositionLiftPercentageValue) { uint8_t * length; - emberAfPutInt16uInResp(ZCL_WINDOW_COVERING_CLUSTER_ID); + emberAfPutInt16uInResp(WindowCovering::Id); length = &appResponseData[appResponseLength]; emberAfPutInt8uInResp(0); // temporary length emberAfPutInt8uInResp(entry.currentPositionLiftPercentageValue); diff --git a/src/app/clusters/switch-server/switch-server.cpp b/src/app/clusters/switch-server/switch-server.cpp index f74677edf24533..64cce040f0adb3 100644 --- a/src/app/clusters/switch-server/switch-server.cpp +++ b/src/app/clusters/switch-server/switch-server.cpp @@ -135,13 +135,13 @@ void SwitchServer::OnMultiPressOngoing(EndpointId endpoint, uint8_t newPosition, } } -void SwitchServer::OnMultiPressComplete(EndpointId endpoint, uint8_t newPosition, uint8_t count) +void SwitchServer::OnMultiPressComplete(EndpointId endpoint, uint8_t previousPosition, uint8_t count) { ChipLogProgress(Zcl, "SwitchServer: OnMultiPressComplete"); // Record MultiPressComplete event EventNumber eventNumber; - Events::MultiPressComplete::Type event{ newPosition, count }; + Events::MultiPressComplete::Type event{ previousPosition, count }; if (CHIP_NO_ERROR != LogEvent(event, endpoint, eventNumber)) { diff --git a/src/app/clusters/test-cluster-server/test-cluster-server.cpp b/src/app/clusters/test-cluster-server/test-cluster-server.cpp index acf56b7ab1bd44..28f8f44b4a7824 100644 --- a/src/app/clusters/test-cluster-server/test-cluster-server.cpp +++ b/src/app/clusters/test-cluster-server/test-cluster-server.cpp @@ -995,7 +995,7 @@ bool emberAfUnitTestingClusterTestSimpleOptionalArgumentRequestCallback( // ----------------------------------------------------------------------------- // Plugin initialization -void MatterUnitTestingPluginServerInitCallback(void) +void MatterUnitTestingPluginServerInitCallback() { registerAttributeAccessOverride(&gAttrAccess); } diff --git a/src/app/clusters/thermostat-client/thermostat-client.cpp b/src/app/clusters/thermostat-client/thermostat-client.cpp index 31b52bf7781ee7..de7afc6267c544 100644 --- a/src/app/clusters/thermostat-client/thermostat-client.cpp +++ b/src/app/clusters/thermostat-client/thermostat-client.cpp @@ -23,7 +23,7 @@ using namespace chip; -void emberAfThermostatClusterClientInitCallback(void) +void emberAfThermostatClusterClientInitCallback() { // TODO } diff --git a/src/app/clusters/thermostat-server/thermostat-server.cpp b/src/app/clusters/thermostat-server/thermostat-server.cpp index c133e1514ca7de..fdb65b21c33fe0 100644 --- a/src/app/clusters/thermostat-server/thermostat-server.cpp +++ b/src/app/clusters/thermostat-server/thermostat-server.cpp @@ -24,7 +24,6 @@ #include #include #include -#include #include #include #include diff --git a/src/app/clusters/thermostat-user-interface-configuration-server/thermostat-user-interface-configuration-server.cpp b/src/app/clusters/thermostat-user-interface-configuration-server/thermostat-user-interface-configuration-server.cpp index 5759a1fe65c4e9..b737888cc3e73d 100644 --- a/src/app/clusters/thermostat-user-interface-configuration-server/thermostat-user-interface-configuration-server.cpp +++ b/src/app/clusters/thermostat-user-interface-configuration-server/thermostat-user-interface-configuration-server.cpp @@ -7,7 +7,6 @@ #include #include #include -#include #include #include #include diff --git a/src/app/clusters/time-format-localization-server/time-format-localization-server.cpp b/src/app/clusters/time-format-localization-server/time-format-localization-server.cpp index 42065e6fd1ad97..5bb010a14d23a1 100644 --- a/src/app/clusters/time-format-localization-server/time-format-localization-server.cpp +++ b/src/app/clusters/time-format-localization-server/time-format-localization-server.cpp @@ -220,7 +220,7 @@ void emberAfTimeFormatLocalizationClusterServerInitCallback(EndpointId endpoint) } } -void MatterTimeFormatLocalizationPluginServerInitCallback(void) +void MatterTimeFormatLocalizationPluginServerInitCallback() { registerAttributeAccessOverride(&gAttrAccess); } diff --git a/src/app/clusters/user-label-server/user-label-server.cpp b/src/app/clusters/user-label-server/user-label-server.cpp index d9bfbbdc8ca159..8b363d1a39b454 100644 --- a/src/app/clusters/user-label-server/user-label-server.cpp +++ b/src/app/clusters/user-label-server/user-label-server.cpp @@ -217,7 +217,7 @@ class UserLabelFabricTableDelegate : public chip::FabricTable::Delegate UserLabelFabricTableDelegate gUserLabelFabricDelegate; -void MatterUserLabelPluginServerInitCallback(void) +void MatterUserLabelPluginServerInitCallback() { registerAttributeAccessOverride(&gAttrAccess); Server::GetInstance().GetFabricTable().AddFabricDelegate(&gUserLabelFabricDelegate); diff --git a/src/app/clusters/window-covering-server/window-covering-server.cpp b/src/app/clusters/window-covering-server/window-covering-server.cpp index 65237ba9b1211f..5955a6bb24ed12 100644 --- a/src/app/clusters/window-covering-server/window-covering-server.cpp +++ b/src/app/clusters/window-covering-server/window-covering-server.cpp @@ -19,7 +19,6 @@ #include #include -#include #include #include #include @@ -842,7 +841,7 @@ bool emberAfWindowCoveringClusterGoToLiftPercentageCallback(app::CommandHandler } else { - emberAfSendImmediateDefaultResponse(EMBER_ZCL_STATUS_INVALID_VALUE); + emberAfSendImmediateDefaultResponse(EMBER_ZCL_STATUS_CONSTRAINT_ERROR); } } else @@ -934,7 +933,7 @@ bool emberAfWindowCoveringClusterGoToTiltPercentageCallback(app::CommandHandler } else { - emberAfSendImmediateDefaultResponse(EMBER_ZCL_STATUS_INVALID_VALUE); + emberAfSendImmediateDefaultResponse(EMBER_ZCL_STATUS_CONSTRAINT_ERROR); } } else diff --git a/src/app/common/templates/templates.json b/src/app/common/templates/templates.json index ea4ae8f0a22417..03327d0469b013 100644 --- a/src/app/common/templates/templates.json +++ b/src/app/common/templates/templates.json @@ -58,11 +58,6 @@ "name": "ZCL callback header", "output": "callback.h" }, - { - "path": "../../zap-templates/templates/app/cluster-id.zapt", - "name": "ZCL cluster-id header", - "output": "cluster-id.h" - }, { "path": "../../zap-templates/templates/app/command-id.zapt", "name": "ZCL command-id header", diff --git a/src/app/tests/TestClusterStateCache.cpp b/src/app/tests/TestClusterStateCache.cpp index d2b85fad74f5d5..172de5dd4cc798 100644 --- a/src/app/tests/TestClusterStateCache.cpp +++ b/src/app/tests/TestClusterStateCache.cpp @@ -181,7 +181,6 @@ void DataSeriesGenerator::Generate(ForwardedDataCallbackValidator & dataCallback StatusIB status; callback->OnReportBegin(); - uint8_t index = 0; for (auto & instruction : mInstructionList) { ConcreteDataAttributePath path(instruction.mEndpointId, Clusters::UnitTesting::Id, 0); @@ -266,8 +265,6 @@ void DataSeriesGenerator::Generate(ForwardedDataCallbackValidator & dataCallback dataCallbackValidator.SetExpectation(); callback->OnAttributeData(path, nullptr, status); } - - index++; } callback->OnReportEnd(); diff --git a/src/app/tests/TestFailSafeContext.cpp b/src/app/tests/TestFailSafeContext.cpp index 9e5d11dc320b73..f0631cd7a92386 100644 --- a/src/app/tests/TestFailSafeContext.cpp +++ b/src/app/tests/TestFailSafeContext.cpp @@ -50,8 +50,10 @@ constexpr FabricIndex kTestAccessingFabricIndex2 = 2; static void TestPlatformMgr_Init(nlTestSuite * inSuite, void * inContext) { +#if !defined(CHIP_DEVICE_LAYER_TARGET_OPEN_IOT_SDK) CHIP_ERROR err = PlatformMgr().InitChipStack(); NL_TEST_ASSERT(inSuite, err == CHIP_NO_ERROR); +#endif // !defined(CHIP_DEVICE_LAYER_TARGET_OPEN_IOT_SDK) } static void TestFailSafeContext_ArmFailSafe(nlTestSuite * inSuite, void * inContext) @@ -121,7 +123,9 @@ int TestFailSafeContext_Setup(void * inContext) */ int TestFailSafeContext_Teardown(void * inContext) { +#if !defined(CHIP_DEVICE_LAYER_TARGET_OPEN_IOT_SDK) PlatformMgr().Shutdown(); +#endif // !defined(CHIP_DEVICE_LAYER_TARGET_OPEN_IOT_SDK) chip::Platform::MemoryShutdown(); return SUCCESS; } diff --git a/src/app/tests/integration/MockEvents.cpp b/src/app/tests/integration/MockEvents.cpp index 2efec7f805673a..62f8c83db83dd4 100644 --- a/src/app/tests/integration/MockEvents.cpp +++ b/src/app/tests/integration/MockEvents.cpp @@ -44,9 +44,9 @@ size_t EventGenerator::GetNumStates() return mNumStates; } -LivenessEventGenerator::LivenessEventGenerator(void) : EventGenerator(10, 0) {} +LivenessEventGenerator::LivenessEventGenerator() : EventGenerator(10, 0) {} -void LivenessEventGenerator::Generate(void) +void LivenessEventGenerator::Generate() { // Scenario: monitoring liveness for two devices -- self and remote. Remote device goes offline and returns. switch (mState) @@ -131,13 +131,13 @@ chip::EventNumber LivenessEventGenerator::LogLiveness(chip::NodeId aNodeId, chip return number; } -MockEventGenerator * MockEventGenerator::GetInstance(void) +MockEventGenerator * MockEventGenerator::GetInstance() { static MockEventGeneratorImpl gMockEventGenerator; return &gMockEventGenerator; } -MockEventGeneratorImpl::MockEventGeneratorImpl(void) : +MockEventGeneratorImpl::MockEventGeneratorImpl() : mpExchangeMgr(nullptr), mTimeBetweenEvents(0), mEventWraparound(false), mpEventGenerator(nullptr), mEventsLeft(0) {} diff --git a/src/app/tests/integration/common.cpp b/src/app/tests/integration/common.cpp index c5089b2c83860c..8cf4bb4cc8a274 100644 --- a/src/app/tests/integration/common.cpp +++ b/src/app/tests/integration/common.cpp @@ -44,7 +44,7 @@ chip::TestPersistentStorageDelegate gStorage; chip::PersistentStorageOperationalKeystore gOperationalKeystore; chip::Credentials::PersistentStorageOpCertStore gOpCertStore; -void InitializeChip(void) +void InitializeChip() { CHIP_ERROR err = CHIP_NO_ERROR; chip::FabricTable::InitParams fabricTableInitParams; @@ -84,7 +84,7 @@ void InitializeChip(void) } } -void ShutdownChip(void) +void ShutdownChip() { gMessageCounterManager.Shutdown(); gExchangeManager.Shutdown(); diff --git a/src/app/tests/suites/DL_Schedules.yaml b/src/app/tests/suites/DL_Schedules.yaml index 580b6556a26869..7f87cfde766436 100644 --- a/src/app/tests/suites/DL_Schedules.yaml +++ b/src/app/tests/suites/DL_Schedules.yaml @@ -108,7 +108,7 @@ tests: - name: "endMinute" value: 00 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Week Day schedule with out-of-bounds index" command: "SetWeekDaySchedule" @@ -129,7 +129,7 @@ tests: - name: "endMinute" value: 00 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Week Day schedule with 0 user index" command: "SetWeekDaySchedule" @@ -150,7 +150,7 @@ tests: - name: "endMinute" value: 00 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Week Day schedule with out-of-bounds user index" command: "SetWeekDaySchedule" @@ -171,7 +171,7 @@ tests: - name: "endMinute" value: 00 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Week Day schedule for non-existing user" command: "SetWeekDaySchedule" @@ -213,7 +213,7 @@ tests: - name: "endMinute" value: 00 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Week Day schedule for Sunday and Monday" command: "SetWeekDaySchedule" @@ -234,7 +234,7 @@ tests: - name: "endMinute" value: 00 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Week Day schedule for Sunday Wednesday and Saturday" command: "SetWeekDaySchedule" @@ -255,7 +255,7 @@ tests: - name: "endMinute" value: 00 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Week Day schedule with invalid start hour" command: "SetWeekDaySchedule" @@ -276,7 +276,7 @@ tests: - name: "endMinute" value: 00 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Week Day schedule with invalid start minute" command: "SetWeekDaySchedule" @@ -297,7 +297,7 @@ tests: - name: "endMinute" value: 00 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Week Day schedule with invalid end hour" command: "SetWeekDaySchedule" @@ -318,7 +318,7 @@ tests: - name: "endMinute" value: 00 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Week Day schedule with invalid end minute" command: "SetWeekDaySchedule" @@ -339,7 +339,7 @@ tests: - name: "endMinute" value: 60 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Week Day schedule with start hour later that end hour" command: "SetWeekDaySchedule" @@ -360,7 +360,7 @@ tests: - name: "endMinute" value: 00 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Week Day schedule with start minute later that end minute when @@ -383,7 +383,7 @@ tests: - name: "endMinute" value: 49 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Make sure that previous operations did not create a schedule" command: "GetWeekDaySchedule" @@ -506,7 +506,7 @@ tests: - name: "localEndTime" value: 12345689 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Year Day schedule with out-of-bounds index" command: "SetYearDaySchedule" @@ -521,7 +521,7 @@ tests: - name: "localEndTime" value: 12345689 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Year Day schedule with 0 user index" command: "SetYearDaySchedule" @@ -536,7 +536,7 @@ tests: - name: "localEndTime" value: 12345689 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Year Day schedule with out-of-bounds user index" command: "SetYearDaySchedule" @@ -551,7 +551,7 @@ tests: - name: "localEndTime" value: 12345689 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Year Day schedule for non-existing user" command: "SetYearDaySchedule" @@ -704,7 +704,7 @@ tests: - name: "operatingMode" value: 0 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Holiday schedule with out-of-bounds index" command: "SetHolidaySchedule" @@ -719,7 +719,7 @@ tests: - name: "operatingMode" value: 0 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Holiday schedule with start hour later that end hour" command: "SetHolidaySchedule" @@ -734,7 +734,7 @@ tests: - name: "operatingMode" value: 0 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Create Holiday schedule with invalid operating mode" command: "SetHolidaySchedule" @@ -749,7 +749,7 @@ tests: - name: "operatingMode" value: 5 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Make sure that previous operations did not create a schedule" command: "GetHolidaySchedule" @@ -918,7 +918,7 @@ tests: - name: "userIndex" value: 1 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Clear Week Day schedule with out-of-bounds index" command: "ClearWeekDaySchedule" @@ -929,7 +929,7 @@ tests: - name: "userIndex" value: 1 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Clear Week Day schedule with 0 user index" command: "ClearWeekDaySchedule" @@ -940,7 +940,7 @@ tests: - name: "userIndex" value: 0 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Clear Week Day schedule with out-of-bounds user index" command: "ClearWeekDaySchedule" @@ -951,7 +951,7 @@ tests: - name: "userIndex" value: NumberOfTotalUsersSupported + 1 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Clear Week Day schedule with non-existing user" command: "ClearWeekDaySchedule" @@ -1043,7 +1043,7 @@ tests: - name: "userIndex" value: 1 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Clear Year Day schedule with out-of-bounds index" command: "ClearYearDaySchedule" @@ -1054,7 +1054,7 @@ tests: - name: "userIndex" value: 1 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Clear Year Day schedule with 0 user index" command: "ClearYearDaySchedule" @@ -1065,7 +1065,7 @@ tests: - name: "userIndex" value: 0 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Clear Year Day schedule with out-of-bounds user index" command: "ClearYearDaySchedule" @@ -1076,7 +1076,7 @@ tests: - name: "userIndex" value: NumberOfTotalUsersSupported + 1 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Clear Year Day schedule with non-existing user" command: "ClearYearDaySchedule" @@ -1164,7 +1164,7 @@ tests: - name: "holidayIndex" value: 0 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Clear Holiday schedule with out-of-bounds index" command: "ClearHolidaySchedule" @@ -1173,7 +1173,7 @@ tests: - name: "holidayIndex" value: NumberOfYearDaySchedulesSupportedPerUser + 1 response: - error: INVALID_FIELD + error: INVALID_COMMAND - label: "Make sure that week day schedule was not deleted" command: "GetWeekDaySchedule" diff --git a/src/app/tests/suites/TestArmFailSafe.yaml b/src/app/tests/suites/TestArmFailSafe.yaml index eb4ee25544d971..245788fd71cc0d 100644 --- a/src/app/tests/suites/TestArmFailSafe.yaml +++ b/src/app/tests/suites/TestArmFailSafe.yaml @@ -36,7 +36,7 @@ tests: cluster: "Operational Credentials" attribute: "Fabrics" response: - value: [{ Label: "", nodeId: nodeId }] + value: [{ Label: "", NodeId: nodeId }] constraints: type: list diff --git a/src/app/tests/suites/TestCluster.yaml b/src/app/tests/suites/TestCluster.yaml index ddf4eb1362bc28..e03a338a90e5fa 100644 --- a/src/app/tests/suites/TestCluster.yaml +++ b/src/app/tests/suites/TestCluster.yaml @@ -914,6 +914,18 @@ tests: "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef", ] + - label: "Write attribute LIST_LONG_OCTET_STRING (for chunked write)" + command: "writeAttribute" + attribute: "list_long_octet_string" + arguments: + value: + [ + "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef", + "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef", + "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef", + "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef", + ] + # Tests for Epoch Microseconds - label: "Read attribute EPOCH_US Default Value" @@ -2953,7 +2965,7 @@ tests: "Send a command that takes an optional parameter but do not set it." command: "TestSimpleOptionalArgumentRequest" response: - error: INVALID_VALUE + error: CONSTRAINT_ERROR - label: "Send a command that takes an optional parameter but do not set it." diff --git a/src/app/tests/suites/TestClusterMultiFabric.yaml b/src/app/tests/suites/TestClusterMultiFabric.yaml index 448fef86b9b38a..d11f5f1d4715ed 100644 --- a/src/app/tests/suites/TestClusterMultiFabric.yaml +++ b/src/app/tests/suites/TestClusterMultiFabric.yaml @@ -75,7 +75,7 @@ tests: # Write in a bogus value for the fabric index. This should never actually make it across the wire, # nor be meaningfully ingested by a correct receiver. # - fabricIndex: 100, + FabricIndex: 100, fabricSensitiveInt8u: 33, optionalFabricSensitiveInt8u: 34, nullableFabricSensitiveInt8u: null, @@ -95,7 +95,7 @@ tests: fabricSensitiveInt8uList: [1, 2, 3, 4], }, { - fabricIndex: 100, + FabricIndex: 100, fabricSensitiveInt8u: 43, optionalFabricSensitiveInt8u: 44, nullableFabricSensitiveInt8u: null, @@ -125,7 +125,7 @@ tests: value: [ { - fabricIndex: 100, + FabricIndex: 100, fabricSensitiveInt8u: 133, optionalFabricSensitiveInt8u: 134, nullableFabricSensitiveInt8u: null, @@ -145,7 +145,7 @@ tests: fabricSensitiveInt8uList: [11, 12, 13, 14], }, { - fabricIndex: 100, + FabricIndex: 100, fabricSensitiveInt8u: 143, optionalFabricSensitiveInt8u: 144, nullableFabricSensitiveInt8u: null, @@ -175,7 +175,7 @@ tests: value: [ { - fabricIndex: 1, + FabricIndex: 1, fabricSensitiveInt8u: 33, optionalFabricSensitiveInt8u: 34, nullableFabricSensitiveInt8u: null, @@ -195,7 +195,7 @@ tests: fabricSensitiveInt8uList: [1, 2, 3, 4], }, { - fabricIndex: 1, + FabricIndex: 1, fabricSensitiveInt8u: 43, optionalFabricSensitiveInt8u: 44, nullableFabricSensitiveInt8u: null, @@ -225,7 +225,7 @@ tests: value: [ { - fabricIndex: 2, + FabricIndex: 2, fabricSensitiveInt8u: 133, optionalFabricSensitiveInt8u: 134, nullableFabricSensitiveInt8u: null, @@ -245,7 +245,7 @@ tests: fabricSensitiveInt8uList: [11, 12, 13, 14], }, { - fabricIndex: 2, + FabricIndex: 2, fabricSensitiveInt8u: 143, optionalFabricSensitiveInt8u: 144, nullableFabricSensitiveInt8u: null, @@ -287,7 +287,7 @@ tests: value: [ { - fabricIndex: 1, + FabricIndex: 1, fabricSensitiveInt8u: 33, optionalFabricSensitiveInt8u: 34, nullableFabricSensitiveInt8u: null, @@ -307,7 +307,7 @@ tests: fabricSensitiveInt8uList: [1, 2, 3, 4], }, { - fabricIndex: 1, + FabricIndex: 1, fabricSensitiveInt8u: 43, optionalFabricSensitiveInt8u: 44, nullableFabricSensitiveInt8u: null, @@ -327,7 +327,7 @@ tests: fabricSensitiveInt8uList: [2, 3, 4, 5], }, { - fabricIndex: 2, + FabricIndex: 2, fabricSensitiveInt8u: 0, nullableFabricSensitiveInt8u: null, fabricSensitiveCharString: "", @@ -345,7 +345,7 @@ tests: fabricSensitiveInt8uList: [], }, { - fabricIndex: 2, + FabricIndex: 2, fabricSensitiveInt8u: 0, nullableFabricSensitiveInt8u: null, fabricSensitiveCharString: "", @@ -374,7 +374,7 @@ tests: value: [ { - fabricIndex: 1, + FabricIndex: 1, fabricSensitiveInt8u: 0, nullableFabricSensitiveInt8u: null, fabricSensitiveCharString: "", @@ -392,7 +392,7 @@ tests: fabricSensitiveInt8uList: [], }, { - fabricIndex: 1, + FabricIndex: 1, fabricSensitiveInt8u: 0, nullableFabricSensitiveInt8u: null, fabricSensitiveCharString: "", @@ -410,7 +410,7 @@ tests: fabricSensitiveInt8uList: [], }, { - fabricIndex: 2, + FabricIndex: 2, fabricSensitiveInt8u: 133, optionalFabricSensitiveInt8u: 134, nullableFabricSensitiveInt8u: null, @@ -430,7 +430,7 @@ tests: fabricSensitiveInt8uList: [11, 12, 13, 14], }, { - fabricIndex: 2, + FabricIndex: 2, fabricSensitiveInt8u: 143, optionalFabricSensitiveInt8u: 144, nullableFabricSensitiveInt8u: null, @@ -460,7 +460,7 @@ tests: value: [ { - fabricIndex: 100, + FabricIndex: 100, fabricSensitiveInt8u: 53, optionalFabricSensitiveInt8u: 54, nullableFabricSensitiveInt8u: null, @@ -490,7 +490,7 @@ tests: value: [ { - fabricIndex: 2, + FabricIndex: 2, fabricSensitiveInt8u: 133, optionalFabricSensitiveInt8u: 134, nullableFabricSensitiveInt8u: null, @@ -510,7 +510,7 @@ tests: fabricSensitiveInt8uList: [11, 12, 13, 14], }, { - fabricIndex: 2, + FabricIndex: 2, fabricSensitiveInt8u: 143, optionalFabricSensitiveInt8u: 144, nullableFabricSensitiveInt8u: null, @@ -540,7 +540,7 @@ tests: value: [ { - fabricIndex: 1, + FabricIndex: 1, fabricSensitiveInt8u: 53, optionalFabricSensitiveInt8u: 54, nullableFabricSensitiveInt8u: null, diff --git a/src/app/tests/suites/TestConstraints.yaml b/src/app/tests/suites/TestConstraints.yaml index f96c8d1d2a513c..92e74944420980 100644 --- a/src/app/tests/suites/TestConstraints.yaml +++ b/src/app/tests/suites/TestConstraints.yaml @@ -112,6 +112,12 @@ tests: constraints: hasMasksSet: [0x01, 0x04] # [MaskVal1, MaskVal3] + - label: "Write attribute BITMAP32 Back to Default Value" + command: "writeAttribute" + attribute: "bitmap32" + arguments: + value: 0 + # Tests for INT32U attribute - label: "Write attribute INT32U Value" diff --git a/src/app/tests/suites/TestModeSelectCluster.yaml b/src/app/tests/suites/TestModeSelectCluster.yaml index 68f8317e16580f..43ae57d4e7097d 100644 --- a/src/app/tests/suites/TestModeSelectCluster.yaml +++ b/src/app/tests/suites/TestModeSelectCluster.yaml @@ -45,16 +45,16 @@ tests: response: value: [ - { Label: "Black", Mode: 0, SemanticTags: [{ "value": 0 }] }, + { Label: "Black", Mode: 0, SemanticTags: [{ "Value": 0 }] }, { Label: "Cappuccino", Mode: 4, - SemanticTags: [{ "value": 0 }], + SemanticTags: [{ "Value": 0 }], }, { Label: "Espresso", Mode: 7, - SemanticTags: [{ "value": 0 }], + SemanticTags: [{ "Value": 0 }], }, ] constraints: diff --git a/src/app/tests/suites/TestMultiAdmin.yaml b/src/app/tests/suites/TestMultiAdmin.yaml index fb05ce34893cee..b26e0b2159edc0 100644 --- a/src/app/tests/suites/TestMultiAdmin.yaml +++ b/src/app/tests/suites/TestMultiAdmin.yaml @@ -98,7 +98,7 @@ tests: attribute: "Fabrics" fabricFiltered: false response: - value: [{ "nodeID": nodeId }] + value: [{ "NodeId": nodeId }] - label: "Close Commissioning Window after failed commissioning" cluster: "AdministratorCommissioning" diff --git a/src/app/tests/suites/certification/PICS.yaml b/src/app/tests/suites/certification/PICS.yaml index ddcda6eb8271ed..cffcba6784369e 100644 --- a/src/app/tests/suites/certification/PICS.yaml +++ b/src/app/tests/suites/certification/PICS.yaml @@ -3714,10 +3714,10 @@ PICS: id: DGTHREAD.S.A0039 - label: "Does the DUT-server support the Delay attribute?" - id: DGTHREAD.S.A003A + id: DGTHREAD.S.A003a - label: "Does the DUT-server support the SecurityPolicy attribute?" - id: DGTHREAD.S.A003B + id: DGTHREAD.S.A003b - label: "Does the DUT-server support the ChannelPage0Mask attribute?" id: DGTHREAD.S.A003c @@ -4589,6 +4589,16 @@ PICS: - label: "Does the DUT(server) support the ReachableChanged event?" id: BINFO.S.E03 + #Features + - label: "Does the device implement the Wi-Fi related features ?" + id: CNET.S.F00 + + - label: "Does the device implement the Thread related features" + id: CNET.S.F01 + + - label: "Does the device implement the Ethernet related features ?" + id: CNET.S.F02 + #Client Attributes - label: "Does the DUT(Client) support the DataModelRevision attribute?" id: BINFO.C.A0000 diff --git a/src/app/tests/suites/certification/Test_TC_ACL_2_3.yaml b/src/app/tests/suites/certification/Test_TC_ACL_2_3.yaml index ee68e0c2b5de21..7ef1ba418e17c4 100644 --- a/src/app/tests/suites/certification/Test_TC_ACL_2_3.yaml +++ b/src/app/tests/suites/certification/Test_TC_ACL_2_3.yaml @@ -20,158 +20,82 @@ PICS: config: nodeId: 0x12344321 - cluster: "Basic" + cluster: "Access Control" endpoint: 0 + D_OK_EMPTY: + type: octet_string + defaultValue: "hex:1718" + D_OK_SINGLE: + type: octet_string + defaultValue: "hex:17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018" + D_OK_FULL: + type: octet_string + defaultValue: "hex:17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E6700D00000F1FF02003148656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E7420616761696E2E2E2E2E2E0018" + D_BAD_LENGTH: + type: octet_string + defaultValue: "hex:17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E6700D00000F1FF02003248656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E7420616761696E2E2E2E2E2E2E0018" + D_BAD_STRUCT: + type: octet_string + defaultValue: "hex:1518" + D_BAD_LIST: + type: octet_string + defaultValue: "hex:3701D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018" + D_BAD_ELEM: + type: octet_string + defaultValue: "hex:17103D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018" + D_BAD_OVERFLOW: + type: octet_string + defaultValue: "hex:17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018FF" + D_BAD_UNDERFLOW: + type: octet_string + defaultValue: "hex:17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E6700" + D_BAD_NONE: + type: octet_string + defaultValue: "" tests: - - label: "Pre-Conditions" - verification: | - Notes - - 1.N1 is the node ID of TH1 - - 2.D_OK_EMPTY:"1718" which is an octstr of length 2 containing valid TLV: - - - top-level anonymous list (empty) - - 3.D_OK_SINGLE:"17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018" which is an octstr of length 50-100 containing valid TLV: - - - top-level anonymous list, containing - one element with profile-specific tag in fully-qualified form - - 4.D_OK_FULL:"17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E6700D00000F1FF02003148656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E7420616761696E2E2E2E2E2E0018" which is an octstr of length 128 containing valid TLV: - - - top-level anonymous list, containing - two elements with profile-specific tag in fully-qualified form - - 5.D_BAD_LENGTH:"17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E6700D00000F1FF02003248656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E7420616761696E2E2E2E2E2E2E0018" which is an octstr of length 129 containing valid TLV: - - - top-level anonymous list, containing - one element with profile-specific tag in fully-qualified form - - 6 .D_BAD_STRUCT: "1518" which is an octstr of length 2 containing valid TLV: - - - top-level anonymous struct, empty - - 7.D_BAD_LIST:"3701D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018" which is an octstr of length 50-100 containing valid TLV: - - - top-level list with context-specific tag, containing - one element with profile-specific tag in fully-qualified form - - 8.D_BAD_ELEM:"17103D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018" which is an octstr of length 50-100 containing valid TLV: - - - top-level anonymous list, containing - one element with anonymous tag - - 9 .D_BAD_OVERFLOW: "17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018FF" which is an octstr of length 50-100 containing valid TLV: - - - top-level anonymous list, containing - one element with profile-specific tag in fully-qualified form - but having extra bytes after the top level list end-of-container - - 10.D_BAD_UNDERFLOW:"17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E6700" which is an octstr of length 50-100 containing invalid TLV: - - - top-level anonymous list, containing - one element with profile-specific tag in fully-qualified form - but lacking the top-level list end-of-container - - 11.D_BAD_NONE: "" which is an octstr of length 0 - disabled: true - - - label: "TH1 commissions DUT using admin node ID N1" - verification: | - DUT - sudo ./chip-all-clusters-app --wifi - - TH1 - ./chip-tool pairing ble-wifi 1 zigbee-thread matter123 20202021 3841 - disabled: true + - label: "Wait for the commissioned device to be retrieved" + cluster: "DelayCommands" + command: "WaitForCommissionee" + arguments: + values: + - name: "nodeId" + value: nodeId - label: "TH1 reads DUT Endpoint 0 OperationalCredentials cluster CurrentFabricIndex attribute" - verification: | - ./chip-tool operationalcredentials read current-fabric-index 1 0 - - On TH1(Chiptool), verify the CurrentFabricIndex attribute of operationalCredential cluster as 1 - - [1658323393.451141][2316:2321] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_003E Attribute 0x0000_0005 DataVersion: 3882577299 - [1658323393.465921][2316:2321] CHIP:TOO: CurrentFabricIndex: 1 - disabled: true + cluster: "Operational Credentials" + command: "readAttribute" + attribute: "CurrentFabricIndex" + response: + saveAs: CurrentFabricIndex - label: "TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol read extension 1 0 - - On TH1(Chiptool) , Verify the extension attribute contains an empty list - - [1657116435.352869][2667:2672] CHIP:DMG: SuppressResponse = true, - [1657116435.352904][2667:2672] CHIP:DMG: InteractionModelRevision = 1 - [1657116435.352935][2667:2672] CHIP:DMG: } - [1657116435.353245][2667:2672] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_001F Attribute 0x0000_0001 DataVersion: 368386360 - [1657116435.353328][2667:2672] CHIP:TOO: Extension: 0 entries - [1657116435.353439][2667:2672] CHIP:EM: Sending Standalone Ack for MessageCounter:265691167 on exchange 19854i - disabled: true + command: "readAttribute" + attribute: "Extension" + response: + value: [] - label: "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of AccessControlExtensionStruct containing 1 element 1. struct: Data field: D_OK_EMPTY : 1718" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol write extension '[{"data":"1718"}]' 1 0 - - On TH1(Chiptool) , Verify that the status is Success when writing the AccessControl cluster Extension attribute - - [1656416335.284463][3747:3752] CHIP:DMG: WriteResponseMessage = - [1656416335.284498][3747:3752] CHIP:DMG: { - [1656416335.284539][3747:3752] CHIP:DMG: AttributeStatusIBs = - [1656416335.284581][3747:3752] CHIP:DMG: [ - [1656416335.284626][3747:3752] CHIP:DMG: AttributeStatusIB = - [1656416335.284663][3747:3752] CHIP:DMG: { - [1656416335.284709][3747:3752] CHIP:DMG: AttributePathIB = - [1656416335.284763][3747:3752] CHIP:DMG: { - [1656416335.284807][3747:3752] CHIP:DMG: Endpoint = 0x0, - [1656416335.284861][3747:3752] CHIP:DMG: Cluster = 0x1f, - [1656416335.284907][3747:3752] CHIP:DMG: Attribute = 0x0000_0001, - [1656416335.284961][3747:3752] CHIP:DMG: } - [1656416335.285018][3747:3752] CHIP:DMG: - [1656416335.285058][3747:3752] CHIP:DMG: StatusIB = - [1656416335.285109][3747:3752] CHIP:DMG: { - [1656416335.285150][3747:3752] CHIP:DMG: status = 0x00 (SUCCESS), - [1656416335.285203][3747:3752] CHIP:DMG: }, - [1656416335.285255][3747:3752] CHIP:DMG: - [1656416335.285290][3747:3752] CHIP:DMG: }, - [1656416335.285349][3747:3752] CHIP:DMG: - [1656416335.285382][3747:3752] CHIP:DMG: AttributeStatusIB = - [1656416335.285432][3747:3752] CHIP:DMG: { - [1656416335.285466][3747:3752] CHIP:DMG: AttributePathIB = - [1656416335.285516][3747:3752] CHIP:DMG: { - [1656416335.285557][3747:3752] CHIP:DMG: Endpoint = 0x0, - [1656416335.285617][3747:3752] CHIP:DMG: Cluster = 0x1f, - [1656416335.285662][3747:3752] CHIP:DMG: Attribute = 0x0000_0001, - [1656416335.285705][3747:3752] CHIP:DMG: ListIndex = Null, - [1656416335.285746][3747:3752] CHIP:DMG: } - [1656416335.285790][3747:3752] CHIP:DMG: - [1656416335.285829][3747:3752] CHIP:DMG: StatusIB = - [1656416335.285867][3747:3752] CHIP:DMG: { - [1656416335.285907][3747:3752] CHIP:DMG: status = 0x00 (SUCCESS), - [1656416335.285948][3747:3752] CHIP:DMG: }, - [1656416335.285988][3747:3752] CHIP:DMG: - [1656416335.286021][3747:3752] CHIP:DMG: }, - disabled: true + command: "writeAttribute" + attribute: "Extension" + arguments: + value: [{ Data: D_OK_EMPTY, FabricIndex: CurrentFabricIndex }] - label: "TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol read extension 1 0 - - On TH1(Chiptool) , Verify value is list of AccessControlExtensionStruct containing 1 element . Data field: D_OK_EMPTY : "1718" and - FabricIndex field: F1 - - - [1657278638.723927][9030:9035] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_001F Attribute 0x0000_0001 DataVersion: 525362695 - [1657278638.724004][9030:9035] CHIP:TOO: Extension: 1 entries - [1657278638.724072][9030:9035] CHIP:TOO: [1]: { - [1657278638.724106][9030:9035] CHIP:TOO: Data: 1718 - [1657278638.724151][9030:9035] CHIP:TOO: FabricIndex: 1 - [1657278638.724180][9030:9035] CHIP:TOO: } - [1657278638.724307][9030:9035] CHIP:EM: Sending Standalone Ack for MessageCounter:131793781 on exchange 9203i - disabled: true + command: "readAttribute" + attribute: "Extension" + response: + value: [{ Data: D_OK_EMPTY, FabricIndex: CurrentFabricIndex }] - label: "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, @@ -179,246 +103,37 @@ tests: 1.struct Data field: D_OK_SINGLE :17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol write extension '[{"data":"17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018"}]' 1 0 - - On TH1(Chiptool) , Verify that the status is success when writing the AccessControl cluster Extension attribute. - - - [1656416899.781899][3814:3819] CHIP:DMG: WriteResponseMessage = - - [1656416899.781952][3814:3819] CHIP:DMG: { - [1656416899.781998][3814:3819] CHIP:DMG: AttributeStatusIBs = - [1656416899.782062][3814:3819] CHIP:DMG: [ - [1656416899.782114][3814:3819] CHIP:DMG: AttributeStatusIB = - [1656416899.782181][3814:3819] CHIP:DMG: { - [1656416899.782236][3814:3819] CHIP:DMG: AttributePathIB = - [1656416899.782301][3814:3819] CHIP:DMG: { - [1656416899.782369][3814:3819] CHIP:DMG: Endpoint = 0x0, - [1656416899.782442][3814:3819] CHIP:DMG: Cluster = 0x1f, - [1656416899.782512][3814:3819] CHIP:DMG: Attribute = 0x0000_0001, - [1656416899.782583][3814:3819] CHIP:DMG: } - [1656416899.782656][3814:3819] CHIP:DMG: - [1656416899.782718][3814:3819] CHIP:DMG: StatusIB = - [1656416899.782782][3814:3819] CHIP:DMG: { - [1656416899.782850][3814:3819] CHIP:DMG: status = 0x00 (SUCCESS), - [1656416899.782916][3814:3819] CHIP:DMG: }, - [1656416899.782981][3814:3819] CHIP:DMG: - [1656416899.783035][3814:3819] CHIP:DMG: }, - [1656416899.783107][3814:3819] CHIP:DMG: - [1656416899.783159][3814:3819] CHIP:DMG: AttributeStatusIB = - [1656416899.783215][3814:3819] CHIP:DMG: { - [1656416899.783269][3814:3819] CHIP:DMG: AttributePathIB = - [1656416899.783331][3814:3819] CHIP:DMG: { - [1656416899.783396][3814:3819] CHIP:DMG: Endpoint = 0x0, - [1656416899.783466][3814:3819] CHIP:DMG: Cluster = 0x1f, - [1656416899.783536][3814:3819] CHIP:DMG: Attribute = 0x0000_0001, - [1656416899.783603][3814:3819] CHIP:DMG: ListIndex = Null, - [1656416899.783669][3814:3819] CHIP:DMG: } - [1656416899.783740][3814:3819] CHIP:DMG: - [1656416899.783802][3814:3819] CHIP:DMG: StatusIB = - [1656416899.783864][3814:3819] CHIP:DMG: { - [1656416899.783928][3814:3819] CHIP:DMG: status = 0x00 (SUCCESS), - [1656416899.784031][3814:3819] CHIP:DMG: }, - [1656416899.784099][3814:3819] CHIP:DMG: - [1656416899.784152][3814:3819] CHIP:DMG: }, - [1656416899.784215][3814:3819] CHIP:DMG: - [1656416899.784265][3814:3819] CHIP:DMG: ], - [1656416899.784333][3814:3819] CHIP:DMG: - [1656416899.784384][3814:3819] CHIP:DMG: InteractionModelRevision = 1 - [1656416899.784434][3814:3819] CHIP:DMG: } - [1656416899.784620][3814:3819] CHIP:DMG: WriteClient moving to [AwaitingDe] - [1656416899.784719][3814:3819] CHIP:EM: Sending Standalone Ack for MessageCounter:116771897 on exchange 19604i - disabled: true + command: "writeAttribute" + attribute: "Extension" + arguments: + value: [{ Data: D_OK_SINGLE, FabricIndex: CurrentFabricIndex }] - label: "TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol read extension 1 0 - - On TH1(Chiptool) , Verify the AccessControlExtensionStruct containing 1 element - Data field: D_OK_SINGLE :"17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018" and FabricIndex field : F1 - - [1657278788.400832][9048:9053] CHIP:DMG: ReportDataMessage = - [1657278788.400863][9048:9053] CHIP:DMG: { - [1657278788.400887][9048:9053] CHIP:DMG: AttributeReportIBs = - [1657278788.400920][9048:9053] CHIP:DMG: [ - [1657278788.400947][9048:9053] CHIP:DMG: AttributeReportIB = - [1657278788.400985][9048:9053] CHIP:DMG: { - [1657278788.401039][9048:9053] CHIP:DMG: AttributeDataIB = - [1657278788.401090][9048:9053] CHIP:DMG: { - [1657278788.401136][9048:9053] CHIP:DMG: DataVersion = 0x1f506609, - [1657278788.401181][9048:9053] CHIP:DMG: AttributePathIB = - [1657278788.401242][9048:9053] CHIP:DMG: { - [1657278788.401299][9048:9053] CHIP:DMG: Endpoint = 0x0, - [1657278788.401348][9048:9053] CHIP:DMG: Cluster = 0x1f, - [1657278788.401406][9048:9053] CHIP:DMG: Attribute = 0x0000_0001, - [1657278788.401462][9048:9053] CHIP:DMG: } - [1657278788.401527][9048:9053] CHIP:DMG: - [1657278788.401587][9048:9053] CHIP:DMG: Data = [ - [1657278788.401646][9048:9053] CHIP:DMG: - [1657278788.401707][9048:9053] CHIP:DMG: ], - [1657278788.401765][9048:9053] CHIP:DMG: }, - [1657278788.401821][9048:9053] CHIP:DMG: - [1657278788.401867][9048:9053] CHIP:DMG: }, - [1657278788.401911][9048:9053] CHIP:DMG: - [1657278788.401945][9048:9053] CHIP:DMG: AttributeReportIB = - [1657278788.402001][9048:9053] CHIP:DMG: { - [1657278788.402031][9048:9053] CHIP:DMG: AttributeDataIB = - [1657278788.402082][9048:9053] CHIP:DMG: { - [1657278788.402119][9048:9053] CHIP:DMG: DataVersion = 0x1f506609, - [1657278788.402163][9048:9053] CHIP:DMG: AttributePathIB = - [1657278788.402200][9048:9053] CHIP:DMG: { - [1657278788.402247][9048:9053] CHIP:DMG: Endpoint = 0x0, - [1657278788.402295][9048:9053] CHIP:DMG: Cluster = 0x1f, - [1657278788.402334][9048:9053] CHIP:DMG: Attribute = 0x0000_0001, - [1657278788.402371][9048:9053] CHIP:DMG: ListIndex = Null, - [1657278788.402407][9048:9053] CHIP:DMG: } - [1657278788.402446][9048:9053] CHIP:DMG: - [1657278788.402481][9048:9053] CHIP:DMG: Data = - [1657278788.402514][9048:9053] CHIP:DMG: { - [1657278788.402574][9048:9053] CHIP:DMG: 0x1 = [ - [1657278788.402634][9048:9053] CHIP:DMG: 0x17, 0xd0, 0x0, 0x0, 0xf1, 0xff, 0x1, 0x0, 0x3d, 0x48, 0x65, 0x6c, 0x6c, 0x6f, 0x20, 0x57, 0x6f, 0x72, 0x6c, 0x64, 0x2e, 0x20, 0x54, 0x68, 0x69, 0x73, 0x20, 0x69, 0x73, 0x20, 0x61, 0x20, 0x73, 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x20, 0x65, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x6c, 0x69, 0x76, 0x69, 0x6e, 0x67, 0x20, 0x61, 0x73, 0x20, 0x61, 0x20, 0x63, 0x68, 0x61, 0x72, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x0, 0x18, - [1657278788.402678][9048:9053] CHIP:DMG: ] - [1657278788.402716][9048:9053] CHIP:DMG: 0xfe = 1, - [1657278788.402755][9048:9053] CHIP:DMG: }, - [1657278788.402785][9048:9053] CHIP:DMG: }, - [1657278788.402824][9048:9053] CHIP:DMG: - [1657278788.402851][9048:9053] CHIP:DMG: }, - [1657278788.402886][9048:9053] CHIP:DMG: - [1657278788.402910][9048:9053] CHIP:DMG: ], - [1657278788.402946][9048:9053] CHIP:DMG: - [1657278788.402972][9048:9053] CHIP:DMG: SuppressResponse = true, - [1657278788.402996][9048:9053] CHIP:DMG: InteractionModelRevision = 1 - [1657278788.403019][9048:9053] CHIP:DMG: } - [1657278788.403304][9048:9053] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_001F Attribute 0x0000_0001 DataVersion: 525362697 - [1657278788.403374][9048:9053] CHIP:TOO: Extension: 1 entries - [1657278788.403426][9048:9053] CHIP:TOO: [1]: { - [1657278788.403457][9048:9053] CHIP:TOO: Data: 17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018 - [1657278788.403509][9048:9053] CHIP:TOO: FabricIndex: 1 - [1657278788.403543][9048:9053] CHIP:TOO: } - [1657278788.403642][9048:9053] CHIP:EM: Sending Standalone Ack for MessageCounter:90870339 on exchange 24533i - disabled: true + command: "readAttribute" + attribute: "Extension" + response: + value: [{ Data: D_OK_SINGLE, FabricIndex: CurrentFabricIndex }] - label: "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of AccessControlExtensionStruct containing 1 element 1.struct Data field: D_OK_FULL - :17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E6700D00000F1FF02003148656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E7420616761696E2E2E2E2E2E0018 - which is an octstr of length 128 containing valid TLV:" + :17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E6700D00000F1FF02003148656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E7420616761696E2E2E2E2E2E0018" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol write extension '[{"data":"17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E6700D00000F1FF02003148656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E7420616761696E2E2E2E2E2E0018"}]' 1 0 - - On TH1(Chiptool) , Verify that the status is success when writing the AccessControl cluster Extension attribute - [1656417544.279572][3888:3893] CHIP:DMG: WriteResponseMessage = - [1656417544.279598][3888:3893] CHIP:DMG: { - [1656417544.279620][3888:3893] CHIP:DMG: AttributeStatusIBs = - [1656417544.279651][3888:3893] CHIP:DMG: [ - [1656417544.279676][3888:3893] CHIP:DMG: AttributeStatusIB = - [1656417544.279710][3888:3893] CHIP:DMG: { - [1656417544.279739][3888:3893] CHIP:DMG: AttributePathIB = - [1656417544.279773][3888:3893] CHIP:DMG: { - [1656417544.279808][3888:3893] CHIP:DMG: Endpoint = 0x0, - [1656417544.279842][3888:3893] CHIP:DMG: Cluster = 0x1f, - [1656417544.279877][3888:3893] CHIP:DMG: Attribute = 0x0000_0001, - [1656417544.279908][3888:3893] CHIP:DMG: } - [1656417544.279944][3888:3893] CHIP:DMG: - [1656417544.279985][3888:3893] CHIP:DMG: StatusIB = - [1656417544.280012][3888:3893] CHIP:DMG: { - [1656417544.280041][3888:3893] CHIP:DMG: status = 0x00 (SUCCESS), - [1656417544.280072][3888:3893] CHIP:DMG: }, - [1656417544.280104][3888:3893] CHIP:DMG: - [1656417544.280130][3888:3893] CHIP:DMG: }, - [1656417544.280165][3888:3893] CHIP:DMG: - [1656417544.280189][3888:3893] CHIP:DMG: AttributeStatusIB = - [1656417544.280216][3888:3893] CHIP:DMG: { - [1656417544.280242][3888:3893] CHIP:DMG: AttributePathIB = - [1656417544.280272][3888:3893] CHIP:DMG: { - [1656417544.280304][3888:3893] CHIP:DMG: Endpoint = 0x0, - [1656417544.280337][3888:3893] CHIP:DMG: Cluster = 0x1f, - [1656417544.280371][3888:3893] CHIP:DMG: Attribute = 0x0000_0001, - [1656417544.280404][3888:3893] CHIP:DMG: ListIndex = Null, - [1656417544.280435][3888:3893] CHIP:DMG: } - [1656417544.280470][3888:3893] CHIP:DMG: - [1656417544.280500][3888:3893] CHIP:DMG: StatusIB = - [1656417544.280530][3888:3893] CHIP:DMG: { - [1656417544.280562][3888:3893] CHIP:DMG: status = 0x00 (SUCCESS), - [1656417544.280593][3888:3893] CHIP:DMG: }, - [1656417544.280624][3888:3893] CHIP:DMG: - disabled: true + command: "writeAttribute" + attribute: "Extension" + arguments: + value: [{ Data: D_OK_FULL, FabricIndex: CurrentFabricIndex }] - label: "TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol read extension 1 0 - On TH1(Chiptool) , Verify AccessControlExtensionStructcontaining 1 element - Data field: - D_OK_FULL :"17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E6700D00000F1FF02003148656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E7420616761696E2E2E2E2E2E0018" and FabricIndex field : F1 - - - 1657278905.391846][9065:9070] CHIP:DMG: ReportDataMessage = - [1657278905.391878][9065:9070] CHIP:DMG: { - [1657278905.391906][9065:9070] CHIP:DMG: AttributeReportIBs = - [1657278905.391951][9065:9070] CHIP:DMG: [ - [1657278905.391986][9065:9070] CHIP:DMG: AttributeReportIB = - [1657278905.392036][9065:9070] CHIP:DMG: { - [1657278905.392068][9065:9070] CHIP:DMG: AttributeDataIB = - [1657278905.392108][9065:9070] CHIP:DMG: { - [1657278905.392153][9065:9070] CHIP:DMG: DataVersion = 0x1f50660b, - [1657278905.392198][9065:9070] CHIP:DMG: AttributePathIB = - [1657278905.392279][9065:9070] CHIP:DMG: { - [1657278905.392328][9065:9070] CHIP:DMG: Endpoint = 0x0, - [1657278905.392381][9065:9070] CHIP:DMG: Cluster = 0x1f, - [1657278905.392430][9065:9070] CHIP:DMG: Attribute = 0x0000_0001, - [1657278905.392470][9065:9070] CHIP:DMG: } - [1657278905.392517][9065:9070] CHIP:DMG: - [1657278905.392561][9065:9070] CHIP:DMG: Data = [ - [1657278905.392604][9065:9070] CHIP:DMG: - [1657278905.392650][9065:9070] CHIP:DMG: ], - [1657278905.392693][9065:9070] CHIP:DMG: }, - [1657278905.392739][9065:9070] CHIP:DMG: - [1657278905.392773][9065:9070] CHIP:DMG: }, - [1657278905.392823][9065:9070] CHIP:DMG: - [1657278905.392857][9065:9070] CHIP:DMG: AttributeReportIB = - [1657278905.392901][9065:9070] CHIP:DMG: { - [1657278905.392936][9065:9070] CHIP:DMG: AttributeDataIB = - [1657278905.392976][9065:9070] CHIP:DMG: { - [1657278905.393016][9065:9070] CHIP:DMG: DataVersion = 0x1f50660b, - [1657278905.393060][9065:9070] CHIP:DMG: AttributePathIB = - [1657278905.393100][9065:9070] CHIP:DMG: { - [1657278905.393135][9065:9070] CHIP:DMG: Endpoint = 0x0, - [1657278905.393170][9065:9070] CHIP:DMG: Cluster = 0x1f, - [1657278905.393207][9065:9070] CHIP:DMG: Attribute = 0x0000_0001, - [1657278905.393252][9065:9070] CHIP:DMG: ListIndex = Null, - [1657278905.393296][9065:9070] CHIP:DMG: } - [1657278905.393343][9065:9070] CHIP:DMG: - [1657278905.393385][9065:9070] CHIP:DMG: Data = - [1657278905.393429][9065:9070] CHIP:DMG: { - [1657278905.393505][9065:9070] CHIP:DMG: 0x1 = [ - [1657278905.393605][9065:9070] CHIP:DMG: 0x17, 0xd0, 0x0, 0x0, 0xf1, 0xff, 0x1, 0x0, 0x3d, 0x48, 0x65, 0x6c, 0x6c, 0x6f, 0x20, 0x57, 0x6f, 0x72, 0x6c, 0x64, 0x2e, 0x20, 0x54, 0x68, 0x69, 0x73, 0x20, 0x69, 0x73, 0x20, 0x61, 0x20, 0x73, 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x20, 0x65, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x6c, 0x69, 0x76, 0x69, 0x6e, 0x67, 0x20, 0x61, 0x73, 0x20, 0x61, 0x20, 0x63, 0x68, 0x61, 0x72, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x0, 0xd0, 0x0, 0x0, 0xf1, 0xff, 0x2, 0x0, 0x31, 0x48, 0x65, 0x6c, 0x6c, 0x6f, 0x20, 0x57, 0x6f, 0x72, 0x6c, 0x64, 0x2e, 0x20, 0x54, 0x68, 0x69, 0x73, 0x20, 0x69, 0x73, 0x20, 0x61, 0x20, 0x73, 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x20, 0x65, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x61, 0x67, 0x61, 0x69, 0x6e, 0x2e, 0x2e, 0x2e, 0x2e, 0x2e, 0x0, 0x18, - [1657278905.393670][9065:9070] CHIP:DMG: ] - [1657278905.393718][9065:9070] CHIP:DMG: 0xfe = 1, - [1657278905.393765][9065:9070] CHIP:DMG: }, - [1657278905.393810][9065:9070] CHIP:DMG: }, - [1657278905.393862][9065:9070] CHIP:DMG: - [1657278905.393899][9065:9070] CHIP:DMG: }, - [1657278905.393942][9065:9070] CHIP:DMG: - [1657278905.393974][9065:9070] CHIP:DMG: ], - [1657278905.394023][9065:9070] CHIP:DMG: - [1657278905.394058][9065:9070] CHIP:DMG: SuppressResponse = true, - [1657278905.394091][9065:9070] CHIP:DMG: InteractionModelRevision = 1 - [1657278905.394122][9065:9070] CHIP:DMG: } - [1657278905.394435][9065:9070] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_001F Attribute 0x0000_0001 DataVersion: 525362699 - [1657278905.394508][9065:9070] CHIP:TOO: Extension: 1 entries - [1657278905.394573][9065:9070] CHIP:TOO: [1]: { - [1657278905.394618][9065:9070] CHIP:TOO: Data: 17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E6700D00000F1FF02003148656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E7420616761696E2E2E2E2E2E0018 - [1657278905.394671][9065:9070] CHIP:TOO: FabricIndex: 1 - [1657278905.394703][9065:9070] CHIP:TOO: } - [1657278905.394800][9065:9070] CHIP:EM: Sending Standalone Ack for MessageCounter:35167907 on exchange 47841i - disabled: true + command: "readAttribute" + attribute: "Extension" + response: + value: [{ Data: D_OK_FULL, FabricIndex: CurrentFabricIndex }] - label: "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, @@ -426,53 +141,24 @@ tests: .struct Data field: D_BAD_LENGTH :17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E6700D00000F1FF02003248656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E7420616761696E2E2E2E2E2E2E0018" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol write extension '[{"data":"17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E6700D00000F1FF02003248656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E7420616761696E2E2E2E2E2E2E0018"}]' 1 0 - On TH1(Chiptool) , Verify that the status is CONSTRAINT_ERROR (0x87) when writing the AccessControl cluster Extension attribute - - [1657279033.591694][9081:9086] CHIP:DMG: StatusIB = - [1657279033.591739][9081:9086] CHIP:DMG: { - [1657279033.591784][9081:9086] CHIP:DMG: status = 0x87 (CONSTRAINT_ERROR), - [1657279033.591830][9081:9086] CHIP:DMG: }, - [1657279033.591876][9081:9086] CHIP:DMG: - [1657279033.591915][9081:9086] CHIP:DMG: }, - [1657279033.591961][9081:9086] CHIP:DMG: - [1657279033.591998][9081:9086] CHIP:DMG: ], - [1657279033.592046][9081:9086] CHIP:DMG: - [1657279033.592081][9081:9086] CHIP:DMG: InteractionModelRevision = 1 - [1657279033.592115][9081:9086] CHIP:DMG: } - [1657279033.592290][9081:9086] CHIP:DMG: WriteClient moving to [AwaitingDe] - [1657279033.592341][9081:9086] CHIP:TOO: Response Failure: IM Error 0x00000587: General error: 0x87 (CONSTRAINT_ERROR) - [1657279033.592418][9081:9086] CHIP:EM: Sending Standalone Ack for MessageCounter:30643689 on exchange 27853i - [1657279033.592517][9081:9086] CHIP:IN: Prepared secure message 0xffff8efdd9d8 to 0x0000000000000001 (1) of type 0x10 and protocolId (0, 0) on exchange 27853i with MessageCounter:149398748. - [1657279033.592572][9081:9086] CHIP:IN: Sending encrypted msg 0xffff8efdd9d8 with MessageCounter:149398748 to 0x0000000000000001 (1) at monotonic time: 000000000083ABDC msec - [1657279033.592744][9081:9086] CHIP:EM: Flushed pending ack for MessageCounter:30643689 on exchange 27853i - disabled: true + command: "writeAttribute" + attribute: "Extension" + arguments: + value: [{ Data: D_BAD_LENGTH, FabricIndex: CurrentFabricIndex }] + response: + error: CONSTRAINT_ERROR - label: "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of AccessControlExtensionStruct containing 1 element 1. struct Data field: D_BAD_STRUCT : 1518" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol write extension '[{"data":"1518"}]' 1 0 - - On TH1(Chiptool) , Verify that the status is CONSTRAINT_ERROR (0x87) when writing the AccessControl cluster Extension attribute - - [1657609094.515713][8195:8200] CHIP:DMG: StatusIB = - [1657609094.515754][8195:8200] CHIP:DMG: { - [1657609094.515797][8195:8200] CHIP:DMG: status = 0x87 (CONSTRAINT_ERROR), - [1657609094.515840][8195:8200] CHIP:DMG: }, - [1657609094.515882][8195:8200] CHIP:DMG: - [1657609094.515919][8195:8200] CHIP:DMG: }, - [1657609094.515970][8195:8200] CHIP:DMG: - [1657609094.516004][8195:8200] CHIP:DMG: ], - [1657609094.516051][8195:8200] CHIP:DMG: - [1657609094.516086][8195:8200] CHIP:DMG: InteractionModelRevision = 1 - [1657609094.516121][8195:8200] CHIP:DMG: } - [1657609094.516266][8195:8200] CHIP:DMG: WriteClient moving to [AwaitingDe] - [1657609094.516312][8195:8200] CHIP:TOO: Response Failure: IM Error 0x00000587: General error: 0x87 (CONSTRAINT_ERROR) - disabled: true + command: "writeAttribute" + attribute: "Extension" + arguments: + value: [{ Data: D_BAD_STRUCT, FabricIndex: CurrentFabricIndex }] + response: + error: CONSTRAINT_ERROR - label: "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, @@ -480,25 +166,12 @@ tests: struct Data field: D_BAD_LIST :3701D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol write extension '[{"data":"3701D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018"}]' 1 0 - - On TH1(Chiptool) , Verify that the status is CONSTRAINT_ERROR (0x87) when writing the AccessControl cluster Extension attribute - - [1657609434.915033][8206:8211] CHIP:DMG: StatusIB = - [1657609434.915073][8206:8211] CHIP:DMG: { - [1657609434.915115][8206:8211] CHIP:DMG: status = 0x87 (CONSTRAINT_ERROR), - [1657609434.915152][8206:8211] CHIP:DMG: }, - [1657609434.915193][8206:8211] CHIP:DMG: - [1657609434.915226][8206:8211] CHIP:DMG: }, - [1657609434.915264][8206:8211] CHIP:DMG: - [1657609434.915293][8206:8211] CHIP:DMG: ], - [1657609434.915333][8206:8211] CHIP:DMG: - [1657609434.915362][8206:8211] CHIP:DMG: InteractionModelRevision = 1 - [1657609434.915391][8206:8211] CHIP:DMG: } - [1657609434.915511][8206:8211] CHIP:DMG: WriteClient moving to [AwaitingDe] - [1657609434.915549][8206:8211] CHIP:TOO: Response Failure: IM Error 0x00000587: General error: 0x87 (CONSTRAINT_ERROR) - disabled: true + command: "writeAttribute" + attribute: "Extension" + arguments: + value: [{ Data: D_BAD_LIST, FabricIndex: CurrentFabricIndex }] + response: + error: CONSTRAINT_ERROR - label: "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, @@ -506,27 +179,12 @@ tests: struct Data field: D_BAD_ELEM :17103D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol write extension '[{"data":"17103D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018"}]' 1 0 - - On TH1(Chiptool) , Verify that the status is CONSTRAINT_ERROR (0x87) when writing the AccessControl cluster Extension attribute - - - [1657609579.494576][8215:8220] CHIP:DMG: - [1657609579.494615][8215:8220] CHIP:DMG: StatusIB = - [1657609579.494656][8215:8220] CHIP:DMG: { - [1657609579.494697][8215:8220] CHIP:DMG: status = 0x87 (CONSTRAINT_ERROR), - [1657609579.494735][8215:8220] CHIP:DMG: }, - [1657609579.494772][8215:8220] CHIP:DMG: - [1657609579.494803][8215:8220] CHIP:DMG: }, - [1657609579.494838][8215:8220] CHIP:DMG: - [1657609579.494867][8215:8220] CHIP:DMG: ], - [1657609579.494906][8215:8220] CHIP:DMG: - [1657609579.494935][8215:8220] CHIP:DMG: InteractionModelRevision = 1 - [1657609579.494963][8215:8220] CHIP:DMG: } - [1657609579.495080][8215:8220] CHIP:DMG: WriteClient moving to [AwaitingDe] - [1657609579.495119][8215:8220] CHIP:TOO: Response Failure: IM Error 0x00000587: General error: 0x87 (CONSTRAINT_ERROR) - disabled: true + command: "writeAttribute" + attribute: "Extension" + arguments: + value: [{ Data: D_BAD_ELEM, FabricIndex: CurrentFabricIndex }] + response: + error: CONSTRAINT_ERROR - label: "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, @@ -534,26 +192,12 @@ tests: .struct Data field: D_BAD_OVERFLOW : 17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018FF" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol write extension '[{"data":"17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018FF"}]' 1 0 - - On TH1(Chiptool) , Verify that the status is CONSTRAINT_ERROR (0x87) when writing the AccessControl cluster Extension attribute - - [1657609625.259137][8223:8228] CHIP:DMG: - [1657609625.259168][8223:8228] CHIP:DMG: StatusIB = - [1657609625.259200][8223:8228] CHIP:DMG: { - [1657609625.259233][8223:8228] CHIP:DMG: status = 0x87 (CONSTRAINT_ERROR), - [1657609625.259268][8223:8228] CHIP:DMG: }, - [1657609625.259301][8223:8228] CHIP:DMG: - [1657609625.259329][8223:8228] CHIP:DMG: }, - [1657609625.259361][8223:8228] CHIP:DMG: - [1657609625.259386][8223:8228] CHIP:DMG: ], - [1657609625.259420][8223:8228] CHIP:DMG: - [1657609625.259445][8223:8228] CHIP:DMG: InteractionModelRevision = 1 - [1657609625.259471][8223:8228] CHIP:DMG: } - [1657609625.259571][8223:8228] CHIP:DMG: WriteClient moving to [AwaitingDe] - [1657609625.259605][8223:8228] CHIP:TOO: Response Failure: IM Error 0x00000587: General error: 0x87 (CONSTRAINT_ERROR) - disabled: true + command: "writeAttribute" + attribute: "Extension" + arguments: + value: [{ Data: D_BAD_OVERFLOW, FabricIndex: CurrentFabricIndex }] + response: + error: CONSTRAINT_ERROR - label: "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, @@ -561,52 +205,24 @@ tests: struct Data field: D_BAD_UNDERFLOW :17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E6700" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol write extension '[{"data":"17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E6700"}]' 1 0 - - On TH1(Chiptool) , Verify that the status is CONSTRAINT_ERROR (0x87) when writing the AccessControl cluster Extension attribute - - [1657609654.299668][8229:8234] CHIP:DMG: StatusIB = - [1657609654.299712][8229:8234] CHIP:DMG: { - [1657609654.299758][8229:8234] CHIP:DMG: status = 0x87 (CONSTRAINT_ERROR), - [1657609654.299808][8229:8234] CHIP:DMG: }, - [1657609654.299852][8229:8234] CHIP:DMG: - [1657609654.299892][8229:8234] CHIP:DMG: }, - [1657609654.299935][8229:8234] CHIP:DMG: - [1657609654.299969][8229:8234] CHIP:DMG: ], - [1657609654.300017][8229:8234] CHIP:DMG: - [1657609654.300053][8229:8234] CHIP:DMG: InteractionModelRevision = 1 - [1657609654.300088][8229:8234] CHIP:DMG: } - [1657609654.300230][8229:8234] CHIP:DMG: WriteClient moving to [AwaitingDe] - [1657609654.300275][8229:8234] CHIP:TOO: Response Failure: IM Error 0x00000587: General error: 0x87 (CONSTRAINT_ERROR) - disabled: true + command: "writeAttribute" + attribute: "Extension" + arguments: + value: [{ Data: D_BAD_UNDERFLOW, FabricIndex: CurrentFabricIndex }] + response: + error: CONSTRAINT_ERROR - label: "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of AccessControlExtensionStruct containing 1 element 1.struct Data field: D_BAD_NONE" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol write extension '[{"data":""}]' 1 0 - - On TH1(Chiptool) , Verify that the status is CONSTRAINT_ERROR (0x87) when writing the AccessControl cluster Extension attribute - - - [1657609694.046042][8236:8241] CHIP:DMG: - [1657609694.046078][8236:8241] CHIP:DMG: StatusIB = - [1657609694.046115][8236:8241] CHIP:DMG: { - [1657609694.046154][8236:8241] CHIP:DMG: status = 0x87 (CONSTRAINT_ERROR), - [1657609694.046192][8236:8241] CHIP:DMG: }, - [1657609694.046229][8236:8241] CHIP:DMG: - [1657609694.046260][8236:8241] CHIP:DMG: }, - [1657609694.046296][8236:8241] CHIP:DMG: - [1657609694.046325][8236:8241] CHIP:DMG: ], - [1657609694.046390][8236:8241] CHIP:DMG: - [1657609694.046423][8236:8241] CHIP:DMG: InteractionModelRevision = 1 - [1657609694.046452][8236:8241] CHIP:DMG: } - [1657609694.046574][8236:8241] CHIP:DMG: WriteClient moving to [AwaitingDe] - [1657609694.046614][8236:8241] CHIP:TOO: Response Failure: IM Error 0x00000587: General error: 0x87 (CONSTRAINT_ERROR) - disabled: true + command: "writeAttribute" + attribute: "Extension" + arguments: + value: [{ Data: D_BAD_NONE, FabricIndex: CurrentFabricIndex }] + response: + error: CONSTRAINT_ERROR - label: "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, @@ -616,123 +232,38 @@ tests: contains Data field: D_OK_SINGLE 17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol write extension '[{"data":"1718"},{"data":"17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320612063686172737472696E670018"}]' 1 0 - - On TH1(Chiptool) , Verify that the status is success for first element and CONSTRAINT_ERROR (0x87) for second element when writing the AccessControl cluster Extension attribute - - [1657609694.044950][8236:8241] CHIP:DMG: WriteResponseMessage = - [1657609694.044980][8236:8241] CHIP:DMG: { - [1657609694.045008][8236:8241] CHIP:DMG: AttributeStatusIBs = - [1657609694.045049][8236:8241] CHIP:DMG: [ - [1657609694.045080][8236:8241] CHIP:DMG: AttributeStatusIB = - [1657609694.045117][8236:8241] CHIP:DMG: { - [1657609694.045149][8236:8241] CHIP:DMG: AttributePathIB = - [1657609694.045187][8236:8241] CHIP:DMG: { - [1657609694.045232][8236:8241] CHIP:DMG: Endpoint = 0x0, - [1657609694.045277][8236:8241] CHIP:DMG: Cluster = 0x1f, - [1657609694.045318][8236:8241] CHIP:DMG: Attribute = 0x0000_0001, - [1657609694.045355][8236:8241] CHIP:DMG: } - [1657609694.045397][8236:8241] CHIP:DMG: - [1657609694.045434][8236:8241] CHIP:DMG: StatusIB = - [1657609694.045472][8236:8241] CHIP:DMG: { - [1657609694.045513][8236:8241] CHIP:DMG: status = 0x00 (SUCCESS), - [1657609694.045552][8236:8241] CHIP:DMG: }, - [1657609694.045594][8236:8241] CHIP:DMG: - [1657609694.045627][8236:8241] CHIP:DMG: }, - [1657609694.045670][8236:8241] CHIP:DMG: - [1657609694.045701][8236:8241] CHIP:DMG: AttributeStatusIB = - [1657609694.045733][8236:8241] CHIP:DMG: { - [1657609694.045765][8236:8241] CHIP:DMG: AttributePathIB = - [1657609694.045801][8236:8241] CHIP:DMG: { - [1657609694.045840][8236:8241] CHIP:DMG: Endpoint = 0x0, - [1657609694.045880][8236:8241] CHIP:DMG: Cluster = 0x1f, - [1657609694.045922][8236:8241] CHIP:DMG: Attribute = 0x0000_0001, - [1657609694.045962][8236:8241] CHIP:DMG: ListIndex = Null, - [1657609694.046000][8236:8241] CHIP:DMG: } - [1657279798.809590][9208:9213] CHIP:DMG: - [1657279798.809629][9208:9213] CHIP:DMG: StatusIB = - [1657279798.809666][9208:9213] CHIP:DMG: { - [1657279798.809702][9208:9213] CHIP:DMG: status = 0x87 (CONSTRAINT_ERROR), - [1657279798.809740][9208:9213] CHIP:DMG: }, - [1657279798.809778][9208:9213] CHIP:DMG: - [1657279798.809808][9208:9213] CHIP:DMG: }, - [1657279798.809843][9208:9213] CHIP:DMG: - [1657279798.809873][9208:9213] CHIP:DMG: ], - [1657279798.809917][9208:9213] CHIP:DMG: - [1657279798.809946][9208:9213] CHIP:DMG: InteractionModelRevision = 1 - [1657279798.809974][9208:9213] CHIP:DMG: } - [1657279798.810132][9208:9213] CHIP:DMG: WriteClient moving to [AwaitingDe] - [1657279798.810171][9208:9213] CHIP:TOO: Response Failure: IM Error 0x00000587: General error: 0x87 (CONSTRAINT_ERROR) - [1657279798.810454][9208:9213] CHIP:EM: Sending Standalone Ack for MessageCounter:192339176 on exchange 15705i - disabled: true + command: "writeAttribute" + attribute: "Extension" + arguments: + value: + [ + { Data: D_OK_EMPTY, FabricIndex: CurrentFabricIndex }, + { Data: D_OK_SINGLE, FabricIndex: CurrentFabricIndex }, + ] + response: + error: CONSTRAINT_ERROR - label: "TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol read extension 1 0 - - On TH1(Chiptool) , Verify Successfully the list of AccessControlExtensionStruct containing Data field: D_OK_EMPTY :"1718" and - FabricIndex field: F1. - - - [1657279968.698117][9221:9226] CHIP:DMG: - [1657279968.698149][9221:9226] CHIP:DMG: SuppressResponse = true, - [1657279968.698193][9221:9226] CHIP:DMG: InteractionModelRevision = 1 - [1657279968.698224][9221:9226] CHIP:DMG: } - [1657279968.698540][9221:9226] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_001F Attribute 0x0000_0001 DataVersion: 525362718 - [1657279968.698608][9221:9226] CHIP:TOO: Extension: 1 entries - [1657279968.698668][9221:9226] CHIP:TOO: [1]: { - [1657279968.698715][9221:9226] CHIP:TOO: Data: 1718 - [1657279968.698761][9221:9226] CHIP:TOO: FabricIndex: 1 - [1657279968.698804][9221:9226] CHIP:TOO: } - [1657279968.698905][9221:9226] CHIP:EM: Sending Standalone Ack for MessageCounter:261322624 on exchange 15524i - disabled: true + command: "readAttribute" + attribute: "Extension" + response: + value: [{ Data: D_OK_EMPTY, FabricIndex: CurrentFabricIndex }] - label: "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is an empty list" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol write extension '[]' 1 0 - - On TH1(Chiptool) , Verify that the status is success when writing the AccessControl cluster Extension attribute - - 7625][1521:1526] CHIP:DMG: AttributeStatusIB = - [1657692723.227673][1521:1526] CHIP:DMG: { - [1657692723.227725][1521:1526] CHIP:DMG: AttributePathIB = - [1657692723.227780][1521:1526] CHIP:DMG: { - [1657692723.227834][1521:1526] CHIP:DMG: Endpoint = 0x0, - [1657692723.227897][1521:1526] CHIP:DMG: Cluster = 0x1f, - [1657692723.227956][1521:1526] CHIP:DMG: Attribute = 0x0000_0001, - [1657692723.228012][1521:1526] CHIP:DMG: } - [1657692723.228073][1521:1526] CHIP:DMG: - [1657692723.228125][1521:1526] CHIP:DMG: StatusIB = - [1657692723.228182][1521:1526] CHIP:DMG: { - [1657692723.228238][1521:1526] CHIP:DMG: status = 0x00 (SUCCESS), - [1657692723.228294][1521:1526] CHIP:DMG: }, - [1657692723.228349][1521:1526] CHIP:DMG: - [1657692723.228397][1521:1526] CHIP:DMG: }, - [1657692723.228449][1521:1526] CHIP:DMG: - [1657692723.228492][1521:1526] CHIP:DMG: ], - [1657692723.228551][1521:1526] CHIP:DMG: - [1657692723.228582][1521:1526] CHIP:DMG: InteractionModelRevision = 1 - [1657692723.228608][1521:1526] CHIP:DMG: } - [1657692723.228738][1521:1526] CHIP:DMG: WriteClient moving to [AwaitingDe] - [1657692723.228802][1521:1526] CHIP:EM: Sending Standalone Ack for MessageCounter:57305662 on exchange 27543i - [1657692723.228869][1521:1526] CHIP:IN: Prepared secure message 0xffff9fffd9d8 to 0x0000000000000001 (1) of type 0x10 and protocolId (0, 0) on exchange 27543i with MessageCounter:9219504. - [1657692723.228909][1521:1526] - disabled: true + command: "writeAttribute" + attribute: "Extension" + arguments: + value: [] - label: "TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute" PICS: ACL.S.A0001 - verification: | - ./chip-tool accesscontrol read extension 1 0 - - On TH1(Chiptool) , Verify AccessControl cluster Extension attribute, value is an empty list - - [1660223145.427219][80697:80702] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_001F Attribute 0x0000_0001 DataVersion: 2385810240 - [1660223145.427227][80697:80702] CHIP:TOO: Extension: 0 entries - disabled: true + command: "readAttribute" + attribute: "Extension" + response: + value: [] diff --git a/src/app/tests/suites/certification/Test_TC_ALOGIN_12_1.yaml b/src/app/tests/suites/certification/Test_TC_ALOGIN_12_1.yaml index a00d3e2b34d7d6..a480adf18fcb4e 100644 --- a/src/app/tests/suites/certification/Test_TC_ALOGIN_12_1.yaml +++ b/src/app/tests/suites/certification/Test_TC_ALOGIN_12_1.yaml @@ -20,74 +20,77 @@ PICS: config: nodeId: 0x12344321 - cluster: "Basic" - endpoint: 0 + cluster: "Account Login" + endpoint: 3 + TempAccountIdentifier: + type: char_string + defaultValue: "1111" + catalogVendorId: + type: int16u + defaultValue: 123 + applicationId: + type: char_string + defaultValue: "exampleid" tests: - - label: "Precondition" - verification: | - Test Setup: Commission DUT to TH, if not done so already. In some cases, such as with a Casting Video Player, the DUT commissions the TH (eg. tv-casting-app). - disabled: true + - label: "Wait for the commissioned device to be retrieved" + cluster: "DelayCommands" + command: "WaitForCommissionee" + arguments: + values: + - name: "nodeId" + value: nodeId - - label: - "Make sure there is a Content App endpoint implementing the Account - Login cluster. Product maker may provide pre-setup steps" - verification: | - The TH commands for this test step can be invoked using chip-tool (when DUT is a commissionee) or tv-casting-app (when DUT is a commissioner). - - The following command on the example tv-app will launch a content app on endpoint 4: - ./chip-tool applicationlauncher launch-app "{"catalogVendorId": 123, "applicationId": "exampleid"}" 1 1 - ./chip-tv-casting-app applicationlauncher launch-app "{"catalogVendorId": 123, "applicationId": "exampleid"}" 1 1 - - Verify in TH Log: - [1654004240716] [9799:7814889] CHIP: [DMG] Received Command Response Data, Endpoint=1 Cluster=0x0000_050C Command=0x0000_0003 - [1654004240717] [9799:7814889] CHIP: [TOO] Endpoint: 1 Cluster: 0x0000_050C Command 0x0000_0003 - [1654004240717] [9799:7814889] CHIP: [TOO] LauncherResponse: { - [1654004240717] [9799:7814889] CHIP: [TOO] status: 0 - [1654004240717] [9799:7814889] CHIP: [TOO] data: 64617461 - [1654004240717] [9799:7814889] CHIP: [TOO] } - disabled: true + - label: "Launch an app with the provided a application ID" + PICS: APPLAUNCHER.S.C00.Rsp + cluster: "Application Launcher" + command: "LaunchApp" + arguments: + values: + - name: "Data" + value: "Hello World" + - name: "application" + value: + { + catalogVendorId: catalogVendorId, + applicationId: applicationId, + } + response: + values: + - name: "status" + value: 0 - label: "TH sends a GetSetupPIN command to the DUT with test values provided by the product maker." PICS: ALOGIN.S.C00.Rsp - verification: | - The TH commands for this test step can be invoked using chip-tool (when DUT is a commissionee) or tv-casting-app (when DUT is a commissioner): - ./chip-tool accountlogin get-setup-pin 1111 1 4 --timedInteractionTimeoutMs 1000 - ./chip-tv-casting-app accountlogin get-setup-pin 1111 1 4 --timedInteractionTimeoutMs 1000 - - On TH Verify that the DUT responds with a valid GetSetupPINResponse. - [1654004273684] [9851:7821178] CHIP: [DMG] Received Command Response Data, Endpoint=4 Cluster=0x0000_050E Command=0x0000_0001 - [1654004273684] [9851:7821178] CHIP: [TOO] Endpoint: 6 Cluster: 0x0000_050E Command 0x0000_0001 - [1654004273684] [9851:7821178] CHIP: [TOO] GetSetupPINResponse: { - [1654004273684] [9851:7821178] CHIP: [TOO] setupPIN: 34567890 - [1654004273684] [9851:7821178] CHIP: [TOO] } - disabled: true + command: "GetSetupPIN" + timedInteractionTimeoutMs: 10000 + arguments: + values: + - name: "TempAccountIdentifier" + value: TempAccountIdentifier + response: + values: + - name: "setupPIN" + saveAs: setupPIN - label: "TH sends a Login command to the DUT with test values provided by the product maker." PICS: ALOGIN.S.C02.Rsp - verification: | - The TH commands for this test step can be invoked using chip-tool (when DUT is a commissionee) or tv-casting-app (when DUT is a commissioner): - ./chip-tool accountlogin login 11111 34567890 1 4 --timedInteractionTimeoutMs 1000 - ./chip-tv-casting-app accountlogin login 11111 34567890 1 4 --timedInteractionTimeoutMs 1000 - - On TH Verify that the DUT responds with a standard command response. - [1654004350009] [9951:7836487] CHIP: [DMG] Received Command Response Status for Endpoint=4 Cluster=0x0000_050E Command=0x0000_0002 Status=0x0 - disabled: true + command: "Login" + timedInteractionTimeoutMs: 10000 + arguments: + values: + - name: "tempAccountIdentifier" + value: TempAccountIdentifier + - name: "setupPIN" + value: setupPIN - label: "TH sends a Logout command to the DUT with test values provided by the product maker." PICS: ALOGIN.S.C03.Rsp - verification: | - The TH commands for this test step can be invoked using chip-tool (when DUT is a commissionee) or tv-casting-app (when DUT is a commissioner): - ./chip-tool accountlogin logout 1 4 --timedInteractionTimeoutMs 1000 - ./chip-tv-casting-app accountlogin logout 1 4 --timedInteractionTimeoutMs 1000 - - On TH Verify that the DUT responds with a standard command response. - - [1654004400892] [9988:7841997] CHIP: [DMG] Received Command Response Status for Endpoint=4 Cluster=0x0000_050E Command=0x0000_0003 Status=0x0 - disabled: true + command: "Logout" + timedInteractionTimeoutMs: 10000 diff --git a/src/app/tests/suites/certification/Test_TC_BRBINFO_1_1.yaml b/src/app/tests/suites/certification/Test_TC_BRBINFO_1_1.yaml index f4eebc4d1089df..44705b9932bdc0 100644 --- a/src/app/tests/suites/certification/Test_TC_BRBINFO_1_1.yaml +++ b/src/app/tests/suites/certification/Test_TC_BRBINFO_1_1.yaml @@ -14,96 +14,202 @@ # Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default name: - 3.1.1. [TC-BRBINFO-1.1] Global Attributes for Bridged Device Basic + 130.1.1. [TC-BRBINFO-1.1] Global Attributes for Bridged Device Basic Information Cluster Cluster [DUT-Server] config: nodeId: 0x12344321 - cluster: "Basic" - endpoint: 0 + cluster: "Bridged Device Basic" + endpoint: 3 tests: - - label: "" - verification: | - Validate these PICS items of attributes which are not allowed in this server cluster implementation - these PICS items should all be FALSE, if any of them is TRUE then FAIL the test - - BRBINFO.S.A0000(DataModelRevision) - - BRBINFO.S.A0004(ProductID) - - BRBINFO.S.A0006(Location) - - BRBINFO.S.A0010(LocalConfigDisabled) - - BRBINFO.S.A0013(CapabilityMinima) - disabled: true - - - label: "Commission DUT to TH (if not already done)" - verification: | - - disabled: true + - label: "Wait for the commissioned device to be retrieved" + cluster: "DelayCommands" + command: "WaitForCommissionee" + arguments: + values: + - name: "nodeId" + value: nodeId - label: "TH reads the ClusterRevision from DUT" - verification: | - ./chip-tool bridgeddevicebasic read cluster-revision 1 3 - - On TH(chip-tool), verify DUT responsds ClusterRevision attribute has value 1 - - [1657695910.794487][15411:15416] CHIP:TOO: Endpoint: 3 Cluster: 0x0000_0039 Attribute 0x0000_FFFD DataVersion: 2577979325 - [1657695910.794568][15411:15416] CHIP:TOO: ClusterRevision: 1 - disabled: true + command: "readAttribute" + attribute: "ClusterRevision" + response: + value: 1 + constraints: + type: int16u - label: "TH reads the FeatureMap from DUT" - verification: | - ./chip-tool bridgeddevicebasic read feature-map 1 3 - - On TH(chip-tool), verify at DUT responds Featuremap value as 0 - - [1658749277.166884][10254:10259] CHIP:TOO: Endpoint: 3 Cluster: 0x0000_0039 Attribute 0x0000_FFFC DataVersion: 3297319126 - [1658749277.166945][10254:10259] CHIP:TOO: FeatureMap: 0 - [1658749277.167033][10254:10259] CHIP:EM: Sending Standalone Ack for MessageCounter:190389852 on exchange 39565i - disabled: true + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 0 + constraints: + type: bitmap32 - label: "TH reads AttributeList from DUT" - verification: | - ./chip-tool bridgeddevicebasic read attribute-list 1 3 - - On TH(chip-tool), verify TH(chip-tool)at DUT responds as list of supported attributes as entries matching TH(chip-tool)e PICS items (see column F) - - [1658833518.065647][9014:9019] CHIP:TOO: Endpoint: 3 Cluster: 0x0000_0039 Attribute 0x0000_FFFB DataVersion: 270848876 - [1658833518.065723][9014:9019] CHIP:TOO: AttributeList: 7 entries - [1658833518.065773][9014:9019] CHIP:TOO: [1]: 5 - [1658833518.065804][9014:9019] CHIP:TOO: [2]: 17 - [1658833518.065833][9014:9019] CHIP:TOO: [3]: 65528 - [1658833518.065862][9014:9019] CHIP:TOO: [4]: 65529 - [1658833518.065891][9014:9019] CHIP:TOO: [5]: 65531 - [1658833518.065919][9014:9019] CHIP:TOO: [6]: 65532 - [1658833518.065949][9014:9019] CHIP:TOO: [7]: 65533 - disabled: true - - - label: "TH reads EventList from DUT" - verification: | - NEED SDK Implementation - - Out of scope for V1 - disabled: true - - - label: "TH reads AcceptedCommandList from DUT" - verification: | - ./chip-tool bridgeddevicebasic read accepted-command-list 1 3 - - On TH(chip-tool), verify DUT responds as list of Accepted Commands as 0 entries - - [1657696300.165081][15447:15452] CHIP:TOO: Endpoint: 3 Cluster: 0x0000_0039 Attribute 0x0000_FFF9 DataVersion: 2577979325 - [1657696300.165174][15447:15452] CHIP:TOO: AcceptedCommandList: 0 entries - disabled: true - - - label: "TH reads GeneratedCommandList from DUT" - verification: | - ./chip-tool bridgeddevicebasic read generated-command-list 1 3 - - On TH(chip-tool), verify that DUT responds as list of GeneratedCommands as 0 entries - - [1657696328.889936][15454:15459] CHIP:TOO: Endpoint: 3 Cluster: 0x0000_0039 Attribute 0x0000_FFF8 DataVersion: 2577979325 - [1657696328.890017][15454:15459] CHIP:TOO: GeneratedCommandList: 0 entries - disabled: true + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [17, 65528, 65529, 65531, 65532, 65533] + + - label: "TH reads optional attribute(VendorName) in AttributeList" + PICS: BRBINFO.S.A0001 + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [1] + + - label: "TH reads optional attribute(VendorID) in AttributeList" + PICS: BRBINFO.S.A0002 + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [2] + + - label: "TH reads optional attribute(ProductName) in AttributeList" + PICS: BRBINFO.S.A0003 + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [3] + + - label: "TH reads optional attribute(NodeLabel) in AttributeList" + PICS: BRBINFO.S.A0005 + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [5] + + - label: "TH reads optional attribute(HardwareVersion) in AttributeList" + PICS: BRBINFO.S.A0007 + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [7] + + - label: + "TH reads optional attribute(HardwareVersionString) in AttributeList" + PICS: BRBINFO.S.A0008 + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [8] + + - label: "TH reads optional attribute(SoftwareVersion) in AttributeList" + PICS: BRBINFO.S.A0009 + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [9] + + - label: + "TH reads optional attribute(SoftwareVersionString) in AttributeList" + PICS: BRBINFO.S.A000a + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [10] + + - label: "TH reads optional attribute(ManufacturingDate) in AttributeList" + PICS: BRBINFO.S.A000b + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [11] + + - label: "TH reads optional attribute(PartNumber) in AttributeList" + PICS: BRBINFO.S.A000c + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [12] + + - label: "TH reads optional attribute(ProductURL) in AttributeList" + PICS: BRBINFO.S.A000d + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [13] + + - label: "TH reads optional attribute(ProductLabel) in AttributeList" + PICS: BRBINFO.S.A000e + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [14] + + - label: "TH reads optional attribute(SerialNumber) in AttributeList" + PICS: BRBINFO.S.A000f + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [15] + + - label: "TH reads optional attribute(UniqueID) in AttributeList" + PICS: BRBINFO.S.A0012 + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [18] + + - label: "TH1 reads AcceptedCommandList from DUT" + command: "readAttribute" + attribute: "AcceptedCommandList" + response: + value: [] + constraints: + type: list + + - label: "TH1 reads GeneratedCommandList from DUT" + command: "readAttribute" + attribute: "GeneratedCommandList" + response: + value: [] + constraints: + type: list + #Commenting out the step EventList attribute which is out of scope for matter V1.0 + #- label: + # "Read EventList attribute from the DUT and Verify that the DUT + # response provides a list of supported events." + # verification: | + # Not implemented in chip-tool + # cluster: "LogCommands" + # command: "UserPrompt" + # PICS: PICS_USER_PROMPT + # arguments: + # values: + # - name: "message" + # value: "Please enter 'y' for success" + # - name: "expectedValue" + # value: "y" diff --git a/src/app/tests/suites/certification/Test_TC_BRBINFO_2_1.yaml b/src/app/tests/suites/certification/Test_TC_BRBINFO_2_1.yaml index 81ca10425f3bd0..6592da0b8d116b 100644 --- a/src/app/tests/suites/certification/Test_TC_BRBINFO_2_1.yaml +++ b/src/app/tests/suites/certification/Test_TC_BRBINFO_2_1.yaml @@ -13,127 +13,128 @@ # limitations under the License. # Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default -name: 3.2.1. [TC-BRBINFO-2.1] Attributes [DUT-Server] +name: 130.2.1. [TC-BRBINFO-2.1] Attributes [DUT-Server] config: nodeId: 0x12344321 - cluster: "Basic" - endpoint: 0 + cluster: "Bridged Device Basic" + endpoint: 3 tests: + - label: "Wait for the commissioned device to be retrieved" + cluster: "DelayCommands" + command: "WaitForCommissionee" + arguments: + values: + - name: "nodeId" + value: nodeId + - label: "TH reads VendorName from the DUT." PICS: BRBINFO.S.A0001 - verification: | - ./chip-tool bridgeddevicebasic read vendor-name 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656495199.434300][2158:2163] CHIP:TOO: VendorName: TEST_VENDOR - disabled: true - - - label: "TH writes VendorName as sample" + command: "readAttribute" + attribute: "VendorName" + response: + saveAs: VendorNameValue + constraints: + type: char_string + maxLength: 32 + + - label: "TH writes VendorName from the DUT." PICS: BRBINFO.S.A0001 - verification: | - ./chip-tool bridgeddevicebasic write vendor-name sample 1 3 + command: "writeAttribute" + attribute: "VendorName" + arguments: + value: "sample" + response: + error: UNSUPPORTED_WRITE - Verify response has unsupported write on TH(chip-tool) Log: - - [1656495259.991989][2164:2169] CHIP:TOO: Response Failure: IM Error 0x00000588: General error: 0x88 (UNSUPPORTED_WRITE) - disabled: true - - - label: "TH reads VendorName" + - label: "TH reads VendorName from the DUT." PICS: BRBINFO.S.A0001 - verification: | - ./chip-tool bridgeddevicebasic read vendor-name 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656495199.434300][2158:2163] CHIP:TOO: VendorName: TEST_VENDOR - disabled: true + command: "readAttribute" + attribute: "VendorName" + response: + value: VendorNameValue - label: "TH reads VendorID from the DUT." PICS: BRBINFO.S.A0002 - verification: | - ./chip-tool bridgeddevicebasic read vendor-id 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE + command: "readAttribute" + attribute: "VendorID" + response: + saveAs: VendorIDValue + constraints: + type: vendor_id + minValue: 1 + maxValue: 65521 - Example Log: - [1656495322.252171][2177:2182] CHIP:TOO: VendorID: 65521 - disabled: true - - - label: "TH writes VendorID as 0x0011" + - label: + "Verify that VendorID matches the value assigned to this manufacturer" + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT && BRBINFO.S.A0002 + arguments: + values: + - name: "message" + value: "Please enter 'y' for success" + - name: "expectedValue" + value: "y" + + - label: "TH writes VendorID from the DUT." PICS: BRBINFO.S.A0002 - verification: | - ./chip-tool bridgeddevicebasic write vendor-name 0x0011 1 3 + command: "writeAttribute" + attribute: "VendorID" + arguments: + value: 0x0011 + response: + error: UNSUPPORTED_WRITE - Verify response has unsupported write on TH(chip-tool) Log: - - [1656495259.991989][2164:2169] CHIP:TOO: Response Failure: IM Error 0x00000588: General error: 0x88 (UNSUPPORTED_WRITE) - disabled: true - - - label: "TH reads VendorID" + - label: "TH reads VendorID from the DUT." PICS: BRBINFO.S.A0002 - verification: | - ./chip-tool bridgeddevicebasic read vendor-id 1 3 + command: "readAttribute" + attribute: "VendorID" + response: + value: VendorIDValue - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656495322.252171][2177:2182] CHIP:TOO: VendorID: 65521 - disabled: true - - - label: "TH reads ProductName from the DUT." + - label: "TH reads ProductName from the DUT" PICS: BRBINFO.S.A0003 - verification: | - ./chip-tool bridgeddevicebasic read product-name 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656495708.412745][2200:2205] CHIP:TOO: ProductName: TEST_PRODUCT - disabled: true - - - label: "TH writes ProductName as newproduct" + command: "readAttribute" + attribute: "ProductName" + response: + saveAs: ProductNameValue + constraints: + type: char_string + maxLength: 32 + + - label: "TH writes ProductName from the DUT." PICS: BRBINFO.S.A0003 - verification: | - ./chip-tool bridgeddevicebasic write vendor-name ""newproduct"" 1 3 - - Verify response has unsupported write on TH(chip-tool) Log: - - NOTE the quotes: single-quote/double-quote/string/double-quote/single-quote - [1656495259.991989][2164:2169] CHIP:TOO: Response Failure: IM Error 0x00000588: General error: 0x88 (UNSUPPORTED_WRITE) - disabled: true - - - label: "TH reads ProductName" + command: "writeAttribute" + attribute: "ProductName" + arguments: + value: "newproduct" + response: + error: UNSUPPORTED_WRITE + + - label: "TH reads ProductName from the DUT" PICS: BRBINFO.S.A0003 - verification: | - ./chip-tool bridgeddevicebasic read product-name 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656495708.412745][2200:2205] CHIP:TOO: ProductName: TEST_PRODUCT - disabled: true + command: "readAttribute" + attribute: "ProductName" + response: + value: ProductNameValue - label: "TH reads NodeLabel from the DUT" PICS: BRBINFO.S.A0005 - verification: | - ./chip-tool bridgeddevicebasic read node-label 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE + command: "readAttribute" + attribute: "NodeLabel" + response: + saveAs: NodeLabelValue + constraints: + type: char_string + maxLength: 32 - Example Log: - [1657696463.081741][15476:15481] CHIP:TOO: Endpoint: 3 Cluster: 0x0000_0039 Attribute 0x0000_0005 DataVersion: 2577979325 - [1657696463.081791][15476:15481] CHIP:TOO: NodeLabel: Light 1 - disabled: true - - - label: "TH writes newnode to NodeLabel" - PICS: BRBINFO.S.A0005 + #Issue https://github.com/project-chip/connectedhomeip/issues/23509 + - label: "TH writes NodeLabel from the DUT." + PICS: BRBINFO.S.A0005 && PICS_USER_PROMPT verification: | - ./chip-tool bridgeddevicebasic write node-label ""newnode"" 1 3 + ./chip-tool bridgeddevicebasic write node-label '"newnode"' 1 3 Verify response has unsupported write on TH(chip-tool) Log: @@ -148,10 +149,17 @@ tests: [1660839701.840827][2444:2449] CHIP:DMG: }, [1660839701.840905][2444:2449] CHIP:DMG: [1660839701.840973][2444:2449] CHIP:DMG: }, - disabled: true + cluster: "LogCommands" + command: "UserPrompt" + arguments: + values: + - name: "message" + value: "Please enter 'y' after success" + - name: "expectedValue" + value: "y" - - label: "TH reads NodeLabel" - PICS: BRBINFO.S.A0005 + - label: "TH reads NodeLabel from the DUT" + PICS: BRBINFO.S.A0005 && PICS_USER_PROMPT verification: | ./chip-tool bridgeddevicebasic read node-label 1 3 @@ -159,370 +167,342 @@ tests: [1657696463.081741][15476:15481] CHIP:TOO: Endpoint: 3 Cluster: 0x0000_0039 Attribute 0x0000_0005 DataVersion: 2577979325 [1657696463.081791][15476:15481] CHIP:TOO: NodeLabel: newnode - disabled: true - - - label: "TH reads HardwareVersion from the DUT." + cluster: "LogCommands" + command: "UserPrompt" + arguments: + values: + - name: "message" + value: "Please enter 'y' after success" + - name: "expectedValue" + value: "y" + + - label: "TH reads HardwareVersion from the DUT" PICS: BRBINFO.S.A0007 - verification: | - ./chip-tool bridgeddevicebasic read hardware-version 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656496175.564718][2302:2307] CHIP:TOO: HardwareVersion: 0 - disabled: true - - - label: "TH writes HardwareVersion as 0x4531" + command: "readAttribute" + attribute: "HardwareVersion" + response: + saveAs: HardwareVersionValue + constraints: + type: int16u + minValue: 0 + maxValue: 65534 + + - label: "TH writes HardwareVersion from the DUT." PICS: BRBINFO.S.A0007 - verification: | - ./chip-tool bridgeddevicebasic write hardware-version-string 0x4531 1 3 - - Verify response has unsupported write on TH(chip-tool) Log: - - [1656495259.991989][2164:2169] CHIP:TOO: Response Failure: IM Error 0x00000588: General error: 0x88 (UNSUPPORTED_WRITE) - disabled: true - - - label: "TH reads HardwareVersion" + command: "writeAttribute" + attribute: "HardwareVersion" + arguments: + value: 0x4531 + response: + error: UNSUPPORTED_WRITE + + - label: "TH reads HardwareVersion from the DUT" PICS: BRBINFO.S.A0007 - verification: | - ./chip-tool bridgeddevicebasic write hardware-version-string 0x4531 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656496175.564718][2302:2307] CHIP:TOO: HardwareVersion: 0 - disabled: true + command: "readAttribute" + attribute: "HardwareVersion" + response: + value: HardwareVersionValue - label: "TH reads HardwareVersionString from the DUT." PICS: BRBINFO.S.A0008 - verification: | - ./chip-tool bridgeddevicebasic read hardware-version-string 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656496257.298675][2315:2320] CHIP:TOO: HardwareVersionString: TEST_VERSION - disabled: true - - - label: "TH writes HardwareVersionString as newhardwareversion" + command: "readAttribute" + attribute: "HardwareVersionString" + response: + saveAs: HardwareVersionStringValue + constraints: + type: char_string + minLength: 1 + maxLength: 64 + + - label: "TH writes HardwareVersionString from the DUT." PICS: BRBINFO.S.A0008 - verification: | - ./chip-tool bridgeddevicebasic write hardware-version-string newhardwareversion 1 3 + command: "writeAttribute" + attribute: "HardwareVersionString" + arguments: + value: "newhardwareversion" + response: + error: UNSUPPORTED_WRITE - Verify response has unsupported write on TH(chip-tool) Log: - - [1656495259.991989][2164:2169] CHIP:TOO: Response Failure: IM Error 0x00000588: General error: 0x88 (UNSUPPORTED_WRITE) - disabled: true - - - label: "TH reads HardwareVersionString" + - label: "TH reads HardwareVersionString from the DUT." PICS: BRBINFO.S.A0008 - verification: | - ./chip-tool bridgeddevicebasic read hardware-version-string 1 3 + command: "readAttribute" + attribute: "HardwareVersionString" + response: + value: HardwareVersionStringValue - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656496257.298675][2315:2320] CHIP:TOO: HardwareVersionString: TEST_VERSION - disabled: true - - - label: "TH reads SoftwareVersion from the DUT." + - label: "TH reads SoftwareVersion from the DUT" PICS: BRBINFO.S.A0009 - verification: | - ./chip-tool bridgeddevicebasic read software-version 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656496411.609866][2348:2353] CHIP:TOO: SoftwareVersion: 1 - disabled: true - - - label: "TH writes SoftwareVersion as 0x8213" + command: "readAttribute" + attribute: "SoftwareVersion" + response: + saveAs: SoftwareVersionValue + constraints: + minValue: 0 + maxValue: 4294967294 + + - label: "TH writes SoftwareVersion from the DUT." PICS: BRBINFO.S.A0009 - verification: | - ./chip-tool bridgeddevicebasic write software-version 0x8213 1 3 - - Verify response has unsupported write on TH(chip-tool) Log: - - [1656495259.991989][2164:2169] CHIP:TOO: Response Failure: IM Error 0x00000588: General error: 0x88 (UNSUPPORTED_WRITE) - disabled: true - - - label: "TH reads SoftwareVersion" + command: "writeAttribute" + attribute: "SoftwareVersion" + arguments: + value: 0x8213 + response: + error: UNSUPPORTED_WRITE + + - label: "TH reads SoftwareVersion from the DUT" PICS: BRBINFO.S.A0009 - verification: | - ./chip-tool bridgeddevicebasic read software-version 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656496411.609866][2348:2353] CHIP:TOO: SoftwareVersion: 1 - disabled: true + command: "readAttribute" + attribute: "SoftwareVersion" + response: + value: SoftwareVersionValue - - label: "TH reads SoftwareVersionString from the DUT." + - label: "TH reads SoftwareVersionString from the DUT" PICS: BRBINFO.S.A000a - verification: | - ./chip-tool bridgeddevicebasic read software-version-string 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656496498.568951][2362:2367] CHIP:TOO: SoftwareVersionString: 1.0 - disabled: true - - - label: "TH writes SoftwareVersionString as 1.0" + command: "readAttribute" + attribute: "SoftwareVersionString" + response: + saveAs: SoftwareVersionStringValue + constraints: + minLength: 1 + maxLength: 64 + + - label: "TH writes SoftwareVersionString from the DUT." PICS: BRBINFO.S.A000a - verification: | - ./chip-tool bridgeddevicebasic write software-version 1.0 1 3 - - Verify response has unsupported write on TH(chip-tool) Log: - - - [1656495259.991989][2164:2169] CHIP:TOO: Response Failure: IM Error 0x00000588: General error: 0x88 (UNSUPPORTED_WRITE) - disabled: true - - - label: "TH reads SoftwareVersionString" + command: "writeAttribute" + attribute: "SoftwareVersionString" + arguments: + value: "1.0" + response: + error: UNSUPPORTED_WRITE + + - label: "TH reads SoftwareVersionString from the DUT" PICS: BRBINFO.S.A000a - verification: | - ./chip-tool bridgeddevicebasic read software-version-string 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656496498.568951][2362:2367] CHIP:TOO: SoftwareVersionString: 1.0 - disabled: true + command: "readAttribute" + attribute: "SoftwareVersionString" + response: + value: SoftwareVersionStringValue - label: "TH reads ManufacturingDate from the DUT." PICS: BRBINFO.S.A000b - verification: | - ./chip-tool bridgeddevicebasic read manufacturing-date 1 3 + command: "readAttribute" + attribute: "ManufacturingDate" + response: + saveAs: ManufacturingDateValue + constraints: + type: char_string + minLength: 8 + maxLength: 16 - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656496661.777852][2388:2393] CHIP:TOO: ManufacturingDate: 20200101 - disabled: true - - - label: "TH writes ManufacturingDate as 20210814789452IN" + - label: + "Verify if the first 8 characters specify date according to ISO 8601, + i.e, YYYYMMDD." + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT && BRBINFO.S.A000b + arguments: + values: + - name: "message" + value: "Please enter 'y' for success" + - name: "expectedValue" + value: "y" + + - label: "TH writes ManufacturingDate from the DUT." PICS: BRBINFO.S.A000b - verification: | - ./chip-tool bridgeddevicebasic write manufacturing-date 20210814789452IN 1 3 - - Verify response has unsupported write on TH(chip-tool) Log: + command: "writeAttribute" + attribute: "ManufacturingDate" + arguments: + value: "20210814789452IN" + response: + error: UNSUPPORTED_WRITE - [1656495259.991989][2164:2169] CHIP:TOO: Response Failure: IM Error 0x00000588: General error: 0x88 (UNSUPPORTED_WRITE) - disabled: true - - - label: "TH reads ManufacturingDate" + - label: "TH reads ManufacturingDate from the DUT." PICS: BRBINFO.S.A000b - verification: | - ./chip-tool bridgeddevicebasic read manufacturing-date 1 3 + command: "readAttribute" + attribute: "ManufacturingDate" + response: + value: ManufacturingDateValue - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656496661.777852][2388:2393] CHIP:TOO: ManufacturingDate: 20200101 - disabled: true - - - label: "TH reads PartNumber from the DUT." + - label: "TH reads PartNumber from the DUT" PICS: BRBINFO.S.A000c - verification: | - ./chip-tool bridgeddevicebasic read part-number 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - - [1656496800.941788][2405:2410] CHIP:TOO: PartNumber: 1234 - disabled: true - - - label: "TH writes PartNumber as newpart" + command: "readAttribute" + attribute: "PartNumber" + response: + saveAs: PartNumberValue + constraints: + type: char_string + maxLength: 32 + + - label: "TH writes PartNumber from the DUT." PICS: BRBINFO.S.A000c - verification: | - ./chip-tool bridgeddevicebasic write part-number newpart 1 3 - - Verify response has unsupported write on TH(chip-tool) Log: - - [1656495259.991989][2164:2169] CHIP:TOO: Response Failure: IM Error 0x00000588: General error: 0x88 (UNSUPPORTED_WRITE) - disabled: true - - - label: "TH reads PartNumber" + command: "writeAttribute" + attribute: "PartNumber" + arguments: + value: "newpart" + response: + error: UNSUPPORTED_WRITE + + - label: "TH reads PartNumber from the DUT" PICS: BRBINFO.S.A000c - verification: | - ./chip-tool bridgeddevicebasic read part-number 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE + command: "readAttribute" + attribute: "PartNumber" + response: + value: PartNumberValue - Example Log: - [1656496800.941788][2405:2410] CHIP:TOO: PartNumber: 1234 - disabled: true - - - label: "TH reads ProductURL from the DUT." + - label: "TH reads ProductURL from the DUT" PICS: BRBINFO.S.A000d - verification: | - ./chip-tool bridgeddevicebasic read product-url 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - - [1656497181.118653][2436:2441] CHIP:TOO: ProductURL: https://example.com/myproduct - disabled: true + command: "readAttribute" + attribute: "ProductURL" + response: + saveAs: ProductURLValue + constraints: + type: long_char_string + maxLength: 256 - - label: "TH writes ProductURL as https://www.example.com" + - label: + "Verify that it specifies a link to a specific web page, Verify that + it follows the syntax rules specified in RFC 3986." + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT && BRBINFO.S.A000d + arguments: + values: + - name: "message" + value: "Please enter 'y' for success" + - name: "expectedValue" + value: "y" + + - label: "TH writes ProductURL from the DUT." PICS: BRBINFO.S.A000d - verification: | - ./chip-tool bridgeddevicebasic write product-url https://www.example.com 1 3 - - Verify response has unsupported write on TH(chip-tool) Log: - - [1656495259.991989][2164:2169] CHIP:TOO: Response Failure: IM Error 0x00000588: General error: 0x88 (UNSUPPORTED_WRITE) - disabled: true - - - label: "TH reads ProductURL" + command: "writeAttribute" + attribute: "ProductURL" + arguments: + value: "https://www.example.com" + response: + error: UNSUPPORTED_WRITE + + - label: "TH reads ProductURL from the DUT" PICS: BRBINFO.S.A000d - verification: | - ./chip-tool bridgeddevicebasic read product-url 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656497181.118653][2436:2441] CHIP:TOO: ProductURL: https://example.com/myproduct - disabled: true + command: "readAttribute" + attribute: "ProductURL" + response: + value: ProductURLValue - label: "TH reads ProductLabel from the DUT." PICS: BRBINFO.S.A000e - verification: | - ./chip-tool bridgeddevicebasic read product-label 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE + command: "readAttribute" + attribute: "ProductLabel" + response: + saveAs: ProductLabelValue + constraints: + type: char_string + maxLength: 64 - Example Log: - - [1656501313.811305][2602:2607] CHIP:TOO: ProductLabel: ABCD - disabled: true - - - label: "TH writes ProductLabel as newproductlabel" + - label: + "Verify that it does not include the name of the vendor as defined + within the VendorName attribute" + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT && BRBINFO.S.A000e + arguments: + values: + - name: "message" + value: "Please enter 'y' for success" + - name: "expectedValue" + value: "y" + + - label: "TH writes ProductLabel from the DUT." PICS: BRBINFO.S.A000e - verification: | - ./chip-tool bridgeddevicebasic write product-label newproductlabel 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656495259.991989][2164:2169] CHIP:TOO: Response Failure: IM Error 0x00000588: General error: 0x88 (UNSUPPORTED_WRITE) - disabled: true + command: "writeAttribute" + attribute: "ProductLabel" + arguments: + value: "newproductlabel" + response: + error: UNSUPPORTED_WRITE - - label: "TH reads ProductLabel" + - label: "TH reads ProductLabel from the DUT." PICS: BRBINFO.S.A000e - verification: | - ./chip-tool bridgeddevicebasic read product-label 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656501313.811305][2602:2607] CHIP:TOO: ProductLabel: ABCD - disabled: true + command: "readAttribute" + attribute: "ProductLabel" + response: + value: ProductLabelValue - label: "TH reads SerialNumber from the DUT." PICS: BRBINFO.S.A000f - verification: | - ./chip-tool bridgeddevicebasic read serial-number 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - - [1656501452.183890][2624:2630] CHIP:TOO: SerialNumber: 5678 - disabled: true - - - label: "TH writes SerialNumber_test as newserialnumber" + command: "readAttribute" + attribute: "SerialNumber" + response: + saveAs: SerialNumberValue + constraints: + type: char_string + maxLength: 32 + + - label: "TH writes SerialNumber from the DUT." PICS: BRBINFO.S.A000f - verification: | - ./chip-tool bridgeddevicebasic write serial-number newserialnumber 1 3 - - Verify response has unsupported write on TH(chip-tool) Log: + command: "writeAttribute" + attribute: "SerialNumber" + arguments: + value: "newserialnumber" + response: + error: UNSUPPORTED_WRITE - [1656495259.991989][2164:2169] CHIP:TOO: Response Failure: IM Error 0x00000588: General error: 0x88 (UNSUPPORTED_WRITE) - disabled: true - - - label: "TH reads SerialNumber" + - label: "TH reads SerialNumber from the DUT." PICS: BRBINFO.S.A000f - verification: | - ./chip-tool bridgeddevicebasic read serial-number 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656501452.183890][2624:2630] CHIP:TOO: SerialNumber: 5678 - disabled: true + command: "readAttribute" + attribute: "SerialNumber" + response: + value: SerialNumberValue - label: "TH reads Reachable from the DUT." PICS: BRBINFO.S.A0011 - verification: | - ./chip-tool bridgeddevicebasic read reachable 1 3 - - Verify value of reachable is type of bool and its true in TH Log: - - [1659012746.234251][8169:8174] CHIP:TOO: Endpoint: 3 Cluster: 0x0000_0039 Attribute 0x0000_0011 DataVersion: 1363291551 - [1659012746.234309][8169:8174] CHIP:TOO: Reachable: TRUE - [1659012746.234420][8169:8174] CHIP:EM: Sending Standalone Ack for MessageCounter:92645971 on exchange 389i - disabled: true + command: "readAttribute" + attribute: "Reachable" + response: + value: true + constraints: + type: boolean - label: "TH sends Write request message to DUT to change value of Reachable to - false." + false" PICS: BRBINFO.S.A0011 - verification: | - ./chip-tool bridgeddevicebasic write-by-id 17 false 1 3 - - - - On TH verify that, TH receives UNSUPPORTED_WRITE response as status - [1656496372.884955][2340:2345] CHIP:DMG: } - [1656496372.885085][2340:2345] CHIP:DMG: WriteClient moving to [AwaitingDe] - [1656496372.885148][2340:2345] CHIP:TOO: Response Failure: IM Error 0x00000588: General error: 0x88 (UNSUPPORTED_WRITE) - [1656496372.885242][2340:2345] CHIP:EM: Sending Standalone Ack for MessageCounter:201795946 on exchange 27637ihe attribute is optional so no example log can be provided. - disabled: true + command: "writeAttribute" + attribute: "Reachable" + arguments: + value: false + response: + error: UNSUPPORTED_WRITE - label: "TH reads Reachable from the DUT." PICS: BRBINFO.S.A0011 - verification: | - ./chip-tool bridgeddevicebasic read reachable 1 3 - On TH verify that the value of reachable is type is same as 51 - - [1659012746.234251][8169:8174] CHIP:TOO: Endpoint: 3 Cluster: 0x0000_0039 Attribute 0x0000_0011 DataVersion: 1363291551 - [1659012746.234309][8169:8174] CHIP:TOO: Reachable: TRUE - [1659012746.234420][8169:8174] CHIP:EM: Sending Standalone Ack for MessageCounter:92645971 on exchange 389i - disabled: true + command: "readAttribute" + attribute: "Reachable" + response: + value: true + constraints: + type: boolean - label: "TH reads UniqueID from the DUT." PICS: BRBINFO.S.A0012 - verification: | - ./chip-tool bridgeddevicebasic read unique-id 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - - [1656501734.253827][2673:2679] CHIP:TOO: UniqueID: 30789FE4FCF832C9 - disabled: true - - - label: "TH writes UniqueID as newid" + command: "readAttribute" + attribute: "UniqueID" + response: + saveAs: UniqueIDValue + constraints: + type: char_string + maxLength: 32 + + - label: "TH writes UniqueID from the DUT." PICS: BRBINFO.S.A0012 - verification: | - ./chip-tool bridgeddevicebasic write unique-id newid 1 3 - - Verify response has unsupported write on TH(chip-tool) Log: + command: "writeAttribute" + attribute: "UniqueID" + arguments: + value: "newid" + response: + error: UNSUPPORTED_WRITE - [1656495259.991989][2164:2169] CHIP:TOO: Response Failure: IM Error 0x00000588: General error: 0x88 (UNSUPPORTED_WRITE) - disabled: true - - - label: "TH reads UniqueID" + - label: "TH reads UniqueID from the DUT." PICS: BRBINFO.S.A0012 - verification: | - ./chip-tool bridgeddevicebasic read unique-id 1 3 - - Optional Attribute - If it is supported, then in TH log it will results in displaying the value, else it will display UNSUPPORTED_ATTRIBUTE - - Example Log: - [1656501734.253827][2673:2679] CHIP:TOO: UniqueID: 30789FE4FCF832C9 - disabled: true + command: "readAttribute" + attribute: "UniqueID" + response: + value: UniqueIDValue diff --git a/src/app/tests/suites/certification/Test_TC_CNET_1_3.yaml b/src/app/tests/suites/certification/Test_TC_CNET_1_3.yaml index 3c5936b993798d..8e167b434b01b1 100644 --- a/src/app/tests/suites/certification/Test_TC_CNET_1_3.yaml +++ b/src/app/tests/suites/certification/Test_TC_CNET_1_3.yaml @@ -11,7 +11,6 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -# Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default name: 12.1.3. [TC-CNET-1.3] Global Attributes for Networking commissioning cluster @@ -22,209 +21,165 @@ PICS: config: nodeId: 0x12344321 - cluster: "Basic" + cluster: "Network Commissioning" endpoint: 0 tests: - - label: "Commission TH and DUT over BLE to setup the Wi-Fi" - verification: | - - disabled: true - - - label: "TH reads the ClusterRevision from DUT" - verification: | - ./chip-tool networkcommissioning read cluster-revision 1 0 - - Verify "ClusterRevision: 1" on the TH(Chip-tool) Log: - - [1649244866.275684][30440:30446] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_FFFD DataVersion: 2702518944 - [1649244866.277721][30440:30446] CHIP:TOO: ClusterRevision: 1 - [1649244866.277827][30440:30446] CHIP:EM: Sending Standalone Ack for MessageCounter:10092551 on exchange 64234i - disabled: true - - - label: "TH reads the FeatureMap from DUT" - verification: | - (WiFi) - ./chip-tool networkcommissioning read feature-map 1 0 - - Verify "FeatureMap" on the TH(Chip-tool) Log: - - [1651215443.195852][3285:3290] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_FFFC DataVersion: 2584224280 - [1651215443.195939][3285:3290] CHIP:TOO: FeatureMap: 1 - - (Ethernet) - ./chip-tool networkcommissioning read feature-map 1 0 - - Verify "FeatureMap" on the TH(Chip-tool) Log: - - [1660315515.081759][32315:32320] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_FFFC DataVersion: 4034679103 - [1660315515.081895][32315:32320] CHIP:TOO: FeatureMap: 4 - - (Thread) - ./chip-tool networkcommissioning read feature-map 1 0 - - Verify "FeatureMap" on the TH(Chip-tool) Log: - - [1660315948.250922][3101:3106] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_FFFC DataVersion: 1122474754 - [1660315948.261520][3101:3106] CHIP:TOO: FeatureMap: 2 - disabled: true - - - label: "TH reads AttributeList from DUT" - verification: | - (WiFi) - ./chip-tool networkcommissioning read attribute-list 1 0 - - Verify "AttributeList" on the TH(Chip-tool) Log: - - [1651215479.539148][3293:3298] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_FFFB DataVersion: 2584224280 - [1651215479.539230][3293:3298] CHIP:TOO: AttributeList: 13 entries - [1651215479.539262][3293:3298] CHIP:TOO: [1]: 0 - [1651215479.539288][3293:3298] CHIP:TOO: [2]: 1 - [1651215479.539323][3293:3298] CHIP:TOO: [3]: 2 - [1651215479.539348][3293:3298] CHIP:TOO: [4]: 3 - [1651215479.539373][3293:3298] CHIP:TOO: [5]: 4 - [1651215479.539397][3293:3298] CHIP:TOO: [6]: 5 - [1651215479.539420][3293:3298] CHIP:TOO: [7]: 6 - [1651215479.539444][3293:3298] CHIP:TOO: [8]: 7 - [1651215479.539468][3293:3298] CHIP:TOO: [9]: 65528 - [1651215479.539493][3293:3298] CHIP:TOO: [10]: 65529 - [1651215479.539517][3293:3298] CHIP:TOO: [11]: 65531 - [1651215479.539541][3293:3298] CHIP:TOO: [12]: 65532 - [1651215479.539564][3293:3298] CHIP:TOO: [13]: 65533 - - - (Ethernet) - - ./chip-tool networkcommissioning read attribute-list 1 0 - - Verify "AttributeList" on the TH(Chip-tool) Log: - - [1660315522.163640][32321:32326] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_FFFB DataVersion: 4034679103 - [1660315522.163797][32321:32326] CHIP:TOO: AttributeList: 13 entries - [1660315522.163880][32321:32326] CHIP:TOO: [1]: 0 - [1660315522.163945][32321:32326] CHIP:TOO: [2]: 1 - [1660315522.164009][32321:32326] CHIP:TOO: [3]: 2 - [1660315522.164106][32321:32326] CHIP:TOO: [4]: 3 - [1660315522.164174][32321:32326] CHIP:TOO: [5]: 4 - [1660315522.164260][32321:32326] CHIP:TOO: [6]: 5 - [1660315522.164328][32321:32326] CHIP:TOO: [7]: 6 - [1660315522.164393][32321:32326] CHIP:TOO: [8]: 7 - [1660315522.164482][32321:32326] CHIP:TOO: [9]: 65528 - [1660315522.164549][32321:32326] CHIP:TOO: [10]: 65529 - [1660315522.164636][32321:32326] CHIP:TOO: [11]: 65531 - [1660315522.164708][32321:32326] CHIP:TOO: [12]: 65532 - [1660315522.164778][32321:32326] CHIP:TOO: [13]: 65533 - - (Thread) - - ./chip-tool networkcommissioning read attribute-list 1 0 - - Verify "AttributeList" on the TH(Chip-tool) Log: - - [1660316011.016650][3112:3117] CHIP:TOO: AttributeList: 13 entries - [1660316011.016678][3112:3117] CHIP:TOO: [1]: 0 - [1660316011.016700][3112:3117] CHIP:TOO: [2]: 1 - [1660316011.016721][3112:3117] CHIP:TOO: [3]: 2 - [1660316011.016741][3112:3117] CHIP:TOO: [4]: 3 - [1660316011.016762][3112:3117] CHIP:TOO: [5]: 4 - [1660316011.016782][3112:3117] CHIP:TOO: [6]: 5 - [1660316011.016803][3112:3117] CHIP:TOO: [7]: 6 - [1660316011.016823][3112:3117] CHIP:TOO: [8]: 7 - [1660316011.016844][3112:3117] CHIP:TOO: [9]: 65528 - [1660316011.016865][3112:3117] CHIP:TOO: [10]: 65529 - [1660316011.016887][3112:3117] CHIP:TOO: [11]: 65531 - [1660316011.016908][3112:3117] CHIP:TOO: [12]: 65532 - [1660316011.016929][3112:3117] CHIP:TOO: [13]: 65533 - [1660316011.017068][3112:3117] CHIP:EM: Sending Standalone Ack for MessageCounter:239150268 on exchange 45209i - disabled: true - - - label: "TH reads EventList from the DUT" - verification: | - out of scope for V1.0 - disabled: true - - - label: "TH reads AcceptedCommandList from DUT" - verification: | - (WiFi) - ./chip-tool networkcommissioning read accepted-command-list 1 0 - - Verify "AcceptedCommandList" on the TH(Chip-tool) Log: - - [1653909914.972854][3424:3429] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_FFF9 DataVersion: 880539056 - [1653909914.973027][3424:3429] CHIP:TOO: AcceptedCommandList: 5 entries - [1653909914.973102][3424:3429] CHIP:TOO: [1]: 0 - [1653909914.973166][3424:3429] CHIP:TOO: [2]: 2 - [1653909914.973228][3424:3429] CHIP:TOO: [3]: 4 - [1653909914.973289][3424:3429] CHIP:TOO: [4]: 6 - [1653909914.973350][3424:3429] CHIP:TOO: [5]: 8 - [1653909914.973574][3424:3429] CHIP:EM: Sending Standalone Ack for MessageCounter:4589161 on exchange 55554i - - - (Ethernet) - ./chip-tool networkcommissioning read accepted-command-list 1 0 - - Verify "AcceptedCommandList" on the TH(Chip-tool) Log: - - [1660315536.068512][32327:32332] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_FFF9 DataVersion: 4034679103 - [1660315536.068654][32327:32332] CHIP:TOO: AcceptedCommandList: 0 entries - - (Thread) - ./chip-tool networkcommissioning read accepted-command-list 1 0 - - Verify "AcceptedCommandList" on the TH(Chip-tool) Log: - - [1660316038.564553][3121:3126] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_FFF9 DataVersion: 1122474754 - [1660316038.564671][3121:3126] CHIP:TOO: AcceptedCommandList: 5 entries - [1660316038.564702][3121:3126] CHIP:TOO: [1]: 0 - [1660316038.564725][3121:3126] CHIP:TOO: [2]: 3 - [1660316038.564747][3121:3126] CHIP:TOO: [3]: 4 - [1660316038.564769][3121:3126] CHIP:TOO: [4]: 6 - [1660316038.564853][3121:3126] CHIP:TOO: [5]: 8 - [1660316038.564991][3121:3126] CHIP:EM: Sending Standalone Ack for MessageCounter:232731891 on exchange 30329i - disabled: true - - - label: "TH reads GeneratedCommandList from DUT" - verification: | - ( WiFi) - ./chip-tool networkcommissioning read generated-command-list 1 0 - - - Verify "GeneratedCommandList" on the TH(Chip-tool) Log: - - [1650370123.417759][42418:42423] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_FFF8 DataVersion: 3182776035 - [1650370123.417866][42418:42423] CHIP:TOO: GeneratedCommandList: 3 entries - [1650370123.417938][42418:42423] CHIP:TOO: [1]: 1 - [1650370123.417977][42418:42423] CHIP:TOO: [2]: 5 - [1650370123.418013][42418:42423] CHIP:TOO: [3]: 7 - [1650370123.418143][42418:42423] CHIP:EM: Sending Standalone Ack for MessageCounter:759910 on exchange 25409i - - - - (Ethernet) - ./chip-tool networkcommissioning read generated-command-list 1 0 - - Verify "GeneratedCommandList" on the TH(Chip-tool) Log: - - [1660315548.937195][32333:32338] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_FFF8 DataVersion: 4034679103 - [1660315548.937327][32333:32338] CHIP:TOO: GeneratedCommandList: 0 entries - - - ( Thread ) - ./chip-tool networkcommissioning read generated-command-list 51 0 - - - Verify "GeneratedCommandList" on the TH(Chip-tool) Log: - - [1650370342.693373][7450:7455] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_FFF8 DataVersion: 1032683896 - [1650370342.693536][7450:7455] CHIP:TOO: GeneratedCommandList: 2 entries - 1650370123.417938][42418:42423] CHIP:TOO: [1]: 1 - [1650370123.417977][42418:42423] CHIP:TOO: [2]: 5 - [1650370123.418013][42418:42423] CHIP:TOO: [3]: 7 - [1650370342.693995][7450:7455] CHIP:EM: Sending Standalone Ack for MessageCounter:2345375 on exchange 25146i - disabled: true - - - label: "NOTE" - verification: | - Repeat the test case by Commission DUT to TH on the Thread and - Ethernet setups - disabled: true + - label: "Wait for the commissioned device to be retrieved" + cluster: "DelayCommands" + command: "WaitForCommissionee" + arguments: + values: + - name: "nodeId" + value: nodeId + + - label: "Read the global attribute: ClusterRevision" + command: "readAttribute" + attribute: "ClusterRevision" + response: + value: 1 + constraints: + type: int16u + + - label: "Read the global attribute: FeatureMap" + PICS: " !CNET.S.F00 && !CNET.S.F01 && !CNET.S.F02 " + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 0 + + - label: "Read the global attribute: FeatureMap when CNET.S.F00 is set" + PICS: CNET.S.F00 + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 1 + + - label: "Read the global attribute: FeatureMap when CNET.S.F01 is set" + PICS: CNET.S.F01 + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 2 + + - label: "Read the global attribute: FeatureMap when CNET.S.F02 is set" + PICS: CNET.S.F02 + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 4 + + - label: "Read the global attribute: AttributeList" + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [65528, 65529, 65531, 65532, 65533] + + - label: + "Read mandatory attributes in AttributeList if + CNET.S.F00(WI)/CNET.S.F01(TH)/CNET.S.F02(ET) is true" + PICS: CNET.S.F00 || CNET.S.F01 || CNET.S.F02 + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [0, 1, 4, 5, 6, 7] + + - label: "Read the optional attribute(ScanMaxTimeSeconds): AttributeList" + PICS: CNET.S.A0002 + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [2] + + - label: + "Reading optional attribute(ConnectMaxTimeSeconds) in AttributeList" + PICS: CNET.S.A0003 + command: "readAttribute" + attribute: "AttributeList" + response: + constraints: + type: list + contains: [3] + + - label: + "Read AcceptedCommandList If DUT supports Wi-Fi/Thread related + features CNET.S.F00(WI),CNET.S.F01(TH)" + PICS: CNET.S.F00 || CNET.S.F01 + command: "readAttribute" + attribute: "AcceptedCommandList" + response: + constraints: + type: list + contains: [0, 4, 6, 8] + + - label: + "Read AcceptedCommandList If DUT supports Wi-Fi related features + (CNET.S.F00(WI) is true)" + PICS: CNET.S.F00 + command: "readAttribute" + attribute: "AcceptedCommandList" + response: + constraints: + type: list + contains: [2] + + - label: + "Read AcceptedCommandList If DUT supports Thread related + features(CNET.S.F01(TH) is true)" + PICS: CNET.S.F01 + command: "readAttribute" + attribute: "AcceptedCommandList" + response: + constraints: + type: list + contains: [3] + + - label: + "Read AcceptedCommandList If DUT supports Ethernet related + features(CNET.S.F02(TH) is true)" + PICS: CNET.S.F02 + command: "readAttribute" + attribute: "AcceptedCommandList" + response: + value: [] + + - label: + "Read the GeneratedCommandList If DUT supports Wi-Fi/Thread related + features(CNET.S.F00(WI) or CNET.S.F01(TH) is true)" + PICS: CNET.S.F00 || CNET.S.F01 + command: "readAttribute" + attribute: "GeneratedCommandList" + response: + constraints: + type: list + contains: [1, 5, 7] + + - label: + "Read the GeneratedCommandList If DUT supports Ethernet related + features(CNET.S.F02(ET) must be true)" + PICS: CNET.S.F02 + command: "readAttribute" + attribute: "GeneratedCommandList" + response: + value: [] + #Commenting out the step EventList attribute which is out of scope for matter V1.0 + #- label: + # "Read EventList attribute from the DUT and Verify that the DUT + # response provides a list of supported events." + # verification: | + # Not implemented in chip-tool + # cluster: "LogCommands" + # command: "UserPrompt" + # PICS: PICS_USER_PROMPT + # arguments: + # values: + # - name: "message" + # value: "Please enter 'y' for success" + # - name: "expectedValue" + # value: "y" diff --git a/src/app/tests/suites/certification/Test_TC_DGTHREAD_1_1.yaml b/src/app/tests/suites/certification/Test_TC_DGTHREAD_1_1.yaml index 8f86d07f252121..e6d2e2a0ba58e9 100644 --- a/src/app/tests/suites/certification/Test_TC_DGTHREAD_1_1.yaml +++ b/src/app/tests/suites/certification/Test_TC_DGTHREAD_1_1.yaml @@ -536,7 +536,7 @@ tests: contains: [55] - label: "Read the optional attribute (ActiveTimestamp) in AttributeList" - PICS: DGTHREAD.S.A0039 + PICS: DGTHREAD.S.A0038 command: "readAttribute" attribute: "AttributeList" response: @@ -545,7 +545,7 @@ tests: contains: [56] - label: "Read the optional attribute (PendingTimestamp) in AttributeList" - PICS: DGTHREAD.S.A003A + PICS: DGTHREAD.S.A0039 command: "readAttribute" attribute: "AttributeList" response: @@ -554,7 +554,7 @@ tests: contains: [57] - label: "Read the optional attribute (Delay) in AttributeList" - PICS: DGTHREAD.S.A003B + PICS: DGTHREAD.S.A003a command: "readAttribute" attribute: "AttributeList" response: diff --git a/src/app/tests/suites/certification/Test_TC_DGTHREAD_2_1.yaml b/src/app/tests/suites/certification/Test_TC_DGTHREAD_2_1.yaml index a204f2abfa3943..269677250dae0d 100644 --- a/src/app/tests/suites/certification/Test_TC_DGTHREAD_2_1.yaml +++ b/src/app/tests/suites/certification/Test_TC_DGTHREAD_2_1.yaml @@ -414,7 +414,7 @@ tests: type: int64u - label: "TH reads Delay attribute value from DUT" - PICS: DGTHREAD.S.A003A + PICS: DGTHREAD.S.A003a command: "readAttribute" attribute: "Delay" response: @@ -441,7 +441,7 @@ tests: [1649825860.867921][3472:3477] CHIP:TOO: } cluster: "LogCommands" command: "UserPrompt" - PICS: PICS_USER_PROMPT && DGTHREAD.S.A003B + PICS: PICS_USER_PROMPT && DGTHREAD.S.A003b arguments: values: - name: "message" diff --git a/src/app/tests/suites/certification/Test_TC_DRLK_2_6.yaml b/src/app/tests/suites/certification/Test_TC_DRLK_2_6.yaml index bffd1db40b6a6d..1761022dd8014e 100644 --- a/src/app/tests/suites/certification/Test_TC_DRLK_2_6.yaml +++ b/src/app/tests/suites/certification/Test_TC_DRLK_2_6.yaml @@ -11,196 +11,146 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -# Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default name: - 116.2.6. [TC-DRLK-2.6] Verification for the following Commands - Set Holiday - Schedule, Get Holiday Schedule, Get Holiday Schedule Response , Clear - Holiday Schedule [DUT-Server] + 111.2.7. [TC-DRLK-2.6] Verification for the following Commands - Set Year + Schedule, Get Year Schedule, Get Year Day Schedule Response and Clear Year + Day Schedule[DUT-Server] PICS: - DRLK.S config: nodeId: 0x12344321 - cluster: "Basic" - endpoint: 0 + cluster: "Door Lock" + endpoint: 1 tests: - - label: "Pre-Conditions" - verification: | - DUT as server - disabled: true + - label: "Wait for commissionee" + cluster: "DelayCommands" + command: "WaitForCommissionee" + arguments: + values: + - name: "nodeId" + value: nodeId - label: "TH reads NumberOfHoliday SchedulesSupported and saves for future use." PICS: DRLK.S.F0b && DRLK.S.A0016 - verification: | - ./chip-tool doorlock read number-of-holiday-schedules-supported 1 1 - Verify " NumberOfHoliDay SchedulesSuppored" on the TH(Chip-tool) Log: - - [1654691068.446440][4655:4660] CHIP:DMG: - [1654691068.446465][4655:4660] CHIP:DMG: SuppressResponse = true, - [1654691068.446492][4655:4660] CHIP:DMG: InteractionModelRevision = 1 - [1654691068.446515][4655:4660] CHIP:DMG: } - [1654691068.446648][4655:4660] CHIP:TOO: Endpoint: 1 Cluster: 0x0000_0101 Attribute 0x0000_0016 DataVersion: 1413324060 - [1654691068.446726][4655:4660] CHIP:TOO: NumberOfHolidaySchedulesSupported: 10 - disabled: true - - - label: - "TH sends Set Holiday Schedule Command to DUT with the following - values: HolidayIndex as 1 LocalStartTime as 20 Seconds LocalEndTime as - 30 Seconds OperatingMode as 0" + command: "readAttribute" + attribute: "NumberOfHolidaySchedulesSupported" + response: + saveAs: NumberOfHolidaySchedulesSupported + constraints: + minValue: 0 + maxValue: 255 + + - label: "Create Holiday schedule with 1 index" PICS: DRLK.S.F0b && DRLK.S.C11.Rsp - verification: | - ./chip-tool doorlock set-holiday-schedule 1 20 30 0 1 1 - Verify " DUT send SUCCESS response." on the TH(Chip-tool) Log: - - [1654691200.905091][4669:4674] CHIP:DMG: StatusIB = - [1654691200.905122][4669:4674] CHIP:DMG: { - [1654691200.905162][4669:4674] CHIP:DMG: status = 0x00 (SUCCESS), - [1654691200.905198][4669:4674] CHIP:DMG: }, - [1654691200.905236][4669:4674] CHIP:DMG: - [1654691200.905266][4669:4674] CHIP:DMG: }, - [1654691200.905301][4669:4674] CHIP:DMG: - [1654691200.905326][4669:4674] CHIP:DMG: }, - [1654691200.905356][4669:4674] CHIP:DMG: - [1654691200.905380][4669:4674] CHIP:DMG: ], - [1654691200.905410][4669:4674] CHIP:DMG: - [1654691200.905434][4669:4674] CHIP:DMG: InteractionModelRevision = 1 - [1654691200.905463][4669:4674] CHIP:DMG: }, - disabled: true - - - label: - "TH sends Get Holiday Schedule Command to DUT with HolidayIndex as 1" + command: "SetHolidaySchedule" + arguments: + values: + - name: "holidayIndex" + value: 1 + - name: "localStartTime" + value: 20 + - name: "localEndTime" + value: 30 + - name: "operatingMode" + value: 0 + + - label: "Get Holiday Schedule with HolidayIndex as 1" PICS: DRLK.S.F0b && DRLK.S.C12.Rsp && DRLK.S.C12.Tx - verification: | - ./chip-tool doorlock get-holiday-schedule 1 1 1 - Verify " DUT responds with Get Holiday Schedule Response" on the TH(Chip-tool) Log: - - [1654691299.545647][4678:4683] CHIP:DMG: Received Command Response Data, Endpoint=1 Cluster=0x0000_0101 Command=0x0000_0012 - [1654691299.545701][4678:4683] CHIP:TOO: Endpoint: 1 Cluster: 0x0000_0101 Command 0x0000_0012 - [1654691299.545769][4678:4683] CHIP:TOO: GetHolidayScheduleResponse: { - [1654691299.545807][4678:4683] CHIP:TOO: holidayIndex: 1 - [1654691299.545830][4678:4683] CHIP:TOO: status: 0 - [1654691299.545853][4678:4683] CHIP:TOO: localStartTime: 20 - [1654691299.545876][4678:4683] CHIP:TOO: localEndTime: 30 - [1654691299.545898][4678:4683] CHIP:TOO: operatingMode: 0 - [1654691299.545922][4678:4683] CHIP:TOO: } - disabled: true - - - label: - "TH sends Set Holiday Schedule Command to DUT with the following - values: HolidayIndex as 1 LocalStartTime as 20 LocalEndTime as 30 - OperatingMode as 5(Invalid value)" + command: "GetHolidaySchedule" + arguments: + values: + - name: "holidayIndex" + value: 1 + response: + values: + - name: "holidayIndex" + value: 1 + - name: "status" + value: 0x0 + - name: "localStartTime" + value: 20 + - name: "localEndTime" + value: 30 + constraints: + minValue: 21 + - name: "operatingMode" + value: 0 + + - label: "Create Holiday schedule with invalid operating mode" PICS: DRLK.S.C11.Rsp - verification: | - ./chip-tool doorlock set-holiday-schedule 1 20 30 5 1 1 - Verify " DUT sends INVALID_COMMAND response" on the TH(Chip-tool) Log: - - [1655373066.616542][2571:2576] CHIP:DMG: { - [1655373066.616583][2571:2576] CHIP:DMG: suppressResponse = false, - [1655373066.616624][2571:2576] CHIP:DMG: InvokeResponseIBs = - [1655373066.616692][2571:2576] CHIP:DMG: [ - [1655373066.616732][2571:2576] CHIP:DMG: InvokeResponseIB = - [1655373066.616799][2571:2576] CHIP:DMG: { - [1655373066.616854][2571:2576] CHIP:DMG: CommandStatusIB = - [1655373066.616913][2571:2576] CHIP:DMG: { - [1655373066.616981][2571:2576] CHIP:DMG: CommandPathIB = - [1655373066.617046][2571:2576] CHIP:DMG: { - [1655373066.617118][2571:2576] CHIP:DMG: EndpointId = 0x1, - [1655373066.617200][2571:2576] CHIP:DMG: ClusterId = 0x101, - [1655373066.617264][2571:2576] CHIP:DMG: CommandId = 0x11, - [1655373066.617338][2571:2576] CHIP:DMG: }, - [1655373066.617412][2571:2576] CHIP:DMG: - [1655373066.617463][2571:2576] CHIP:DMG: StatusIB = - [1655373066.617538][2571:2576] CHIP:DMG: { - [1655373066.617612][2571:2576] CHIP:DMG: status = 0x85 (INVALID_COMMAND), - [1655373066.617672][2571:2576] CHIP:DMG: }, - [1655373066.617745][2571:2576] CHIP:DMG: - [1655373066.617806][2571:2576] CHIP:DMG: }, - [1655373066.617863][2571:2576] CHIP:DMG: - [1655373066.617921][2571:2576] CHIP:DMG: }, - [1655373066.617970][2571:2576] CHIP:DMG: - [1655373066.618024][2571:2576] CHIP:DMG: ], - [1655373066.618073][2571:2576] CHIP:DMG: - [1655373066.618127][2571:2576] CHIP:DMG: InteractionModelRevision = 1 - [1655373066.618166][2571:2576] CHIP:DMG: }, - disabled: true - - - label: - "TH sends Get Holiday Schedule Command to DUT with Invalid - HolidayIndex as 15." + command: "SetHolidaySchedule" + arguments: + values: + - name: "holidayIndex" + value: 1 + - name: "localStartTime" + value: 20 + - name: "localEndTime" + value: 30 + - name: "operatingMode" + value: 5 + response: + error: INVALID_COMMAND + + - label: "Get Holiday Schedule with Invalid HolidayIndex 15." PICS: DRLK.S.F0b && DRLK.S.C12.Rsp && DRLK.S.C12.Tx - verification: | - ./chip-tool doorlock get-holiday-schedule 15 1 1 - Verify " DUT sends INVALID_COMMAND response" on the TH(Chip-tool) Log: - - [1654691634.513667][4728:4733] CHIP:DMG: }, - [1654691634.513979][4728:4733] CHIP:DMG: Received Command Response Data, Endpoint=1 Cluster=0x0000_0101 Command=0x0000_0012 - [1654691634.514168][4728:4733] CHIP:TOO: Endpoint: 1 Cluster: 0x0000_0101 Command 0x0000_0012 - [1658471936.478043][2537:2542] CHIP:DMG: }, - [1658471936.478124][2537:2542] CHIP:DMG: Received Command Response Data, Endpoint=1 Cluster=0x0000_0101 Command=0x0000_0012 - [1658471936.478183][2537:2542] CHIP:TOO: Endpoint: 1 Cluster: 0x0000_0101 Command 0x0000_0012 - [1658471936.478270][2537:2542] CHIP:TOO: GetHolidayScheduleResponse: { - [1658471936.478316][2537:2542] CHIP:TOO: holidayIndex: 15 - [1658471936.478363][2537:2542] CHIP:TOO: status: 133 - [1658471936.478395][2537:2542] CHIP:TOO: } - [1654691634.514670][4728:4733] CHIP:TOO: } - disabled: true - - - label: - "TH sends Get Holiday Schedule Command to DUT with the HolidayIndex as - 10 (value is in the the range of step 1 but Holiday Schedule entry not - available)" + command: "GetHolidaySchedule" + arguments: + values: + - name: "holidayIndex" + value: 15 + response: + values: + - name: "holidayIndex" + value: 15 + - name: "status" + value: 133 + + - label: "Get Holiday Schedule with the Non-scheduled HolidayIndex" PICS: DRLK.S.F0b && DRLK.S.C12.Rsp && DRLK.S.C12.Tx - verification: | - ./chip-tool doorlock get-holiday-schedule 10 1 1 - Verify " DUT sends a NOT_FOUND status" on the TH(Chip-tool) Log: - - [1654691928.900652][4772:4777] CHIP:DMG: }, - [1654691928.900762][4772:4777] CHIP:DMG: Received Command Response Data, Endpoint=1 Cluster=0x0000_0101 Command=0x0000_0012 - [1654691928.900844][4772:4777] CHIP:TOO: Endpoint: 1 Cluster: 0x0000_0101 Command 0x0000_0012 - [1654691928.900944][4772:4777] CHIP:TOO: GetHolidayScheduleResponse: { - [1654691928.901003][4772:4777] CHIP:TOO: holidayIndex: 10 - [1654691928.901047][4772:4777] CHIP:TOO: status: 139 - [1654691928.901093][4772:4777] CHIP:TOO: } - disabled: true - - - label: - "TH send Clear Holiday Schedule Command to DUT with HolidayIndex as 1" + command: "GetHolidaySchedule" + arguments: + values: + - name: "holidayIndex" + value: 10 + response: + values: + - name: "holidayIndex" + value: 10 + - name: "status" + value: 139 + + - label: "Clear Holiday schedule with 1 index" PICS: DRLK.S.F0b && DRLK.S.C13.Rsp - verification: | - ./chip-tool doorlock clear-holiday-schedule 1 1 1 - Verify " DUT sends SUCCESS response" on the TH(Chip-tool) Log: - - [1654692125.827938][4791:4796] CHIP:DMG: StatusIB = - [1654692125.828009][4791:4796] CHIP:DMG: { - [1654692125.828080][4791:4796] CHIP:DMG: status = 0x00 (SUCCESS), - [1654692125.828156][4791:4796] CHIP:DMG: }, - [1654692125.828233][4791:4796] CHIP:DMG: - [1654692125.828296][4791:4796] CHIP:DMG: }, - [1654692125.828367][4791:4796] CHIP:DMG: - [1654692125.828424][4791:4796] CHIP:DMG: }, - [1654692125.828488][4791:4796] CHIP:DMG: - [1654692125.828538][4791:4796] CHIP:DMG: ], - [1654692125.828601][4791:4796] CHIP:DMG: - [1654692125.828652][4791:4796] CHIP:DMG: InteractionModelRevision = 1 - [1654692125.828701][4791:4796] CHIP:DMG: }, - disabled: true + command: "ClearHolidaySchedule" + arguments: + values: + - name: "holidayIndex" + value: 1 - - label: - "TH sends Get Holiday Schedule Command to DUT with HolidayIndex as 1." + - label: "Make sure that holiday schedule was deleted" PICS: DRLK.S.F0b && DRLK.S.C12.Rsp && DRLK.S.C12.Tx - verification: | - ./chip-tool doorlock get-holiday-schedule 1 1 1 - Verify " DUT sends a NOT_FOUND status" on the TH(Chip-tool) Log: - - [1658472025.923305][2560:2565] CHIP:DMG: }, - [1658472025.923366][2560:2565] CHIP:DMG: Received Command Response Data, Endpoint=1 Cluster=0x0000_0101 Command=0x0000_0012 - [1658472025.923417][2560:2565] CHIP:TOO: Endpoint: 1 Cluster: 0x0000_0101 Command 0x0000_0012 - [1658472025.923491][2560:2565] CHIP:TOO: GetHolidayScheduleResponse: { - [1658472025.923528][2560:2565] CHIP:TOO: holidayIndex: 1 - [1658472025.923565][2560:2565] CHIP:TOO: status: 139 - [1658472025.923590][2560:2565] CHIP:TOO: } - disabled: true + command: "GetHolidaySchedule" + arguments: + values: + - name: "holidayIndex" + value: 1 + response: + values: + - name: "holidayIndex" + value: 1 + - name: "status" + value: 139 + + - label: "Cleanup the created user" + command: "ClearUser" + timedInteractionTimeoutMs: 10000 + arguments: + values: + - name: "userIndex" + value: 1 diff --git a/src/app/tests/suites/certification/Test_TC_TSTAT_2_1.yaml b/src/app/tests/suites/certification/Test_TC_TSTAT_2_1.yaml index 01bfc0f3e0d651..3650f474548981 100644 --- a/src/app/tests/suites/certification/Test_TC_TSTAT_2_1.yaml +++ b/src/app/tests/suites/certification/Test_TC_TSTAT_2_1.yaml @@ -541,7 +541,7 @@ tests: attribute: "SetpointChangeSourceTimestamp" response: constraints: - type: utc + type: epoch_s - label: "Read OccupiedSetback attribute from the DUT" PICS: TSTAT.S.F02 diff --git a/src/app/tests/suites/certification/Test_TC_WAKEONLAN_4_1.yaml b/src/app/tests/suites/certification/Test_TC_WAKEONLAN_4_1.yaml index 3ad64bad5263c0..ade30fa0aa5996 100644 --- a/src/app/tests/suites/certification/Test_TC_WAKEONLAN_4_1.yaml +++ b/src/app/tests/suites/certification/Test_TC_WAKEONLAN_4_1.yaml @@ -20,62 +20,32 @@ PICS: config: nodeId: 0x12344321 - cluster: "Basic" - endpoint: 0 + cluster: "Wake on LAN" + endpoint: 1 tests: + - label: "Wait for the commissioned device to be retrieved" + cluster: "DelayCommands" + command: "WaitForCommissionee" + arguments: + values: + - name: "nodeId" + value: nodeId + - label: "TH reads the MACAddress attribute from the DUT" PICS: WAKEONLAN.S.A0000 - verification: | - The TH commands for this test step can be invoked using chip-tool (when DUT is a commissionee) or tv-casting-app (when DUT is a commissioner): - ./chip-tool wakeonlan read macaddress 1 1 - ./chip-tv-casting-app wakeonlan read macaddress 1 1 - - On TH Verify that the response contains a 48-bit MAC Address. Record the MAC address. - [1654248817.394846][3637:3643] CHIP:TOO: Endpoint: 1 Cluster: 0x0000_0503 Attribute 0x0000_0000 DataVersion: 3900236652 - [1654248817.394895][3637:3643] CHIP:TOO: MACAddress: e4:5f:01:69:61:b1 - [1654248817.394982][3637:3643] CHIP:EM: Sending Standalone Ack for MessageCounter:15292555 on exchange 12123i - disabled: true + command: "readAttribute" + attribute: "MACAddress" + response: + constraints: + minLength: 12 - label: "TH sends a Sleep command to DUT" PICS: LOWPOWER.S.C00.Rsp - verification: | - The TH commands for this test step can be invoked using chip-tool (when DUT is a commissionee) or tv-casting-app (when DUT is a commissioner): - ./chip-tool lowpower sleep 1 1 - ./chip-tv-casting-app lowpower sleep 1 1 - - On TH verify the success response received from DUT - [1646101689.826629][3009:3014] CHIP:DMG: InvokeResponseMessage = - [1646101689.826665][3009:3014] CHIP:DMG: { - [1646101689.826697][3009:3014] CHIP:DMG: suppressResponse = false, - [1646101689.826727][3009:3014] CHIP:DMG: InvokeResponseIBs = - [1646101689.826769][3009:3014] CHIP:DMG: [ - [1646101689.826804][3009:3014] CHIP:DMG: InvokeResponseIB = - [1646101689.826848][3009:3014] CHIP:DMG: { - [1646101689.826882][3009:3014] CHIP:DMG: CommandStatusIB = - [1646101689.826922][3009:3014] CHIP:DMG: { - [1646101689.826954][3009:3014] CHIP:DMG: CommandPathIB = - [1646101689.826989][3009:3014] CHIP:DMG: { - [1646101689.827031][3009:3014] CHIP:DMG: EndpointId = 0x1, - [1646101689.827082][3009:3014] CHIP:DMG: ClusterId = 0x508, - [1646101689.827127][3009:3014] CHIP:DMG: CommandId = 0x0, - [1646101689.827172][3009:3014] CHIP:DMG: }, - [1646101689.827223][3009:3014] CHIP:DMG: - [1646101689.827260][3009:3014] CHIP:DMG: StatusIB = - [1646101689.827311][3009:3014] CHIP:DMG: { - [1646101689.827360][3009:3014] CHIP:DMG: status = 0x0, - [1646101689.827411][3009:3014] CHIP:DMG: }, - [1646101689.827457][3009:3014] CHIP:DMG: - [1646101689.827498][3009:3014] CHIP:DMG: }, - [1646101689.827540][3009:3014] CHIP:DMG: - [1646101689.827607][3009:3014] CHIP:DMG: }, - [1646101689.827658][3009:3014] CHIP:DMG: - [1646101689.827689][3009:3014] CHIP:DMG: ], - [1646101689.827730][3009:3014] CHIP:DMG: - [1646101689.827761][3009:3014] CHIP:DMG: InteractionModelRevision = 1 - [1646101689.827792][3009:3014] CHIP:DMG: }, - [1646101689.827875][3009:3014] CHIP:DMG: Received Command Response Status for Endpoint=1 Cluster=0x0000_0508 Command=0x0000_0000 Status=0x0 - disabled: true + cluster: "Low Power" + command: "Sleep" + response: + error: 0 - label: "TH sends a Wake-On LAN magic packet containing the MAC address from @@ -90,4 +60,12 @@ tests: [1654248854.491994][3652:3657] CHIP:TOO: AcceptedCommandList: 1 entries [1654248854.492040][3652:3657] CHIP:TOO: [1]: 0 [1654248854.492157][3652:3657] CHIP:EM: Sending Standalone Ack for MessageCounter:15063522 on exchange 51389i - disabled: true + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: "Please enter 'y' after success" + - name: "expectedValue" + value: "y" diff --git a/src/app/tests/suites/certification/ci-pics-values b/src/app/tests/suites/certification/ci-pics-values index f7ea6ee0e55372..5c616c535dd52d 100644 --- a/src/app/tests/suites/certification/ci-pics-values +++ b/src/app/tests/suites/certification/ci-pics-values @@ -1033,8 +1033,8 @@ DGTHREAD.S.A0036=1 DGTHREAD.S.A0037=1 DGTHREAD.S.A0038=1 DGTHREAD.S.A0039=1 -DGTHREAD.S.A003A=1 -DGTHREAD.S.A003B=1 +DGTHREAD.S.A003a=1 +DGTHREAD.S.A003b=1 DGTHREAD.S.A003c=1 DGTHREAD.S.A003d=1 DGTHREAD.S.A003e=1 @@ -1358,6 +1358,11 @@ CNET.S.A0005=1 CNET.S.A0006=1 CNET.S.A0007=1 +#Features +CNET.S.F00=0 +CNET.S.F01=0 +CNET.S.F02=1 + #Server Commands CNET.S.C00.Rsp=1 CNET.S.C01.Tx=1 @@ -1573,26 +1578,26 @@ MCORE.SC.ADV=1 #Bridged Device Basic Information #server -BRBINFO.S.A0000=1 -BRBINFO.S.A0001=1 -BRBINFO.S.A0002=1 -BRBINFO.S.A0003=1 -BRBINFO.S.A0004=1 +BRBINFO.S.A0000=0 +BRBINFO.S.A0001=0 +BRBINFO.S.A0002=0 +BRBINFO.S.A0003=0 +BRBINFO.S.A0004=0 BRBINFO.S.A0005=1 -BRBINFO.S.A0006=1 -BRBINFO.S.A0007=1 -BRBINFO.S.A0008=1 -BRBINFO.S.A0009=1 -BRBINFO.S.A000a=1 -BRBINFO.S.A000b=1 -BRBINFO.S.A000c=1 -BRBINFO.S.A000d=1 -BRBINFO.S.A000e=1 -BRBINFO.S.A000f=1 -BRBINFO.S.A0010=1 +BRBINFO.S.A0006=0 +BRBINFO.S.A0007=0 +BRBINFO.S.A0008=0 +BRBINFO.S.A0009=0 +BRBINFO.S.A000a=0 +BRBINFO.S.A000b=0 +BRBINFO.S.A000c=0 +BRBINFO.S.A000d=0 +BRBINFO.S.A000e=0 +BRBINFO.S.A000f=0 +BRBINFO.S.A0010=0 BRBINFO.S.A0011=1 -BRBINFO.S.A0012=1 -BRBINFO.S.A0013=1 +BRBINFO.S.A0012=0 +BRBINFO.S.A0013=0 #Events BRBINFO.S.E00=1 diff --git a/src/app/tests/suites/ciTests.json b/src/app/tests/suites/ciTests.json index 58a3bd5145cb3c..8e02636bd76894 100644 --- a/src/app/tests/suites/ciTests.json +++ b/src/app/tests/suites/ciTests.json @@ -3,10 +3,15 @@ "TestAccessControlCluster", "Test_TC_ACL_1_1", "Test_TC_ACL_2_1", - "Test_TC_ACL_2_2" + "Test_TC_ACL_2_2", + "Test_TC_ACL_2_3" ], "BooleanState": ["Test_TC_BOOL_1_1", "Test_TC_BOOL_2_1"], "Binding": ["Test_TC_BIND_1_1"], + "BridgedDeviceBasicInformation": [ + "Test_TC_BRBINFO_1_1", + "Test_TC_BRBINFO_2_1" + ], "Actions": ["Test_TC_ACT_1_1"], "ColorControl": [ "Test_TC_CC_1_1", @@ -90,6 +95,7 @@ "Test_TC_APBSC_1_10", "Test_TC_CONTENTLAUNCHER_1_11", "Test_TC_ALOGIN_1_12", + "Test_TC_ALOGIN_12_1", "Test_TC_LOWPOWER_2_1", "Test_TC_KEYPADINPUT_3_2", "Test_TC_KEYPADINPUT_3_3", @@ -102,6 +108,7 @@ "Test_TC_MEDIAINPUT_3_11", "Test_TC_MEDIAINPUT_3_12", "Test_TC_MEDIAINPUT_3_13", + "Test_TC_WAKEONLAN_4_1", "Test_TC_CHANNEL_5_1", "Test_TC_CHANNEL_5_2", "Test_TC_CHANNEL_5_3", @@ -240,6 +247,7 @@ "Test_TC_DRLK_2_3", "Test_TC_DRLK_2_4", "Test_TC_DRLK_2_5", + "Test_TC_DRLK_2_6", "Test_TC_DRLK_2_7", "Test_TC_DRLK_2_9" ], @@ -253,6 +261,7 @@ "collection": [ "AccessControl", "BooleanState", + "BridgedDeviceBasicInformation", "Actions", "Binding", "ColorControl", diff --git a/src/app/tests/suites/manualTests.json b/src/app/tests/suites/manualTests.json index fb755f1f72b12e..1835bb8cf21eac 100644 --- a/src/app/tests/suites/manualTests.json +++ b/src/app/tests/suites/manualTests.json @@ -137,7 +137,6 @@ "Test_TC_MEDIAINPUT_3_15", "Test_TC_MEDIAINPUT_3_16", "Test_TC_MEDIAINPUT_3_17", - "Test_TC_WAKEONLAN_4_1", "Test_TC_CHANNEL_5_4", "Test_TC_CHANNEL_5_5", "Test_TC_CHANNEL_5_6", @@ -152,7 +151,6 @@ "Test_TC_CONTENTLAUNCHER_10_7", "Test_TC_MC_11_1", "Test_TC_MC_11_2", - "Test_TC_ALOGIN_12_1", "Test_TC_ALOGIN_12_2" ], "MultipleFabrics": [ @@ -277,7 +275,6 @@ ], "DoorLock": [ "Test_TC_DRLK_2_1", - "Test_TC_DRLK_2_6", "Test_TC_DRLK_2_8", "Test_TC_DRLK_2_10", "Test_TC_DRLK_3_1", @@ -327,7 +324,6 @@ ], "PumpConfigurationControl": ["Test_TC_PCC_3_1"], "AccessControl": [ - "Test_TC_ACL_2_3", "Test_TC_ACL_2_4", "Test_TC_ACL_2_5", "Test_TC_ACL_2_6", @@ -338,8 +334,6 @@ ], "UserLabel": ["Test_TC_ULABEL_3_1"], "BridgedDeviceBasicInformation": [ - "Test_TC_BRBINFO_1_1", - "Test_TC_BRBINFO_2_1", "Test_TC_BRBINFO_2_2", "Test_TC_BRBINFO_2_3" ], diff --git a/src/app/util/af-enums.h b/src/app/util/af-enums.h index 6bcf85cd189999..646ea32c5565d7 100644 --- a/src/app/util/af-enums.h +++ b/src/app/util/af-enums.h @@ -28,7 +28,6 @@ enum EmberAfStatus : uint8_t EMBER_ZCL_STATUS_FAILURE = 0x01, EMBER_ZCL_STATUS_INVALID_SUBSCRIPTION = 0x7D, EMBER_ZCL_STATUS_UNSUPPORTED_ACCESS = 0x7E, - EMBER_ZCL_STATUS_NOT_AUTHORIZED = 0x7E, // Deprecated; same as UNSUPPORTED_ACCESS EMBER_ZCL_STATUS_UNSUPPORTED_ENDPOINT = 0x7F, EMBER_ZCL_STATUS_MALFORMED_COMMAND = 0x80, EMBER_ZCL_STATUS_UNSUPPORTED_COMMAND = 0x81, @@ -36,14 +35,10 @@ enum EmberAfStatus : uint8_t EMBER_ZCL_STATUS_DEPRECATED83 = 0x83, EMBER_ZCL_STATUS_DEPRECATED84 = 0x84, EMBER_ZCL_STATUS_INVALID_COMMAND = 0x85, - EMBER_ZCL_STATUS_INVALID_FIELD = 0x85, // Deprecated; same as INVALID_COMMAND EMBER_ZCL_STATUS_UNSUPPORTED_ATTRIBUTE = 0x86, EMBER_ZCL_STATUS_CONSTRAINT_ERROR = 0x87, - EMBER_ZCL_STATUS_INVALID_VALUE = 0x87, // Deprecated; same as CONSTRAINT_ERROR EMBER_ZCL_STATUS_UNSUPPORTED_WRITE = 0x88, - EMBER_ZCL_STATUS_READ_ONLY = 0x88, // Deprecated; same as UNSUPPORTED_WRITE EMBER_ZCL_STATUS_RESOURCE_EXHAUSTED = 0x89, - EMBER_ZCL_STATUS_INSUFFICIENT_SPACE = 0x89, // Deprecated; same as RESOURCE_EXHAUSTED EMBER_ZCL_STATUS_DUPLICATE_EXISTS = 0x8A, EMBER_ZCL_STATUS_NOT_FOUND = 0x8B, EMBER_ZCL_STATUS_UNREPORTABLE_ATTRIBUTE = 0x8C, diff --git a/src/app/util/af-event.cpp b/src/app/util/af-event.cpp index 6e381149c083b8..cdc780b8e5a5d3 100644 --- a/src/app/util/af-event.cpp +++ b/src/app/util/af-event.cpp @@ -37,7 +37,7 @@ struct EmberEventData /** The control structure for the event. */ EmberEventControl * control; /** The procedure to call when the event fires. */ - void (*handler)(void); + void (*handler)(); }; // ***************************************************************************** diff --git a/src/app/util/af.h b/src/app/util/af.h index 043c5e80ebe5bb..9c9bad4b3f1345 100644 --- a/src/app/util/af.h +++ b/src/app/util/af.h @@ -303,16 +303,6 @@ void emberAfCopyLongString(uint8_t * dest, const uint8_t * src, size_t size); */ bool emberAfIsDeviceIdentifying(chip::EndpointId endpoint); -/** - * @brief Function that enables or disables an endpoint. - * - * By calling this function, you turn off all processing of incoming traffic - * for a given endpoint. - * - * @param endpoint Zigbee endpoint number - */ -void emberAfSetDeviceEnabled(chip::EndpointId endpoint, bool enabled); - /** @} END Device Control */ /** @name Miscellaneous */ diff --git a/src/app/util/attribute-storage.cpp b/src/app/util/attribute-storage.cpp index 7eab17cdef45ea..e30b990546b62d 100644 --- a/src/app/util/attribute-storage.cpp +++ b/src/app/util/attribute-storage.cpp @@ -110,7 +110,7 @@ static uint16_t findClusterEndpointIndex(EndpointId endpoint, ClusterId clusterI //------------------------------------------------------------------------------ // Initial configuration -void emberAfEndpointConfigure(void) +void emberAfEndpointConfigure() { uint16_t ep; @@ -197,7 +197,7 @@ EmberAfStatus emberAfSetDynamicEndpoint(uint16_t index, EndpointId id, const Emb if (realIndex >= MAX_ENDPOINT_COUNT) { - return EMBER_ZCL_STATUS_INSUFFICIENT_SPACE; + return EMBER_ZCL_STATUS_RESOURCE_EXHAUSTED; } if (id == kInvalidEndpointId) { @@ -207,7 +207,7 @@ EmberAfStatus emberAfSetDynamicEndpoint(uint16_t index, EndpointId id, const Emb auto serverClusterCount = emberAfClusterCountForEndpointType(ep, /* server = */ true); if (dataVersionStorage.size() < serverClusterCount) { - return EMBER_ZCL_STATUS_INSUFFICIENT_SPACE; + return EMBER_ZCL_STATUS_RESOURCE_EXHAUSTED; } index = static_cast(realIndex); @@ -242,7 +242,6 @@ EmberAfStatus emberAfSetDynamicEndpoint(uint16_t index, EndpointId id, const Emb // Now enable the endpoint. emberAfEndpointEnableDisable(id, true); - emberAfSetDeviceEnabled(id, true); return EMBER_ZCL_STATUS_SUCCESS; } @@ -257,7 +256,6 @@ EndpointId emberAfClearDynamicEndpoint(uint16_t index) (emberAfEndpointIndexIsEnabled(index))) { ep = emAfEndpoints[index].endpoint; - emberAfSetDeviceEnabled(ep, false); emberAfEndpointEnableDisable(ep, false); emAfEndpoints[index].endpoint = kInvalidEndpointId; } @@ -265,12 +263,12 @@ EndpointId emberAfClearDynamicEndpoint(uint16_t index) return ep; } -uint16_t emberAfFixedEndpointCount(void) +uint16_t emberAfFixedEndpointCount() { return FIXED_ENDPOINT_COUNT; } -uint16_t emberAfEndpointCount(void) +uint16_t emberAfEndpointCount() { return emberEndpointCount; } @@ -357,7 +355,7 @@ static void initializeEndpoint(EmberAfDefinedEndpoint * definedEndpoint) } // Calls the init functions. -void emAfCallInits(void) +void emAfCallInits() { uint16_t index; for (index = 0; index < emberAfEndpointCount(); index++) @@ -417,7 +415,7 @@ static EmberAfStatus typeSensitiveMemCopy(ClusterId clusterId, uint8_t * dest, u { if (bufferSize < 1) { - return EMBER_ZCL_STATUS_INSUFFICIENT_SPACE; + return EMBER_ZCL_STATUS_RESOURCE_EXHAUSTED; } emberAfCopyString(dest, src, bufferSize - 1); } @@ -425,7 +423,7 @@ static EmberAfStatus typeSensitiveMemCopy(ClusterId clusterId, uint8_t * dest, u { if (bufferSize < 2) { - return EMBER_ZCL_STATUS_INSUFFICIENT_SPACE; + return EMBER_ZCL_STATUS_RESOURCE_EXHAUSTED; } emberAfCopyLongString(dest, src, bufferSize - 2); } @@ -433,7 +431,7 @@ static EmberAfStatus typeSensitiveMemCopy(ClusterId clusterId, uint8_t * dest, u { if (bufferSize < 2) { - return EMBER_ZCL_STATUS_INSUFFICIENT_SPACE; + return EMBER_ZCL_STATUS_RESOURCE_EXHAUSTED; } // Just copy the length. @@ -443,7 +441,7 @@ static EmberAfStatus typeSensitiveMemCopy(ClusterId clusterId, uint8_t * dest, u { if (!ignoreReadLength && readLength < am->size) { - return EMBER_ZCL_STATUS_INSUFFICIENT_SPACE; + return EMBER_ZCL_STATUS_RESOURCE_EXHAUSTED; } if (src == nullptr) { @@ -547,7 +545,7 @@ EmberAfStatus emAfReadOrWriteAttribute(EmberAfAttributeSearchRecord * attRecord, if (!emberAfAttributeWriteAccessCallback(attRecord->endpoint, attRecord->clusterId, am->attributeId)) { - return EMBER_ZCL_STATUS_NOT_AUTHORIZED; + return EMBER_ZCL_STATUS_UNSUPPORTED_ACCESS; } } else @@ -562,7 +560,7 @@ EmberAfStatus emAfReadOrWriteAttribute(EmberAfAttributeSearchRecord * attRecord, if (!emberAfAttributeReadAccessCallback(attRecord->endpoint, attRecord->clusterId, am->attributeId)) { - return EMBER_ZCL_STATUS_NOT_AUTHORIZED; + return EMBER_ZCL_STATUS_UNSUPPORTED_ACCESS; } } diff --git a/src/app/util/attribute-table.cpp b/src/app/util/attribute-table.cpp index 57128f16b2b09c..4012932b2dc381 100644 --- a/src/app/util/attribute-table.cpp +++ b/src/app/util/attribute-table.cpp @@ -85,7 +85,7 @@ static void emberAfAttributeDecodeAndPrintCluster(ClusterId cluster) #endif // defined(EMBER_AF_PRINT_ENABLE) && defined(EMBER_AF_PRINT_ATTRIBUTES) } -void emberAfPrintAttributeTable(void) +void emberAfPrintAttributeTable() { uint8_t data[ATTRIBUTE_LARGEST]; decltype(emberAfEndpointCount()) endpointIndex; @@ -216,8 +216,8 @@ static bool IsNullValue(const uint8_t * data, uint16_t dataLen, bool isAttribute // device is not found in the attribute table) // - EMBER_ZCL_STATUS_INVALID_DATA_TYPE: if the data type passed in doesnt match the type // stored in the attribute table -// - EMBER_ZCL_STATUS_READ_ONLY: if the attribute isnt writable -// - EMBER_ZCL_STATUS_INVALID_VALUE: if the value is set out of the allowable range for +// - EMBER_ZCL_STATUS_UNSUPPORTED_WRITE: if the attribute isnt writable +// - EMBER_ZCL_STATUS_CONSTRAINT_ERROR: if the value is set out of the allowable range for // the attribute // - EMBER_ZCL_STATUS_SUCCESS: if the attribute was found and successfully written // @@ -267,12 +267,12 @@ EmberAfStatus emAfWriteAttribute(EndpointId endpoint, ClusterId cluster, Attribu { emberAfAttributesPrintln("%pattr not writable", "WRITE ERR: "); emberAfAttributesFlush(); - return EMBER_ZCL_STATUS_READ_ONLY; + return EMBER_ZCL_STATUS_UNSUPPORTED_WRITE; } } // if the value the attribute is being set to is out of range - // return EMBER_ZCL_STATUS_INVALID_VALUE + // return EMBER_ZCL_STATUS_CONSTRAINT_ERROR if ((metadata->mask & ATTRIBUTE_MASK_MIN_MAX) != 0U) { EmberAfDefaultAttributeValue minv = metadata->defaultValue.ptrToMinMaxValue->minValue; @@ -309,7 +309,7 @@ EmberAfStatus emAfWriteAttribute(EndpointId endpoint, ClusterId cluster, Attribu // null value is always in-range for a nullable attribute. (!metadata->IsNullable() || !IsNullValue(data, dataLen, isAttributeSigned))) { - return EMBER_ZCL_STATUS_INVALID_VALUE; + return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } } @@ -406,7 +406,7 @@ EmberAfStatus emAfReadAttribute(EndpointId endpoint, ClusterId cluster, Attribut } else { // failed, print debug info - if (status == EMBER_ZCL_STATUS_INSUFFICIENT_SPACE) + if (status == EMBER_ZCL_STATUS_RESOURCE_EXHAUSTED) { emberAfAttributesPrintln("READ: attribute size too large for caller"); emberAfAttributesFlush(); diff --git a/src/app/util/generic-callback-stubs.cpp b/src/app/util/generic-callback-stubs.cpp index 768ffb03871fea..ba8ee45b766ed5 100644 --- a/src/app/util/generic-callback-stubs.cpp +++ b/src/app/util/generic-callback-stubs.cpp @@ -16,7 +16,7 @@ */ #include -#include +#include #include #include diff --git a/src/app/util/generic-callbacks.h b/src/app/util/generic-callbacks.h index f690732081cc44..0da0b07d17ca80 100644 --- a/src/app/util/generic-callbacks.h +++ b/src/app/util/generic-callbacks.h @@ -110,7 +110,7 @@ bool emberAfAttributeWriteAccessCallback(chip::EndpointId endpoint, chip::Cluste * value of EMBER_ZCL_STATUS_SUCCESS. Ensure that the size of the externally * managed attribute value is smaller than what the buffer can hold. In the case * of a buffer overflow throw an appropriate error such as - * EMBER_ZCL_STATUS_INSUFFICIENT_SPACE. Any other return value indicates the + * EMBER_ZCL_STATUS_RESOURCE_EXHAUSTED. Any other return value indicates the * application was not able to read the attribute. */ EmberAfStatus emberAfExternalAttributeReadCallback(chip::EndpointId endpoint, chip::ClusterId clusterId, diff --git a/src/app/util/message.cpp b/src/app/util/message.cpp index 86175ca4f2006a..5c69f621a5db74 100644 --- a/src/app/util/message.cpp +++ b/src/app/util/message.cpp @@ -44,7 +44,7 @@ static uint8_t * zeroLenBytePtr = (uint8_t *) &zeroLenByte; // Utilities for adding bytes to the response buffer: appResponseData. These // functions take care of incrementing appResponseLength. -void emberAfClearResponseData(void) +void emberAfClearResponseData() { emberAfResponseType = ZCL_UTIL_RESP_NORMAL; // To prevent accidentally sending to someone else, diff --git a/src/app/util/mock/attribute-storage.cpp b/src/app/util/mock/attribute-storage.cpp index d4a9cddace1bb2..1276db759fc37b 100644 --- a/src/app/util/mock/attribute-storage.cpp +++ b/src/app/util/mock/attribute-storage.cpp @@ -96,7 +96,7 @@ uint8_t mockAttribute4[256] = { } // namespace -uint16_t emberAfEndpointCount(void) +uint16_t emberAfEndpointCount() { return ArraySize(endpoints); } diff --git a/src/app/util/types_stub.h b/src/app/util/types_stub.h index 56f15a23efedb4..b0b4aa875ed0c2 100644 --- a/src/app/util/types_stub.h +++ b/src/app/util/types_stub.h @@ -451,8 +451,6 @@ enum */ struct EmberBindingTableEntry { - EmberBindingTableEntry() = default; - static EmberBindingTableEntry ForNode(chip::FabricIndex fabric, chip::NodeId node, chip::EndpointId localEndpoint, chip::EndpointId remoteEndpoint, chip::Optional cluster) { diff --git a/src/app/util/util.cpp b/src/app/util/util.cpp index a9dcb7a735eac1..1115b776d5f2e8 100644 --- a/src/app/util/util.cpp +++ b/src/app/util/util.cpp @@ -18,8 +18,8 @@ #include "app/util/common.h" #include #include -#include #include +#include #include #include #include @@ -41,9 +41,6 @@ using namespace chip; //------------------------------------------------------------------------------ // Globals -// Storage and functions for turning on and off devices -bool afDeviceEnabled[MAX_ENDPOINT_COUNT]; - #ifdef EMBER_AF_ENABLE_STATISTICS // a variable containing the number of messages send from the utilities // since emberAfInit was called. @@ -51,8 +48,8 @@ uint32_t afNumPktsSent; #endif const EmberAfClusterName zclClusterNames[] = { - CLUSTER_IDS_TO_NAMES // defined in print-cluster.h - { ZCL_NULL_CLUSTER_ID, nullptr }, // terminator + CLUSTER_IDS_TO_NAMES // defined in print-cluster.h + { kInvalidClusterId, nullptr }, // terminator }; // A pointer to the current command being processed @@ -83,27 +80,12 @@ EMBER_AF_GENERATED_PLUGIN_TICK_FUNCTION_DECLARATIONS //------------------------------------------------------------------------------ -// Device enabled/disabled functions - -void emberAfSetDeviceEnabled(EndpointId endpoint, bool enabled) -{ - uint16_t index = emberAfIndexFromEndpoint(endpoint); - if (index != 0xFFFF && index < sizeof(afDeviceEnabled)) - { - afDeviceEnabled[index] = enabled; - } -#ifdef ZCL_USING_BASIC_CLUSTER_DEVICE_ENABLED_ATTRIBUTE - emberAfWriteServerAttribute(endpoint, ZCL_BASIC_CLUSTER_ID, ZCL_DEVICE_ENABLED_ATTRIBUTE_ID, (uint8_t *) &enabled, - ZCL_BOOLEAN_ATTRIBUTE_TYPE); -#endif -} - // Is the device identifying? bool emberAfIsDeviceIdentifying(EndpointId endpoint) { #ifdef ZCL_USING_IDENTIFY_CLUSTER_SERVER uint16_t identifyTime; - EmberAfStatus status = emberAfReadServerAttribute(endpoint, ZCL_IDENTIFY_CLUSTER_ID, ZCL_IDENTIFY_TIME_ATTRIBUTE_ID, + EmberAfStatus status = emberAfReadServerAttribute(endpoint, app::Clusters::Identify::Id, ZCL_IDENTIFY_TIME_ATTRIBUTE_ID, (uint8_t *) &identifyTime, sizeof(identifyTime)); return (status == EMBER_ZCL_STATUS_SUCCESS && 0 < identifyTime); #else @@ -167,14 +149,12 @@ void emberAfInit(chip::Messaging::ExchangeManager * exchangeMgr) // emberAfPopNetworkIndex(); } - memset(afDeviceEnabled, true, emberAfEndpointCount()); - MATTER_PLUGINS_INIT emAfCallInits(); } -void emberAfTick(void) +void emberAfTick() { // Call the AFV2-specific per-endpoint callbacks // Anything that defines callbacks as void *TickCallback(void) is called in @@ -217,7 +197,7 @@ void MatterFanControlPluginServerInitCallback() {} // such as after a leave network. This allows zcl utils to clear state // that should not be kept when changing networks // **************************************** -void emberAfStackDown(void) +void emberAfStackDown() { emberAfRegistrationAbortCallback(); } @@ -230,7 +210,7 @@ uint16_t emberAfFindClusterNameIndex(ClusterId cluster) { static_assert(sizeof(ClusterId) == 4, "May need to adjust our index type or somehow define it in terms of cluster id type"); uint16_t index = 0; - while (zclClusterNames[index].id != ZCL_NULL_CLUSTER_ID) + while (zclClusterNames[index].id != kInvalidClusterId) { if (zclClusterNames[index].id == cluster) { @@ -264,7 +244,7 @@ void emberAfDecodeAndPrintCluster(ClusterId cluster) // If it is invalid, we just return the // EMBER_AF_NULL_MANUFACTURER_CODE, which we tend to use // for references to the standard library. -uint16_t emberAfGetMfgCodeFromCurrentCommand(void) +uint16_t emberAfGetMfgCodeFromCurrentCommand() { if (emberAfCurrentCommand() != nullptr) { @@ -296,7 +276,7 @@ void emberAfSetRetryOverride(EmberAfRetryOverride value) emberAfApsRetryOverride = value; } -EmberAfRetryOverride emberAfGetRetryOverride(void) +EmberAfRetryOverride emberAfGetRetryOverride() { return (EmberAfRetryOverride) emberAfApsRetryOverride; } @@ -330,7 +310,7 @@ void emberAfSetDisableDefaultResponse(EmberAfDisableDefaultResponse value) } } -EmberAfDisableDefaultResponse emberAfGetDisableDefaultResponse(void) +EmberAfDisableDefaultResponse emberAfGetDisableDefaultResponse() { return (EmberAfDisableDefaultResponse) emAfDisableDefaultResponse; } diff --git a/src/app/util/util.h b/src/app/util/util.h index 54a2a224a2b1bd..0949aea7afef9b 100644 --- a/src/app/util/util.h +++ b/src/app/util/util.h @@ -50,8 +50,6 @@ typedef struct extern const EmberAfClusterName zclClusterNames[]; -#define ZCL_NULL_CLUSTER_ID 0xFFFF - #include // Override APS retry: 0 - don't touch, 1 - always set, 2 - always unset diff --git a/src/app/zap-templates/templates/app/MatterIDL.zapt b/src/app/zap-templates/templates/app/MatterIDL.zapt index f7d77fec087a1c..5092a6b252102c 100644 --- a/src/app/zap-templates/templates/app/MatterIDL.zapt +++ b/src/app/zap-templates/templates/app/MatterIDL.zapt @@ -117,7 +117,7 @@ {{#user_endpoints}} endpoint {{endpointId}} { {{#if deviceIdentifier}} - device type {{chip_friendly_endpoint_type_name}} = {{deviceIdentifier}}; + device type {{chip_friendly_endpoint_type_name}} = {{deviceIdentifier}}, version {{endpointVersion}}; {{/if~}} {{#user_clusters}} diff --git a/src/app/zap-templates/templates/app/print-cluster.zapt b/src/app/zap-templates/templates/app/print-cluster.zapt index c5d56577a31228..3d1a17d764d224 100644 --- a/src/app/zap-templates/templates/app/print-cluster.zapt +++ b/src/app/zap-templates/templates/app/print-cluster.zapt @@ -3,13 +3,15 @@ // Prevent multiple inclusion #pragma once +#include + // This is the mapping of IDs to cluster names assuming a format according // to the "EmberAfClusterName" defined in the ZCL header. // The names of clusters that are not present, are removed. {{#zcl_clusters}} #if defined(ZCL_USING_{{asDelimitedMacro this.define}}_SERVER) || defined(ZCL_USING_{{asDelimitedMacro this.define}}_CLIENT) - #define CHIP_PRINTCLUSTER_{{asDelimitedMacro this.define}} {ZCL_{{asDelimitedMacro this.define}}_ID, "{{this.label}}" }, + #define CHIP_PRINTCLUSTER_{{asDelimitedMacro this.define}} { chip::app::Clusters::{{asUpperCamelCase this.label}}::Id, "{{this.label}}" }, #else #define CHIP_PRINTCLUSTER_{{asDelimitedMacro this.define}} #endif diff --git a/src/app/zap-templates/zcl/data-model/all.xml b/src/app/zap-templates/zcl/data-model/all.xml index c050af49dcafa5..9126b0ff26101a 100644 --- a/src/app/zap-templates/zcl/data-model/all.xml +++ b/src/app/zap-templates/zcl/data-model/all.xml @@ -13,6 +13,7 @@ + diff --git a/src/app/zap-templates/zcl/data-model/chip/chip-types.xml b/src/app/zap-templates/zcl/data-model/chip/chip-types.xml index e5e3e3859bf53d..95123673d405fb 100644 --- a/src/app/zap-templates/zcl/data-model/chip/chip-types.xml +++ b/src/app/zap-templates/zcl/data-model/chip/chip-types.xml @@ -53,7 +53,6 @@ limitations under the License. - diff --git a/src/app/zap-templates/zcl/data-model/chip/client-monitoring-cluster.xml b/src/app/zap-templates/zcl/data-model/chip/client-monitoring-cluster.xml new file mode 100644 index 00000000000000..9dc128947904c5 --- /dev/null +++ b/src/app/zap-templates/zcl/data-model/chip/client-monitoring-cluster.xml @@ -0,0 +1,52 @@ + + + + + + + + + + + + + + General + Client Monitoring + 0x1046 + CLIENT_MONITORING_CLUSTER + Client Monitoring allows for ensuring that listed clients meet the required monitoring conditions on the server. + IdleModeInterval + ActiveModeInterval + ActiveModeThreshold + + + ExpectedClients + + + Register a client to the end device + + + + + + + Request the end device to stay in Active Mode for an additional ActiveModeThreshold + + + + diff --git a/src/app/zap-templates/zcl/data-model/chip/group-key-mgmt-cluster.xml b/src/app/zap-templates/zcl/data-model/chip/group-key-mgmt-cluster.xml index 5addebd25e05cf..26f58bf58b92d2 100644 --- a/src/app/zap-templates/zcl/data-model/chip/group-key-mgmt-cluster.xml +++ b/src/app/zap-templates/zcl/data-model/chip/group-key-mgmt-cluster.xml @@ -64,13 +64,13 @@ limitations under the License. MaxGroupKeysPerFabric - Revoke a Root Key from a Group + Write a new set of keys for the given key set id. - Revoke a Root Key from a Group + Read the keys for a given key set id. diff --git a/src/app/zap-templates/zcl/data-model/chip/switch-cluster.xml b/src/app/zap-templates/zcl/data-model/chip/switch-cluster.xml index 512cf5b384d055..8bb770d56a291f 100644 --- a/src/app/zap-templates/zcl/data-model/chip/switch-cluster.xml +++ b/src/app/zap-templates/zcl/data-model/chip/switch-cluster.xml @@ -60,7 +60,7 @@ Interactions with the switch device are exposed as attributes (for the latching MultiPress Complete - + diff --git a/src/app/zap-templates/zcl/data-model/chip/thermostat-cluster.xml b/src/app/zap-templates/zcl/data-model/chip/thermostat-cluster.xml index 00d568567a8ddc..b1f0608e9f0be5 100644 --- a/src/app/zap-templates/zcl/data-model/chip/thermostat-cluster.xml +++ b/src/app/zap-templates/zcl/data-model/chip/thermostat-cluster.xml @@ -111,7 +111,7 @@ limitations under the License. ThermostatRunningState SetpointChangeSource SetpointChangeAmount - SetpointChangeSourceTimestamp + SetpointChangeSourceTimestamp OccupiedSetback diff --git a/src/app/zap-templates/zcl/zcl-with-test-extensions.json b/src/app/zap-templates/zcl/zcl-with-test-extensions.json index 241753199a7105..51f9acc0a93d58 100644 --- a/src/app/zap-templates/zcl/zcl-with-test-extensions.json +++ b/src/app/zap-templates/zcl/zcl-with-test-extensions.json @@ -25,6 +25,7 @@ "chip-ota.xml", "chip-types.xml", "channel-cluster.xml", + "client-monitoring-cluster.xml", "clusters-extensions.xml", "content-launch-cluster.xml", "descriptor-cluster.xml", diff --git a/src/app/zap-templates/zcl/zcl.json b/src/app/zap-templates/zcl/zcl.json index 801b04b57c0c94..52f482acb70847 100644 --- a/src/app/zap-templates/zcl/zcl.json +++ b/src/app/zap-templates/zcl/zcl.json @@ -20,6 +20,7 @@ "chip-ota.xml", "chip-types.xml", "channel-cluster.xml", + "client-monitoring-cluster.xml", "clusters-extensions.xml", "content-launch-cluster.xml", "descriptor-cluster.xml", diff --git a/src/app/zap_cluster_list.py b/src/app/zap_cluster_list.py index 11b3c21f05623b..1515eee90d2bad 100755 --- a/src/app/zap_cluster_list.py +++ b/src/app/zap_cluster_list.py @@ -25,6 +25,7 @@ 'ACTIONS_CLUSTER': [], 'BRIDGED_DEVICE_BASIC_CLUSTER': ['bridged-device-basic-information-server'], 'CHANNEL_CLUSTER': ['channel-server'], + 'CLIENT_MONITORING_CLUSTER': ['client-monitoring-server'], 'COLOR_CONTROL_CLUSTER': ['color-control-server'], 'COMMISSIONING_CLUSTER': [], 'CONTENT_LAUNCHER_CLUSTER': ['content-launch-server'], @@ -77,7 +78,7 @@ 'SWITCH_CLUSTER': ['switch-server'], 'TARGET_NAVIGATOR_CLUSTER': ['target-navigator-server'], 'TEMPERATURE_MEASUREMENT_CLUSTER': [], - 'TEST_CLUSTER': ['test-cluster-server'], + 'UNIT_TESTING_CLUSTER': ['test-cluster-server'], 'THERMOSTAT_CLUSTER': ['thermostat-server'], 'THERMOSTAT_USER_INTERFACE_CONFIGURATION_CLUSTER': ['thermostat-user-interface-configuration-server'], 'THREAD_NETWORK_DIAGNOSTICS_CLUSTER': ['thread-network-diagnostics-server'], @@ -110,6 +111,7 @@ 'ACTIONS_CLUSTER': [], 'BRIDGED_DEVICE_BASIC_CLUSTER': [], 'CHANNEL_CLUSTER': [], + 'CLIENT_MONITORING_CLUSTER': [], 'COLOR_CONTROL_CLUSTER': [], 'COMMISSIONING_CLUSTER': [], 'CONTENT_LAUNCHER_CLUSTER': [], @@ -162,7 +164,7 @@ 'SWITCH_CLUSTER': [], 'TARGET_NAVIGATOR_CLUSTER': [], 'TEMPERATURE_MEASUREMENT_CLUSTER': [], - 'TEST_CLUSTER': [], + 'UNIT_TESTING_CLUSTER': [], 'THERMOSTAT_CLUSTER': ['thermostat-client'], 'THERMOSTAT_USER_INTERFACE_CONFIGURATION_CLUSTER': [], 'THREAD_NETWORK_DIAGNOSTICS_CLUSTER': [], diff --git a/src/ble/BleLayer.cpp b/src/ble/BleLayer.cpp index 3b2db861743de8..b560e6dc511592 100644 --- a/src/ble/BleLayer.cpp +++ b/src/ble/BleLayer.cpp @@ -735,7 +735,7 @@ BleTransportProtocolVersion BleLayer::GetHighestSupportedProtocolVersion(const B shift_width ^= 4; uint8_t version = reqMsg.mSupportedProtocolVersions[(i / 2)]; - version = (version >> shift_width) & 0x0F; // Grab just the nibble we want. + version = static_cast((version >> shift_width) & 0x0F); // Grab just the nibble we want. if ((version >= CHIP_BLE_TRANSPORT_PROTOCOL_MIN_SUPPORTED_VERSION) && (version <= CHIP_BLE_TRANSPORT_PROTOCOL_MAX_SUPPORTED_VERSION) && (version > retVersion)) diff --git a/src/ble/CHIPBleServiceData.h b/src/ble/CHIPBleServiceData.h index c39a30ed8a72c1..965ae74307448b 100644 --- a/src/ble/CHIPBleServiceData.h +++ b/src/ble/CHIPBleServiceData.h @@ -94,8 +94,8 @@ struct ChipBLEDeviceIdentificationInfo void SetDeviceDiscriminator(uint16_t deviceDiscriminator) { // Discriminator is 12-bit long, so don't overwrite bits 12th through 15th - deviceDiscriminator &= kDiscriminatorMask; - deviceDiscriminator |= static_cast(DeviceDiscriminatorAndAdvVersion[1] << 8u & ~kDiscriminatorMask); + auto advVersion = static_cast(DeviceDiscriminatorAndAdvVersion[1] << 8u & ~kDiscriminatorMask); + deviceDiscriminator = static_cast(advVersion | (deviceDiscriminator & kDiscriminatorMask)); chip::Encoding::LittleEndian::Put16(DeviceDiscriminatorAndAdvVersion, deviceDiscriminator); } diff --git a/src/ble/tests/TestBleErrorStr.cpp b/src/ble/tests/TestBleErrorStr.cpp index c3005cc4c9cf29..9dc727a60347ee 100644 --- a/src/ble/tests/TestBleErrorStr.cpp +++ b/src/ble/tests/TestBleErrorStr.cpp @@ -113,7 +113,7 @@ static const nlTest sTests[] = }; // clang-format on -int TestBleErrorStr(void) +int TestBleErrorStr() { // clang-format off nlTestSuite theSuite = diff --git a/src/controller/AutoCommissioner.cpp b/src/controller/AutoCommissioner.cpp index 579d9c2d31dab1..982f62765bace6 100644 --- a/src/controller/AutoCommissioner.cpp +++ b/src/controller/AutoCommissioner.cpp @@ -109,7 +109,7 @@ CHIP_ERROR AutoCommissioner::SetCommissioningParameters(const CommissioningParam if (params.GetCountryCode().HasValue()) { - auto & code = params.GetCountryCode().Value(); + auto code = params.GetCountryCode().Value(); MutableCharSpan copiedCode(mCountryCode); if (CopyCharSpanToMutableCharSpan(code, copiedCode) == CHIP_NO_ERROR) { diff --git a/src/controller/SetUpCodePairer.cpp b/src/controller/SetUpCodePairer.cpp index 09ee3a012a4021..d9a372f3d025be 100644 --- a/src/controller/SetUpCodePairer.cpp +++ b/src/controller/SetUpCodePairer.cpp @@ -224,7 +224,7 @@ bool SetUpCodePairer::ConnectToDiscoveredDevice() // connection attempt fails and calls right back into us to try the next // thing. SetUpCodePairerParameters params(mDiscoveredParameters.front()); - mDiscoveredParameters.pop(); + mDiscoveredParameters.pop_front(); params.SetSetupPINCode(mSetUpPINCode); @@ -272,7 +272,7 @@ void SetUpCodePairer::OnDiscoveredDeviceOverBle(BLE_CONNECTION_OBJECT connObj) mWaitingForDiscovery[kBLETransport] = false; - mDiscoveredParameters.emplace(connObj); + mDiscoveredParameters.emplace_front(connObj); ConnectToDiscoveredDevice(); } @@ -341,7 +341,12 @@ void SetUpCodePairer::NotifyCommissionableDeviceDiscovered(const Dnssd::Discover ChipLogProgress(Controller, "Discovered device to be commissioned over DNS-SD"); - mDiscoveredParameters.emplace(nodeData.resolutionData); + auto & resolutionData = nodeData.resolutionData; + for (size_t i = 0; i < resolutionData.numIPs; i++) + { + mDiscoveredParameters.emplace_back(nodeData.resolutionData, i); + } + ConnectToDiscoveredDevice(); } @@ -394,7 +399,7 @@ void SetUpCodePairer::ResetDiscoveryState() while (!mDiscoveredParameters.empty()) { - mDiscoveredParameters.pop(); + mDiscoveredParameters.pop_front(); } mCurrentPASEParameters.ClearValue(); @@ -542,12 +547,12 @@ void SetUpCodePairer::OnDeviceDiscoveredTimeoutCallback(System::Layer * layer, v } } -SetUpCodePairerParameters::SetUpCodePairerParameters(const Dnssd::CommonResolutionData & data) +SetUpCodePairerParameters::SetUpCodePairerParameters(const Dnssd::CommonResolutionData & data, size_t index) { mInterfaceId = data.interfaceId; Platform::CopyString(mHostName, data.hostName); - auto & ip = data.ipAddress[0]; + auto & ip = data.ipAddress[index]; SetPeerAddress(Transport::PeerAddress::UDP(ip, data.port, ip.IsIPv6LinkLocal() ? data.interfaceId : Inet::InterfaceId::Null())); if (data.mrpRetryIntervalIdle.HasValue()) diff --git a/src/controller/SetUpCodePairer.h b/src/controller/SetUpCodePairer.h index eae15065d75966..0b665a9cbbaa1b 100644 --- a/src/controller/SetUpCodePairer.h +++ b/src/controller/SetUpCodePairer.h @@ -41,7 +41,7 @@ #include -#include +#include namespace chip { namespace Controller { @@ -51,7 +51,7 @@ class DeviceCommissioner; class SetUpCodePairerParameters : public RendezvousParameters { public: - SetUpCodePairerParameters(const Dnssd::CommonResolutionData & data); + SetUpCodePairerParameters(const Dnssd::CommonResolutionData & data, size_t index); #if CONFIG_NETWORK_LAYER_BLE SetUpCodePairerParameters(BLE_CONNECTION_OBJECT connObj); #endif // CONFIG_NETWORK_LAYER_BLE @@ -188,10 +188,10 @@ class DLL_EXPORT SetUpCodePairer : public DevicePairingDelegate // process happening via the relevant transport. bool mWaitingForDiscovery[kTransportTypeCount] = { false }; - // Queue of things we have discovered but not tried connecting to yet. The + // Double ended-queue of things we have discovered but not tried connecting to yet. The // general discovery/pairing process will terminate once this queue is empty // and all the booleans in mWaitingForDiscovery are false. - std::queue mDiscoveredParameters; + std::deque mDiscoveredParameters; // Current thing we are trying to connect to over UDP. If a PASE connection fails with // a CHIP_ERROR_TIMEOUT, the discovered parameters will be used to ask the diff --git a/src/controller/data_model/BUILD.gn b/src/controller/data_model/BUILD.gn index 011669db09524a..95b0e6cf02072a 100644 --- a/src/controller/data_model/BUILD.gn +++ b/src/controller/data_model/BUILD.gn @@ -31,6 +31,12 @@ chip_data_model("data_model") { } if (current_os == "android" || build_java_matter_controller) { + config("java-build-config") { + if (build_java_matter_controller) { + include_dirs = java_matter_controller_dependent_paths + } + } + chip_codegen("java-jni-generate") { input = "controller-clusters.matter" generator = "java" @@ -167,12 +173,21 @@ if (current_os == "android" || build_java_matter_controller) { "jni/UnitTestingClient-ReadImpl.cpp", "jni/UnitTestingClient-InvokeSubscribeImpl.cpp", ] + + deps = [ + ":data_model", + "${chip_root}/src/platform:platform_buildconfig", + ] + + public_configs = [ ":java-build-config" ] } source_set("java-jni-sources") { - sources = get_target_outputs(":java-jni-generate") + public_configs = [ + ":java-build-config", + "${chip_root}/src:includes", + ] - public_configs = [ "${chip_root}/src:includes" ] deps = [ ":data_model", ":java-jni-generate", @@ -182,7 +197,6 @@ if (current_os == "android" || build_java_matter_controller) { ] if (build_java_matter_controller) { - include_dirs = java_matter_controller_dependent_paths deps += [ "${chip_root}/src/platform/Linux" ] } else { deps += [ "${chip_root}/src/platform/android" ] diff --git a/src/controller/data_model/controller-clusters.matter b/src/controller/data_model/controller-clusters.matter index f5d80fdf265ac7..7b448f4a558053 100644 --- a/src/controller/data_model/controller-clusters.matter +++ b/src/controller/data_model/controller-clusters.matter @@ -1739,7 +1739,7 @@ client cluster Switch = 59 { } info event MultiPressComplete = 6 { - INT8U newPosition = 0; + INT8U previousPosition = 0; INT8U totalNumberOfPressesCounted = 1; } @@ -4406,7 +4406,7 @@ client cluster UnitTesting = 4294048773 { } endpoint 1 { - device type rootdevice = 22; + device type rootdevice = 22, version 1; binding cluster Identify; binding cluster Groups; binding cluster Scenes; diff --git a/src/controller/data_model/controller-clusters.zap b/src/controller/data_model/controller-clusters.zap index 73ce6039c09532..217d7aefafe6bb 100644 --- a/src/controller/data_model/controller-clusters.zap +++ b/src/controller/data_model/controller-clusters.zap @@ -1,5 +1,5 @@ { - "featureLevel": 81, + "featureLevel": 87, "creator": "zap", "keyValuePairs": [ { @@ -16,6 +16,12 @@ } ], "package": [ + { + "pathRelativity": "relativeToZap", + "path": "../../app/zap-templates/app-templates.json", + "type": "gen-templates-json", + "version": "chip-v1" + }, { "pathRelativity": "relativeToZap", "path": "../../app/zap-templates/zcl/zcl.json", @@ -23,12 +29,6 @@ "category": "matter", "version": 1, "description": "Matter SDK ZCL data" - }, - { - "pathRelativity": "relativeToZap", - "path": "../../app/zap-templates/app-templates.json", - "type": "gen-templates-json", - "version": "chip-v1" } ], "endpointTypes": [ @@ -1383,7 +1383,7 @@ "code": 15, "mfgCode": null, "side": "server", - "type": "bitmap8", + "type": "LevelControlOptions", "included": 1, "storageOption": "RAM", "singleton": 0, @@ -17766,7 +17766,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "client", "enabled": 1, "commands": [ @@ -17954,7 +17954,7 @@ "name": "Unit Testing", "code": 4294048773, "mfgCode": null, - "define": "TEST_CLUSTER", + "define": "UNIT_TESTING_CLUSTER", "side": "server", "enabled": 0, "commands": [ @@ -19557,5 +19557,6 @@ "endpointVersion": 1, "deviceIdentifier": 22 } - ] + ], + "log": [] } \ No newline at end of file diff --git a/src/controller/java/zap-generated/CHIPEventTLVValueDecoder.cpp b/src/controller/java/zap-generated/CHIPEventTLVValueDecoder.cpp index cea5d480a81416..eb53f82a2cefd7 100644 --- a/src/controller/java/zap-generated/CHIPEventTLVValueDecoder.cpp +++ b/src/controller/java/zap-generated/CHIPEventTLVValueDecoder.cpp @@ -1879,12 +1879,12 @@ jobject DecodeEventValue(const app::ConcreteEventPath & aPath, TLV::TLVReader & { return nullptr; } - jobject value_newPosition; - std::string value_newPositionClassName = "java/lang/Integer"; - std::string value_newPositionCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(value_newPositionClassName.c_str(), - value_newPositionCtorSignature.c_str(), - cppValue.newPosition, value_newPosition); + jobject value_previousPosition; + std::string value_previousPositionClassName = "java/lang/Integer"; + std::string value_previousPositionCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(value_previousPositionClassName.c_str(), + value_previousPositionCtorSignature.c_str(), + cppValue.previousPosition, value_previousPosition); jobject value_totalNumberOfPressesCounted; std::string value_totalNumberOfPressesCountedClassName = "java/lang/Integer"; @@ -1909,7 +1909,7 @@ jobject DecodeEventValue(const app::ConcreteEventPath & aPath, TLV::TLVReader & return nullptr; } - jobject value = env->NewObject(multiPressCompleteStructClass, multiPressCompleteStructCtor, value_newPosition, + jobject value = env->NewObject(multiPressCompleteStructClass, multiPressCompleteStructCtor, value_previousPosition, value_totalNumberOfPressesCounted); return value; diff --git a/src/controller/java/zap-generated/chip/devicecontroller/ChipEventStructs.java b/src/controller/java/zap-generated/chip/devicecontroller/ChipEventStructs.java index f2cadefe25e82c..c3068410dcb48a 100644 --- a/src/controller/java/zap-generated/chip/devicecontroller/ChipEventStructs.java +++ b/src/controller/java/zap-generated/chip/devicecontroller/ChipEventStructs.java @@ -763,12 +763,12 @@ public String toString() { } public static class SwitchClusterMultiPressCompleteEvent { - public Integer newPosition; + public Integer previousPosition; public Integer totalNumberOfPressesCounted; public SwitchClusterMultiPressCompleteEvent( - Integer newPosition, Integer totalNumberOfPressesCounted) { - this.newPosition = newPosition; + Integer previousPosition, Integer totalNumberOfPressesCounted) { + this.previousPosition = previousPosition; this.totalNumberOfPressesCounted = totalNumberOfPressesCounted; } @@ -776,8 +776,8 @@ public SwitchClusterMultiPressCompleteEvent( public String toString() { StringBuilder output = new StringBuilder(); output.append("SwitchClusterMultiPressCompleteEvent {\n"); - output.append("\tnewPosition: "); - output.append(newPosition); + output.append("\tpreviousPosition: "); + output.append(previousPosition); output.append("\n"); output.append("\ttotalNumberOfPressesCounted: "); output.append(totalNumberOfPressesCounted); diff --git a/src/controller/python/chip/clusters/Objects.py b/src/controller/python/chip/clusters/Objects.py index ebe66dee75d117..1f68a49e4e4244 100644 --- a/src/controller/python/chip/clusters/Objects.py +++ b/src/controller/python/chip/clusters/Objects.py @@ -11142,11 +11142,11 @@ def event_id(cls) -> int: def descriptor(cls) -> ClusterObjectDescriptor: return ClusterObjectDescriptor( Fields = [ - ClusterObjectFieldDescriptor(Label="newPosition", Tag=0, Type=uint), + ClusterObjectFieldDescriptor(Label="previousPosition", Tag=0, Type=uint), ClusterObjectFieldDescriptor(Label="totalNumberOfPressesCounted", Tag=1, Type=uint), ]) - newPosition: 'uint' = 0 + previousPosition: 'uint' = 0 totalNumberOfPressesCounted: 'uint' = 0 @@ -26805,6 +26805,235 @@ def attribute_type(cls) -> ClusterObjectFieldDescriptor: +@dataclass +class ClientMonitoring(Cluster): + id: typing.ClassVar[int] = 0x1046 + + @ChipUtility.classproperty + def descriptor(cls) -> ClusterObjectDescriptor: + return ClusterObjectDescriptor( + Fields = [ + ClusterObjectFieldDescriptor(Label="idleModeInterval", Tag=0x00000000, Type=uint), + ClusterObjectFieldDescriptor(Label="activeModeInterval", Tag=0x00000001, Type=uint), + ClusterObjectFieldDescriptor(Label="activeModeThreshold", Tag=0x00000002, Type=uint), + ClusterObjectFieldDescriptor(Label="expectedClients", Tag=0x00000003, Type=typing.List[ClientMonitoring.Structs.MonitoringRegistration]), + ClusterObjectFieldDescriptor(Label="generatedCommandList", Tag=0x0000FFF8, Type=typing.List[uint]), + ClusterObjectFieldDescriptor(Label="acceptedCommandList", Tag=0x0000FFF9, Type=typing.List[uint]), + ClusterObjectFieldDescriptor(Label="attributeList", Tag=0x0000FFFB, Type=typing.List[uint]), + ClusterObjectFieldDescriptor(Label="featureMap", Tag=0x0000FFFC, Type=uint), + ClusterObjectFieldDescriptor(Label="clusterRevision", Tag=0x0000FFFD, Type=uint), + ]) + + idleModeInterval: 'uint' = None + activeModeInterval: 'uint' = None + activeModeThreshold: 'uint' = None + expectedClients: 'typing.List[ClientMonitoring.Structs.MonitoringRegistration]' = None + generatedCommandList: 'typing.List[uint]' = None + acceptedCommandList: 'typing.List[uint]' = None + attributeList: 'typing.List[uint]' = None + featureMap: 'uint' = None + clusterRevision: 'uint' = None + + + class Structs: + @dataclass + class MonitoringRegistration(ClusterObject): + @ChipUtility.classproperty + def descriptor(cls) -> ClusterObjectDescriptor: + return ClusterObjectDescriptor( + Fields = [ + ClusterObjectFieldDescriptor(Label="clientNodeId", Tag=1, Type=uint), + ClusterObjectFieldDescriptor(Label="ICid", Tag=2, Type=uint), + ClusterObjectFieldDescriptor(Label="fabricIndex", Tag=254, Type=uint), + ]) + + clientNodeId: 'uint' = 0 + ICid: 'uint' = 0 + fabricIndex: 'uint' = 0 + + + + class Commands: + @dataclass + class RegisterClientMonitoring(ClusterCommand): + cluster_id: typing.ClassVar[int] = 0x1046 + command_id: typing.ClassVar[int] = 0x0000 + is_client: typing.ClassVar[bool] = True + response_type: typing.ClassVar[str] = None + + @ChipUtility.classproperty + def descriptor(cls) -> ClusterObjectDescriptor: + return ClusterObjectDescriptor( + Fields = [ + ClusterObjectFieldDescriptor(Label="clientNodeId", Tag=0, Type=uint), + ClusterObjectFieldDescriptor(Label="ICid", Tag=1, Type=uint), + ]) + + clientNodeId: 'uint' = 0 + ICid: 'uint' = 0 + + @dataclass + class StayAwakeRequest(ClusterCommand): + cluster_id: typing.ClassVar[int] = 0x1046 + command_id: typing.ClassVar[int] = 0x0001 + is_client: typing.ClassVar[bool] = True + response_type: typing.ClassVar[str] = None + + @ChipUtility.classproperty + def descriptor(cls) -> ClusterObjectDescriptor: + return ClusterObjectDescriptor( + Fields = [ + ]) + + + + class Attributes: + @dataclass + class IdleModeInterval(ClusterAttributeDescriptor): + @ChipUtility.classproperty + def cluster_id(cls) -> int: + return 0x1046 + + @ChipUtility.classproperty + def attribute_id(cls) -> int: + return 0x00000000 + + @ChipUtility.classproperty + def attribute_type(cls) -> ClusterObjectFieldDescriptor: + return ClusterObjectFieldDescriptor(Type=uint) + + value: 'uint' = 0 + + @dataclass + class ActiveModeInterval(ClusterAttributeDescriptor): + @ChipUtility.classproperty + def cluster_id(cls) -> int: + return 0x1046 + + @ChipUtility.classproperty + def attribute_id(cls) -> int: + return 0x00000001 + + @ChipUtility.classproperty + def attribute_type(cls) -> ClusterObjectFieldDescriptor: + return ClusterObjectFieldDescriptor(Type=uint) + + value: 'uint' = 0 + + @dataclass + class ActiveModeThreshold(ClusterAttributeDescriptor): + @ChipUtility.classproperty + def cluster_id(cls) -> int: + return 0x1046 + + @ChipUtility.classproperty + def attribute_id(cls) -> int: + return 0x00000002 + + @ChipUtility.classproperty + def attribute_type(cls) -> ClusterObjectFieldDescriptor: + return ClusterObjectFieldDescriptor(Type=uint) + + value: 'uint' = 0 + + @dataclass + class ExpectedClients(ClusterAttributeDescriptor): + @ChipUtility.classproperty + def cluster_id(cls) -> int: + return 0x1046 + + @ChipUtility.classproperty + def attribute_id(cls) -> int: + return 0x00000003 + + @ChipUtility.classproperty + def attribute_type(cls) -> ClusterObjectFieldDescriptor: + return ClusterObjectFieldDescriptor(Type=typing.List[ClientMonitoring.Structs.MonitoringRegistration]) + + value: 'typing.List[ClientMonitoring.Structs.MonitoringRegistration]' = field(default_factory=lambda: []) + + @dataclass + class GeneratedCommandList(ClusterAttributeDescriptor): + @ChipUtility.classproperty + def cluster_id(cls) -> int: + return 0x1046 + + @ChipUtility.classproperty + def attribute_id(cls) -> int: + return 0x0000FFF8 + + @ChipUtility.classproperty + def attribute_type(cls) -> ClusterObjectFieldDescriptor: + return ClusterObjectFieldDescriptor(Type=typing.List[uint]) + + value: 'typing.List[uint]' = field(default_factory=lambda: []) + + @dataclass + class AcceptedCommandList(ClusterAttributeDescriptor): + @ChipUtility.classproperty + def cluster_id(cls) -> int: + return 0x1046 + + @ChipUtility.classproperty + def attribute_id(cls) -> int: + return 0x0000FFF9 + + @ChipUtility.classproperty + def attribute_type(cls) -> ClusterObjectFieldDescriptor: + return ClusterObjectFieldDescriptor(Type=typing.List[uint]) + + value: 'typing.List[uint]' = field(default_factory=lambda: []) + + @dataclass + class AttributeList(ClusterAttributeDescriptor): + @ChipUtility.classproperty + def cluster_id(cls) -> int: + return 0x1046 + + @ChipUtility.classproperty + def attribute_id(cls) -> int: + return 0x0000FFFB + + @ChipUtility.classproperty + def attribute_type(cls) -> ClusterObjectFieldDescriptor: + return ClusterObjectFieldDescriptor(Type=typing.List[uint]) + + value: 'typing.List[uint]' = field(default_factory=lambda: []) + + @dataclass + class FeatureMap(ClusterAttributeDescriptor): + @ChipUtility.classproperty + def cluster_id(cls) -> int: + return 0x1046 + + @ChipUtility.classproperty + def attribute_id(cls) -> int: + return 0x0000FFFC + + @ChipUtility.classproperty + def attribute_type(cls) -> ClusterObjectFieldDescriptor: + return ClusterObjectFieldDescriptor(Type=uint) + + value: 'uint' = 0 + + @dataclass + class ClusterRevision(ClusterAttributeDescriptor): + @ChipUtility.classproperty + def cluster_id(cls) -> int: + return 0x1046 + + @ChipUtility.classproperty + def attribute_id(cls) -> int: + return 0x0000FFFD + + @ChipUtility.classproperty + def attribute_type(cls) -> ClusterObjectFieldDescriptor: + return ClusterObjectFieldDescriptor(Type=uint) + + value: 'uint' = 0 + + + @dataclass class UnitTesting(Cluster): id: typing.ClassVar[int] = 0xFFF1FC05 diff --git a/src/controller/python/chip/yaml/constraints.py b/src/controller/python/chip/yaml/constraints.py index 933d74fdf4a562..49ac8c99153eff 100644 --- a/src/controller/python/chip/yaml/constraints.py +++ b/src/controller/python/chip/yaml/constraints.py @@ -36,7 +36,7 @@ def is_met(self, response) -> bool: class _LoadableConstraint(BaseConstraint): '''Constraints where value might be stored in VariableStorage needing runtime load.''' - def __init__(self, value, field_type, variable_storage: VariableStorage): + def __init__(self, value, field_type, variable_storage: VariableStorage, config_values: dict): self._variable_storage = variable_storage # When not none _indirect_value_key is binding a name to the constraint value, and the # actual value can only be looked-up dynamically, which is why this is a key name. @@ -50,8 +50,8 @@ def __init__(self, value, field_type, variable_storage: VariableStorage): if isinstance(value, str) and self._variable_storage.is_key_saved(value): self._indirect_value_key = value else: - self._value = Converter.convert_yaml_type( - value, field_type) + self._value = Converter.parse_and_convert_yaml_value( + value, field_type, config_values) def get_value(self): '''Gets the current value of the constraint. @@ -112,8 +112,9 @@ def is_met(self, response) -> bool: class _ConstraintMinValue(_LoadableConstraint): - def __init__(self, min_value, field_type, variable_storage: VariableStorage): - super().__init__(min_value, field_type, variable_storage) + def __init__(self, min_value, field_type, variable_storage: VariableStorage, + config_values: dict): + super().__init__(min_value, field_type, variable_storage, config_values) def is_met(self, response) -> bool: min_value = self.get_value() @@ -121,8 +122,9 @@ def is_met(self, response) -> bool: class _ConstraintMaxValue(_LoadableConstraint): - def __init__(self, max_value, field_type, variable_storage: VariableStorage): - super().__init__(max_value, field_type, variable_storage) + def __init__(self, max_value, field_type, variable_storage: VariableStorage, + config_values: dict): + super().__init__(max_value, field_type, variable_storage, config_values) def is_met(self, response) -> bool: max_value = self.get_value() @@ -162,16 +164,17 @@ def is_met(self, response) -> bool: class _ConstraintNotValue(_LoadableConstraint): - def __init__(self, not_value, field_type, variable_storage: VariableStorage): - super().__init__(not_value, field_type, variable_storage) + def __init__(self, not_value, field_type, variable_storage: VariableStorage, + config_values: dict): + super().__init__(not_value, field_type, variable_storage, config_values) def is_met(self, response) -> bool: not_value = self.get_value() return response != not_value -def get_constraints(constraints, field_type, - variable_storage: VariableStorage) -> list[BaseConstraint]: +def get_constraints(constraints, field_type, variable_storage: VariableStorage, + config_values: dict) -> list[BaseConstraint]: _constraints = [] if 'hasValue' in constraints: _constraints.append(_ConstraintHasValue(constraints.get('hasValue'))) @@ -193,11 +196,11 @@ def get_constraints(constraints, field_type, if 'minValue' in constraints: _constraints.append(_ConstraintMinValue( - constraints.get('minValue'), field_type, variable_storage)) + constraints.get('minValue'), field_type, variable_storage, config_values)) if 'maxValue' in constraints: _constraints.append(_ConstraintMaxValue( - constraints.get('maxValue'), field_type, variable_storage)) + constraints.get('maxValue'), field_type, variable_storage, config_values)) if 'contains' in constraints: _constraints.append(_ConstraintContains(constraints.get('contains'))) @@ -213,6 +216,6 @@ def get_constraints(constraints, field_type, if 'notValue' in constraints: _constraints.append(_ConstraintNotValue( - constraints.get('notValue'), field_type, variable_storage)) + constraints.get('notValue'), field_type, variable_storage, config_values)) return _constraints diff --git a/src/controller/python/chip/yaml/format_converter.py b/src/controller/python/chip/yaml/format_converter.py index f6402c59706058..fc3c5a1b873cfc 100644 --- a/src/controller/python/chip/yaml/format_converter.py +++ b/src/controller/python/chip/yaml/format_converter.py @@ -23,8 +23,44 @@ import binascii +def substitute_in_config_variables(field_value, config_values: dict): + ''' Substitutes values that are config variables. + + YAML values can contain a string of a configuration variable name. In these instances we + substitute the configuration variable name with the actual value. + + For examples see unittest src/controller/python/test/unit_tests/test_yaml_format_converter.py + + # TODO This should also substitue any saveAs values as well as perform any required + # evaluations. + + Args: + 'field_value': Value as extracted from YAML. + 'config_values': Dictionary of global configuration variables. + Returns: + Value with all global configuration variables substituted with the real value. + ''' + if isinstance(field_value, dict): + return {key: substitute_in_config_variables( + field_value[key], config_values) for key in field_value} + if isinstance(field_value, list): + return [substitute_in_config_variables(item, config_values) for item in field_value] + if isinstance(field_value, str) and field_value in config_values: + config_value = config_values[field_value] + if isinstance(config_value, dict) and 'defaultValue' in config_value: + # TODO currently we don't validate that if config_value['type'] is provided + # that the type does in fact match our expectation. + return config_value['defaultValue'] + return config_values[field_value] + + return field_value + + def convert_yaml_octet_string_to_bytes(s: str) -> bytes: - """Convert YAML octet string body to bytes, handling any c-style hex escapes (e.g. \x5a) and hex: prefix""" + '''Convert YAML octet string body to bytes. + + Included handling any c-style hex escapes (e.g. \x5a) and 'hex:' prefix. + ''' # Step 1: handle explicit "hex:" prefix if s.startswith('hex:'): return binascii.unhexlify(s[4:]) @@ -60,14 +96,21 @@ def convert_name_value_pair_to_dict(arg_values): return ret_value -def convert_yaml_type(field_value, field_type, use_from_dict=False): - ''' Converts yaml value to expected type. +def convert_yaml_type(field_value, field_type, inline_cast_dict_to_struct): + ''' Converts yaml value to provided pythonic type. + + The YAML representation when converted to a dictionary does not line up to + the python type data model for the various command/attribute/event object + types. This function converts 'field_value' to the appropriate provided + 'field_type'. - The YAML representation when converted to a Python dictionary does not - quite line up in terms of type (see each of the specific if branches - below for the rationale for the necessary fix-ups). This function does - a fix-up given a field value (as present in the YAML) and its matching - cluster object type and returns it. + Args: + 'field_value': Value as extracted from yaml + 'field_type': Pythonic command/attribute/event object type that we + are converting value to. + 'inline_cast_dict_to_struct': If true, for any dictionary 'field_value' + types provided we will do a convertion to the corresponding data + model class in `field_type` by doing field_type.FromDict(...). ''' origin = typing.get_origin(field_type) @@ -110,8 +153,8 @@ def convert_yaml_type(field_value, field_type, use_from_dict=False): f'Did not find field "{item}" in {str(field_type)}') from None return_field_value[field_descriptor.Label] = convert_yaml_type( - field_value[item], field_descriptor.Type, use_from_dict) - if use_from_dict: + field_value[item], field_descriptor.Type, inline_cast_dict_to_struct) + if inline_cast_dict_to_struct: return field_type.FromDict(return_field_value) return return_field_value elif(type(field_value) is float): @@ -122,7 +165,8 @@ def convert_yaml_type(field_value, field_type, use_from_dict=False): # The field type passed in is the type of the list element and not list[T]. for idx, item in enumerate(field_value): - field_value[idx] = convert_yaml_type(item, list_element_type, use_from_dict) + field_value[idx] = convert_yaml_type(item, list_element_type, + inline_cast_dict_to_struct) return field_value # YAML conversion treats all numbers as ints. Convert to a uint type if the schema # type indicates so. @@ -139,3 +183,25 @@ def convert_yaml_type(field_value, field_type, use_from_dict=False): # By default, just return the field_value casted to field_type. else: return field_type(field_value) + + +def parse_and_convert_yaml_value(field_value, field_type, config_values: dict, + inline_cast_dict_to_struct: bool = False): + ''' Parse and converts YAML type + + Parsing the YAML value means performing required substitutions and evaluations. Parsing is + then followed by converting from the YAML type done using yaml.safe_load() to the type used in + the various command/attribute/event object data model types. + + Args: + 'field_value': Value as extracted from yaml to be parsed + 'field_type': Pythonic command/attribute/event object type that we + are converting value to. + 'config_values': Dictionary of global configuration variables. + 'inline_cast_dict_to_struct': If true, for any dictionary 'field_value' + types provided we will do an inline convertion to the corresponding + struct in `field_type` by doing field_type.FromDict(...). + ''' + field_value_with_config_variables = substitute_in_config_variables(field_value, config_values) + return convert_yaml_type(field_value_with_config_variables, field_type, + inline_cast_dict_to_struct) diff --git a/src/controller/python/chip/yaml/parser.py b/src/controller/python/chip/yaml/parser.py index a3f38f7514fde0..b70a743147063d 100644 --- a/src/controller/python/chip/yaml/parser.py +++ b/src/controller/python/chip/yaml/parser.py @@ -69,8 +69,8 @@ def __init__(self, value, response_type, context: _ExecutionContext): if isinstance(value, str) and self._variable_storage.is_key_saved(value): self._load_expected_response_in_verify = value else: - self._expected_response = Converter.convert_yaml_type( - value, response_type, use_from_dict=True) + self._expected_response = Converter.parse_and_convert_yaml_value( + value, response_type, context.config_values, inline_cast_dict_to_struct=True) def verify(self, response): if (self._expected_response_type is None): @@ -145,8 +145,8 @@ def __init__(self, item: dict, cluster: str, context: _ExecutionContext): request_data_as_dict = Converter.convert_name_value_pair_to_dict(args) try: - request_data = Converter.convert_yaml_type( - request_data_as_dict, type(command_object)) + request_data = Converter.parse_and_convert_yaml_value( + request_data_as_dict, type(command_object), context.config_values) except ValueError: raise ParsingError('Could not covert yaml type') @@ -166,8 +166,8 @@ def __init__(self, item: dict, cluster: str, context: _ExecutionContext): expected_response_args = self._expected_raw_response['values'] expected_response_data_as_dict = Converter.convert_name_value_pair_to_dict( expected_response_args) - expected_response_data = Converter.convert_yaml_type( - expected_response_data_as_dict, expected_command) + expected_response_data = Converter.parse_and_convert_yaml_value( + expected_response_data_as_dict, expected_command, context.config_values) self._expected_response_object = expected_command.FromDict(expected_response_data) def run_action(self, dev_ctrl: ChipDeviceCtrl, endpoint: int, node_id: int): @@ -260,7 +260,8 @@ def __init__(self, item: dict, cluster: str, context: _ExecutionContext): if constraints: self._constraints = get_constraints(constraints, self._request_object.attribute_type.Type, - context.variable_storage) + context.variable_storage, + context.config_values) def run_action(self, dev_ctrl: ChipDeviceCtrl, endpoint: int, node_id: int): try: @@ -326,8 +327,8 @@ def __init__(self, item: dict, cluster: str, context: _ExecutionContext): if (item.get('arguments')): args = item['arguments']['value'] try: - request_data = Converter.convert_yaml_type( - args, attribute.attribute_type.Type) + request_data = Converter.parse_and_convert_yaml_value( + args, attribute.attribute_type.Type, context.config_values) except ValueError: raise ParsingError('Could not covert yaml type') diff --git a/src/controller/python/test/unit_tests/test_yaml_format_converter.py b/src/controller/python/test/unit_tests/test_yaml_format_converter.py index fa46705be65ed9..05f58d20b59418 100644 --- a/src/controller/python/test/unit_tests/test_yaml_format_converter.py +++ b/src/controller/python/test/unit_tests/test_yaml_format_converter.py @@ -15,7 +15,7 @@ # limitations under the License. # -from chip.yaml.format_converter import convert_yaml_octet_string_to_bytes +from chip.yaml.format_converter import convert_yaml_octet_string_to_bytes, substitute_in_config_variables from binascii import unhexlify import unittest @@ -44,6 +44,75 @@ def test_common_cases(self): convert_yaml_octet_string_to_bytes("hex:aa5") +class TestSubstitueInConfigVariables(unittest.TestCase): + + def setUp(self): + self.common_config = { + 'arg1': { + 'defaultValue': 1 + }, + 'arg2': { + 'defaultValue': 2 + }, + 'no_explicit_default': 3 + } + + def test_basic_substitution(self): + self.assertEqual(substitute_in_config_variables('arg1', self.common_config), 1) + self.assertEqual(substitute_in_config_variables('arg2', self.common_config), 2) + self.assertEqual(substitute_in_config_variables('arg3', self.common_config), 'arg3') + self.assertEqual(substitute_in_config_variables('no_explicit_default', self.common_config), 3) + + def test_basis_dict_substitution(self): + basic_dict = { + 'arg1': 'arg1', + 'arg2': 'arg2', + 'arg3': 'arg3', + 'no_explicit_default': 'no_explicit_default', + } + expected_dict = { + 'arg1': 1, + 'arg2': 2, + 'arg3': 'arg3', + 'no_explicit_default': 3, + } + self.assertEqual(substitute_in_config_variables(basic_dict, self.common_config), expected_dict) + + def test_basis_list_substitution(self): + basic_list = ['arg1', 'arg2', 'arg3', 'no_explicit_default'] + expected_list = [1, 2, 'arg3', 3] + self.assertEqual(substitute_in_config_variables(basic_list, self.common_config), expected_list) + + def test_complex_nested_type(self): + complex_nested_type = { + 'arg1': ['arg1', 'arg2', 'arg3', 'no_explicit_default'], + 'arg2': 'arg22', + 'arg3': { + 'no_explicit_default': 'no_explicit_default', + 'arg2': 'arg2', + 'another_dict': { + 'arg1': ['arg1', 'arg1', 'arg1', 'no_explicit_default'], + }, + 'another_list': ['arg1', 'arg2', 'arg3', 'no_explicit_default'] + }, + 'no_explicit_default': 'no_explicit_default', + } + expected_result = { + 'arg1': [1, 2, 'arg3', 3], + 'arg2': 'arg22', + 'arg3': { + 'no_explicit_default': 3, + 'arg2': 2, + 'another_dict': { + 'arg1': [1, 1, 1, 3], + }, + 'another_list': [1, 2, 'arg3', 3] + }, + 'no_explicit_default': 3, + } + self.assertEqual(substitute_in_config_variables(complex_nested_type, self.common_config), expected_result) + + def main(): unittest.main() diff --git a/src/controller/tests/BUILD.gn b/src/controller/tests/BUILD.gn index ec7f26b6d7d2d4..0528c977c95a3b 100644 --- a/src/controller/tests/BUILD.gn +++ b/src/controller/tests/BUILD.gn @@ -26,9 +26,9 @@ chip_test_suite("tests") { if (chip_device_platform != "mbed" && chip_device_platform != "efr32" && chip_device_platform != "esp32") { test_sources += [ "TestServerCommandDispatch.cpp" ] - test_sources += [ "TestReadChunking.cpp" ] test_sources += [ "TestEventChunking.cpp" ] test_sources += [ "TestEventCaching.cpp" ] + test_sources += [ "TestReadChunking.cpp" ] test_sources += [ "TestWriteChunking.cpp" ] } diff --git a/src/credentials/BUILD.gn b/src/credentials/BUILD.gn index b33a9bcdbf1b5d..82cf18b6bc0fd7 100644 --- a/src/credentials/BUILD.gn +++ b/src/credentials/BUILD.gn @@ -59,9 +59,10 @@ static_library("credentials") { # TODO: These tests files should be removed after the DeviceAttestationCredsExample implementation # is changed to generate it's own credentials instead of using Test credentials. - # For mbed and nrfconnect test builds, which are bilding monolithic test library these files are not needed. + # For some platforms test builds, which are bilding monolithic test library these files are not needed. import("${chip_root}/build/chip/tests.gni") if (!(chip_build_tests && (chip_device_platform == "mbed" || + chip_device_platform == "openiotsdk" || chip_device_platform == "nrfconnect"))) { sources += [ "tests/CHIPAttCert_test_vectors.cpp", @@ -70,7 +71,7 @@ static_library("credentials") { } if (chip_device_platform == "esp32" || chip_device_platform == "nrfconnect" || - chip_device_platform == "efr32") { + chip_device_platform == "efr32" || chip_device_platform == "openiotsdk") { defines = [ "CURRENT_TIME_NOT_IMPLEMENTED=1" ] } @@ -98,7 +99,7 @@ static_library("default_attestation_verifier") { ] if (chip_device_platform == "esp32" || chip_device_platform == "nrfconnect" || - chip_device_platform == "efr32") { + chip_device_platform == "efr32" || chip_device_platform == "openiotsdk") { defines = [ "CURRENT_TIME_NOT_IMPLEMENTED=1" ] } diff --git a/src/credentials/tests/BUILD.gn b/src/credentials/tests/BUILD.gn index 041d26e20e3138..fd24132e4cab1b 100644 --- a/src/credentials/tests/BUILD.gn +++ b/src/credentials/tests/BUILD.gn @@ -46,7 +46,6 @@ chip_test_suite("tests") { test_sources = [ "TestCertificationDeclaration.cpp", "TestChipCert.cpp", - "TestCommissionerDUTVectors.cpp", "TestDeviceAttestationConstruction.cpp", "TestDeviceAttestationCredentials.cpp", "TestFabricTable.cpp", @@ -54,6 +53,11 @@ chip_test_suite("tests") { "TestPersistentStorageOpCertStore.cpp", ] + # DUTVectors test requires which is not supported on all platforms + if (chip_device_platform != "openiotsdk") { + test_sources += [ "TestCommissionerDUTVectors.cpp" ] + } + cflags = [ "-Wconversion" ] public_deps = [ diff --git a/src/credentials/tests/TestCertificationDeclaration.cpp b/src/credentials/tests/TestCertificationDeclaration.cpp index 7a2608744d3756..e0e678f176b56c 100644 --- a/src/credentials/tests/TestCertificationDeclaration.cpp +++ b/src/credentials/tests/TestCertificationDeclaration.cpp @@ -622,7 +622,7 @@ static const nlTest sTests[] = { NL_TEST_DEF_FN(TestCD_EncodeDecode), NL_TEST_DEF_FN(TestCD_DefaultCdTrustStore), NL_TEST_SENTINEL() }; -int TestCertificationDeclaration(void) +int TestCertificationDeclaration() { nlTestSuite theSuite = { "CHIP Certification Declaration tests", &sTests[0], nullptr, nullptr }; diff --git a/src/credentials/tests/TestChipCert.cpp b/src/credentials/tests/TestChipCert.cpp index 2319e3825bf076..a61da27841e4ef 100644 --- a/src/credentials/tests/TestChipCert.cpp +++ b/src/credentials/tests/TestChipCert.cpp @@ -2064,7 +2064,7 @@ static const nlTest sTests[] = { }; // clang-format on -int TestChipCert(void) +int TestChipCert() { // clang-format off nlTestSuite theSuite = diff --git a/src/crypto/BUILD.gn b/src/crypto/BUILD.gn index ced579399a3b06..93293295a1ca1e 100644 --- a/src/crypto/BUILD.gn +++ b/src/crypto/BUILD.gn @@ -22,7 +22,8 @@ import("crypto.gni") if (chip_crypto == "") { if (current_os == "android" || current_os == "freertos" || - current_os == "zephyr" || current_os == "mbed" || current_os == "webos") { + current_os == "zephyr" || current_os == "mbed" || current_os == "webos" || + current_os == "cmsis-rtos") { chip_crypto = "mbedtls" } else { chip_crypto = "openssl" @@ -107,9 +108,7 @@ if (chip_crypto == "openssl") { sources = [ "CHIPCryptoPALmbedTLS.cpp" ] public_deps = [ ":public_headers" ] - external_mbedtls = current_os == "zephyr" - - if (!external_mbedtls) { + if (!chip_external_mbedtls) { public_deps += [ "${mbedtls_root}:mbedtls" ] } } diff --git a/src/crypto/CHIPCryptoPALOpenSSL.cpp b/src/crypto/CHIPCryptoPALOpenSSL.cpp index f630aa40f4e9a2..8a24fde3c54fd4 100644 --- a/src/crypto/CHIPCryptoPALOpenSSL.cpp +++ b/src/crypto/CHIPCryptoPALOpenSSL.cpp @@ -1674,7 +1674,8 @@ CHIP_ERROR VerifyAttestationCertificateFormat(const ByteSpan & cert, Attestation { bool keyCertSignFlag = keyUsage & X509v3_KU_KEY_CERT_SIGN; bool crlSignFlag = keyUsage & X509v3_KU_CRL_SIGN; - bool otherFlags = keyUsage & ~(X509v3_KU_CRL_SIGN | X509v3_KU_KEY_CERT_SIGN | X509v3_KU_DIGITAL_SIGNATURE); + bool otherFlags = keyUsage & + ~static_cast(X509v3_KU_CRL_SIGN | X509v3_KU_KEY_CERT_SIGN | X509v3_KU_DIGITAL_SIGNATURE); VerifyOrExit(keyCertSignFlag && crlSignFlag && !otherFlags, err = CHIP_ERROR_INTERNAL); } } diff --git a/src/crypto/CHIPCryptoPALmbedTLS.cpp b/src/crypto/CHIPCryptoPALmbedTLS.cpp index 9cb3c746fbd2b3..2ce3bc7aba8c30 100644 --- a/src/crypto/CHIPCryptoPALmbedTLS.cpp +++ b/src/crypto/CHIPCryptoPALmbedTLS.cpp @@ -241,20 +241,20 @@ static inline mbedtls_sha256_context * to_inner_hash_sha256_context(HashSHA256Op return SafePointerCast(context); } -Hash_SHA256_stream::Hash_SHA256_stream(void) +Hash_SHA256_stream::Hash_SHA256_stream() { mbedtls_sha256_context * context = to_inner_hash_sha256_context(&mContext); mbedtls_sha256_init(context); } -Hash_SHA256_stream::~Hash_SHA256_stream(void) +Hash_SHA256_stream::~Hash_SHA256_stream() { mbedtls_sha256_context * context = to_inner_hash_sha256_context(&mContext); mbedtls_sha256_free(context); Clear(); } -CHIP_ERROR Hash_SHA256_stream::Begin(void) +CHIP_ERROR Hash_SHA256_stream::Begin() { mbedtls_sha256_context * const context = to_inner_hash_sha256_context(&mContext); @@ -320,7 +320,7 @@ CHIP_ERROR Hash_SHA256_stream::Finish(MutableByteSpan & out_buffer) return CHIP_NO_ERROR; } -void Hash_SHA256_stream::Clear(void) +void Hash_SHA256_stream::Clear() { mbedtls_platform_zeroize(this, sizeof(*this)); } @@ -969,7 +969,7 @@ static inline Spake2p_Context * to_inner_spake2p_context(Spake2pOpaqueContext * return SafePointerCast(context); } -CHIP_ERROR Spake2p_P256_SHA256_HKDF_HMAC::InitInternal(void) +CHIP_ERROR Spake2p_P256_SHA256_HKDF_HMAC::InitInternal() { CHIP_ERROR error = CHIP_NO_ERROR; int result = 0; diff --git a/src/crypto/crypto.gni b/src/crypto/crypto.gni index 1c99fb9c85d2cd..6ca932212d5ca3 100644 --- a/src/crypto/crypto.gni +++ b/src/crypto/crypto.gni @@ -16,4 +16,10 @@ declare_args() { # Crypto implementation: mbedtls, openssl, tinycrypt, boringssl, platform. chip_crypto = "" chip_with_se05x = 0 + + # Compile mbedtls externally. Only used if chip_crypto == "mbedtls" + chip_external_mbedtls = false } + +assert(!chip_external_mbedtls || chip_crypto == "mbedtls", + "Use of external mbedtls requires the mbedtls crypto impl") diff --git a/src/crypto/tests/BUILD.gn b/src/crypto/tests/BUILD.gn index fac74ed677c009..1865d875a90f2c 100644 --- a/src/crypto/tests/BUILD.gn +++ b/src/crypto/tests/BUILD.gn @@ -49,7 +49,7 @@ chip_test_suite("tests") { ] if (chip_device_platform == "esp32" || chip_device_platform == "nrfconnect" || - chip_device_platform == "efr32") { + chip_device_platform == "efr32" || chip_device_platform == "openiotsdk") { defines = [ "CURRENT_TIME_NOT_IMPLEMENTED=1" ] } diff --git a/src/darwin/Framework/CHIP/MTRAsyncCallbackWorkQueue.mm b/src/darwin/Framework/CHIP/MTRAsyncCallbackWorkQueue.mm index 5d0bae67fd408a..edb2265dfc5db7 100644 --- a/src/darwin/Framework/CHIP/MTRAsyncCallbackWorkQueue.mm +++ b/src/darwin/Framework/CHIP/MTRAsyncCallbackWorkQueue.mm @@ -19,7 +19,7 @@ #import #import "MTRAsyncCallbackWorkQueue.h" -#import "MTRLogging.h" +#import "MTRLogging_Internal.h" #pragma mark - Class extensions @@ -59,10 +59,17 @@ - (instancetype)initWithContext:(id)context queue:(dispatch_queue_t)queue _context = context; _queue = queue; _items = [NSMutableArray array]; + MTR_LOG_INFO("MTRAsyncCallbackWorkQueue init for context %@", context); } return self; } +- (NSString *)description +{ + return [NSString + stringWithFormat:@"MTRAsyncCallbackWorkQueue context: %@ items count: %lu", self.context, (unsigned long) self.items.count]; +} + - (void)enqueueWorkItem:(MTRAsyncCallbackQueueWorkItem *)item { os_unfair_lock_lock(&_lock); @@ -80,6 +87,8 @@ - (void)invalidate _items = nil; os_unfair_lock_unlock(&_lock); + MTR_LOG_INFO( + "MTRAsyncCallbackWorkQueue invalidate for context %@ items count: %lu", _context, (unsigned long) invalidateItems.count); for (MTRAsyncCallbackQueueWorkItem * item in invalidateItems) { [item cancel]; } @@ -94,7 +103,7 @@ - (void)_postProcessWorkItem:(MTRAsyncCallbackQueueWorkItem *)workItem retry:(BO if (!self.runningWorkItemCount) { // something is wrong with state - nothing is currently running os_unfair_lock_unlock(&_lock); - MTR_LOG_ERROR("endWork: no work is running on work queue"); + MTR_LOG_ERROR("MTRAsyncCallbackWorkQueue endWork: no work is running on work queue"); return; } @@ -104,7 +113,7 @@ - (void)_postProcessWorkItem:(MTRAsyncCallbackQueueWorkItem *)workItem retry:(BO if (firstWorkItem != workItem) { // something is wrong with this work item - should not be currently running os_unfair_lock_unlock(&_lock); - MTR_LOG_ERROR("endWork: work item is not first on work queue"); + MTR_LOG_ERROR("MTRAsyncCallbackWorkQueue endWork: work item is not first on work queue"); return; } @@ -138,11 +147,14 @@ - (void)_callNextReadyWorkItem return; } - // when "concurrency width" is implemented this will be incremented instead - self.runningWorkItemCount = 1; + // only proceed to mark queue as running if there are items to run + if (self.items.count) { + // when "concurrency width" is implemented this will be incremented instead + self.runningWorkItemCount = 1; - MTRAsyncCallbackQueueWorkItem * workItem = self.items.firstObject; - [workItem callReadyHandlerWithContext:self.context]; + MTRAsyncCallbackQueueWorkItem * workItem = self.items.firstObject; + [workItem callReadyHandlerWithContext:self.context]; + } } @end diff --git a/src/darwin/Framework/CHIP/MTRAttestationInfo.m b/src/darwin/Framework/CHIP/MTRAttestationInfo.mm similarity index 100% rename from src/darwin/Framework/CHIP/MTRAttestationInfo.m rename to src/darwin/Framework/CHIP/MTRAttestationInfo.mm diff --git a/src/darwin/Framework/CHIP/MTRBaseDevice.mm b/src/darwin/Framework/CHIP/MTRBaseDevice.mm index a2996d7bcbc603..eb39a8609f7350 100644 --- a/src/darwin/Framework/CHIP/MTRBaseDevice.mm +++ b/src/darwin/Framework/CHIP/MTRBaseDevice.mm @@ -24,7 +24,7 @@ #import "MTRCluster_internal.h" #import "MTRError_Internal.h" #import "MTREventTLVValueDecoder_Internal.h" -#import "MTRLogging.h" +#import "MTRLogging_Internal.h" #import "MTRSetupPayload_Internal.h" #include "app/ConcreteAttributePath.h" @@ -107,7 +107,24 @@ static void AddReadClientContainer(uint64_t deviceId, MTRReadClientContainer * c [readClientContainersLock unlock]; } -static void PurgeReadClientContainers(uint64_t deviceId, dispatch_queue_t queue, void (^_Nullable completion)(void)) +static void ReinstateReadClientList(NSMutableArray * readClientList, NSNumber * key, + dispatch_queue_t queue, dispatch_block_t _Nullable completion) +{ + [readClientContainersLock lock]; + auto existingList = readClientContainers[key]; + if (existingList) { + [existingList addObjectsFromArray:readClientList]; + } else { + readClientContainers[key] = readClientList; + } + [readClientContainersLock unlock]; + if (completion) { + dispatch_async(queue, completion); + } +} + +static void PurgeReadClientContainers( + MTRDeviceController * controller, uint64_t deviceId, dispatch_queue_t queue, void (^_Nullable completion)(void)) { InitializeReadClientContainers(); @@ -119,22 +136,28 @@ static void PurgeReadClientContainers(uint64_t deviceId, dispatch_queue_t queue, [readClientContainersLock unlock]; // Destroy read clients in the work queue - dispatch_async(DeviceLayer::PlatformMgrImpl().GetWorkQueue(), ^{ - for (MTRReadClientContainer * container in listToDelete) { - if (container.readClientPtr) { - Platform::Delete(container.readClientPtr); - container.readClientPtr = nullptr; + [controller + asyncDispatchToMatterQueue:^(Controller::DeviceCommissioner * commissioner) { + for (MTRReadClientContainer * container in listToDelete) { + if (container.readClientPtr) { + Platform::Delete(container.readClientPtr); + container.readClientPtr = nullptr; + } + if (container.pathParams) { + Platform::Delete(container.pathParams); + container.pathParams = nullptr; + } } - if (container.pathParams) { - Platform::Delete(container.pathParams); - container.pathParams = nullptr; + [listToDelete removeAllObjects]; + if (completion) { + dispatch_async(queue, completion); } } - [listToDelete removeAllObjects]; - if (completion) { - dispatch_async(queue, completion); - } - }); + errorHandler:^(NSError * error) { + // Can't delete things. Just put them back, and hope we + // can delete them later. + ReinstateReadClientList(listToDelete, key, queue, completion); + }]; } static void PurgeCompletedReadClientContainers(uint64_t deviceId) @@ -157,7 +180,8 @@ static void PurgeCompletedReadClientContainers(uint64_t deviceId) #ifdef DEBUG // This function is for unit testing only. This function closes all read clients. -static void CauseReadClientFailure(uint64_t deviceId, dispatch_queue_t queue, void (^_Nullable completion)(void)) +static void CauseReadClientFailure( + MTRDeviceController * controller, uint64_t deviceId, dispatch_queue_t queue, void (^_Nullable completion)(void)) { InitializeReadClientContainers(); @@ -168,18 +192,23 @@ static void CauseReadClientFailure(uint64_t deviceId, dispatch_queue_t queue, vo [readClientContainers removeObjectForKey:key]; [readClientContainersLock unlock]; - dispatch_async(DeviceLayer::PlatformMgrImpl().GetWorkQueue(), ^{ - for (MTRReadClientContainer * container in listToFail) { - // Send auto resubscribe request again by read clients, which must fail. - chip::app::ReadPrepareParams readParams; - if (container.readClientPtr) { - container.readClientPtr->SendAutoResubscribeRequest(std::move(readParams)); + [controller + asyncDispatchToMatterQueue:^(Controller::DeviceCommissioner * commissioner) { + for (MTRReadClientContainer * container in listToFail) { + // Send auto resubscribe request again by read clients, which must fail. + chip::app::ReadPrepareParams readParams; + if (container.readClientPtr) { + container.readClientPtr->SendAutoResubscribeRequest(std::move(readParams)); + } + } + if (completion) { + dispatch_async(queue, completion); } } - if (completion) { - dispatch_async(queue, completion); - } - }); + errorHandler:^(NSError * error) { + // Can't fail things. Just put them back. + ReinstateReadClientList(listToFail, key, queue, completion); + }]; } #endif @@ -321,6 +350,7 @@ - (void)subscribeWithQueue:(dispatch_queue_t)queue MTRClusterStateCacheContainer * container = weakPtr; if (container) { container.cppClusterStateCache = nullptr; + container.baseDevice = nil; } }; } @@ -393,6 +423,7 @@ - (void)subscribeWithQueue:(dispatch_queue_t)queue clusterStateCacheContainer.cppClusterStateCache = clusterStateCache.get(); // ClusterStateCache will be deleted when OnDone is called. callback->AdoptClusterStateCache(std::move(clusterStateCache)); + clusterStateCacheContainer.baseDevice = self; } // Callback and ReadClient will be deleted when OnDone is called. callback->AdoptReadClient(std::move(readClient)); @@ -1243,7 +1274,7 @@ - (void)deregisterReportHandlersWithQueue:(dispatch_queue_t)queue completion:(di { // This method must only be used for MTRDeviceOverXPC. However, for unit testing purpose, the method purges all read clients. MTR_LOG_DEBUG("Unexpected call to deregister report handlers"); - PurgeReadClientContainers(self.nodeID, queue, completion); + PurgeReadClientContainers(self.deviceController, self.nodeID, queue, completion); } namespace { @@ -1389,7 +1420,7 @@ - (void)openCommissioningWindowWithSetupPasscode:(NSNumber *)setupPasscode - (void)failSubscribers:(dispatch_queue_t)queue completion:(void (^)(void))completion { MTR_LOG_DEBUG("Causing failure in subscribers on purpose"); - CauseReadClientFailure(self.nodeID, queue, completion); + CauseReadClientFailure(self.deviceController, self.nodeID, queue, completion); } #endif diff --git a/src/darwin/Framework/CHIP/MTRCSRInfo.m b/src/darwin/Framework/CHIP/MTRCSRInfo.mm similarity index 100% rename from src/darwin/Framework/CHIP/MTRCSRInfo.m rename to src/darwin/Framework/CHIP/MTRCSRInfo.mm diff --git a/src/darwin/Framework/CHIP/MTRCallbackBridgeBase_internal.h b/src/darwin/Framework/CHIP/MTRCallbackBridgeBase_internal.h index 31ac86e348f8bc..c6ef366925302f 100644 --- a/src/darwin/Framework/CHIP/MTRCallbackBridgeBase_internal.h +++ b/src/darwin/Framework/CHIP/MTRCallbackBridgeBase_internal.h @@ -27,6 +27,8 @@ #include #include +NS_ASSUME_NONNULL_BEGIN + /** * Bridge that allows invoking a given MTRActionBlock on the Matter queue, after * communication with the device in question has been established, as far as we @@ -35,11 +37,7 @@ class MTRCallbackBridgeBase { }; -// TODO: ADD NS_ASSUME_NONNULL_BEGIN to this header. When that happens, note -// that in MTRActionBlock the two callback pointers are nonnull and the two -// arguments of MTRResponseHandler are both nullable. - -typedef void (^MTRResponseHandler)(id value, NSError * error); +typedef void (^MTRResponseHandler)(id _Nullable value, NSError * _Nullable error); typedef void (*MTRErrorCallback)(void * context, CHIP_ERROR error); /** @@ -85,7 +83,7 @@ template class MTRCallbackBridge : public MTRCallbackBridgeBase { * Construct a callback bridge, which can then have DispatchAction() called * on it. */ - MTRCallbackBridge(dispatch_queue_t queue, MTRResponseHandler handler, MTRActionBlock action, T OnSuccessFn) + MTRCallbackBridge(dispatch_queue_t queue, MTRResponseHandler handler, MTRActionBlock _Nonnull action, T OnSuccessFn) : mQueue(queue) , mHandler(handler) , mAction(action) @@ -123,29 +121,38 @@ template class MTRCallbackBridge : public MTRCallbackBridgeBase { } /** - * Run the given MTRLocalActionBlock on the Matter thread, then handle + * Try to run the given MTRLocalActionBlock on the Matter thread, if we have + * a device and it's attached to a running controller, then handle * converting the value produced by the success callback to the right type * so it can be passed to a callback of the type we're templated over. * * Does not attempt to establish any sessions to devices. Must not be used * with any action blocks that need a session. */ - void DispatchLocalAction(MTRLocalActionBlock action) + void DispatchLocalAction(MTRBaseDevice * _Nullable device, MTRLocalActionBlock _Nonnull action) { - LogRequestStart(); + if (!device) { + OnFailureFn(this, CHIP_ERROR_INCORRECT_STATE); + return; + } - // For now keep sync dispatch here. - dispatch_sync(chip::DeviceLayer::PlatformMgrImpl().GetWorkQueue(), ^{ - CHIP_ERROR err = action(mSuccess, mFailure); - if (err != CHIP_NO_ERROR) { - NSLog(@"Failure performing action. C++-mangled success callback type: '%s', error: %s", typeid(T).name(), - chip::ErrorStr(err)); + LogRequestStart(); - // Take the normal async error-reporting codepath. This will also - // handle cleaning us up properly. - OnFailureFn(this, err); + [device.deviceController + asyncDispatchToMatterQueue:^(chip::Controller::DeviceCommissioner *) { + CHIP_ERROR err = action(mSuccess, mFailure); + if (err != CHIP_NO_ERROR) { + NSLog(@"Failure performing action. C++-mangled success callback type: '%s', error: %s", typeid(T).name(), + chip::ErrorStr(err)); + + // Take the normal async error-reporting codepath. This will also + // handle cleaning us up properly. + OnFailureFn(this, err); + } } - }); + errorHandler:^(NSError * error) { + DispatchFailure(this, error); + }]; } void ActionWithPASEDevice(MTRBaseDevice * device) @@ -187,8 +194,8 @@ template class MTRCallbackBridge : public MTRCallbackBridgeBase { ChipLogDetail(Controller, "%s", mCookie.UTF8String); } - void MaybeDoAction( - chip::Messaging::ExchangeManager * exchangeManager, const chip::Optional & session, NSError * error) + void MaybeDoAction(chip::Messaging::ExchangeManager * _Nullable exchangeManager, + const chip::Optional & session, NSError * _Nullable error) { // Make sure we don't hold on to our action longer than we have to. auto action = mAction; @@ -213,7 +220,7 @@ template class MTRCallbackBridge : public MTRCallbackBridgeBase { static void OnFailureFn(void * context, CHIP_ERROR error) { DispatchFailure(context, [MTRError errorForCHIPErrorCode:error]); } - static void DispatchSuccess(void * context, id value) { DispatchCallbackResult(context, nil, value); } + static void DispatchSuccess(void * context, id _Nullable value) { DispatchCallbackResult(context, nil, value); } static void DispatchFailure(void * context, NSError * error) { DispatchCallbackResult(context, error, nil); } @@ -241,7 +248,7 @@ template class MTRCallbackBridge : public MTRCallbackBridgeBase { dispatch_queue_t mQueue; private: - static void DispatchCallbackResult(void * context, NSError * error, id value) + static void DispatchCallbackResult(void * context, NSError * _Nullable error, id _Nullable value) { MTRCallbackBridge * callbackBridge = static_cast(context); if (!callbackBridge) { @@ -267,7 +274,7 @@ template class MTRCallbackBridge : public MTRCallbackBridgeBase { } MTRResponseHandler mHandler; - MTRActionBlock mAction; + MTRActionBlock _Nullable mAction; bool mKeepAlive = false; T mSuccess; @@ -277,3 +284,5 @@ template class MTRCallbackBridge : public MTRCallbackBridgeBase { NSDate * mRequestTime; NSString * mCookie; }; + +NS_ASSUME_NONNULL_END diff --git a/src/darwin/Framework/CHIP/MTRCertificates.mm b/src/darwin/Framework/CHIP/MTRCertificates.mm index 39735bd79d3771..c1699d616c3706 100644 --- a/src/darwin/Framework/CHIP/MTRCertificates.mm +++ b/src/darwin/Framework/CHIP/MTRCertificates.mm @@ -16,8 +16,8 @@ #import "MTRCertificates.h" #import "MTRError_Internal.h" -#import "MTRLogging.h" -#import "MTRMemory.h" +#import "MTRFramework.h" +#import "MTRLogging_Internal.h" #import "MTROperationalCredentialsDelegate.h" #import "MTRP256KeypairBridge.h" #import "NSDataSpanConversion.h" @@ -31,15 +31,17 @@ @implementation MTRCertificates ++ (void)initialize +{ + MTRFrameworkInit(); +} + + (MTRCertificateDERBytes _Nullable)createRootCertificate:(id)keypair issuerID:(NSNumber * _Nullable)issuerID fabricID:(NSNumber * _Nullable)fabricID error:(NSError * __autoreleasing *)error { - NSLog(@"Generating root certificate"); - - [MTRMemory ensureInit]; - + MTR_LOG_DEFAULT("Generating root certificate"); NSData * rootCert = nil; CHIP_ERROR err = MTROperationalCredentialsDelegate::GenerateRootCertificate(keypair, issuerID, fabricID, &rootCert); if (error) { @@ -47,7 +49,7 @@ + (MTRCertificateDERBytes _Nullable)createRootCertificate:(id)keypai } if (err != CHIP_NO_ERROR) { - NSLog(@"Generating root certificate failed: %s", ErrorStr(err)); + MTR_LOG_ERROR("Generating root certificate failed: %s", ErrorStr(err)); } return rootCert; @@ -60,10 +62,7 @@ + (MTRCertificateDERBytes _Nullable)createIntermediateCertificate:(id caseAuthenticatedTags:(NSArray * _Nullable)caseAuthenticatedTags error:(NSError * __autoreleasing _Nullable * _Nullable)error { - NSLog(@"Generating operational certificate"); - - [MTRMemory ensureInit]; - + MTR_LOG_DEFAULT("Generating operational certificate"); NSData * opcert = nil; CHIP_ERROR err = MTROperationalCredentialsDelegate::GenerateOperationalCertificate( signingKeypair, signingCertificate, operationalPublicKey, fabricID, nodeID, caseAuthenticatedTags, &opcert); @@ -98,7 +94,7 @@ + (MTRCertificateDERBytes _Nullable)createOperationalCertificate:(id } if (err != CHIP_NO_ERROR) { - NSLog(@"Generating operational certificate failed: %s", ErrorStr(err)); + MTR_LOG_ERROR("Generating operational certificate failed: %s", ErrorStr(err)); } return opcert; @@ -106,12 +102,10 @@ + (MTRCertificateDERBytes _Nullable)createOperationalCertificate:(id + (BOOL)keypair:(id)keypair matchesCertificate:(NSData *)certificate { - [MTRMemory ensureInit]; - P256PublicKey keypairPubKey; CHIP_ERROR err = MTRP256KeypairBridge::MatterPubKeyFromSecKeyRef(keypair.publicKey, &keypairPubKey); if (err != CHIP_NO_ERROR) { - NSLog(@"Can't extract public key from keypair: %s", ErrorStr(err)); + MTR_LOG_ERROR("Can't extract public key from keypair: %s", ErrorStr(err)); return NO; } P256PublicKeySpan keypairKeySpan(keypairPubKey.ConstBytes()); @@ -119,7 +113,7 @@ + (BOOL)keypair:(id)keypair matchesCertificate:(NSData *)certificate P256PublicKey certPubKey; err = ExtractPubkeyFromX509Cert(AsByteSpan(certificate), certPubKey); if (err != CHIP_NO_ERROR) { - NSLog(@"Can't extract public key from certificate: %s", ErrorStr(err)); + MTR_LOG_ERROR("Can't extract public key from certificate: %s", ErrorStr(err)); return NO; } P256PublicKeySpan certKeySpan(certPubKey.ConstBytes()); @@ -129,12 +123,10 @@ + (BOOL)keypair:(id)keypair matchesCertificate:(NSData *)certificate + (BOOL)isCertificate:(MTRCertificateDERBytes)certificate1 equalTo:(MTRCertificateDERBytes)certificate2 { - [MTRMemory ensureInit]; - P256PublicKey pubKey1; CHIP_ERROR err = ExtractPubkeyFromX509Cert(AsByteSpan(certificate1), pubKey1); if (err != CHIP_NO_ERROR) { - NSLog(@"Can't extract public key from first certificate: %s", ErrorStr(err)); + MTR_LOG_ERROR("Can't extract public key from first certificate: %s", ErrorStr(err)); return NO; } P256PublicKeySpan keySpan1(pubKey1.ConstBytes()); @@ -142,7 +134,7 @@ + (BOOL)isCertificate:(MTRCertificateDERBytes)certificate1 equalTo:(MTRCertifica P256PublicKey pubKey2; err = ExtractPubkeyFromX509Cert(AsByteSpan(certificate2), pubKey2); if (err != CHIP_NO_ERROR) { - NSLog(@"Can't extract public key from second certificate: %s", ErrorStr(err)); + MTR_LOG_ERROR("Can't extract public key from second certificate: %s", ErrorStr(err)); return NO; } P256PublicKeySpan keySpan2(pubKey1.ConstBytes()); @@ -154,14 +146,14 @@ + (BOOL)isCertificate:(MTRCertificateDERBytes)certificate1 equalTo:(MTRCertifica ChipDN subject1; err = ExtractSubjectDNFromX509Cert(AsByteSpan(certificate1), subject1); if (err != CHIP_NO_ERROR) { - NSLog(@"Can't extract subject DN from first certificate: %s", ErrorStr(err)); + MTR_LOG_ERROR("Can't extract subject DN from first certificate: %s", ErrorStr(err)); return NO; } ChipDN subject2; err = ExtractSubjectDNFromX509Cert(AsByteSpan(certificate2), subject2); if (err != CHIP_NO_ERROR) { - NSLog(@"Can't extract subject DN from second certificate: %s", ErrorStr(err)); + MTR_LOG_ERROR("Can't extract subject DN from second certificate: %s", ErrorStr(err)); return NO; } @@ -171,8 +163,6 @@ + (BOOL)isCertificate:(MTRCertificateDERBytes)certificate1 equalTo:(MTRCertifica + (NSData * _Nullable)createCertificateSigningRequest:(id)keypair error:(NSError * __autoreleasing _Nullable * _Nullable)error { - [MTRMemory ensureInit]; - MTRP256KeypairBridge keypairBridge; CHIP_ERROR err = CHIP_NO_ERROR; do { @@ -206,7 +196,7 @@ + (MTRCertificateTLVBytes _Nullable)convertX509Certificate:(MTRCertificateDERByt chip::MutableByteSpan chipCertBytes(chipCertBuffer); CHIP_ERROR errorCode = chip::Credentials::ConvertX509CertToChipCert(x509CertBytes, chipCertBytes); - MTR_LOG_ERROR("ConvertX509CertToChipCert: %{public}s", chip::ErrorStr(errorCode)); + MTR_LOG_ERROR("ConvertX509CertToChipCert: %s", chip::ErrorStr(errorCode)); if (errorCode != CHIP_NO_ERROR) return nil; @@ -224,7 +214,7 @@ + (MTRCertificateDERBytes _Nullable)convertMatterCertificate:(MTRCertificateTLVB CHIP_ERROR errorCode = chip::Credentials::ConvertChipCertToX509Cert(tlvCertBytes, derCertBytes); if (errorCode != CHIP_NO_ERROR) { - MTR_LOG_ERROR("ConvertChipCertToX509Cert: %{public}s", chip::ErrorStr(errorCode)); + MTR_LOG_ERROR("ConvertChipCertToX509Cert: %s", chip::ErrorStr(errorCode)); return nil; } diff --git a/src/darwin/Framework/CHIP/MTRClusterStateCacheContainer.mm b/src/darwin/Framework/CHIP/MTRClusterStateCacheContainer.mm index 81eb66239b596b..7550e1ef3f2448 100644 --- a/src/darwin/Framework/CHIP/MTRClusterStateCacheContainer.mm +++ b/src/darwin/Framework/CHIP/MTRClusterStateCacheContainer.mm @@ -21,9 +21,10 @@ #import "MTRCluster.h" #import "MTRClusterStateCacheContainer_Internal.h" #import "MTRDeviceControllerXPCConnection.h" +#import "MTRDeviceController_Internal.h" #import "MTRError.h" #import "MTRError_Internal.h" -#import "MTRLogging.h" +#import "MTRLogging_Internal.h" #include #include @@ -31,12 +32,20 @@ using namespace chip; +@interface MTRClusterStateCacheContainer () +@property (nonatomic, readwrite, copy) NSNumber * deviceID; +@property (nonatomic, readwrite, weak, nullable) MTRDeviceControllerXPCConnection * xpcConnection; +@property (nonatomic, readwrite, strong, nullable) id xpcControllerID; +@property (atomic, readwrite) BOOL shouldUseXPC; +@end + @implementation MTRClusterStateCacheContainer - (instancetype)init { if ([super init]) { _cppClusterStateCache = nullptr; + _baseDevice = nil; _shouldUseXPC = NO; } return self; @@ -94,7 +103,7 @@ - (void)readAttributesWithEndpointID:(NSNumber * _Nullable)endpointID MTRDeviceControllerXPCConnection * xpcConnection = self.xpcConnection; if (!xpcConnection) { MTR_LOG_ERROR("Attribute cache read failed: MTRDeviceController was already disposed"); - completion(nil, [NSError errorWithDomain:MTRErrorDomain code:MTRErrorCodeGeneralError userInfo:nil]); + completionHandler(nil, [NSError errorWithDomain:MTRErrorDomain code:MTRErrorCodeGeneralError userInfo:nil]); return; } __auto_type controllerId = self.xpcControllerID; @@ -102,81 +111,93 @@ - (void)readAttributesWithEndpointID:(NSNumber * _Nullable)endpointID [xpcConnection getProxyHandleWithCompletion:^(dispatch_queue_t _Nonnull queue, MTRDeviceControllerXPCProxyHandle * _Nullable handle) { if (handle) { - [handle.proxy readAttributeCacheWithController:controllerId - nodeId:nodeId.unsignedLongLongValue - endpointId:endpointID - clusterId:clusterID - attributeId:attributeID - completion:^(id _Nullable values, NSError * _Nullable error) { - completion([MTRDeviceController decodeXPCResponseValues:values], error); - __auto_type handleRetainer = handle; - (void) handleRetainer; - }]; + [handle.proxy + readAttributeCacheWithController:controllerId + nodeId:nodeId.unsignedLongLongValue + endpointId:endpointID + clusterId:clusterID + attributeId:attributeID + completion:^(id _Nullable values, NSError * _Nullable error) { + completionHandler([MTRDeviceController decodeXPCResponseValues:values], error); + __auto_type handleRetainer = handle; + (void) handleRetainer; + }]; } else { MTR_LOG_ERROR("Attribute cache read failed due to XPC connection failure"); - completion(nil, [NSError errorWithDomain:MTRErrorDomain code:MTRErrorCodeGeneralError userInfo:nil]); + completionHandler(nil, [NSError errorWithDomain:MTRErrorDomain code:MTRErrorCodeGeneralError userInfo:nil]); } }]; return; } - dispatch_async(DeviceLayer::PlatformMgrImpl().GetWorkQueue(), ^{ - if (endpointID == nil && clusterID == nil) { - MTR_LOG_ERROR("Error: currently read from attribute cache does not support wildcards for both endpoint and cluster"); - completionHandler(nil, [NSError errorWithDomain:MTRErrorDomain code:MTRErrorCodeInvalidArgument userInfo:nil]); - return; - } - - if (!self.cppClusterStateCache) { - MTR_LOG_ERROR("Error: No attribute cache available to read from"); - completionHandler(nil, [NSError errorWithDomain:MTRErrorDomain code:MTRErrorCodeGeneralError userInfo:nil]); - return; - } + if (!self.baseDevice) { + MTR_LOG_ERROR("Error: No attribute cache available to read from"); + completionHandler(nil, [NSError errorWithDomain:MTRErrorDomain code:MTRErrorCodeGeneralError userInfo:nil]); + return; + } - NSMutableArray * result = [[NSMutableArray alloc] init]; - CHIP_ERROR err = CHIP_NO_ERROR; - if (endpointID == nil) { - err = self.cppClusterStateCache->ForEachAttribute( - static_cast([clusterID unsignedLongValue]), [&](const app::ConcreteAttributePath & path) { - if (attributeID == nil - || static_cast([attributeID unsignedLongValue]) == path.mAttributeId) { + [self.baseDevice.deviceController + asyncDispatchToMatterQueue:^(Controller::DeviceCommissioner *) { + if (endpointID == nil && clusterID == nil) { + MTR_LOG_ERROR( + "Error: currently read from attribute cache does not support wildcards for both endpoint and cluster"); + completionHandler(nil, [NSError errorWithDomain:MTRErrorDomain code:MTRErrorCodeInvalidArgument userInfo:nil]); + return; + } + + if (!self.cppClusterStateCache) { + MTR_LOG_ERROR("Error: No attribute cache available to read from"); + completionHandler(nil, [NSError errorWithDomain:MTRErrorDomain code:MTRErrorCodeGeneralError userInfo:nil]); + return; + } + + NSMutableArray * result = [[NSMutableArray alloc] init]; + CHIP_ERROR err = CHIP_NO_ERROR; + if (endpointID == nil) { + err = self.cppClusterStateCache->ForEachAttribute( + static_cast([clusterID unsignedLongValue]), [&](const app::ConcreteAttributePath & path) { + if (attributeID == nil + || static_cast([attributeID unsignedLongValue]) == path.mAttributeId) { + (void) AppendAttributeValueToArray(path, self.cppClusterStateCache, result); + } + return CHIP_NO_ERROR; + }); + } else if (clusterID == nil) { + err = self.cppClusterStateCache->ForEachCluster( + static_cast([endpointID unsignedShortValue]), [&](chip::ClusterId enumeratedClusterId) { + (void) self.cppClusterStateCache->ForEachAttribute( + static_cast([endpointID unsignedShortValue]), enumeratedClusterId, + [&](const app::ConcreteAttributePath & path) { + if (attributeID == nil + || static_cast([attributeID unsignedLongValue]) == path.mAttributeId) { + (void) AppendAttributeValueToArray(path, self.cppClusterStateCache, result); + } + return CHIP_NO_ERROR; + }); + return CHIP_NO_ERROR; + }); + } else if (attributeID == nil) { + err = self.cppClusterStateCache->ForEachAttribute(static_cast([endpointID unsignedShortValue]), + static_cast([clusterID unsignedLongValue]), [&](const app::ConcreteAttributePath & path) { (void) AppendAttributeValueToArray(path, self.cppClusterStateCache, result); - } - return CHIP_NO_ERROR; - }); - } else if (clusterID == nil) { - err = self.cppClusterStateCache->ForEachCluster( - static_cast([endpointID unsignedShortValue]), [&](chip::ClusterId enumeratedClusterId) { - (void) self.cppClusterStateCache->ForEachAttribute( - static_cast([endpointID unsignedShortValue]), enumeratedClusterId, - [&](const app::ConcreteAttributePath & path) { - if (attributeID == nil - || static_cast([attributeID unsignedLongValue]) == path.mAttributeId) { - (void) AppendAttributeValueToArray(path, self.cppClusterStateCache, result); - } - return CHIP_NO_ERROR; - }); - return CHIP_NO_ERROR; - }); - } else if (attributeID == nil) { - err = self.cppClusterStateCache->ForEachAttribute(static_cast([endpointID unsignedShortValue]), - static_cast([clusterID unsignedLongValue]), [&](const app::ConcreteAttributePath & path) { - (void) AppendAttributeValueToArray(path, self.cppClusterStateCache, result); - return CHIP_NO_ERROR; - }); - } else { - app::ConcreteAttributePath path; - path.mEndpointId = static_cast([endpointID unsignedShortValue]); - path.mClusterId = static_cast([clusterID unsignedLongValue]); - path.mAttributeId = static_cast([attributeID unsignedLongValue]); - err = AppendAttributeValueToArray(path, self.cppClusterStateCache, result); - } - if (err == CHIP_NO_ERROR) { - completionHandler(result, nil); - } else { - completionHandler(nil, [NSError errorWithDomain:MTRErrorDomain code:err.AsInteger() userInfo:nil]); + return CHIP_NO_ERROR; + }); + } else { + app::ConcreteAttributePath path; + path.mEndpointId = static_cast([endpointID unsignedShortValue]); + path.mClusterId = static_cast([clusterID unsignedLongValue]); + path.mAttributeId = static_cast([attributeID unsignedLongValue]); + err = AppendAttributeValueToArray(path, self.cppClusterStateCache, result); + } + if (err == CHIP_NO_ERROR) { + completionHandler(result, nil); + } else { + completionHandler(nil, [NSError errorWithDomain:MTRErrorDomain code:err.AsInteger() userInfo:nil]); + } } - }); + errorHandler:^(NSError * error) { + completionHandler(nil, error); + }]; } @end diff --git a/src/darwin/Framework/CHIP/MTRClusterStateCacheContainer_Internal.h b/src/darwin/Framework/CHIP/MTRClusterStateCacheContainer_Internal.h index 4b6c6eb47a3c62..d515cf2b325cbb 100644 --- a/src/darwin/Framework/CHIP/MTRClusterStateCacheContainer_Internal.h +++ b/src/darwin/Framework/CHIP/MTRClusterStateCacheContainer_Internal.h @@ -27,10 +27,7 @@ NS_ASSUME_NONNULL_BEGIN @interface MTRClusterStateCacheContainer () @property (atomic, readwrite, nullable) chip::app::ClusterStateCache * cppClusterStateCache; -@property (nonatomic, readwrite, copy) NSNumber * deviceID; -@property (nonatomic, readwrite, weak, nullable) MTRDeviceControllerXPCConnection * xpcConnection; -@property (nonatomic, readwrite, strong, nullable) id xpcControllerID; -@property (atomic, readwrite) BOOL shouldUseXPC; +@property (nonatomic, readwrite, nullable) MTRBaseDevice * baseDevice; @end diff --git a/src/darwin/Framework/CHIP/MTRCommissioningParameters.h b/src/darwin/Framework/CHIP/MTRCommissioningParameters.h index ff115df8a8eade..1359178ec9f5c7 100644 --- a/src/darwin/Framework/CHIP/MTRCommissioningParameters.h +++ b/src/darwin/Framework/CHIP/MTRCommissioningParameters.h @@ -60,6 +60,8 @@ NS_ASSUME_NONNULL_BEGIN * An optional delegate that can be notified upon completion of device * attestation. See documentation for MTRDeviceAttestationDelegate for * details. + * + * The delegate methods will be invoked on an arbitrary thread. */ @property (nonatomic, strong, nullable) id deviceAttestationDelegate; /** @@ -68,7 +70,6 @@ NS_ASSUME_NONNULL_BEGIN * * If nil, the fail-safe will not be extended before calling into the * deviceAttestationDelegate. - */ @property (nonatomic, copy, nullable) NSNumber * failSafeExpiryTimeout MTR_NEWLY_AVAILABLE; diff --git a/src/darwin/Framework/CHIP/MTRCommissioningParameters.m b/src/darwin/Framework/CHIP/MTRCommissioningParameters.mm similarity index 100% rename from src/darwin/Framework/CHIP/MTRCommissioningParameters.m rename to src/darwin/Framework/CHIP/MTRCommissioningParameters.mm diff --git a/src/darwin/Framework/CHIP/MTRMemory.mm b/src/darwin/Framework/CHIP/MTRDefines.h similarity index 69% rename from src/darwin/Framework/CHIP/MTRMemory.mm rename to src/darwin/Framework/CHIP/MTRDefines.h index f6c94bf4682b18..0751dda4011c77 100644 --- a/src/darwin/Framework/CHIP/MTRMemory.mm +++ b/src/darwin/Framework/CHIP/MTRDefines.h @@ -1,4 +1,5 @@ /** + * * Copyright (c) 2022 Project CHIP Authors * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -14,19 +15,12 @@ * limitations under the License. */ -#import "MTRMemory.h" - -#include - -@implementation MTRMemory +#import -+ (void)ensureInit -{ - static dispatch_once_t onceToken; - dispatch_once(&onceToken, ^{ - // The malloc version of MemoryInit never fails. - chip::Platform::MemoryInit(); - }); -} +#define MTR_EXPORT __attribute__((visibility("default"))) -@end +#ifdef __cplusplus +#define MTR_EXTERN extern "C" MTR_EXPORT +#else +#define MTR_EXTERN extern MTR_EXPORT +#endif diff --git a/src/darwin/Framework/CHIP/MTRDevice.mm b/src/darwin/Framework/CHIP/MTRDevice.mm index 382d114e887534..b8ac46c3004b47 100644 --- a/src/darwin/Framework/CHIP/MTRDevice.mm +++ b/src/darwin/Framework/CHIP/MTRDevice.mm @@ -25,7 +25,7 @@ #import "MTRDevice_Internal.h" #import "MTRError_Internal.h" #import "MTREventTLVValueDecoder_Internal.h" -#import "MTRLogging.h" +#import "MTRLogging_Internal.h" #include "lib/core/CHIPError.h" #include "lib/core/DataModelTypes.h" @@ -130,13 +130,18 @@ - (id)strongObject #pragma mark - MTRDevice @interface MTRDevice () @property (nonatomic, readonly) os_unfair_lock lock; // protects the caches and device state -@property (nonatomic) dispatch_queue_t queue; +@property (nonatomic) chip::FabricIndex fabricIndex; @property (nonatomic) MTRWeakReference> * weakDelegate; @property (nonatomic) dispatch_queue_t delegateQueue; @property (nonatomic) NSArray *> * unreportedEvents; @property (nonatomic) BOOL subscriptionActive; +#define MTRDEVICE_SUBSCRIPTION_ATTEMPT_MIN_WAIT_SECONDS (1) +#define MTRDEVICE_SUBSCRIPTION_ATTEMPT_MAX_WAIT_SECONDS (3600) +@property (nonatomic) uint32_t lastSubscriptionAttemptWait; +@property (nonatomic) BOOL reattemptingSubscription; + // Read cache is attributePath => NSDictionary of value. // See MTRDeviceResponseHandler definition for value dictionary details. @property (nonatomic) NSMutableDictionary * readCache; @@ -155,17 +160,23 @@ - (instancetype)initWithNodeID:(NSNumber *)nodeID controller:(MTRDeviceControlle if (self = [super init]) { _lock = OS_UNFAIR_LOCK_INIT; _nodeID = [nodeID copy]; + _fabricIndex = controller.fabricIndex; _deviceController = controller; - _queue = dispatch_queue_create("com.apple.matter.framework.xpc.workqueue", DISPATCH_QUEUE_SERIAL); - ; + _queue = dispatch_queue_create("com.apple.matter.framework.device.workqueue", DISPATCH_QUEUE_SERIAL); _readCache = [NSMutableDictionary dictionary]; _expectedValueCache = [NSMutableDictionary dictionary]; _asyncCallbackWorkQueue = [[MTRAsyncCallbackWorkQueue alloc] initWithContext:self queue:_queue]; _state = MTRDeviceStateUnknown; + MTR_LOG_INFO("%@ init with hex nodeID 0x%016llX", self, _nodeID.unsignedLongLongValue); } return self; } +- (NSString *)description +{ + return [NSString stringWithFormat:@"[fabric: %u, nodeID: %@]", self, _fabricIndex, _nodeID]; +} + + (instancetype)deviceWithNodeID:(NSNumber *)nodeID controller:(MTRDeviceController *)controller { return [controller deviceForNodeID:nodeID]; @@ -179,11 +190,22 @@ + (instancetype)deviceWithNodeID:(NSNumber *)nodeID controller:(MTRDeviceControl - (void)setDelegate:(id)delegate queue:(dispatch_queue_t)queue { + MTR_LOG_INFO("%@ setDelegate %@", self, delegate); os_unfair_lock_lock(&self->_lock); _weakDelegate = [MTRWeakReference weakReferenceWithObject:delegate]; _delegateQueue = queue; - [self setupSubscription]; + [self _setupSubscription]; + + os_unfair_lock_unlock(&self->_lock); +} + +- (void)invalidate +{ + MTR_LOG_INFO("%@ invalidate", self); + os_unfair_lock_lock(&self->_lock); + + _weakDelegate = nil; os_unfair_lock_unlock(&self->_lock); } @@ -192,6 +214,9 @@ - (void)_handleSubscriptionEstablished { os_unfair_lock_lock(&self->_lock); + // reset subscription attempt wait time when subscription succeeds + _lastSubscriptionAttemptWait = 0; + _state = MTRDeviceStateReachable; id delegate = _weakDelegate.strongObject; if (delegate) { @@ -208,6 +233,7 @@ - (void)_handleSubscriptionError:(NSError *)error os_unfair_lock_lock(&self->_lock); _subscriptionActive = NO; + _unreportedEvents = nil; id delegate = _weakDelegate.strongObject; if (delegate) { @@ -237,7 +263,43 @@ - (void)_handleResubscriptionNeeded - (void)_handleSubscriptionReset { - // TODO: logic to reattempt subscription with exponential back off + os_unfair_lock_lock(&self->_lock); + // if there is no delegate then also do not retry + id delegate = _weakDelegate.strongObject; + if (!delegate) { + MTR_LOG_INFO("%@ no delegate - do not reattempt subscription", self); + os_unfair_lock_unlock(&self->_lock); + return; + } + + // don't schedule multiple retries + if (self.reattemptingSubscription) { + MTR_LOG_INFO("%@ already reattempting subscription", self); + os_unfair_lock_unlock(&self->_lock); + return; + } + + self.reattemptingSubscription = YES; + + if (_lastSubscriptionAttemptWait < MTRDEVICE_SUBSCRIPTION_ATTEMPT_MIN_WAIT_SECONDS) { + _lastSubscriptionAttemptWait = MTRDEVICE_SUBSCRIPTION_ATTEMPT_MIN_WAIT_SECONDS; + } else { + _lastSubscriptionAttemptWait *= 2; + if (_lastSubscriptionAttemptWait > MTRDEVICE_SUBSCRIPTION_ATTEMPT_MAX_WAIT_SECONDS) { + _lastSubscriptionAttemptWait = MTRDEVICE_SUBSCRIPTION_ATTEMPT_MAX_WAIT_SECONDS; + } + } + + MTR_LOG_INFO("%@ scheduling to reattempt subscription in %u seconds", self, _lastSubscriptionAttemptWait); + dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(_lastSubscriptionAttemptWait * NSEC_PER_SEC)), self.queue, ^{ + os_unfair_lock_lock(&self->_lock); + MTR_LOG_INFO("%@ reattempting subscription", self); + self.reattemptingSubscription = NO; + [self _setupSubscription]; + os_unfair_lock_unlock(&self->_lock); + }); + + os_unfair_lock_unlock(&self->_lock); } // assume lock is held @@ -258,6 +320,7 @@ - (void)_handleAttributeReport:(NSArray *> *)attrib { os_unfair_lock_lock(&self->_lock); + // _getAttributesToReportWithReportedValues will log attribute paths reported [self _reportAttributes:[self _getAttributesToReportWithReportedValues:attributeReport]]; os_unfair_lock_unlock(&self->_lock); @@ -286,8 +349,11 @@ - (void)_handleEventReport:(NSArray *> *)eventRepor os_unfair_lock_unlock(&self->_lock); } -- (void)setupSubscription +// assume lock is held +- (void)_setupSubscription { + os_unfair_lock_assert_owner(&self->_lock); + // for now just subscribe once if (_subscriptionActive) { return; @@ -299,8 +365,10 @@ - (void)setupSubscription completion:^(chip::Messaging::ExchangeManager * _Nullable exchangeManager, const chip::Optional & session, NSError * _Nullable error) { if (error != nil) { + MTR_LOG_INFO("%@ getSessionForNode error %@", self, error); dispatch_async(self.queue, ^{ [self _handleSubscriptionError:error]; + [self _handleSubscriptionReset]; }); return; } @@ -329,66 +397,83 @@ - (void)setupSubscription readParams.mpEventPathParamsList = eventPath.get(); readParams.mEventPathParamsListSize = 1; readParams.mKeepSubscriptions = true; + readParams.mIsFabricFiltered = false; attributePath.release(); eventPath.release(); - std::unique_ptr callback; - std::unique_ptr readClient; - std::unique_ptr clusterStateCache; - callback = std::make_unique( + auto callback = std::make_unique( ^(NSArray * value) { + MTR_LOG_INFO("%@ got attribute report %@", self, value); dispatch_async(self.queue, ^{ // OnAttributeData (after OnReportEnd) [self _handleAttributeReport:value]; }); }, ^(NSArray * value) { + MTR_LOG_INFO("%@ got event report %@", self, value); dispatch_async(self.queue, ^{ // OnEventReport (after OnReportEnd) [self _handleEventReport:value]; }); }, ^(NSError * error) { + MTR_LOG_INFO("%@ got subscription error %@", self, error); dispatch_async(self.queue, ^{ // OnError [self _handleSubscriptionError:error]; }); }, ^(NSError * error, NSNumber * resubscriptionDelay) { + MTR_LOG_INFO("%@ got resubscription error %@ delay %@", self, error, resubscriptionDelay); dispatch_async(self.queue, ^{ // OnResubscriptionNeeded [self _handleResubscriptionNeeded]; }); }, ^(void) { + MTR_LOG_INFO("%@ got subscription established", self); dispatch_async(self.queue, ^{ // OnSubscriptionEstablished [self _handleSubscriptionEstablished]; }); }, ^(void) { + MTR_LOG_INFO("%@ got subscription done", self); dispatch_async(self.queue, ^{ // OnDone [self _handleSubscriptionReset]; }); }); - readClient = std::make_unique(InteractionModelEngine::GetInstance(), exchangeManager, - callback->GetBufferedCallback(), ReadClient::InteractionType::Subscribe); + + // Set up a cluster state cache. We really just want this for the + // logic it has for tracking data versions and event numbers so we + // minimize the amount of data we request on resubscribes; we + // don't care about the data it stores. Ideally we could use the + // dataversion-management logic without needing to store the data + // separately from the data store we already have, or we would + // stop storing our data separately. + auto clusterStateCache = std::make_unique(*callback.get()); + auto readClient + = std::make_unique(InteractionModelEngine::GetInstance(), exchangeManager, + clusterStateCache->GetBufferedCallback(), ReadClient::InteractionType::Subscribe); // SendAutoResubscribeRequest cleans up the params, even on failure. CHIP_ERROR err = readClient->SendAutoResubscribeRequest(std::move(readParams)); if (err != CHIP_NO_ERROR) { + NSError * error = [MTRError errorForCHIPErrorCode:err]; + MTR_LOG_INFO("%@ SendAutoResubscribeRequest error %@", self, error); dispatch_async(self.queue, ^{ - [self _handleSubscriptionError:[MTRError errorForCHIPErrorCode:err]]; + [self _handleSubscriptionError:error]; }); return; } - // Callback and ReadClient will be deleted when OnDone is called or an error is - // encountered. + // Callback and ClusterStateCache and ReadClient will be deleted + // when OnDone is called or an error is encountered. callback->AdoptReadClient(std::move(readClient)); + callback->AdoptClusterStateCache(std::move(clusterStateCache)); callback.release(); }]; } @@ -399,11 +484,12 @@ - (void)setupSubscription attributeID:(NSNumber *)attributeID params:(MTRReadParams *)params { + NSString * logPrefix = [NSString stringWithFormat:@"%@ read %@ %@ %@", self, endpointID, clusterID, attributeID]; // Create work item, set ready handler to perform task, then enqueue the work - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:_queue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTR_LOG_INFO("%@ dequeueWorkItem %@", logPrefix, self->_asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [self newBaseDevice]; - [baseDevice readAttributesWithEndpointID:endpointID clusterID:clusterID @@ -414,18 +500,23 @@ - (void)setupSubscription if (values) { // Since the format is the same data-value dictionary, this looks like an attribute // report + MTR_LOG_INFO("%@ completion values %@", logPrefix, values); [self _handleAttributeReport:values]; } // TODO: better retry logic if (error && (retryCount < 2)) { + MTR_LOG_INFO( + "%@ completion error %@ retryWork %lu", logPrefix, error, (unsigned long) retryCount); [workItem retryWork]; } else { + MTR_LOG_INFO("%@ completion error %@ endWork", logPrefix, error); [workItem endWork]; } }]; }; workItem.readyHandler = readyHandler; + MTR_LOG_INFO("%@ enqueueWorkItem %@", logPrefix, _asyncCallbackWorkQueue); [_asyncCallbackWorkQueue enqueueWorkItem:workItem]; // Return current known / expected value right away @@ -444,12 +535,14 @@ - (void)writeAttributeWithEndpointID:(NSNumber *)endpointID expectedValueInterval:(NSNumber *)expectedValueInterval timedWriteTimeout:(NSNumber * _Nullable)timeout { + NSString * logPrefix = [NSString stringWithFormat:@"%@ write %@ %@ %@", self, endpointID, clusterID, attributeID]; if (timeout) { timeout = MTRClampedNumber(timeout, @(1), @(UINT16_MAX)); } expectedValueInterval = MTRClampedNumber(expectedValueInterval, @(1), @(UINT32_MAX)); - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:_queue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTR_LOG_INFO("%@ dequeueWorkItem %@", logPrefix, self->_asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [self newBaseDevice]; [baseDevice writeAttributeWithEndpointID:endpointID @@ -459,13 +552,12 @@ - (void)writeAttributeWithEndpointID:(NSNumber *)endpointID timedWriteTimeout:timeout queue:self.queue completion:^(NSArray *> * _Nullable values, NSError * _Nullable error) { - if (values) { - [self _handleAttributeReport:values]; - } + MTR_LOG_INFO("%@ completion error %@ endWork", logPrefix, error); [workItem endWork]; }]; }; workItem.readyHandler = readyHandler; + MTR_LOG_INFO("%@ enqueueWorkItem %@", logPrefix, _asyncCallbackWorkQueue); [_asyncCallbackWorkQueue enqueueWorkItem:workItem]; // Commit change into expected value cache @@ -487,6 +579,7 @@ - (void)invokeCommandWithEndpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue completion:(MTRDeviceResponseHandler)completion { + NSString * logPrefix = [NSString stringWithFormat:@"%@ command %@ %@ %@", self, endpointID, clusterID, commandID]; if (timeout) { timeout = MTRClampedNumber(timeout, @(1), @(UINT16_MAX)); } @@ -495,8 +588,9 @@ - (void)invokeCommandWithEndpointID:(NSNumber *)endpointID } else { expectedValueInterval = MTRClampedNumber(expectedValueInterval, @(1), @(UINT32_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:_queue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTR_LOG_INFO("%@ dequeueWorkItem %@", logPrefix, self->_asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [self newBaseDevice]; [baseDevice invokeCommandWithEndpointID:endpointID @@ -506,6 +600,7 @@ - (void)invokeCommandWithEndpointID:(NSNumber *)endpointID timedInvokeTimeout:timeout queue:self.queue completion:^(NSArray *> * _Nullable values, NSError * _Nullable error) { + MTR_LOG_INFO("%@ completion values %@ error %@ endWork", logPrefix, values, error); dispatch_async(queue, ^{ completion(values, error); }); @@ -513,6 +608,7 @@ - (void)invokeCommandWithEndpointID:(NSNumber *)endpointID }]; }; workItem.readyHandler = readyHandler; + MTR_LOG_INFO("%@ enqueueWorkItem %@", logPrefix, _asyncCallbackWorkQueue); [_asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (expectedValues) { @@ -563,6 +659,7 @@ - (void)_checkExpiredExpectedValues // remove from expected value cache and report attributes as needed NSMutableArray * attributesToReport = [NSMutableArray array]; + NSMutableArray * attributePathsToReport = [NSMutableArray array]; for (MTRPair * attributeInfo in attributeInfoToRemove) { // compare with known value and mark for report if different MTRAttributePath * attributePath = attributeInfo.first; @@ -571,10 +668,14 @@ - (void)_checkExpiredExpectedValues if (cachedAttributeDataValue && ![self _attributeDataValue:attributeDataValue isEqualToDataValue:cachedAttributeDataValue]) { [attributesToReport addObject:@{ MTRAttributePathKey : attributePath, MTRDataKey : cachedAttributeDataValue }]; + [attributePathsToReport addObject:attributePath]; } _expectedValueCache[attributePath] = nil; } + + // log attribute paths + MTR_LOG_INFO("%@ report from expired expected values %@", self, attributePathsToReport); [self _reportAttributes:attributesToReport]; // Have a reasonable minimum wait time for expiration timers @@ -586,7 +687,7 @@ - (void)_checkExpiredExpectedValues waitTime = MTR_DEVICE_EXPIRATION_CHECK_TIMER_MINIMUM_WAIT_TIME; } MTRWeakReference * weakSelf = [MTRWeakReference weakReferenceWithObject:self]; - dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(waitTime * NSEC_PER_SEC)), _queue, ^{ + dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(waitTime * NSEC_PER_SEC)), self.queue, ^{ MTRDevice * strongSelf = weakSelf.strongObject; [strongSelf _performScheduledExpirationCheck]; }); @@ -631,8 +732,8 @@ - (void)_performScheduledExpirationCheck return cachedAttributeValue; } else { // TODO: when not found in cache, generated default values should be used - MTR_LOG_INFO( - "_attributeValueDictionaryForAttributePath: could not find cached attribute values for attribute %@", attributePath); + MTR_LOG_INFO("%@ _attributeValueDictionaryForAttributePath: could not find cached attribute values for attribute %@", self, + attributePath); } os_unfair_lock_unlock(&self->_lock); @@ -653,6 +754,7 @@ - (NSArray *)_getAttributesToReportWithReportedValues:(NSArray_lock); NSMutableArray * attributesToReport = [NSMutableArray array]; + NSMutableArray * attributePathsToReport = [NSMutableArray array]; for (NSDictionary * attributeReponseValue in reportedAttributeValues) { MTRAttributePath * attributePath = attributeReponseValue[MTRAttributePathKey]; NSDictionary * attributeDataValue = attributeReponseValue[MTRDataKey]; @@ -669,30 +771,42 @@ - (NSArray *)_getAttributesToReportWithReportedValues:(NSArray * expectedValue = _expectedValueCache[attributePath]; if (expectedValue) { if (![self _attributeDataValue:attributeDataValue isEqualToDataValue:expectedValue.second]) { shouldReportAttribute = YES; } _expectedValueCache[attributePath] = nil; - } - - // then compare and update read cache - if (![self _attributeDataValue:attributeDataValue isEqualToDataValue:_readCache[attributePath]]) { + _readCache[attributePath] = attributeDataValue; + } else if (![self _attributeDataValue:attributeDataValue isEqualToDataValue:_readCache[attributePath]]) { + // otherwise compare and update read cache _readCache[attributePath] = attributeDataValue; shouldReportAttribute = YES; } + + if (!shouldReportAttribute) { + if (expectedValue) { + MTR_LOG_INFO("%@ report %@ value filtered - same as expected values", self, attributePath); + } else { + MTR_LOG_INFO("%@ report %@ value filtered - same values as cache", self, attributePath); + } + } } if (shouldReportAttribute) { [attributesToReport addObject:attributeReponseValue]; + [attributePathsToReport addObject:attributePath]; } } + MTR_LOG_INFO("%@ report from reported values %@", self, attributePathsToReport); + return attributesToReport; } @@ -703,6 +817,7 @@ - (NSArray *)_getAttributesToReportWithNewExpectedValues:(NSArray_lock); NSMutableArray * attributesToReport = [NSMutableArray array]; + NSMutableArray * attributePathsToReport = [NSMutableArray array]; for (NSDictionary * attributeReponseValue in expectedAttributeValues) { MTRAttributePath * attributePath = attributeReponseValue[MTRAttributePathKey]; NSDictionary * attributeDataValue = attributeReponseValue[MTRDataKey]; @@ -726,9 +841,12 @@ - (NSArray *)_getAttributesToReportWithNewExpectedValues:(NSArray *> *)values expe // since NSTimeInterval is in seconds, convert ms into seconds in double NSDate * expirationTime = [NSDate dateWithTimeIntervalSinceNow:expectedValueInterval.doubleValue / 1000]; + MTR_LOG_INFO( + "Setting expected values %@ with expiration time %f seconds from now", values, [expirationTime timeIntervalSinceNow]); + os_unfair_lock_lock(&self->_lock); - NSArray * attributesToReport = [self _getAttributesToReportWithNewExpectedValues:values expirationTime:expirationTime]; + // _getAttributesToReportWithNewExpectedValues will log attribute paths reported + NSArray * attributesToReport = [self _getAttributesToReportWithNewExpectedValues:values expirationTime:expirationTime]; [self _reportAttributes:attributesToReport]; [self _checkExpiredExpectedValues]; diff --git a/src/darwin/Framework/CHIP/MTRDeviceAttestationDelegate.h b/src/darwin/Framework/CHIP/MTRDeviceAttestationDelegate.h index d54fdeb577adb7..375805f092d793 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceAttestationDelegate.h +++ b/src/darwin/Framework/CHIP/MTRDeviceAttestationDelegate.h @@ -30,9 +30,7 @@ NS_ASSUME_NONNULL_BEGIN @end /** - * The protocol definition for the MTRDeviceAttestationDelegate - * - * All delegate methods will be called on the callers queue. + * The protocol definition for the MTRDeviceAttestationDelegate. */ @protocol MTRDeviceAttestationDelegate @optional diff --git a/src/darwin/Framework/CHIP/MTRDeviceAttestationDelegateBridge.h b/src/darwin/Framework/CHIP/MTRDeviceAttestationDelegateBridge.h index 30eff23345c7e7..201137d63b3bc4 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceAttestationDelegateBridge.h +++ b/src/darwin/Framework/CHIP/MTRDeviceAttestationDelegateBridge.h @@ -28,12 +28,12 @@ NS_ASSUME_NONNULL_BEGIN class MTRDeviceAttestationDelegateBridge : public chip::Credentials::DeviceAttestationDelegate { public: MTRDeviceAttestationDelegateBridge(MTRDeviceController * deviceController, - id deviceAttestationDelegate, dispatch_queue_t queue, - chip::Optional expiryTimeoutSecs, bool shouldWaitAfterDeviceAttestation = false) + id deviceAttestationDelegate, chip::Optional expiryTimeoutSecs, + bool shouldWaitAfterDeviceAttestation = false) : mResult(chip::Credentials::AttestationVerificationResult::kSuccess) , mDeviceController(deviceController) , mDeviceAttestationDelegate(deviceAttestationDelegate) - , mQueue(queue) + , mQueue(dispatch_queue_create("com.csa.matter.framework.device_attestation.workqueue", DISPATCH_QUEUE_SERIAL)) , mExpiryTimeoutSecs(expiryTimeoutSecs) , mShouldWaitAfterDeviceAttestation(shouldWaitAfterDeviceAttestation) { diff --git a/src/darwin/Framework/CHIP/MTRDeviceAttestationDelegateBridge.mm b/src/darwin/Framework/CHIP/MTRDeviceAttestationDelegateBridge.mm index 4a489aa8ddef7b..2f0c7f9373e913 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceAttestationDelegateBridge.mm +++ b/src/darwin/Framework/CHIP/MTRDeviceAttestationDelegateBridge.mm @@ -18,6 +18,7 @@ #import "MTRDeviceAttestationDelegateBridge.h" #import "MTRDeviceAttestationDelegate_Internal.h" #import "MTRError_Internal.h" +#import "MTRLogging_Internal.h" #import "NSDataSpanConversion.h" void MTRDeviceAttestationDelegateBridge::OnDeviceAttestationCompleted(chip::Controller::DeviceCommissioner * deviceCommissioner, @@ -25,7 +26,8 @@ chip::Credentials::AttestationVerificationResult attestationResult) { dispatch_async(mQueue, ^{ - NSLog(@"MTRDeviceAttestationDelegateBridge::OnDeviceAttestationFailed completed with result: %hu", attestationResult); + MTR_LOG_DEFAULT( + "MTRDeviceAttestationDelegateBridge::OnDeviceAttestationFailed completed with result: %hu", attestationResult); mResult = attestationResult; diff --git a/src/darwin/Framework/CHIP/MTRDeviceController+XPC.m b/src/darwin/Framework/CHIP/MTRDeviceController+XPC.mm similarity index 100% rename from src/darwin/Framework/CHIP/MTRDeviceController+XPC.m rename to src/darwin/Framework/CHIP/MTRDeviceController+XPC.mm diff --git a/src/darwin/Framework/CHIP/MTRDeviceController.mm b/src/darwin/Framework/CHIP/MTRDeviceController.mm index c8722212a0d765..c9446ffcbbde0b 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceController.mm +++ b/src/darwin/Framework/CHIP/MTRDeviceController.mm @@ -27,7 +27,7 @@ #import "MTRDevice_Internal.h" #import "MTRError_Internal.h" #import "MTRKeypair.h" -#import "MTRLogging.h" +#import "MTRLogging_Internal.h" #import "MTROperationalCredentialsDelegate.h" #import "MTRP256KeypairBridge.h" #import "MTRPersistentStorageDelegateBridge.h" @@ -188,6 +188,11 @@ - (void)cleanup delete _deviceControllerDelegateBridge; _deviceControllerDelegateBridge = nullptr; } + + for (MTRDevice * device in [self.nodeIDToDeviceMap allValues]) { + [device invalidate]; + } + [self.nodeIDToDeviceMap removeAllObjects]; } - (BOOL)startup:(MTRDeviceControllerStartupParamsInternal *)startupParams @@ -439,7 +444,7 @@ - (BOOL)commissionNodeWithID:(NSNumber *)nodeID shouldWaitAfterDeviceAttestation = YES; } _deviceAttestationDelegateBridge = new MTRDeviceAttestationDelegateBridge( - self, commissioningParams.deviceAttestationDelegate, _chipWorkQueue, timeoutSecs, shouldWaitAfterDeviceAttestation); + self, commissioningParams.deviceAttestationDelegate, timeoutSecs, shouldWaitAfterDeviceAttestation); params.SetDeviceAttestationDelegate(_deviceAttestationDelegateBridge); } @@ -530,6 +535,7 @@ - (void)removeDevice:(MTRDevice *)device os_unfair_lock_lock(&_deviceMapLock); MTRDevice * deviceToRemove = self.nodeIDToDeviceMap[device.nodeID]; if (deviceToRemove == device) { + [deviceToRemove invalidate]; self.nodeIDToDeviceMap[device.nodeID] = nil; } else { MTR_LOG_ERROR("Error: Cannot remove device %p with nodeID %llu", device, device.nodeID.unsignedLongLongValue); diff --git a/src/darwin/Framework/CHIP/MTRDeviceControllerDelegateBridge.mm b/src/darwin/Framework/CHIP/MTRDeviceControllerDelegateBridge.mm index 3ac0883dc61815..bc7865a0594e06 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceControllerDelegateBridge.mm +++ b/src/darwin/Framework/CHIP/MTRDeviceControllerDelegateBridge.mm @@ -18,6 +18,7 @@ #import "MTRDeviceControllerDelegateBridge.h" #import "MTRDeviceController.h" #import "MTRError_Internal.h" +#import "MTRLogging_Internal.h" MTRDeviceControllerDelegateBridge::MTRDeviceControllerDelegateBridge(void) : mDelegate(nil) @@ -59,7 +60,7 @@ void MTRDeviceControllerDelegateBridge::OnStatusUpdate(chip::Controller::DevicePairingDelegate::Status status) { - NSLog(@"DeviceControllerDelegate status updated: %d", status); + MTR_LOG_DEFAULT("DeviceControllerDelegate status updated: %d", status); id strongDelegate = mDelegate; MTRDeviceController * strongController = mController; @@ -75,7 +76,7 @@ void MTRDeviceControllerDelegateBridge::OnPairingComplete(CHIP_ERROR error) { - NSLog(@"DeviceControllerDelegate Pairing complete. Status %s", chip::ErrorStr(error)); + MTR_LOG_DEFAULT("DeviceControllerDelegate Pairing complete. Status %s", chip::ErrorStr(error)); id strongDelegate = mDelegate; MTRDeviceController * strongController = mController; @@ -91,14 +92,14 @@ void MTRDeviceControllerDelegateBridge::OnPairingDeleted(CHIP_ERROR error) { - NSLog(@"DeviceControllerDelegate Pairing deleted. Status %s", chip::ErrorStr(error)); + MTR_LOG_DEFAULT("DeviceControllerDelegate Pairing deleted. Status %s", chip::ErrorStr(error)); // This is never actually called; just do nothing. } void MTRDeviceControllerDelegateBridge::OnCommissioningComplete(chip::NodeId nodeId, CHIP_ERROR error) { - NSLog(@"DeviceControllerDelegate Commissioning complete. NodeId %llu Status %s", nodeId, chip::ErrorStr(error)); + MTR_LOG_DEFAULT("DeviceControllerDelegate Commissioning complete. NodeId %llu Status %s", nodeId, chip::ErrorStr(error)); id strongDelegate = mDelegate; MTRDeviceController * strongController = mController; diff --git a/src/darwin/Framework/CHIP/MTRDeviceControllerFactory.h b/src/darwin/Framework/CHIP/MTRDeviceControllerFactory.h index 97e7ca28749050..34dc57bee7b47f 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceControllerFactory.h +++ b/src/darwin/Framework/CHIP/MTRDeviceControllerFactory.h @@ -21,6 +21,7 @@ */ #import +#import NS_ASSUME_NONNULL_BEGIN @@ -44,21 +45,29 @@ MTR_NEWLY_AVAILABLE /* * OTA Provider delegate to be called when an OTA Requestor is requesting a software update. * Defaults to nil. + * + * Calls to this delegate can happen on an arbitrary thread, but will not happen + * concurrently. */ @property (nonatomic, strong, nullable) id otaProviderDelegate; /* * The Product Attestation Authority certificates that are trusted to sign - * device attestation information. Defaults to nil. + * device attestation information (and in particular to sign Product Attestation + * Intermediate certificates, which then sign Device Attestation Certificates). * + * Defaults to nil. */ -@property (nonatomic, copy, nullable) NSArray * paaCerts; +@property (nonatomic, copy, nullable) NSArray * productAttestationAuthorityCertificates; /* - * The Certificate Declaration certificates that are trusted to sign - * device attestation information. Defaults to nil. + * The Certification Declaration certificates whose public keys correspond to + * private keys that are trusted to sign certification declarations. Defaults + * to nil. * + * These certificates are used in addition to, not replacing, the default set of + * well-known certification declaration signing keys. */ -@property (nonatomic, copy, nullable) NSArray * cdCerts; +@property (nonatomic, copy, nullable) NSArray * certificationDeclarationCertificates; /* * The network port to bind to. If not specified, an ephemeral port will be * used. @@ -142,7 +151,11 @@ MTR_NEWLY_DEPRECATED("Please use MTRDeviceControllerFactoryParams") @interface MTRControllerFactoryParams : MTRDeviceControllerFactoryParams @property (nonatomic, strong, readonly) id storageDelegate MTR_NEWLY_DEPRECATED( "Please use the storage property"); -@property (nonatomic, assign) BOOL startServer; +@property (nonatomic, assign) BOOL startServer MTR_NEWLY_DEPRECATED("Please use shouldStartServer"); +@property (nonatomic, copy, nullable) + NSArray * paaCerts MTR_NEWLY_DEPRECATED("Please use productAttestationAuthorityCertificates"); +@property (nonatomic, copy, nullable) + NSArray * cdCerts MTR_NEWLY_DEPRECATED("Please use certificationDeclarationCertificates"); @end MTR_NEWLY_DEPRECATED("Please use MTRDeviceControllerFactory") diff --git a/src/darwin/Framework/CHIP/MTRDeviceControllerFactory.mm b/src/darwin/Framework/CHIP/MTRDeviceControllerFactory.mm index 9167cd047c1209..d0040a2caf54ba 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceControllerFactory.mm +++ b/src/darwin/Framework/CHIP/MTRDeviceControllerFactory.mm @@ -25,8 +25,8 @@ #import "MTRDeviceControllerStartupParams_Internal.h" #import "MTRDeviceController_Internal.h" #import "MTRError_Internal.h" -#import "MTRLogging.h" -#import "MTRMemory.h" +#import "MTRFramework.h" +#import "MTRLogging_Internal.h" #import "MTROTAProviderDelegateBridge.h" #import "MTRP256KeypairBridge.h" #import "MTRPersistentStorageDelegateBridge.h" @@ -50,7 +50,6 @@ static NSString * const kErrorPersistentStorageInit = @"Init failure while creating a persistent storage delegate"; static NSString * const kErrorAttestationTrustStoreInit = @"Init failure while creating the attestation trust store"; static NSString * const kErrorDACVerifierInit = @"Init failure while creating the device attestation verifier"; -static NSString * const kInfoFactoryShutdown = @"Shutting down the Matter controller factory"; static NSString * const kErrorGroupProviderInit = @"Init failure while initializing group data provider"; static NSString * const kErrorControllersInit = @"Init controllers array failure"; static NSString * const kErrorControllerFactoryInit = @"Init failure while initializing controller factory"; @@ -85,6 +84,11 @@ - (MTRDeviceController * _Nullable)maybeInitializeOTAProvider:(MTRDeviceControll @implementation MTRDeviceControllerFactory ++ (void)initialize +{ + MTRFrameworkInit(); +} + + (instancetype)sharedInstance { static MTRDeviceControllerFactory * factory = nil; @@ -105,7 +109,6 @@ - (instancetype)init _running = NO; _chipWorkQueue = DeviceLayer::PlatformMgrImpl().GetWorkQueue(); _controllerFactory = &DeviceControllerFactory::GetInstance(); - [MTRMemory ensureInit]; _groupStorageDelegate = new chip::TestPersistentStorageDelegate(); if ([self checkForInitError:(_groupStorageDelegate != nullptr) logMsg:kErrorGroupProviderInit]) { @@ -321,8 +324,9 @@ - (BOOL)startControllerFactory:(MTRDeviceControllerFactoryParams *)startupParams // Initialize device attestation verifier const Credentials::AttestationTrustStore * trustStore; - if (startupParams.paaCerts) { - _attestationTrustStoreBridge = new MTRAttestationTrustStoreBridge(startupParams.paaCerts); + if (startupParams.productAttestationAuthorityCertificates) { + _attestationTrustStoreBridge + = new MTRAttestationTrustStoreBridge(startupParams.productAttestationAuthorityCertificates); if (_attestationTrustStoreBridge == nullptr) { MTR_LOG_ERROR("Error: %@", kErrorAttestationTrustStoreInit); errorCode = CHIP_ERROR_NO_MEMORY; @@ -340,7 +344,7 @@ - (BOOL)startControllerFactory:(MTRDeviceControllerFactoryParams *)startupParams return; } - if (startupParams.cdCerts) { + if (startupParams.certificationDeclarationCertificates) { auto cdTrustStore = _deviceAttestationVerifier->GetCertificationDeclarationTrustStore(); if (cdTrustStore == nullptr) { MTR_LOG_ERROR("Error: %@", kErrorCDCertStoreInit); @@ -348,7 +352,7 @@ - (BOOL)startControllerFactory:(MTRDeviceControllerFactoryParams *)startupParams return; } - for (NSData * cdSigningCert in startupParams.cdCerts) { + for (NSData * cdSigningCert in startupParams.certificationDeclarationCertificates) { errorCode = cdTrustStore->AddTrustedKey(AsByteSpan(cdSigningCert)); if (errorCode != CHIP_NO_ERROR) { MTR_LOG_ERROR("Error: %@", kErrorCDCertStoreInit); @@ -414,7 +418,7 @@ - (void)stopControllerFactory [_controllers[0] shutdown]; } - MTR_LOG_DEBUG("%@", kInfoFactoryShutdown); + MTR_LOG_DEBUG("Shutting down the Matter controller factory"); _controllerFactory->Shutdown(); [self cleanupStartupObjects]; @@ -671,8 +675,11 @@ - (MTRDeviceController * _Nullable)maybeInitializeOTAProvider:(MTRDeviceControll VerifyOrReturnValue(_otaProviderDelegateBridge != nil, controller); VerifyOrReturnValue([_controllers count] == 1, controller); - auto systemState = _controllerFactory->GetSystemState(); - CHIP_ERROR err = _otaProviderDelegateBridge->Init(systemState->SystemLayer(), systemState->ExchangeMgr()); + __block CHIP_ERROR err; + dispatch_sync(_chipWorkQueue, ^{ + auto systemState = _controllerFactory->GetSystemState(); + err = _otaProviderDelegateBridge->Init(systemState->SystemLayer(), systemState->ExchangeMgr()); + }); if (CHIP_NO_ERROR != err) { MTR_LOG_ERROR("Failed to init provider delegate bridge: %" CHIP_ERROR_FORMAT, err.Format()); [controller shutdown]; @@ -708,19 +715,23 @@ - (void)controllerShuttingDown:(MTRDeviceController *)controller [_controllers removeObject:controller]; if ([_controllers count] == 0) { - if (_otaProviderDelegateBridge) { - _otaProviderDelegateBridge->Shutdown(); - } - // That was our last controller. Stop the event loop before it // shuts down, because shutdown of the last controller will tear // down most of the world. DeviceLayer::PlatformMgrImpl().StopEventLoopTask(); + if (_otaProviderDelegateBridge) { + _otaProviderDelegateBridge->Shutdown(); + } + [controller shutDownCppController]; } else { // Do the controller shutdown on the Matter work queue. dispatch_sync(_chipWorkQueue, ^{ + if (_otaProviderDelegateBridge) { + _otaProviderDelegateBridge->ControllerShuttingDown(controller); + } + [controller shutDownCppController]; }); } @@ -761,8 +772,8 @@ - (instancetype)initWithStorage:(id)storage _storage = storage; _otaProviderDelegate = nil; - _paaCerts = nil; - _cdCerts = nil; + _productAttestationAuthorityCertificates = nil; + _certificationDeclarationCertificates = nil; _port = nil; _shouldStartServer = NO; @@ -835,4 +846,24 @@ - (void)setStartServer:(BOOL)startServer self.shouldStartServer = startServer; } +- (nullable NSArray *)paaCerts +{ + return self.productAttestationAuthorityCertificates; +} + +- (void)setPaaCerts:(nullable NSArray *)paaCerts +{ + self.productAttestationAuthorityCertificates = paaCerts; +} + +- (nullable NSArray *)cdCerts +{ + return self.certificationDeclarationCertificates; +} + +- (void)setCdCerts:(nullable NSArray *)cdCerts +{ + self.certificationDeclarationCertificates = cdCerts; +} + @end diff --git a/src/darwin/Framework/CHIP/MTRDeviceControllerOverXPC.m b/src/darwin/Framework/CHIP/MTRDeviceControllerOverXPC.mm similarity index 99% rename from src/darwin/Framework/CHIP/MTRDeviceControllerOverXPC.m rename to src/darwin/Framework/CHIP/MTRDeviceControllerOverXPC.mm index 929e4792535baf..b78f498b2fbb82 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceControllerOverXPC.m +++ b/src/darwin/Framework/CHIP/MTRDeviceControllerOverXPC.mm @@ -21,7 +21,7 @@ #import "MTRDeviceControllerXPCConnection.h" #import "MTRDeviceOverXPC.h" #import "MTRError.h" -#import "MTRLogging.h" +#import "MTRLogging_Internal.h" #import diff --git a/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams.h b/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams.h index dfafee444916aa..8ff5775ed71279 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams.h +++ b/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams.h @@ -16,7 +16,7 @@ #import -typedef NSData * MTRCertificateDERBytes; +#import NS_ASSUME_NONNULL_BEGIN diff --git a/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams.mm b/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams.mm index c2f0242d6ffc20..557864bc28e60b 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams.mm +++ b/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams.mm @@ -17,7 +17,7 @@ #import "MTRDeviceControllerStartupParams.h" #import "MTRCertificates.h" #import "MTRDeviceControllerStartupParams_Internal.h" -#import "MTRLogging.h" +#import "MTRLogging_Internal.h" #import "MTRP256KeypairBridge.h" #import "NSDataSpanConversion.h" diff --git a/src/darwin/Framework/CHIP/MTRDeviceControllerXPCConnection.m b/src/darwin/Framework/CHIP/MTRDeviceControllerXPCConnection.mm similarity index 99% rename from src/darwin/Framework/CHIP/MTRDeviceControllerXPCConnection.m rename to src/darwin/Framework/CHIP/MTRDeviceControllerXPCConnection.mm index a5513da513a0d1..dc5cec1081dbf7 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceControllerXPCConnection.m +++ b/src/darwin/Framework/CHIP/MTRDeviceControllerXPCConnection.mm @@ -17,7 +17,7 @@ #import "MTRDeviceControllerXPCConnection.h" #import "MTRDeviceControllerOverXPC.h" -#import "MTRLogging.h" +#import "MTRLogging_Internal.h" #import diff --git a/src/darwin/Framework/CHIP/MTRDeviceOverXPC.m b/src/darwin/Framework/CHIP/MTRDeviceOverXPC.mm similarity index 99% rename from src/darwin/Framework/CHIP/MTRDeviceOverXPC.m rename to src/darwin/Framework/CHIP/MTRDeviceOverXPC.mm index a746d0aabe4c0a..cea5e0308e595a 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceOverXPC.m +++ b/src/darwin/Framework/CHIP/MTRDeviceOverXPC.mm @@ -23,7 +23,7 @@ #import "MTRDeviceControllerOverXPC_Internal.h" #import "MTRDeviceControllerXPCConnection.h" #import "MTRError.h" -#import "MTRLogging.h" +#import "MTRLogging_Internal.h" NS_ASSUME_NONNULL_BEGIN diff --git a/src/darwin/Framework/CHIP/MTRDevice_Internal.h b/src/darwin/Framework/CHIP/MTRDevice_Internal.h index 9d2e77876261f0..c1611acaa39e8f 100644 --- a/src/darwin/Framework/CHIP/MTRDevice_Internal.h +++ b/src/darwin/Framework/CHIP/MTRDevice_Internal.h @@ -33,8 +33,15 @@ typedef void (^MTRDevicePerformAsyncBlock)(MTRBaseDevice * baseDevice); - (void)setExpectedValues:(NSArray *> *)values expectedValueInterval:(NSNumber *)expectedValueIntervalMs; +// called by controller to clean up and shutdown +- (void)invalidate; + @property (nonatomic, readonly) MTRDeviceController * deviceController; @property (nonatomic, readonly, copy) NSNumber * nodeID; +// Queue used for various internal bookkeeping work. In general endWork calls +// on work items should happen on this queue, so we don't block progress of the +// asyncCallbackWorkQueue on any client code. +@property (nonatomic) dispatch_queue_t queue; @property (nonatomic, readonly) MTRAsyncCallbackWorkQueue * asyncCallbackWorkQueue; @end diff --git a/src/darwin/Framework/CHIP/MTRFramework.h b/src/darwin/Framework/CHIP/MTRFramework.h new file mode 100644 index 00000000000000..0017081b318d8f --- /dev/null +++ b/src/darwin/Framework/CHIP/MTRFramework.h @@ -0,0 +1,20 @@ +/** + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * Performs per-process initialization of the Matter stack. + */ +void MTRFrameworkInit(); diff --git a/src/darwin/Framework/CHIP/MTRFramework.mm b/src/darwin/Framework/CHIP/MTRFramework.mm new file mode 100644 index 00000000000000..e6a0e672955be3 --- /dev/null +++ b/src/darwin/Framework/CHIP/MTRFramework.mm @@ -0,0 +1,38 @@ +/** + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#import "MTRFramework.h" + +#include +#include +#include + +void MTRFrameworkInit() +{ + static dispatch_once_t onceToken; + dispatch_once(&onceToken, ^{ + // Ensure Matter Platform::Memory is initialized. This only needs + // to happen once per process, because in practice we just use + // malloc/free so there is nothing to initialize, so this just needs + // to happen to avoid debug assertions. The malloc version of + // MemoryInit() never fails. + chip::Platform::MemoryInit(); + + // Suppress CHIP logging until we actually need it for redirection + // (see MTRSetLogCallback()). Logging to os_log is always enabled. + chip::Logging::SetLogFilter(chip::Logging::kLogCategory_None); + }); +} diff --git a/src/darwin/Framework/CHIP/MTRKeypair.h b/src/darwin/Framework/CHIP/MTRKeypair.h index b0affe4f5ba678..a4e4521b2864a6 100644 --- a/src/darwin/Framework/CHIP/MTRKeypair.h +++ b/src/darwin/Framework/CHIP/MTRKeypair.h @@ -20,6 +20,16 @@ NS_ASSUME_NONNULL_BEGIN +/** + * This protocol is used by the Matter framework to sign messages with a private + * key and verify signatures with a public key. + * + * The Matter framework may call keypair methods from arbitrary threads and + * concurrently. + * + * Implementations of the keypair methods must not call into any Matter + * framework APIs. + */ @protocol MTRKeypair @required /** diff --git a/src/darwin/Framework/CHIP/MTRLogging.h b/src/darwin/Framework/CHIP/MTRLogging.h index f2bcb33f12d555..104c7987a9090e 100644 --- a/src/darwin/Framework/CHIP/MTRLogging.h +++ b/src/darwin/Framework/CHIP/MTRLogging.h @@ -1,6 +1,6 @@ /* * - * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2022 Project CHIP Authors * All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -16,12 +16,28 @@ * limitations under the License. */ -#import +#import -#define MTR_LOG_FAULT(format, ...) os_log_fault(OS_LOG_DEFAULT, format, ##__VA_ARGS__) -#define MTR_LOG_ERROR(format, ...) os_log_error(OS_LOG_DEFAULT, format, ##__VA_ARGS__) -#define MTR_LOG_INFO(format, ...) os_log_info(OS_LOG_DEFAULT, format, ##__VA_ARGS__) -#define MTR_LOG_DEBUG(format, ...) os_log_debug(OS_LOG_DEFAULT, format, ##__VA_ARGS__) +NS_ASSUME_NONNULL_BEGIN -#define MTR_LOG_METHOD_ENTRY() \ - ({ os_log_debug(OS_LOG_DEFAULT, "[<%@: %p> %@]", NSStringFromClass([self class]), self, NSStringFromSelector(_cmd)); }) +typedef NS_ENUM(NSInteger, MTRLogType) { + MTRLogTypeError = 1, + MTRLogTypeProgress = 2, + MTRLogTypeDetail = 3, +}; + +typedef void (^MTRLogCallback)(MTRLogType type, NSString * moduleName, NSString * message); + +/** + * Arranges for log messages from the Matter stack to be delivered to a callback block. + * + * @param logTypeThreshold only messages up to (and including) the specified log type will be delivered + * @param callback the block to call, or nil to disable the log callback. + * + * The callback block may be called concurrently and/or from arbitrary threads. + * It SHALL NOT call back directly or indirectly into any Matter APIs, + * nor block the calling thread for a non-trivial amount of time. + */ +MTR_EXTERN MTR_NEWLY_AVAILABLE void MTRSetLogCallback(MTRLogType logTypeThreshold, MTRLogCallback _Nullable callback); + +NS_ASSUME_NONNULL_END diff --git a/src/darwin/Framework/CHIP/MTRLogging.mm b/src/darwin/Framework/CHIP/MTRLogging.mm new file mode 100644 index 00000000000000..23b310a37a05fa --- /dev/null +++ b/src/darwin/Framework/CHIP/MTRLogging.mm @@ -0,0 +1,70 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#import "MTRLogging_Internal.h" + +#import "MTRFramework.h" + +#import +#import +#import + +using namespace chip::Logging; + +static_assert(MTRLogTypeError == (NSInteger) kLogCategory_Error, "MTRLogType* != kLogCategory_*"); +static_assert(MTRLogTypeProgress == (NSInteger) kLogCategory_Progress, "MTRLogType* != kLogCategory_*"); +static_assert(MTRLogTypeDetail == (NSInteger) kLogCategory_Detail, "MTRLogType* != kLogCategory_*"); + +static os_unfair_lock logCallbackLock = OS_UNFAIR_LOCK_INIT; +static MTRLogCallback logCallback = nil; + +static void MTRLogCallbackTrampoline(const char * moduleName, uint8_t category, const char * format, va_list args) +{ + os_unfair_lock_lock(&logCallbackLock); + MTRLogCallback callback = logCallback; + os_unfair_lock_unlock(&logCallbackLock); + if (!callback) { + return; + } + +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wformat-nonliteral" + // Note: Format using NSString so that '%@' placeholders are supported + NSString * message = [[NSString alloc] initWithFormat:@(format) arguments:args]; +#pragma clang diagnostic pop + + auto type = std::min(static_cast(category), MTRLogTypeDetail); // hide kLogCategory_Automation + callback(type, @(moduleName), message); +} + +void MTRSetLogCallback(MTRLogType logTypeThreshold, MTRLogCallback _Nullable callback) +{ + MTRFrameworkInit(); + + os_unfair_lock_lock(&logCallbackLock); + if (callback) { + SetLogRedirectCallback(&MTRLogCallbackTrampoline); + SetLogFilter(static_cast(std::min(std::max(logTypeThreshold, MTRLogTypeError), MTRLogTypeDetail))); + logCallback = callback; + } else { + logCallback = nil; + SetLogFilter(kLogCategory_None); + SetLogRedirectCallback(nullptr); + } + os_unfair_lock_unlock(&logCallbackLock); +} diff --git a/src/darwin/Framework/CHIP/MTRLogging_Internal.h b/src/darwin/Framework/CHIP/MTRLogging_Internal.h new file mode 100644 index 00000000000000..9b2d2fce418822 --- /dev/null +++ b/src/darwin/Framework/CHIP/MTRLogging_Internal.h @@ -0,0 +1,26 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#import + +#include + +#define MTR_LOG_ERROR(msg, ...) ChipLogError(NotSpecified, msg, ##__VA_ARGS__) +#define MTR_LOG_DEFAULT(msg, ...) ChipLogProgress(NotSpecified, msg, ##__VA_ARGS__) +#define MTR_LOG_INFO(msg, ...) ChipLogDetail(NotSpecified, msg, ##__VA_ARGS__) +#define MTR_LOG_DEBUG(msg, ...) ChipLogDetail(NotSpecified, msg, ##__VA_ARGS__) // same as INFO diff --git a/src/darwin/Framework/CHIP/MTRManualSetupPayloadParser.mm b/src/darwin/Framework/CHIP/MTRManualSetupPayloadParser.mm index fc493afb507c91..3a0435de6dc99d 100644 --- a/src/darwin/Framework/CHIP/MTRManualSetupPayloadParser.mm +++ b/src/darwin/Framework/CHIP/MTRManualSetupPayloadParser.mm @@ -17,8 +17,8 @@ #import "MTRManualSetupPayloadParser.h" #import "MTRError_Internal.h" -#import "MTRLogging.h" -#import "MTRMemory.h" +#import "MTRFramework.h" +#import "MTRLogging_Internal.h" #import "MTRSetupPayload_Internal.h" #import @@ -29,10 +29,14 @@ @implementation MTRManualSetupPayloadParser { chip::ManualSetupPayloadParser * _chipManualSetupPayloadParser; } ++ (void)initialize +{ + MTRFrameworkInit(); +} + - (id)initWithDecimalStringRepresentation:(NSString *)decimalStringRepresentation { if (self = [super init]) { - [MTRMemory ensureInit]; _decimalStringRepresentation = decimalStringRepresentation; _chipManualSetupPayloadParser = new chip::ManualSetupPayloadParser(std::string([decimalStringRepresentation UTF8String])); } diff --git a/src/darwin/Framework/CHIP/MTROTAProviderDelegate.h b/src/darwin/Framework/CHIP/MTROTAProviderDelegate.h index 6952bfe3da1490..7b81b72af50652 100644 --- a/src/darwin/Framework/CHIP/MTROTAProviderDelegate.h +++ b/src/darwin/Framework/CHIP/MTROTAProviderDelegate.h @@ -21,13 +21,21 @@ NS_ASSUME_NONNULL_BEGIN typedef void (^MTRQueryImageCompletionHandler)( - MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error); + MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error); typedef void (^MTRApplyUpdateRequestCompletionHandler)( - MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, NSError * _Nullable error); + MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, NSError * _Nullable error); typedef void (^MTRBDXQueryCompletionHandler)(NSData * _Nullable data, BOOL isEOF); +MTR_NEWLY_DEPRECATED("Please use MTRQueryImageCompletionHandler") +typedef void (^MTRQueryImageCompletionHandlerDeprecated)( + MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error); + +MTR_NEWLY_DEPRECATED("Plase Use MTRApplyUpdateRequestCompletionHandler") +typedef void (^MTRApplyUpdateRequestCompletionHandlerDeprecated)( + MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, NSError * _Nullable error); + /** * The protocol definition for the MTROTAProviderDelegate * @@ -52,12 +60,12 @@ typedef void (^MTRBDXQueryCompletionHandler)(NSData * _Nullable data, BOOL isEOF */ - (void)handleQueryImageForNodeID:(NSNumber *)nodeID controller:(MTRDeviceController *)controller - params:(MTROtaSoftwareUpdateProviderClusterQueryImageParams *)params + params:(MTROTASoftwareUpdateProviderClusterQueryImageParams *)params completion:(MTRQueryImageCompletionHandler)completion MTR_NEWLY_AVAILABLE; - (void)handleQueryImageForNodeID:(NSNumber *)nodeID controller:(MTRDeviceController *)controller params:(MTROtaSoftwareUpdateProviderClusterQueryImageParams *)params - completionHandler:(MTRQueryImageCompletionHandler)completionHandler + completionHandler:(MTRQueryImageCompletionHandlerDeprecated)completionHandler MTR_NEWLY_DEPRECATED("Please use the selector ending in completion:"); /** @@ -71,12 +79,12 @@ typedef void (^MTRBDXQueryCompletionHandler)(NSData * _Nullable data, BOOL isEOF */ - (void)handleApplyUpdateRequestForNodeID:(NSNumber *)nodeID controller:(MTRDeviceController *)controller - params:(MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams *)params + params:(MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams *)params completion:(MTRApplyUpdateRequestCompletionHandler)completion MTR_NEWLY_AVAILABLE; - (void)handleApplyUpdateRequestForNodeID:(NSNumber *)nodeID controller:(MTRDeviceController *)controller params:(MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams *)params - completionHandler:(MTRApplyUpdateRequestCompletionHandler)completionHandler + completionHandler:(MTRApplyUpdateRequestCompletionHandlerDeprecated)completionHandler MTR_NEWLY_DEPRECATED("Please use the selector ending in completion:"); /** @@ -89,7 +97,7 @@ typedef void (^MTRBDXQueryCompletionHandler)(NSData * _Nullable data, BOOL isEOF */ - (void)handleNotifyUpdateAppliedForNodeID:(NSNumber *)nodeID controller:(MTRDeviceController *)controller - params:(MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams *)params + params:(MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)handleNotifyUpdateAppliedForNodeID:(NSNumber *)nodeID controller:(MTRDeviceController *)controller diff --git a/src/darwin/Framework/CHIP/MTROTAProviderDelegateBridge.h b/src/darwin/Framework/CHIP/MTROTAProviderDelegateBridge.h index 97aa258dad2617..a4b69f231dacd7 100644 --- a/src/darwin/Framework/CHIP/MTROTAProviderDelegateBridge.h +++ b/src/darwin/Framework/CHIP/MTROTAProviderDelegateBridge.h @@ -28,8 +28,15 @@ class MTROTAProviderDelegateBridge : public chip::app::Clusters::OTAProviderDele ~MTROTAProviderDelegateBridge(); CHIP_ERROR Init(chip::System::Layer * systemLayer, chip::Messaging::ExchangeManager * exchangeManager); + + // Shutdown must be called after the event loop has been stopped, since it + // touches Matter objects. void Shutdown(); + // ControllerShuttingDown must be called on the Matter work queue, since it + // touches Matter objects. + void ControllerShuttingDown(MTRDeviceController * controller); + void HandleQueryImage( chip::app::CommandHandler * commandObj, const chip::app::ConcreteCommandPath & commandPath, const chip::app::Clusters::OtaSoftwareUpdateProvider::Commands::QueryImage::DecodableType & commandData) override; @@ -45,22 +52,22 @@ class MTROTAProviderDelegateBridge : public chip::app::Clusters::OTAProviderDele private: static CHIP_ERROR ConvertToQueryImageParams( const chip::app::Clusters::OtaSoftwareUpdateProvider::Commands::QueryImage::DecodableType & commandData, - MTROtaSoftwareUpdateProviderClusterQueryImageParams * commandParams); + MTROTASoftwareUpdateProviderClusterQueryImageParams * commandParams); static void ConvertFromQueryImageResponseParms( - const MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams * responseParams, + const MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * responseParams, chip::app::Clusters::OtaSoftwareUpdateProvider::Commands::QueryImageResponse::Type & response); static void ConvertToApplyUpdateRequestParams( const chip::app::Clusters::OtaSoftwareUpdateProvider::Commands::ApplyUpdateRequest::DecodableType & commandData, - MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams * commandParams); + MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams * commandParams); static void ConvertFromApplyUpdateRequestResponseParms( - const MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * responseParams, + const MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams * responseParams, chip::app::Clusters::OtaSoftwareUpdateProvider::Commands::ApplyUpdateResponse::Type & response); static void ConvertToNotifyUpdateAppliedParams( const chip::app::Clusters::OtaSoftwareUpdateProvider::Commands::NotifyUpdateApplied::DecodableType & commandData, - MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams * commandParams); + MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams * commandParams); _Nullable id mDelegate; - dispatch_queue_t mWorkQueue; + dispatch_queue_t mDelegateNotificationQueue; }; NS_ASSUME_NONNULL_END diff --git a/src/darwin/Framework/CHIP/MTROTAProviderDelegateBridge.mm b/src/darwin/Framework/CHIP/MTROTAProviderDelegateBridge.mm index c2ce1b39548b47..7d5e8c165669bd 100644 --- a/src/darwin/Framework/CHIP/MTROTAProviderDelegateBridge.mm +++ b/src/darwin/Framework/CHIP/MTROTAProviderDelegateBridge.mm @@ -17,16 +17,19 @@ #import "MTROTAProviderDelegateBridge.h" #import "MTRDeviceControllerFactory_Internal.h" +#import "MTRDeviceController_Internal.h" #import "NSDataSpanConversion.h" #import "NSStringSpanConversion.h" #include +#include #include #include #include #include #include +#include #include #include @@ -49,6 +52,8 @@ CHIP_ERROR PrepareForTransfer(FabricIndex fabricIndex, NodeId nodeId) { + assertChipStackLockedByCurrentThread(); + VerifyOrReturnError(mDelegate != nil, CHIP_ERROR_INCORRECT_STATE); VerifyOrReturnError(mExchangeMgr != nullptr, CHIP_ERROR_INCORRECT_STATE); VerifyOrReturnError(mSystemLayer != nullptr, CHIP_ERROR_INCORRECT_STATE); @@ -61,6 +66,8 @@ CHIP_ERROR PrepareForTransfer(FabricIndex fabricIndex, NodeId nodeId) CHIP_ERROR Init(System::Layer * systemLayer, Messaging::ExchangeManager * exchangeMgr) { + assertChipStackLockedByCurrentThread(); + VerifyOrReturnError(mSystemLayer == nullptr, CHIP_ERROR_INCORRECT_STATE); VerifyOrReturnError(mExchangeMgr == nullptr, CHIP_ERROR_INCORRECT_STATE); VerifyOrReturnError(systemLayer != nullptr, CHIP_ERROR_INCORRECT_STATE); @@ -70,13 +77,14 @@ CHIP_ERROR Init(System::Layer * systemLayer, Messaging::ExchangeManager * exchan mSystemLayer = systemLayer; mExchangeMgr = exchangeMgr; - mWorkQueue = DeviceLayer::PlatformMgrImpl().GetWorkQueue(); return CHIP_NO_ERROR; } CHIP_ERROR Shutdown() { + assertChipStackLockedByCurrentThread(); + VerifyOrReturnError(mSystemLayer != nullptr, CHIP_ERROR_INCORRECT_STATE); VerifyOrReturnError(mExchangeMgr != nullptr, CHIP_ERROR_INCORRECT_STATE); @@ -84,25 +92,39 @@ CHIP_ERROR Shutdown() mExchangeMgr = nullptr; mSystemLayer = nullptr; - mWorkQueue = nil; + mDelegateNotificationQueue = nil; ResetState(); return CHIP_NO_ERROR; } - void SetDelegate(id delegate) + void ControllerShuttingDown(MTRDeviceController * controller) + { + assertChipStackLockedByCurrentThread(); + + if (mInitialized && mFabricIndex.Value() == controller.fabricIndex) { + ResetState(); + } + } + + void SetDelegate(id delegate, dispatch_queue_t delegateNotificationQueue) { if (delegate) { mDelegate = delegate; + mDelegateNotificationQueue = delegateNotificationQueue; } else { ResetState(); + mDelegate = nil; + mDelegateNotificationQueue = nil; } } private: CHIP_ERROR OnMessageToSend(TransferSession::OutputEvent & event) { + assertChipStackLockedByCurrentThread(); + VerifyOrReturnError(mExchangeCtx != nullptr, CHIP_ERROR_INCORRECT_STATE); VerifyOrReturnError(mDelegate != nil, CHIP_ERROR_INCORRECT_STATE); @@ -120,6 +142,8 @@ CHIP_ERROR OnMessageToSend(TransferSession::OutputEvent & event) CHIP_ERROR OnTransferSessionBegin(TransferSession::OutputEvent & event) { + assertChipStackLockedByCurrentThread(); + VerifyOrReturnError(mFabricIndex.HasValue(), CHIP_ERROR_INCORRECT_STATE); VerifyOrReturnError(mNodeId.HasValue(), CHIP_ERROR_INCORRECT_STATE); uint16_t fdl = 0; @@ -128,33 +152,48 @@ CHIP_ERROR OnTransferSessionBegin(TransferSession::OutputEvent & event) auto fileDesignator = [[NSString alloc] initWithBytes:fd length:fdl encoding:NSUTF8StringEncoding]; auto offset = @(mTransfer.GetStartOffset()); + + auto * controller = [[MTRDeviceControllerFactory sharedInstance] runningControllerForFabricIndex:mFabricIndex.Value()]; + VerifyOrReturnError(controller != nil, CHIP_ERROR_INCORRECT_STATE); + + auto transferGeneration = mTransferGeneration; + auto completionHandler = ^(NSError * _Nullable error) { - dispatch_async(mWorkQueue, ^{ - if (error != nil) { - LogErrorOnFailure([MTRError errorToCHIPErrorCode:error]); - LogErrorOnFailure(mTransfer.AbortTransfer(bdx::StatusCode::kUnknown)); - return; + [controller + asyncDispatchToMatterQueue:^(chip::Controller::DeviceCommissioner *) { + assertChipStackLockedByCurrentThread(); + + if (!mInitialized || mTransferGeneration != transferGeneration) { + // Callback for a stale transfer. + return; + } + + if (error != nil) { + LogErrorOnFailure([MTRError errorToCHIPErrorCode:error]); + LogErrorOnFailure(mTransfer.AbortTransfer(bdx::StatusCode::kUnknown)); + return; + } + + // bdx::TransferSession will automatically reject a transfer if there are no + // common supported control modes. It will also default to the smaller + // block size. + TransferSession::TransferAcceptData acceptData; + acceptData.ControlMode = bdx::TransferControlFlags::kReceiverDrive; + acceptData.MaxBlockSize = mTransfer.GetTransferBlockSize(); + acceptData.StartOffset = mTransfer.GetStartOffset(); + acceptData.Length = mTransfer.GetTransferLength(); + + LogErrorOnFailure(mTransfer.AcceptTransfer(acceptData)); } - - // bdx::TransferSession will automatically reject a transfer if there are no - // common supported control modes. It will also default to the smaller - // block size. - TransferSession::TransferAcceptData acceptData; - acceptData.ControlMode = bdx::TransferControlFlags::kReceiverDrive; - acceptData.MaxBlockSize = mTransfer.GetTransferBlockSize(); - acceptData.StartOffset = mTransfer.GetStartOffset(); - acceptData.Length = mTransfer.GetTransferLength(); - - LogErrorOnFailure(mTransfer.AcceptTransfer(acceptData)); - }); + errorHandler:^(NSError *) { + // Not much we can do here + }]; }; - auto * controller = [[MTRDeviceControllerFactory sharedInstance] runningControllerForFabricIndex:mFabricIndex.Value()]; - VerifyOrReturnError(controller != nil, CHIP_ERROR_INCORRECT_STATE); auto nodeId = @(mNodeId.Value()); auto strongDelegate = mDelegate; - dispatch_async(mWorkQueue, ^{ + dispatch_async(mDelegateNotificationQueue, ^{ if ([strongDelegate respondsToSelector:@selector (handleBDXTransferSessionBeginForNodeID:controller:fileDesignator:offset:completion:)]) { [strongDelegate handleBDXTransferSessionBeginForNodeID:nodeId @@ -176,6 +215,8 @@ CHIP_ERROR OnTransferSessionBegin(TransferSession::OutputEvent & event) CHIP_ERROR OnTransferSessionEnd(TransferSession::OutputEvent & event) { + assertChipStackLockedByCurrentThread(); + VerifyOrReturnError(mFabricIndex.HasValue(), CHIP_ERROR_INCORRECT_STATE); VerifyOrReturnError(mNodeId.HasValue(), CHIP_ERROR_INCORRECT_STATE); @@ -191,7 +232,7 @@ CHIP_ERROR OnTransferSessionEnd(TransferSession::OutputEvent & event) auto nodeId = @(mNodeId.Value()); auto strongDelegate = mDelegate; - dispatch_async(mWorkQueue, ^{ + dispatch_async(mDelegateNotificationQueue, ^{ [strongDelegate handleBDXTransferSessionEndForNodeID:nodeId controller:controller error:[MTRError errorForCHIPErrorCode:error]]; @@ -203,6 +244,8 @@ CHIP_ERROR OnTransferSessionEnd(TransferSession::OutputEvent & event) CHIP_ERROR OnBlockQuery(TransferSession::OutputEvent & event) { + assertChipStackLockedByCurrentThread(); + VerifyOrReturnError(mFabricIndex.HasValue(), CHIP_ERROR_INCORRECT_STATE); VerifyOrReturnError(mNodeId.HasValue(), CHIP_ERROR_INCORRECT_STATE); @@ -214,34 +257,48 @@ CHIP_ERROR OnBlockQuery(TransferSession::OutputEvent & event) bytesToSkip = @(event.bytesToSkip.BytesToSkip); } - auto completionHandler = ^(NSData * _Nullable data, BOOL isEOF) { - dispatch_async(mWorkQueue, ^{ - if (data == nil) { - LogErrorOnFailure(mTransfer.AbortTransfer(bdx::StatusCode::kUnknown)); - return; - } + auto * controller = [[MTRDeviceControllerFactory sharedInstance] runningControllerForFabricIndex:mFabricIndex.Value()]; + VerifyOrReturnError(controller != nil, CHIP_ERROR_INCORRECT_STATE); - TransferSession::BlockData blockData; - blockData.Data = static_cast([data bytes]); - blockData.Length = static_cast([data length]); - blockData.IsEof = isEOF; + auto transferGeneration = mTransferGeneration; - CHIP_ERROR err = mTransfer.PrepareBlock(blockData); - if (CHIP_NO_ERROR != err) { - LogErrorOnFailure(err); - LogErrorOnFailure(mTransfer.AbortTransfer(bdx::StatusCode::kUnknown)); + auto completionHandler = ^(NSData * _Nullable data, BOOL isEOF) { + [controller + asyncDispatchToMatterQueue:^(chip::Controller::DeviceCommissioner *) { + assertChipStackLockedByCurrentThread(); + + if (!mInitialized || mTransferGeneration != transferGeneration) { + // Callback for a stale transfer. + return; + } + + if (data == nil) { + LogErrorOnFailure(mTransfer.AbortTransfer(bdx::StatusCode::kUnknown)); + return; + } + + TransferSession::BlockData blockData; + blockData.Data = static_cast([data bytes]); + blockData.Length = static_cast([data length]); + blockData.IsEof = isEOF; + + CHIP_ERROR err = mTransfer.PrepareBlock(blockData); + if (CHIP_NO_ERROR != err) { + LogErrorOnFailure(err); + LogErrorOnFailure(mTransfer.AbortTransfer(bdx::StatusCode::kUnknown)); + } } - }); + errorHandler:^(NSError *) { + // Not much we can do here + }]; }; // TODO Handle MaxLength - auto * controller = [[MTRDeviceControllerFactory sharedInstance] runningControllerForFabricIndex:mFabricIndex.Value()]; - VerifyOrReturnError(controller != nil, CHIP_ERROR_INCORRECT_STATE); auto nodeId = @(mNodeId.Value()); auto strongDelegate = mDelegate; - dispatch_async(mWorkQueue, ^{ + dispatch_async(mDelegateNotificationQueue, ^{ if ([strongDelegate respondsToSelector:@selector (handleBDXQueryForNodeID:controller:blockSize:blockIndex:bytesToSkip:completion:)]) { [strongDelegate handleBDXQueryForNodeID:nodeId @@ -303,6 +360,8 @@ void HandleTransferSessionOutput(TransferSession::OutputEvent & event) override CHIP_ERROR ConfigureState(chip::FabricIndex fabricIndex, chip::NodeId nodeId) { + assertChipStackLockedByCurrentThread(); + if (mInitialized) { // Prevent a new node connection since another is active. VerifyOrReturnError(mFabricIndex.Value() == fabricIndex && mNodeId.Value() == nodeId, CHIP_ERROR_BUSY); @@ -321,11 +380,14 @@ CHIP_ERROR ConfigureState(chip::FabricIndex fabricIndex, chip::NodeId nodeId) void ResetState() { + assertChipStackLockedByCurrentThread(); + if (!mInitialized) { return; } Responder::ResetTransfer(); + ++mTransferGeneration; mFabricIndex.ClearValue(); mNodeId.ClearValue(); @@ -341,8 +403,14 @@ void ResetState() Optional mFabricIndex; Optional mNodeId; id mDelegate = nil; - dispatch_queue_t mWorkQueue = nil; + dispatch_queue_t mDelegateNotificationQueue = nil; Messaging::ExchangeManager * mExchangeMgr = nullptr; + + // Since we are a singleton, we get reused across transfers, but also have + // async calls that can happen. The transfer generation keeps track of + // which transfer we are currently doing, so we can ignore async calls + // attached to no-longer-running transfers. + uint64_t mTransferGeneration = 0; }; BdxOTASender gOtaSender; @@ -351,15 +419,15 @@ void ResetState() MTROTAProviderDelegateBridge::MTROTAProviderDelegateBridge(id delegate) : mDelegate(delegate) - , mWorkQueue(DeviceLayer::PlatformMgrImpl().GetWorkQueue()) + , mDelegateNotificationQueue(dispatch_queue_create("com.csa.matter.framework.otaprovider.workqueue", DISPATCH_QUEUE_SERIAL)) { - gOtaSender.SetDelegate(delegate); + gOtaSender.SetDelegate(delegate, mDelegateNotificationQueue); Clusters::OTAProvider::SetDelegate(kOtaProviderEndpoint, this); } MTROTAProviderDelegateBridge::~MTROTAProviderDelegateBridge() { - gOtaSender.SetDelegate(nil); + gOtaSender.SetDelegate(nil, nil); Clusters::OTAProvider::SetDelegate(kOtaProviderEndpoint, nullptr); } @@ -370,6 +438,11 @@ void ResetState() void MTROTAProviderDelegateBridge::Shutdown() { gOtaSender.Shutdown(); } +void MTROTAProviderDelegateBridge::ControllerShuttingDown(MTRDeviceController * controller) +{ + gOtaSender.ControllerShuttingDown(controller); +} + namespace { // Return false if we could not get peer node info (a running controller for // the fabric and a node id). In that case we will have already added an @@ -456,13 +529,15 @@ bool GetPeerNodeInfo(CommandHandler * commandHandler, const ConcreteCommandPath void MTROTAProviderDelegateBridge::HandleQueryImage( CommandHandler * commandObj, const ConcreteCommandPath & commandPath, const Commands::QueryImage::DecodableType & commandData) { + assertChipStackLockedByCurrentThread(); + NodeId nodeId; MTRDeviceController * controller; if (!GetPeerNodeInfo(commandObj, commandPath, &nodeId, &controller)) { return; } - auto * commandParams = [[MTROtaSoftwareUpdateProviderClusterQueryImageParams alloc] init]; + auto * commandParams = [[MTROTASoftwareUpdateProviderClusterQueryImageParams alloc] init]; CHIP_ERROR err = ConvertToQueryImageParams(commandData, commandParams); if (err != CHIP_NO_ERROR) { commandObj->AddStatus(commandPath, Protocols::InteractionModel::Status::InvalidCommand); @@ -473,68 +548,81 @@ bool GetPeerNodeInfo(CommandHandler * commandHandler, const ConcreteCommandPath __block CommandHandler::Handle handle(commandObj); __block ConcreteCommandPath cachedCommandPath(commandPath.mEndpointId, commandPath.mClusterId, commandPath.mCommandId); - auto completionHandler = ^( - MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error) { - dispatch_async(mWorkQueue, ^{ - CommandHandler * handler = EnsureValidState(handle, cachedCommandPath, "QueryImage", data, error); - VerifyOrReturn(handler != nullptr); - - ChipLogDetail(Controller, "QueryImage: application responded with: %s", - [[data description] cStringUsingEncoding:NSUTF8StringEncoding]); - - Commands::QueryImageResponse::Type response; - ConvertFromQueryImageResponseParms(data, response); - - auto hasUpdate = [data.status isEqual:@(MTROtaSoftwareUpdateProviderOTAQueryStatusUpdateAvailable)]; - auto isBDXProtocolSupported = - [commandParams.protocolsSupported containsObject:@(MTROtaSoftwareUpdateProviderOTADownloadProtocolBDXSynchronous)]; - - if (hasUpdate && isBDXProtocolSupported) { - auto fabricIndex = handler->GetSubjectDescriptor().fabricIndex; - auto nodeId = handler->GetSubjectDescriptor().subject; - CHIP_ERROR err = gOtaSender.PrepareForTransfer(fabricIndex, nodeId); - if (CHIP_NO_ERROR != err) { - LogErrorOnFailure(err); - handler->AddStatus(cachedCommandPath, Protocols::InteractionModel::Status::Failure); - handle.Release(); - return; - } - - auto targetNodeId = handler->GetExchangeContext()->GetSessionHandle()->AsSecureSession()->GetLocalScopedNodeId(); - - char uriBuffer[kMaxBDXURILen]; - MutableCharSpan uri(uriBuffer); - err = bdx::MakeURI(targetNodeId.GetNodeId(), AsCharSpan(data.imageURI), uri); - if (CHIP_NO_ERROR != err) { - LogErrorOnFailure(err); - handler->AddStatus(cachedCommandPath, Protocols::InteractionModel::Status::Failure); - handle.Release(); - return; - } - - response.imageURI.SetValue(uri); - handler->AddResponse(cachedCommandPath, response); - handle.Release(); - return; - } - - handler->AddResponse(cachedCommandPath, response); - handle.Release(); - }); - }; + auto completionHandler + = ^(MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error) { + [controller + asyncDispatchToMatterQueue:^(chip::Controller::DeviceCommissioner *) { + assertChipStackLockedByCurrentThread(); + + CommandHandler * handler = EnsureValidState(handle, cachedCommandPath, "QueryImage", data, error); + VerifyOrReturn(handler != nullptr); + + ChipLogDetail(Controller, "QueryImage: application responded with: %s", + [[data description] cStringUsingEncoding:NSUTF8StringEncoding]); + + Commands::QueryImageResponse::Type response; + ConvertFromQueryImageResponseParms(data, response); + + auto hasUpdate = [data.status isEqual:@(MTROtaSoftwareUpdateProviderOTAQueryStatusUpdateAvailable)]; + auto isBDXProtocolSupported = [commandParams.protocolsSupported + containsObject:@(MTROtaSoftwareUpdateProviderOTADownloadProtocolBDXSynchronous)]; + + if (hasUpdate && isBDXProtocolSupported) { + auto fabricIndex = handler->GetSubjectDescriptor().fabricIndex; + auto nodeId = handler->GetSubjectDescriptor().subject; + CHIP_ERROR err = gOtaSender.PrepareForTransfer(fabricIndex, nodeId); + if (CHIP_NO_ERROR != err) { + LogErrorOnFailure(err); + handler->AddStatus(cachedCommandPath, Protocols::InteractionModel::Status::Failure); + handle.Release(); + return; + } + + auto targetNodeId + = handler->GetExchangeContext()->GetSessionHandle()->AsSecureSession()->GetLocalScopedNodeId(); + + char uriBuffer[kMaxBDXURILen]; + MutableCharSpan uri(uriBuffer); + err = bdx::MakeURI(targetNodeId.GetNodeId(), AsCharSpan(data.imageURI), uri); + if (CHIP_NO_ERROR != err) { + LogErrorOnFailure(err); + handler->AddStatus(cachedCommandPath, Protocols::InteractionModel::Status::Failure); + handle.Release(); + return; + } + + response.imageURI.SetValue(uri); + handler->AddResponse(cachedCommandPath, response); + handle.Release(); + return; + } + + handler->AddResponse(cachedCommandPath, response); + handle.Release(); + } + + errorHandler:^(NSError *) { + // Not much we can do here + }]; + }; auto strongDelegate = mDelegate; - dispatch_async(mWorkQueue, ^{ + dispatch_async(mDelegateNotificationQueue, ^{ if ([strongDelegate respondsToSelector:@selector(handleQueryImageForNodeID:controller:params:completion:)]) { [strongDelegate handleQueryImageForNodeID:@(nodeId) controller:controller params:commandParams completion:completionHandler]; } else { - [strongDelegate handleQueryImageForNodeID:@(nodeId) - controller:controller - params:commandParams - completionHandler:completionHandler]; + // Cast is safe because subclass does not add any selectors. + [strongDelegate + handleQueryImageForNodeID:@(nodeId) + controller:controller + params:static_cast(commandParams) + completionHandler:^(MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, + NSError * _Nullable error) { + completionHandler(data, error); + }]; } }); } @@ -542,6 +630,8 @@ bool GetPeerNodeInfo(CommandHandler * commandHandler, const ConcreteCommandPath void MTROTAProviderDelegateBridge::HandleApplyUpdateRequest(CommandHandler * commandObj, const ConcreteCommandPath & commandPath, const Commands::ApplyUpdateRequest::DecodableType & commandData) { + assertChipStackLockedByCurrentThread(); + NodeId nodeId; MTRDeviceController * controller; if (!GetPeerNodeInfo(commandObj, commandPath, &nodeId, &controller)) { @@ -553,36 +643,48 @@ bool GetPeerNodeInfo(CommandHandler * commandHandler, const ConcreteCommandPath __block ConcreteCommandPath cachedCommandPath(commandPath.mEndpointId, commandPath.mClusterId, commandPath.mCommandId); auto completionHandler - = ^(MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, NSError * _Nullable error) { - dispatch_async(mWorkQueue, ^{ - CommandHandler * handler = EnsureValidState(handle, cachedCommandPath, "ApplyUpdateRequest", data, error); - VerifyOrReturn(handler != nullptr); - - ChipLogDetail(Controller, "ApplyUpdateRequest: application responded with: %s", - [[data description] cStringUsingEncoding:NSUTF8StringEncoding]); - - Commands::ApplyUpdateResponse::Type response; - ConvertFromApplyUpdateRequestResponseParms(data, response); - handler->AddResponse(cachedCommandPath, response); - handle.Release(); - }); + = ^(MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, NSError * _Nullable error) { + [controller + asyncDispatchToMatterQueue:^(chip::Controller::DeviceCommissioner *) { + assertChipStackLockedByCurrentThread(); + + CommandHandler * handler = EnsureValidState(handle, cachedCommandPath, "ApplyUpdateRequest", data, error); + VerifyOrReturn(handler != nullptr); + + ChipLogDetail(Controller, "ApplyUpdateRequest: application responded with: %s", + [[data description] cStringUsingEncoding:NSUTF8StringEncoding]); + + Commands::ApplyUpdateResponse::Type response; + ConvertFromApplyUpdateRequestResponseParms(data, response); + handler->AddResponse(cachedCommandPath, response); + handle.Release(); + } + errorHandler:^(NSError *) { + // Not much we can do here + }]; }; - auto * commandParams = [[MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams alloc] init]; + auto * commandParams = [[MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams alloc] init]; ConvertToApplyUpdateRequestParams(commandData, commandParams); auto strongDelegate = mDelegate; - dispatch_async(mWorkQueue, ^{ + dispatch_async(mDelegateNotificationQueue, ^{ if ([strongDelegate respondsToSelector:@selector(handleApplyUpdateRequestForNodeID:controller:params:completion:)]) { [strongDelegate handleApplyUpdateRequestForNodeID:@(nodeId) controller:controller params:commandParams completion:completionHandler]; } else { - [strongDelegate handleApplyUpdateRequestForNodeID:@(nodeId) - controller:controller - params:commandParams - completionHandler:completionHandler]; + // Cast is safe because subclass does not add any selectors. + [strongDelegate + handleApplyUpdateRequestForNodeID:@(nodeId) + controller:controller + params:static_cast( + commandParams) + completionHandler:^(MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, + NSError * _Nullable error) { + completionHandler(data, error); + }]; } }); } @@ -590,6 +692,8 @@ bool GetPeerNodeInfo(CommandHandler * commandHandler, const ConcreteCommandPath void MTROTAProviderDelegateBridge::HandleNotifyUpdateApplied(CommandHandler * commandObj, const ConcreteCommandPath & commandPath, const Commands::NotifyUpdateApplied::DecodableType & commandData) { + assertChipStackLockedByCurrentThread(); + NodeId nodeId; MTRDeviceController * controller; if (!GetPeerNodeInfo(commandObj, commandPath, &nodeId, &controller)) { @@ -601,36 +705,45 @@ bool GetPeerNodeInfo(CommandHandler * commandHandler, const ConcreteCommandPath __block ConcreteCommandPath cachedCommandPath(commandPath.mEndpointId, commandPath.mClusterId, commandPath.mCommandId); auto completionHandler = ^(NSError * _Nullable error) { - dispatch_async(mWorkQueue, ^{ - CommandHandler * handler = EnsureValidState(handle, cachedCommandPath, "NotifyUpdateApplied", error); - VerifyOrReturn(handler != nullptr); + [controller + asyncDispatchToMatterQueue:^(chip::Controller::DeviceCommissioner *) { + assertChipStackLockedByCurrentThread(); - handler->AddStatus(cachedCommandPath, Protocols::InteractionModel::Status::Success); - handle.Release(); - }); + CommandHandler * handler = EnsureValidState(handle, cachedCommandPath, "NotifyUpdateApplied", error); + VerifyOrReturn(handler != nullptr); + + handler->AddStatus(cachedCommandPath, Protocols::InteractionModel::Status::Success); + handle.Release(); + } + errorHandler:^(NSError *) { + // Not much we can do here + }]; }; - auto * commandParams = [[MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams alloc] init]; + auto * commandParams = [[MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams alloc] init]; ConvertToNotifyUpdateAppliedParams(commandData, commandParams); auto strongDelegate = mDelegate; - dispatch_async(mWorkQueue, ^{ + dispatch_async(mDelegateNotificationQueue, ^{ if ([strongDelegate respondsToSelector:@selector(handleNotifyUpdateAppliedForNodeID:controller:params:completion:)]) { [strongDelegate handleNotifyUpdateAppliedForNodeID:@(nodeId) controller:controller params:commandParams completion:completionHandler]; } else { - [strongDelegate handleNotifyUpdateAppliedForNodeID:@(nodeId) - controller:controller - params:commandParams - completionHandler:completionHandler]; + // Cast is safe because subclass does not add any selectors. + [strongDelegate + handleNotifyUpdateAppliedForNodeID:@(nodeId) + controller:controller + params:static_cast( + commandParams) + completionHandler:completionHandler]; } }); } CHIP_ERROR MTROTAProviderDelegateBridge::ConvertToQueryImageParams( - const Commands::QueryImage::DecodableType & commandData, MTROtaSoftwareUpdateProviderClusterQueryImageParams * commandParams) + const Commands::QueryImage::DecodableType & commandData, MTROTASoftwareUpdateProviderClusterQueryImageParams * commandParams) { commandParams.vendorId = [NSNumber numberWithUnsignedShort:commandData.vendorId]; commandParams.productId = [NSNumber numberWithUnsignedShort:commandData.productId]; @@ -663,7 +776,7 @@ bool GetPeerNodeInfo(CommandHandler * commandHandler, const ConcreteCommandPath } void MTROTAProviderDelegateBridge::ConvertFromQueryImageResponseParms( - const MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams * responseParams, + const MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * responseParams, Commands::QueryImageResponse::Type & response) { response.status = static_cast([responseParams.status intValue]); @@ -699,14 +812,14 @@ bool GetPeerNodeInfo(CommandHandler * commandHandler, const ConcreteCommandPath void MTROTAProviderDelegateBridge::ConvertToApplyUpdateRequestParams( const Commands::ApplyUpdateRequest::DecodableType & commandData, - MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams * commandParams) + MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams * commandParams) { commandParams.updateToken = AsData(commandData.updateToken); commandParams.newVersion = [NSNumber numberWithUnsignedLong:commandData.newVersion]; } void MTROTAProviderDelegateBridge::ConvertFromApplyUpdateRequestResponseParms( - const MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * responseParams, + const MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams * responseParams, Commands::ApplyUpdateResponse::Type & response) { response.action = static_cast([responseParams.action intValue]); @@ -715,7 +828,7 @@ bool GetPeerNodeInfo(CommandHandler * commandHandler, const ConcreteCommandPath void MTROTAProviderDelegateBridge::ConvertToNotifyUpdateAppliedParams( const Commands::NotifyUpdateApplied::DecodableType & commandData, - MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams * commandParams) + MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams * commandParams) { commandParams.updateToken = AsData(commandData.updateToken); commandParams.softwareVersion = [NSNumber numberWithUnsignedLong:commandData.softwareVersion]; diff --git a/src/darwin/Framework/CHIP/MTROnboardingPayloadParser.m b/src/darwin/Framework/CHIP/MTROnboardingPayloadParser.mm similarity index 100% rename from src/darwin/Framework/CHIP/MTROnboardingPayloadParser.m rename to src/darwin/Framework/CHIP/MTROnboardingPayloadParser.mm diff --git a/src/darwin/Framework/CHIP/MTROperationalCredentialsDelegate.mm b/src/darwin/Framework/CHIP/MTROperationalCredentialsDelegate.mm index 0703f4c065e76b..ba11b3c947a479 100644 --- a/src/darwin/Framework/CHIP/MTROperationalCredentialsDelegate.mm +++ b/src/darwin/Framework/CHIP/MTROperationalCredentialsDelegate.mm @@ -21,10 +21,8 @@ #import -#include - #import "MTRCertificates.h" -#import "MTRLogging.h" +#import "MTRLogging_Internal.h" #import "NSDataSpanConversion.h" #include @@ -94,12 +92,12 @@ uint32_t validityStart, validityEnd; if (!ToChipEpochTime(0, validityStart)) { - NSLog(@"Failed in computing certificate validity start date"); + MTR_LOG_ERROR("Failed in computing certificate validity start date"); return CHIP_ERROR_INTERNAL; } if (!ToChipEpochTime(kCertificateValiditySecs, validityEnd)) { - NSLog(@"Failed in computing certificate validity end date"); + MTR_LOG_ERROR("Failed in computing certificate validity end date"); return CHIP_ERROR_INTERNAL; } @@ -378,12 +376,12 @@ uint64_t GetIssuerId(NSNumber * _Nullable providedIssuerId) uint32_t validityStart, validityEnd; if (!ToChipEpochTime(0, validityStart)) { - NSLog(@"Failed in computing certificate validity start date"); + MTR_LOG_ERROR("Failed in computing certificate validity start date"); return CHIP_ERROR_INTERNAL; } if (!ToChipEpochTime(kCertificateValiditySecs, validityEnd)) { - NSLog(@"Failed in computing certificate validity end date"); + MTR_LOG_ERROR("Failed in computing certificate validity end date"); return CHIP_ERROR_INTERNAL; } @@ -428,12 +426,12 @@ uint64_t GetIssuerId(NSNumber * _Nullable providedIssuerId) uint32_t validityStart, validityEnd; if (!ToChipEpochTime(0, validityStart)) { - NSLog(@"Failed in computing certificate validity start date"); + MTR_LOG_ERROR("Failed in computing certificate validity start date"); return CHIP_ERROR_INTERNAL; } if (!ToChipEpochTime(kCertificateValiditySecs, validityEnd)) { - NSLog(@"Failed in computing certificate validity end date"); + MTR_LOG_ERROR("Failed in computing certificate validity end date"); return CHIP_ERROR_INTERNAL; } diff --git a/src/darwin/Framework/CHIP/MTRP256KeypairBridge.mm b/src/darwin/Framework/CHIP/MTRP256KeypairBridge.mm index c1045a428eb3f7..d253baa8dbf95c 100644 --- a/src/darwin/Framework/CHIP/MTRP256KeypairBridge.mm +++ b/src/darwin/Framework/CHIP/MTRP256KeypairBridge.mm @@ -18,11 +18,11 @@ #import "MTRP256KeypairBridge.h" #import "NSDataSpanConversion.h" -#import +#import #include #import "MTRKeypair.h" -#import "MTRLogging.h" +#import "MTRLogging_Internal.h" using namespace chip::Crypto; @@ -31,7 +31,7 @@ if (![keypair respondsToSelector:@selector(signMessageECDSA_DER:)] && ![keypair respondsToSelector:@selector(signMessageECDSA_RAW:)]) { // Not a valid MTRKeypair implementation. - NSLog(@"Keypair does not support message signing"); + MTR_LOG_ERROR("Keypair does not support message signing"); return CHIP_ERROR_INVALID_ARGUMENT; } diff --git a/src/darwin/Framework/CHIP/MTRPersistentStorageDelegateBridge.mm b/src/darwin/Framework/CHIP/MTRPersistentStorageDelegateBridge.mm index fdcde68d6799cc..69e4103645d4ea 100644 --- a/src/darwin/Framework/CHIP/MTRPersistentStorageDelegateBridge.mm +++ b/src/darwin/Framework/CHIP/MTRPersistentStorageDelegateBridge.mm @@ -17,6 +17,8 @@ #import "MTRPersistentStorageDelegateBridge.h" +#import "MTRLogging_Internal.h" + #define LOG_DEBUG_PERSISTENT_STORAGE_DELEGATE 0 MTRPersistentStorageDelegateBridge::MTRPersistentStorageDelegateBridge(id delegate) @@ -38,7 +40,7 @@ dispatch_sync(mWorkQueue, ^{ #if LOG_DEBUG_PERSISTENT_STORAGE_DELEGATE - NSLog(@"PersistentStorageDelegate Sync Get Value for Key: %@", keyString); + MTR_LOG_DEBUG("PersistentStorageDelegate Sync Get Value for Key: %@", keyString); #endif NSData * value = [mDelegate storageDataForKey:keyString]; @@ -81,7 +83,7 @@ __block CHIP_ERROR error = CHIP_NO_ERROR; dispatch_sync(mWorkQueue, ^{ #if LOG_DEBUG_PERSISTENT_STORAGE_DELEGATE - NSLog(@"PersistentStorageDelegate Set Key %@", keyString); + MTR_LOG_DEBUG("PersistentStorageDelegate Set Key %@", keyString); #endif if ([mDelegate setStorageData:valueData forKey:keyString] == NO) { @@ -99,7 +101,7 @@ __block CHIP_ERROR error = CHIP_NO_ERROR; dispatch_sync(mWorkQueue, ^{ #if LOG_DEBUG_PERSISTENT_STORAGE_DELEGATE - NSLog(@"PersistentStorageDelegate Delete Key: %@", keyString); + MTR_LOG_DEBUG("PersistentStorageDelegate Delete Key: %@", keyString); #endif if ([mDelegate removeStorageDataForKey:keyString] == NO) { diff --git a/src/darwin/Framework/CHIP/MTRQRCodeSetupPayloadParser.mm b/src/darwin/Framework/CHIP/MTRQRCodeSetupPayloadParser.mm index 8d0354c0cef147..bbb8042bb65e6e 100644 --- a/src/darwin/Framework/CHIP/MTRQRCodeSetupPayloadParser.mm +++ b/src/darwin/Framework/CHIP/MTRQRCodeSetupPayloadParser.mm @@ -17,8 +17,8 @@ #import "MTRQRCodeSetupPayloadParser.h" #import "MTRError_Internal.h" -#import "MTRLogging.h" -#import "MTRMemory.h" +#import "MTRFramework.h" +#import "MTRLogging_Internal.h" #import "MTRSetupPayload_Internal.h" #import @@ -29,10 +29,14 @@ @implementation MTRQRCodeSetupPayloadParser { chip::QRCodeSetupPayloadParser * _chipQRCodeSetupPayloadParser; } ++ (void)initialize +{ + MTRFrameworkInit(); +} + - (id)initWithBase38Representation:(NSString *)base38Representation { if (self = [super init]) { - [MTRMemory ensureInit]; _base38Representation = base38Representation; _chipQRCodeSetupPayloadParser = new chip::QRCodeSetupPayloadParser(std::string([base38Representation UTF8String])); } diff --git a/src/darwin/Framework/CHIP/MTRStorage.h b/src/darwin/Framework/CHIP/MTRStorage.h index 445f55ef38e493..97813fdbb957e9 100644 --- a/src/darwin/Framework/CHIP/MTRStorage.h +++ b/src/darwin/Framework/CHIP/MTRStorage.h @@ -24,6 +24,9 @@ NS_ASSUME_NONNULL_BEGIN * * The Matter framework may call storage methods from arbitrary threads, but * will not call storage methods concurrently. + * + * Implementations of the storage methods must not call into any Matter + * framework APIs. */ MTR_NEWLY_AVAILABLE @protocol MTRStorage diff --git a/src/darwin/Framework/CHIP/MTRThreadOperationalDataset.mm b/src/darwin/Framework/CHIP/MTRThreadOperationalDataset.mm index fb50d87981b845..dc8876b870f425 100644 --- a/src/darwin/Framework/CHIP/MTRThreadOperationalDataset.mm +++ b/src/darwin/Framework/CHIP/MTRThreadOperationalDataset.mm @@ -17,7 +17,7 @@ #import "MTRThreadOperationalDataset.h" -#include "MTRLogging.h" +#include "MTRLogging_Internal.h" #include #include diff --git a/src/darwin/Framework/CHIP/Matter.h b/src/darwin/Framework/CHIP/Matter.h index 5fd4b1483cc007..179c28424581ba 100644 --- a/src/darwin/Framework/CHIP/Matter.h +++ b/src/darwin/Framework/CHIP/Matter.h @@ -37,6 +37,7 @@ #import #import #import +#import #import #import #import @@ -46,6 +47,7 @@ #import #import #import +#import #import #import #import diff --git a/src/darwin/Framework/CHIP/Resources/Logging/com.csa.matter.plist b/src/darwin/Framework/CHIP/Resources/Logging/com.csa.matter.plist new file mode 100644 index 00000000000000..68261053076d7c --- /dev/null +++ b/src/darwin/Framework/CHIP/Resources/Logging/com.csa.matter.plist @@ -0,0 +1,18 @@ + + + + + DEFAULT-OPTIONS + + Default-Privacy-Setting + public + Level + + Enable + info + Persist + default + + + + diff --git a/src/darwin/Framework/CHIP/templates/MTRBaseClusters-src.zapt b/src/darwin/Framework/CHIP/templates/MTRBaseClusters-src.zapt index a475e8b604d667..f94760b6257782 100644 --- a/src/darwin/Framework/CHIP/templates/MTRBaseClusters-src.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRBaseClusters-src.zapt @@ -24,7 +24,7 @@ using chip::SessionHandle; // NOLINTBEGIN(clang-analyzer-cplusplus.NewDeleteLeaks): Linter is unable to locate the delete on these objects. {{#chip_client_clusters includeAll=true}} -@implementation MTRBaseCluster{{asUpperCamelCase name}} +@implementation MTRBaseCluster{{asUpperCamelCase name preserveAcronyms=true}} - (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue { @@ -42,14 +42,16 @@ using chip::SessionHandle; } {{#chip_cluster_commands}} -{{#*inline "callbackName"}}{{#if hasSpecificResponse}}{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase responseName}}{{else}}CommandSuccess{{/if}}{{/inline}} +{{#*inline "cluster"}}{{asUpperCamelCase parent.name preserveAcronyms=true}}{{/inline}} +{{#*inline "command"}}{{asUpperCamelCase name preserveAcronyms=true}}{{/inline}} +{{#*inline "callbackName"}}{{#if hasSpecificResponse}}{{>cluster}}Cluster{{asUpperCamelCase responseName preserveAcronyms=true}}{{else}}CommandSuccess{{/if}}{{/inline}} {{#unless (hasArguments)}} - (void){{asLowerCamelCase name}}WithCompletion:({{>command_completion_type command=.}})completion { [self {{asLowerCamelCase name}}WithParams:nil completion:completion]; } {{/unless}} -- (void){{asLowerCamelCase name}}WithParams: (MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}Params * {{#unless (commandHasRequiredField .)}}_Nullable{{/unless}})params completion:({{>command_completion_type command=.}})completion +- (void){{asLowerCamelCase name}}WithParams: (MTR{{>cluster}}Cluster{{>command}}Params * {{#unless (commandHasRequiredField .)}}_Nullable{{/unless}})params completion:({{>command_completion_type command=.}})completion { // Make a copy of params before we go async. params = [params copy]; @@ -102,7 +104,7 @@ using chip::SessionHandle; {{/chip_cluster_commands}} {{#chip_server_cluster_attributes}} -{{#*inline "attribute"}}Attribute{{asUpperCamelCase name}}{{/inline}} +{{#*inline "attribute"}}Attribute{{asUpperCamelCase name preserveAcronyms=true}}{{/inline}} - (void)read{{>attribute}}With {{~#if_is_fabric_scoped_struct type~}} Params:(MTRReadParams * _Nullable)params completion: @@ -179,7 +181,7 @@ reportHandler:(void (^)({{asObjectiveCClass type parent.name}} * _Nullable value + (void) read{{>attribute}}WithClusterStateCache:(MTRClusterStateCacheContainer *)clusterStateCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue completion:(void (^)({{asObjectiveCClass type parent.name}} * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTR{{>attribute_data_callback_name}}CallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^({{>attribute_data_callback_name}}Callback successCb, MTRErrorCallback failureCb) { + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^({{>attribute_data_callback_name}}Callback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; using TypeInfo = {{asUpperCamelCase parent.name}}::Attributes::{{asUpperCamelCase name}}::TypeInfo; @@ -202,11 +204,11 @@ reportHandler:(void (^)({{asObjectiveCClass type parent.name}} * _Nullable value {{/chip_server_cluster_attributes}} @end -{{#if (isStrEqual (asUpperCamelCase name) "UnitTesting")}} +{{#unless (isStrEqual (asUpperCamelCase name preserveAcronyms=true) (compatClusterNameRemapping name))}} -@implementation MTRBaseClusterTestCluster +@implementation MTRBaseCluster{{compatClusterNameRemapping name}} @end -{{/if}} +{{/unless}} @implementation MTRBaseCluster{{compatClusterNameRemapping name}} (Deprecated) @@ -215,7 +217,7 @@ reportHandler:(void (^)({{asObjectiveCClass type parent.name}} * _Nullable value { [self {{asLowerCamelCase name}}WithParams:params completion: {{#if hasSpecificResponse}} - ^(MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase responseName}}Params * _Nullable data, NSError * _Nullable error) { + ^(MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase responseName preserveAcronyms=true}}Params * _Nullable data, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. completionHandler(static_cast(data), error); } @@ -233,7 +235,7 @@ reportHandler:(void (^)({{asObjectiveCClass type parent.name}} * _Nullable value {{/chip_cluster_commands}} {{#chip_server_cluster_attributes}} -{{!Backwards compat for now: Treat DeviceTypeList as DeviceList. Ideally we would have both, not just DeviceList. }} +{{!Backwards compat for now: Treat DeviceTypeList as DeviceList. That's OK, since this is a deprecated API. }} {{#*inline "attribute"}}Attribute{{#if (isStrEqual (asUpperCamelCase parent.name) "Descriptor")}}{{#if (isStrEqual (asUpperCamelCase name) "DeviceTypeList")}}DeviceList{{else}}{{asUpperCamelCase name}}{{/if}}{{else}}{{asUpperCamelCase name}}{{/if}}{{/inline}} {{! TODO: We need a better setup for the API_AVALABLE annotations here; this does not scale at all sanely. }} - (void)read{{>attribute}}With @@ -244,7 +246,7 @@ reportHandler:(void (^)({{asObjectiveCClass type parent.name}} * _Nullable value {{~/if_is_fabric_scoped_struct~}} (void (^)({{asObjectiveCClass type parent.name compatRemapClusterName=true}} * _Nullable value, NSError * _Nullable error))completionHandler { - [self readAttribute{{asUpperCamelCase name}}With{{#if_is_fabric_scoped_struct type}}Params:params completion:{{else}}Completion:{{/if_is_fabric_scoped_struct}} + [self readAttribute{{asUpperCamelCase name preserveAcronyms=true}}With{{#if_is_fabric_scoped_struct type}}Params:params completion:{{else}}Completion:{{/if_is_fabric_scoped_struct}} ^({{asObjectiveCClass type parent.name}} * _Nullable value, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. completionHandler(static_cast<{{asObjectiveCClass type parent.name compatRemapClusterName=true}} *>(value), error); @@ -253,11 +255,11 @@ reportHandler:(void (^)({{asObjectiveCClass type parent.name}} * _Nullable value {{#if isWritableAttribute}} - (void)write{{>attribute}}WithValue:({{asObjectiveCType type parent.name compatRemapClusterName=true}})value completionHandler:(MTRStatusCompletion)completionHandler { - [self writeAttribute{{asUpperCamelCase name}}WithValue:value params:nil completion:completionHandler]; + [self writeAttribute{{asUpperCamelCase name preserveAcronyms=true}}WithValue:value params:nil completion:completionHandler]; } - (void)write{{>attribute}}WithValue:({{asObjectiveCType type parent.name compatRemapClusterName=true}})value params:(MTRWriteParams * _Nullable)params completionHandler:(MTRStatusCompletion)completionHandler { - [self writeAttribute{{asUpperCamelCase name}}WithValue:value params:params completion:completionHandler]; + [self writeAttribute{{asUpperCamelCase name preserveAcronyms=true}}WithValue:value params:params completion:completionHandler]; } {{/if}} {{#if isReportableAttribute}} @@ -272,7 +274,7 @@ subscriptionEstablished:(MTRSubscriptionEstablishedHandler _Nullable)subscriptio subscribeParams.minInterval = minInterval; subscribeParams.maxInterval = maxInterval; } - [self subscribeAttribute{{asUpperCamelCase name}}WithParams:subscribeParams subscriptionEstablished:subscriptionEstablishedHandler reportHandler: + [self subscribeAttribute{{asUpperCamelCase name preserveAcronyms=true}}WithParams:subscribeParams subscriptionEstablished:subscriptionEstablishedHandler reportHandler: ^({{asObjectiveCClass type parent.name}} * _Nullable value, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. reportHandler(static_cast<{{asObjectiveCClass type parent.name compatRemapClusterName=true}} *>(value), error) ; @@ -280,7 +282,7 @@ subscriptionEstablished:(MTRSubscriptionEstablishedHandler _Nullable)subscriptio } + (void) read{{>attribute}}WithAttributeCache:(MTRAttributeCacheContainer *)attributeCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue completionHandler:(void (^)({{asObjectiveCClass type parent.name compatRemapClusterName=true}} * _Nullable value, NSError * _Nullable error))completionHandler { - [self readAttribute{{asUpperCamelCase name}}WithClusterStateCache:attributeCacheContainer.realContainer endpoint:endpoint queue:queue completion: + [self readAttribute{{asUpperCamelCase name preserveAcronyms=true}}WithClusterStateCache:attributeCacheContainer.realContainer endpoint:endpoint queue:queue completion: ^({{asObjectiveCClass type parent.name}} * _Nullable value, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. completionHandler(static_cast<{{asObjectiveCClass type parent.name compatRemapClusterName=true}} *>(value), error); diff --git a/src/darwin/Framework/CHIP/templates/MTRBaseClusters.zapt b/src/darwin/Framework/CHIP/templates/MTRBaseClusters.zapt index 0a6e7ee7585e72..b9444fa86dbd06 100644 --- a/src/darwin/Framework/CHIP/templates/MTRBaseClusters.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRBaseClusters.zapt @@ -14,26 +14,34 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster {{name}} - * {{description}} + * + * {{description}} */ -{{#if (isStrEqual (asUpperCamelCase name) "UnitTesting")}} +{{#unless (isStrEqual (asUpperCamelCase name preserveAcronyms=true) (compatClusterNameRemapping name))}} MTR_NEWLY_AVAILABLE -{{/if}} -@interface MTRBaseCluster{{asUpperCamelCase name}} : MTRCluster +{{/unless}} +@interface MTRBaseCluster{{asUpperCamelCase name preserveAcronyms=true}} : MTRCluster - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; {{#chip_cluster_commands}} -- (void){{asLowerCamelCase name}}WithParams:(MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}Params * {{#unless (commandHasRequiredField .)}}_Nullable{{/unless}})params completion:({{>command_completion_type command=.}})completion MTR_NEWLY_AVAILABLE; +/** + * Command {{name}} + * + * {{description}} + */ +{{#*inline "cluster"}}{{asUpperCamelCase parent.name preserveAcronyms=true}}{{/inline~}} +{{~#*inline "command"}}{{asUpperCamelCase name preserveAcronyms=true}}{{/inline~}} +- (void){{asLowerCamelCase name}}WithParams:(MTR{{>cluster}}Cluster{{>command}}Params * {{#unless (commandHasRequiredField .)}}_Nullable{{/unless}})params completion:({{>command_completion_type command=.}})completion MTR_NEWLY_AVAILABLE; {{#unless (hasArguments)}} - (void){{asLowerCamelCase name}}WithCompletion:({{>command_completion_type command=.}})completion MTR_NEWLY_AVAILABLE; {{/unless}} {{/chip_cluster_commands}} {{#chip_server_cluster_attributes}} -{{#*inline "attribute"}}Attribute{{asUpperCamelCase name}}{{/inline}} +{{#*inline "attribute"}}Attribute{{asUpperCamelCase name preserveAcronyms=true}}{{/inline}} - (void)read{{>attribute}}With {{~#if_is_fabric_scoped_struct type~}} Params:(MTRReadParams * _Nullable)params completion: @@ -59,10 +67,15 @@ subscriptionEstablished:(MTRSubscriptionEstablishedHandler _Nullable)subscriptio {{/chip_client_clusters}} -MTR_NEWLY_DEPRECATED("Please use MTRBaseClusterUnitTesting") -@interface MTRBaseClusterTestCluster : MTRBaseClusterUnitTesting +{{#chip_client_clusters includeAll=true}} +{{#unless (isStrEqual (asUpperCamelCase name preserveAcronyms=true) (compatClusterNameRemapping name))}} +MTR_NEWLY_DEPRECATED("Please use MTRBaseCluster{{asUpperCamelCase name preserveAcronyms=true}}") +@interface MTRBaseCluster{{compatClusterNameRemapping name}} : MTRBaseCluster{{asUpperCamelCase name preserveAcronyms=true}} @end +{{/unless}} +{{/chip_client_clusters}} + {{#zcl_clusters}} {{#zcl_enums}} {{#*inline "enumDef"}} @@ -71,19 +84,16 @@ typedef NS_ENUM({{asUnderlyingZclType name}}, {{objCEnumName clusterName label}} {{objCEnumName ../clusterName ../label}}{{objCEnumItemLabel label}} = {{asHex value 2}}, {{/zcl_enum_items}} } -{{#if (isStrEqual (asUpperCamelCase clusterName) "UnitTesting")}} -MTR_NEWLY_AVAILABLE -{{else if (isStrEqual (asUpperCamelCase clusterName) "TestCluster")}} -MTR_NEWLY_DEPRECATED("Please use {{objCEnumName "UnitTesting" label}}") -{{/if}} -; {{/inline}} -{{> enumDef name=name clusterName=../name label=label}} +{{> enumDef name=name clusterName=(asUpperCamelCase ../name preserveAcronyms=true) label=label}} +{{#unless (isStrEqual (asUpperCamelCase ../name preserveAcronyms=true) (compatClusterNameRemapping ../name))}} +MTR_NEWLY_AVAILABLE; -{{#if (isStrEqual (asUpperCamelCase ../name) "UnitTesting")}} -{{> enumDef name=name clusterName="TestCluster" label=label}} +{{> enumDef name=name clusterName=(compatClusterNameRemapping ../name) label=label}} +MTR_NEWLY_DEPRECATED("Please use {{objCEnumName (asUpperCamelCase ../name preserveAcronyms=true) label}}") +{{/unless}} +; -{{/if}} {{/zcl_enums}} {{#zcl_bitmaps}} {{#*inline "bitmapDef"}} @@ -93,29 +103,26 @@ typedef NS_OPTIONS({{asUnderlyingZclType name}}, {{objCEnumName clusterName labe {{/zcl_bitmap_items}} } {{! TODO: We need a better setup for the API_AVALABLE annotations here; this does not scale at all sanely. }} -{{#if (isStrEqual (asUpperCamelCase ../name) "Switch")}} +{{#if (isStrEqual (asUpperCamelCase clusterName) "Switch")}} {{#if (isStrEqual (asUpperCamelCase label) "SwitchFeature")}} API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) {{/if}} {{/if}} -{{#if (isStrEqual (asUpperCamelCase ../name) "MediaPlayback")}} +{{#if (isStrEqual (asUpperCamelCase clusterName) "MediaPlayback")}} {{#if (isStrEqual (asUpperCamelCase label) "MediaPlaybackFeature")}} API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) {{/if}} {{/if}} -{{#if (isStrEqual (asUpperCamelCase clusterName) "UnitTesting")}} -MTR_NEWLY_AVAILABLE -{{else if (isStrEqual (asUpperCamelCase clusterName) "TestCluster")}} -MTR_NEWLY_DEPRECATED("Please use {{objCEnumName "UnitTesting" label}}") -{{/if}} -; {{/inline}} -{{> bitmapDef name=name clusterName=../name label=label}} +{{> bitmapDef name=name clusterName=(asUpperCamelCase ../name preserveAcronyms=true) label=label}} +{{#unless (isStrEqual (asUpperCamelCase ../name preserveAcronyms=true) (compatClusterNameRemapping ../name))}} +MTR_NEWLY_AVAILABLE; -{{#if (isStrEqual (asUpperCamelCase ../name) "UnitTesting")}} -{{> bitmapDef name=name clusterName="TestCluster" label=label}} +{{> bitmapDef name=name clusterName=(compatClusterNameRemapping ../name) label=label}} +MTR_NEWLY_DEPRECATED("Please use {{objCEnumName (asUpperCamelCase ../name preserveAcronyms=true) label}}") +{{/unless}} +; -{{/if}} {{/zcl_bitmaps}} {{/zcl_clusters}} @@ -136,7 +143,7 @@ MTR_NEWLY_DEPRECATED("Please use {{objCEnumName "UnitTesting" label}}") {{/chip_cluster_commands}} {{#chip_server_cluster_attributes}} -{{!Backwards compat for now: Treat DeviceTypeList as DeviceList. Ideally we would have both, not just DeviceList. }} +{{!Backwards compat for now: Treat DeviceTypeList as DeviceList. That's OK, since this is a deprecated API. }} {{#*inline "attribute"}}Attribute{{#if (isStrEqual (asUpperCamelCase parent.name) "Descriptor")}}{{#if (isStrEqual (asUpperCamelCase name) "DeviceTypeList")}}DeviceList{{else}}{{asUpperCamelCase name}}{{/if}}{{else}}{{asUpperCamelCase name}}{{/if}}{{/inline}} {{! TODO: We need a better setup for the API_AVALABLE annotations here; this does not scale at all sanely. }} - (void)read{{>attribute}}With @@ -146,21 +153,21 @@ MTR_NEWLY_DEPRECATED("Please use {{objCEnumName "UnitTesting" label}}") CompletionHandler: {{~/if_is_fabric_scoped_struct~}} (void (^)({{asObjectiveCClass type parent.name compatRemapClusterName=true}} * _Nullable value, NSError * _Nullable error))completionHandler {{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}}{{#if (isStrEqual (asUpperCamelCase name) "WriteOnlyInt8u")}}API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)){{/if}}{{/if}} - MTR_NEWLY_DEPRECATED("Please use read{{>attribute}}With{{#if_is_fabric_scoped_struct type}}Params:completion:{{else}}Completion:{{/if_is_fabric_scoped_struct}}"); + MTR_NEWLY_DEPRECATED("Please use readAttribute{{asUpperCamelCase name preserveAcronyms=true}}With{{#if_is_fabric_scoped_struct type}}Params:completion:{{else}}Completion:{{/if_is_fabric_scoped_struct}}"); {{#if isWritableAttribute}} - (void)write{{>attribute}}WithValue:({{asObjectiveCType type parent.name compatRemapClusterName=true}})value completionHandler:(MTRStatusCompletion)completionHandler {{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}}{{#if (isStrEqual (asUpperCamelCase name) "WriteOnlyInt8u")}}API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)){{/if}}{{/if}} - MTR_NEWLY_DEPRECATED("Please use write{{>attribute}}WithValue:completion:"); + MTR_NEWLY_DEPRECATED("Please use writeAttribute{{asUpperCamelCase name preserveAcronyms=true}}WithValue:completion:"); - (void)write{{>attribute}}WithValue:({{asObjectiveCType type parent.name compatRemapClusterName=true}})value params:(MTRWriteParams * _Nullable)params completionHandler:(MTRStatusCompletion)completionHandler {{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}}{{#if (isStrEqual (asUpperCamelCase name) "WriteOnlyInt8u")}}API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)){{/if}}{{/if}} - MTR_NEWLY_DEPRECATED("Please use write{{>attribute}}WithValue:params:completion:"); + MTR_NEWLY_DEPRECATED("Please use writeAttribute{{asUpperCamelCase name preserveAcronyms=true}}WithValue:params:completion:"); {{/if}} {{#if isReportableAttribute}} {{! TODO: We need a better setup for the API_AVALABLE annotations here; this does not scale at all sanely. }} - (void) subscribe{{>attribute}}WithMinInterval:(NSNumber * _Nonnull)minInterval maxInterval:(NSNumber * _Nonnull)maxInterval params:(MTRSubscribeParams * _Nullable)params subscriptionEstablished:(MTRSubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)({{asObjectiveCClass type parent.name compatRemapClusterName=true}} * _Nullable value, NSError * _Nullable error))reportHandler {{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}}{{#if (isStrEqual (asUpperCamelCase name) "WriteOnlyInt8u")}}API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)){{/if}}{{/if}} - MTR_NEWLY_DEPRECATED("Please use subscribe{{>attribute}}WithParams:subscriptionEstablished:"); + MTR_NEWLY_DEPRECATED("Please use subscribeAttribute{{asUpperCamelCase name preserveAcronyms=true}}WithParams:subscriptionEstablished:"); + (void) read{{>attribute}}WithAttributeCache:(MTRAttributeCacheContainer *)attributeCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue completionHandler:(void (^)({{asObjectiveCClass type parent.name compatRemapClusterName=true}} * _Nullable value, NSError * _Nullable error))completionHandler {{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}}{{#if (isStrEqual (asUpperCamelCase name) "WriteOnlyInt8u")}}API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)){{/if}}{{/if}} - MTR_NEWLY_DEPRECATED("Please use read{{>attribute}}WithAttributeCache:endpoint:queue:completion:"); + MTR_NEWLY_DEPRECATED("Please use readAttribute{{asUpperCamelCase name preserveAcronyms=true}}WithAttributeCache:endpoint:queue:completion:"); {{/if}} {{/chip_server_cluster_attributes}} diff --git a/src/darwin/Framework/CHIP/templates/MTRBaseClusters_internal.zapt b/src/darwin/Framework/CHIP/templates/MTRBaseClusters_internal.zapt index b341bcfe62bff7..15fc82e76a062f 100644 --- a/src/darwin/Framework/CHIP/templates/MTRBaseClusters_internal.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRBaseClusters_internal.zapt @@ -9,7 +9,7 @@ {{#chip_client_clusters includeAll=true}} -@interface MTRBaseCluster{{asUpperCamelCase name}} () +@interface MTRBaseCluster{{asUpperCamelCase name preserveAcronyms=true}} () @property (nonatomic, strong, readonly) MTRBaseDevice * device; @property (nonatomic, assign, readonly) chip::EndpointId endpoint; @end diff --git a/src/darwin/Framework/CHIP/templates/MTRCallbackBridge-src.zapt b/src/darwin/Framework/CHIP/templates/MTRCallbackBridge-src.zapt index 178a1ec356ba20..7025741ede6586 100644 --- a/src/darwin/Framework/CHIP/templates/MTRCallbackBridge-src.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRCallbackBridge-src.zapt @@ -40,13 +40,13 @@ {{#chip_client_clusters includeAll=true}} {{#chip_server_cluster_attributes}} {{#if isArray}} -{{#>MTRCallbackBridge ns=parent.name }}{{asUpperCamelCase ../../name}}{{asUpperCamelCase ../name}}ListAttributeCallback{{/MTRCallbackBridge}} +{{#>MTRCallbackBridge ns=parent.name }}{{asUpperCamelCase ../../name preserveAcronyms=true}}{{asUpperCamelCase ../name preserveAcronyms=true}}ListAttributeCallback{{/MTRCallbackBridge}} {{else}} {{#if_is_struct type}} - {{#>MTRCallbackBridge ns=parent.name }}{{asUpperCamelCase ../../name}}{{asUpperCamelCase ../name}}StructAttributeCallback{{/MTRCallbackBridge}} + {{#>MTRCallbackBridge ns=parent.name }}{{asUpperCamelCase ../../name preserveAcronyms=true}}{{asUpperCamelCase ../name preserveAcronyms=true}}StructAttributeCallback{{/MTRCallbackBridge}} {{/if_is_struct}} {{#if_is_strongly_typed_bitmap type}} - {{#>MTRCallbackBridge ns=parent.name }}{{asUpperCamelCase ../../name}}{{asUpperCamelCase ../name}}AttributeCallback{{/MTRCallbackBridge}} + {{#>MTRCallbackBridge ns=parent.name }}{{asUpperCamelCase ../../name preserveAcronyms=true}}{{asUpperCamelCase ../name preserveAcronyms=true}}AttributeCallback{{/MTRCallbackBridge}} {{/if_is_strongly_typed_bitmap}} {{/if}} {{/chip_server_cluster_attributes}} @@ -54,13 +54,13 @@ {{#chip_client_clusters includeAll=true}} {{#chip_cluster_responses}} -{{#>MTRCallbackBridge partial-type="Command" }}{{asUpperCamelCase ../../name}}Cluster{{asUpperCamelCase ../name}}Callback{{/MTRCallbackBridge}} +{{#>MTRCallbackBridge partial-type="Command" }}{{asUpperCamelCase ../../name preserveAcronyms=true}}Cluster{{asUpperCamelCase ../name preserveAcronyms=true}}Callback{{/MTRCallbackBridge}} {{/chip_cluster_responses}} {{/chip_client_clusters}} {{#zcl_clusters}} {{#zcl_enums}} -{{#>MTRCallbackBridge type=(asType label) isNullable=false ns=parent.name}}{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}AttributeCallback{{/MTRCallbackBridge}} -{{#>MTRCallbackBridge type=(asType label) isNullable=true ns=parent.name}}Nullable{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}AttributeCallback{{/MTRCallbackBridge}} +{{#>MTRCallbackBridge type=(asType label) isNullable=false ns=parent.name}}{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}AttributeCallback{{/MTRCallbackBridge}} +{{#>MTRCallbackBridge type=(asType label) isNullable=true ns=parent.name}}Nullable{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}AttributeCallback{{/MTRCallbackBridge}} {{/zcl_enums}} {{/zcl_clusters}} diff --git a/src/darwin/Framework/CHIP/templates/MTRCallbackBridge_internal.zapt b/src/darwin/Framework/CHIP/templates/MTRCallbackBridge_internal.zapt index 84c1f5686d0722..ccddfc9fa88989 100644 --- a/src/darwin/Framework/CHIP/templates/MTRCallbackBridge_internal.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRCallbackBridge_internal.zapt @@ -16,27 +16,27 @@ typedef void (*NullableVendorIdAttributeCallback)(void *, const chip::app::DataM {{#chip_client_clusters includeAll=true}} {{#chip_cluster_responses}} -typedef void (*{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}CallbackType)(void *, const chip::app::Clusters::{{asUpperCamelCase parent.name}}::Commands::{{asUpperCamelCase name}}::DecodableType &); +typedef void (*{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}CallbackType)(void *, const chip::app::Clusters::{{asUpperCamelCase parent.name}}::Commands::{{asUpperCamelCase name}}::DecodableType &); {{/chip_cluster_responses}} {{/chip_client_clusters}} {{#zcl_clusters}} {{#zcl_enums}} -typedef void (*{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}AttributeCallback)(void *, chip::app::Clusters::{{asUpperCamelCase parent.name}}::{{asType label}}); -typedef void (*Nullable{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}AttributeCallback)(void *, const chip::app::DataModel::Nullable &); +typedef void (*{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}AttributeCallback)(void *, chip::app::Clusters::{{asUpperCamelCase parent.name}}::{{asType label}}); +typedef void (*Nullable{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}AttributeCallback)(void *, const chip::app::DataModel::Nullable &); {{/zcl_enums}} {{/zcl_clusters}} {{#chip_client_clusters includeAll=true}} {{#chip_server_cluster_attributes}} {{#if isArray}} -typedef void (*{{asUpperCamelCase parent.name}}{{asUpperCamelCase name}}ListAttributeCallback)(void * context, {{zapTypeToDecodableClusterObjectType type ns=parent.name isArgument=true}} data); +typedef void (*{{asUpperCamelCase parent.name preserveAcronyms=true}}{{asUpperCamelCase name preserveAcronyms=true}}ListAttributeCallback)(void * context, {{zapTypeToDecodableClusterObjectType type ns=parent.name isArgument=true}} data); {{else}} {{#if_is_struct type}} -typedef void (*{{asUpperCamelCase parent.name}}{{asUpperCamelCase name}}StructAttributeCallback)(void *, {{zapTypeToDecodableClusterObjectType type ns=parent.name isArgument=true forceNotOptional=true}}); +typedef void (*{{asUpperCamelCase parent.name preserveAcronyms=true}}{{asUpperCamelCase name preserveAcronyms=true}}StructAttributeCallback)(void *, {{zapTypeToDecodableClusterObjectType type ns=parent.name isArgument=true forceNotOptional=true}}); {{/if_is_struct}} {{#if_is_strongly_typed_bitmap type}} -typedef void (*{{asUpperCamelCase parent.name}}{{asUpperCamelCase name}}AttributeCallback)(void *, {{zapTypeToDecodableClusterObjectType type ns=parent.name isArgument=true forceNotOptional=true}}); +typedef void (*{{asUpperCamelCase parent.name preserveAcronyms=true}}{{asUpperCamelCase name preserveAcronyms=true}}AttributeCallback)(void *, {{zapTypeToDecodableClusterObjectType type ns=parent.name isArgument=true forceNotOptional=true}}); {{/if_is_strongly_typed_bitmap}} {{/if}} {{/chip_server_cluster_attributes}} @@ -76,13 +76,13 @@ typedef void (*{{asUpperCamelCase parent.name}}{{asUpperCamelCase name}}Attribut {{#chip_client_clusters includeAll=true}} {{#chip_server_cluster_attributes}} {{#if isArray}} -{{#>MTRCallbackBridge header="1" ns=parent.name }}{{asUpperCamelCase ../../name}}{{asUpperCamelCase ../name}}ListAttributeCallback{{/MTRCallbackBridge}} +{{#>MTRCallbackBridge header="1" ns=parent.name }}{{asUpperCamelCase ../../name preserveAcronyms=true}}{{asUpperCamelCase ../name preserveAcronyms=true}}ListAttributeCallback{{/MTRCallbackBridge}} {{else}} {{#if_is_struct type}} - {{#>MTRCallbackBridge header="1" ns=parent.name }}{{asUpperCamelCase ../../name}}{{asUpperCamelCase ../name}}StructAttributeCallback{{/MTRCallbackBridge}} + {{#>MTRCallbackBridge header="1" ns=parent.name }}{{asUpperCamelCase ../../name preserveAcronyms=true}}{{asUpperCamelCase ../name preserveAcronyms=true}}StructAttributeCallback{{/MTRCallbackBridge}} {{/if_is_struct}} {{#if_is_strongly_typed_bitmap type}} - {{#>MTRCallbackBridge header="1" ns=parent.name }}{{asUpperCamelCase ../../name}}{{asUpperCamelCase ../name}}AttributeCallback{{/MTRCallbackBridge}} + {{#>MTRCallbackBridge header="1" ns=parent.name }}{{asUpperCamelCase ../../name preserveAcronyms=true}}{{asUpperCamelCase ../name preserveAcronyms=true}}AttributeCallback{{/MTRCallbackBridge}} {{/if_is_strongly_typed_bitmap}} {{/if}} {{/chip_server_cluster_attributes}} @@ -90,13 +90,13 @@ typedef void (*{{asUpperCamelCase parent.name}}{{asUpperCamelCase name}}Attribut {{#chip_client_clusters includeAll=true}} {{#chip_cluster_responses}} -{{#>MTRCallbackBridge header="1" partial-type="Command" }}{{asUpperCamelCase ../../name}}Cluster{{asUpperCamelCase ../name}}Callback{{/MTRCallbackBridge}} +{{#>MTRCallbackBridge header="1" partial-type="Command" }}{{asUpperCamelCase ../../name preserveAcronyms=true}}Cluster{{asUpperCamelCase ../name preserveAcronyms=true}}Callback{{/MTRCallbackBridge}} {{/chip_cluster_responses}} {{/chip_client_clusters}} {{#zcl_clusters}} {{#zcl_enums}} -{{#>MTRCallbackBridge header="1" type=(asType label) isNullable=false ns=parent.name}}{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}AttributeCallback{{/MTRCallbackBridge}} -{{#>MTRCallbackBridge header="1" type=(asType label) isNullable=true ns=parent.name}}Nullable{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}AttributeCallback{{/MTRCallbackBridge}} +{{#>MTRCallbackBridge header="1" type=(asType label) isNullable=false ns=parent.name}}{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}AttributeCallback{{/MTRCallbackBridge}} +{{#>MTRCallbackBridge header="1" type=(asType label) isNullable=true ns=parent.name}}Nullable{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}AttributeCallback{{/MTRCallbackBridge}} {{/zcl_enums}} {{/zcl_clusters}} diff --git a/src/darwin/Framework/CHIP/templates/MTRClusterConstants.zapt b/src/darwin/Framework/CHIP/templates/MTRClusterConstants.zapt index 1f93d4b2f5d654..0fdc8ebf367d78 100644 --- a/src/darwin/Framework/CHIP/templates/MTRClusterConstants.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRClusterConstants.zapt @@ -10,7 +10,8 @@ typedef NS_ENUM(uint32_t, MTRClusterIDType) { MTRCluster{{compatClusterNameRemapping label}}ID MTR_NEWLY_DEPRECATED("Please use MTRClusterIDType{{asUpperCamelCase label}}ID")= {{asMEI manufacturerCode code}}, {{/zcl_clusters}} {{#zcl_clusters}} -MTRClusterIDType{{asUpperCamelCase label}}ID MTR_NEWLY_AVAILABLE = {{asMEI manufacturerCode code}}, +{{~#*inline "cluster"}}{{asUpperCamelCase label preserveAcronyms=true}}{{/inline~}} +MTRClusterIDType{{>cluster}}ID MTR_NEWLY_AVAILABLE = {{asMEI manufacturerCode code}}, {{/zcl_clusters}} }; @@ -28,8 +29,9 @@ MTR_NEWLY_DEPRECATED("Please use MTRAttributeIDTypeGlobalAttribute{{asUpperCamel // Global attributes {{#zcl_attributes_server}} +{{~#*inline "attribute"}}{{asUpperCamelCase label preserveAcronyms=true}}{{/inline~}} {{#unless clusterRef}} -MTRAttributeIDTypeGlobalAttribute{{asUpperCamelCase label}}ID MTR_NEWLY_AVAILABLE = {{asMEI manufacturerCode code}}, +MTRAttributeIDTypeGlobalAttribute{{>attribute}}ID MTR_NEWLY_AVAILABLE = {{asMEI manufacturerCode code}}, {{/unless}} {{/zcl_attributes_server}} @@ -63,13 +65,15 @@ MTRCluster{{compatClusterNameRemapping ../clusterName}}Attribute{{asUpperCamelCa {{/last}} {{/zcl_attributes_server}} {{#zcl_attributes_server}} +{{~#*inline "cluster"}}{{asUpperCamelCase ../clusterName preserveAcronyms=true}}{{/inline~}} +{{~#*inline "attribute"}}{{asUpperCamelCase label preserveAcronyms=true}}{{/inline~}} {{#first}} -// Cluster {{asUpperCamelCase ../clusterName}} attributes +// Cluster {{> cluster}} attributes {{/first}} {{#if clusterRef}} -MTRAttributeIDTypeCluster{{asUpperCamelCase parent.label}}Attribute{{asUpperCamelCase label}}ID MTR_NEWLY_AVAILABLE = {{asMEI manufacturerCode code}}, +MTRAttributeIDTypeCluster{{>cluster}}Attribute{{>attribute}}ID MTR_NEWLY_AVAILABLE = {{asMEI manufacturerCode code}}, {{else}} -MTRAttributeIDTypeCluster{{asUpperCamelCase ../clusterName}}Attribute{{asUpperCamelCase label}}ID MTR_NEWLY_AVAILABLE= MTRAttributeIDTypeGlobalAttribute{{asUpperCamelCase label}}ID, +MTRAttributeIDTypeCluster{{>cluster}}Attribute{{>attribute}}ID MTR_NEWLY_AVAILABLE= MTRAttributeIDTypeGlobalAttribute{{asUpperCamelCase label}}ID, {{/if}} {{#last}} @@ -98,10 +102,12 @@ MTR_NEWLY_DEPRECATED("Please use MTRCommandIDTypeCluster{{asUpperCamelCase ../cl {{/last}} {{/zcl_commands}} {{#zcl_commands}} +{{~#*inline "cluster"}}{{asUpperCamelCase ../clusterName preserveAcronyms=true}}{{/inline~}} +{{~#*inline "command"}}{{asUpperCamelCase label preserveAcronyms=true}}{{/inline~}} {{#first}} -// Cluster {{asUpperCamelCase ../clusterName}} commands +// Cluster {{>cluster}} commands {{/first}} -MTRCommandIDTypeCluster{{asUpperCamelCase ../clusterName}}Command{{asUpperCamelCase label}}ID MTR_NEWLY_AVAILABLE = {{asMEI manufacturerCode code}}, +MTRCommandIDTypeCluster{{>cluster}}Command{{>command}}ID MTR_NEWLY_AVAILABLE = {{asMEI manufacturerCode code}}, {{#last}} {{/last}} @@ -129,10 +135,12 @@ MTR_NEWLY_DEPRECATED("Please use MTREventIDTypeCluster{{asUpperCamelCase ../clus {{/last}} {{/zcl_events}} {{#zcl_events}} +{{~#*inline "cluster"}}{{asUpperCamelCase ../clusterName preserveAcronyms=true}}{{/inline~}} +{{~#*inline "event"}}{{asUpperCamelCase name preserveAcronyms=true}}{{/inline~}} {{#first}} -// Cluster {{asUpperCamelCase ../clusterName}} events +// Cluster {{>cluster}} events {{/first}} -MTREventIDTypeCluster{{asUpperCamelCase ../clusterName}}Event{{asUpperCamelCase name}}ID MTR_NEWLY_AVAILABLE = {{asMEI manufacturerCode code}}, +MTREventIDTypeCluster{{>cluster}}Event{{>event}}ID MTR_NEWLY_AVAILABLE = {{asMEI manufacturerCode code}}, {{#last}} {{/last}} diff --git a/src/darwin/Framework/CHIP/templates/MTRClusters-src.zapt b/src/darwin/Framework/CHIP/templates/MTRClusters-src.zapt index c427058683ea2d..a8dc906972e105 100644 --- a/src/darwin/Framework/CHIP/templates/MTRClusters-src.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRClusters-src.zapt @@ -12,6 +12,7 @@ #import "MTRCluster_internal.h" #import "MTRStructsObjc.h" #import "MTRCommandPayloadsObjc.h" +#import "MTRLogging_Internal.h" #include #include @@ -23,9 +24,21 @@ using namespace chip::app::Clusters; using chip::Messaging::ExchangeManager; using chip::SessionHandle; +static void MTRClustersLogEnqueue(NSString *logPrefix, MTRAsyncCallbackWorkQueue *workQueue) { + MTR_LOG_INFO("%@ enqueueWorkItem %@", logPrefix, workQueue); +} + +static void MTRClustersLogDequeue(NSString *logPrefix, MTRAsyncCallbackWorkQueue *workQueue) { + MTR_LOG_INFO("%@ dequeueWorkItem %@", logPrefix, workQueue); +} + +static void MTRClustersLogCompletion(NSString *logPrefix, id value, NSError *error) { + MTR_LOG_INFO("%@ completion value %@ error %@ endWork", logPrefix, value, error); +} + // NOLINTBEGIN(clang-analyzer-cplusplus.NewDeleteLeaks): Linter is unable to locate the delete on these objects. {{#chip_client_clusters includeAll=true}} -@implementation MTRCluster{{asUpperCamelCase name}} +@implementation MTRCluster{{asUpperCamelCase name preserveAcronyms=true}} - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue { @@ -43,26 +56,31 @@ using chip::SessionHandle; } {{#chip_cluster_commands}} -{{#*inline "callbackName"}}{{#if hasSpecificResponse}}{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase responseName}}{{else}}CommandSuccess{{/if}}{{/inline}} +{{#*inline "cluster"}}{{asUpperCamelCase parent.name preserveAcronyms=true}}{{/inline}} +{{#*inline "callbackName"}}{{#if hasSpecificResponse}}{{>cluster}}Cluster{{asUpperCamelCase responseName preserveAcronyms=true}}{{else}}CommandSuccess{{/if}}{{/inline}} {{#unless (hasArguments)}} - (void){{asLowerCamelCase name}}WithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:({{>command_completion_type command=.}})completion { [self {{asLowerCamelCase name}}WithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; } {{/unless}} -- (void){{asLowerCamelCase name}}WithParams: (MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}Params * {{#unless (commandHasRequiredField .)}}_Nullable{{/unless}})params expectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:({{>command_completion_type command=.}})completion +- (void){{asLowerCamelCase name}}WithParams: (MTR{{>cluster}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}Params * {{#unless (commandHasRequiredField .)}}_Nullable{{/unless}})params expectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:({{>command_completion_type command=.}})completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, (unsigned int)MTRClusterIDType{{>cluster}}ID, (unsigned int)MTRCommandIDTypeCluster{{>cluster}}Command{{asUpperCamelCase name preserveAcronyms=true}}ID]; // Make a copy of params before we go async. params = [params copy]; NSNumber *timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice *baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; - auto * bridge = new MTR{{>callbackName}}CallbackBridge(self.callbackQueue, + auto * bridge = new MTR{{>callbackName}}CallbackBridge(self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ {{#if hasSpecificResponse}} {{! This treats completion as taking an id for the data. This is not great from a type-safety perspective, of course. }} @@ -73,6 +91,7 @@ using chip::SessionHandle; type-safety perspective, of course. }} completion(error); {{/if}} + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, {{>callbackName}}CallbackType successCb, MTRErrorCallback failureCb, MTRCallbackBridgeBase * bridge) { @@ -107,6 +126,7 @@ using chip::SessionHandle; std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -121,10 +141,10 @@ using chip::SessionHandle; {{/chip_cluster_commands}} {{#chip_server_cluster_attributes}} -{{!Backwards compat for now: Treat DeviceTypeList as DeviceList. Ideally we would have both, not just DeviceList. }} -{{#*inline "attribute"}}Attribute{{#if (isStrEqual (asUpperCamelCase parent.name) "Descriptor")}}{{#if (isStrEqual (asUpperCamelCase name) "DeviceTypeList")}}DeviceList{{else}}{{asUpperCamelCase name}}{{/if}}{{else}}{{asUpperCamelCase name}}{{/if}}{{/inline}} +{{#*inline "cluster"}}{{asUpperCamelCase parent.name preserveAcronyms=true}}{{/inline}} +{{#*inline "attribute"}}Attribute{{asUpperCamelCase name preserveAcronyms=true}}{{/inline}} - (NSDictionary *)read{{>attribute}}WithParams:(MTRReadParams * _Nullable)params { - return [self.device readAttributeWithEndpointID:@(_endpoint) clusterID:@(MTRClusterIDType{{asUpperCamelCase parent.name}}ID) attributeID:@(MTRAttributeIDTypeCluster{{asUpperCamelCase parent.name}}Attribute{{asUpperCamelCase name}}ID) params:params]; + return [self.device readAttributeWithEndpointID:@(_endpoint) clusterID:@(MTRClusterIDType{{>cluster}}ID) attributeID:@(MTRAttributeIDTypeCluster{{>cluster}}{{>attribute}}ID) params:params]; } {{#if isWritableAttribute}} @@ -142,7 +162,7 @@ using chip::SessionHandle; } {{/if}} - [self.device writeAttributeWithEndpointID:@(_endpoint) clusterID:@(MTRClusterIDType{{asUpperCamelCase parent.name}}ID) attributeID:@(MTRAttributeIDTypeCluster{{asUpperCamelCase parent.name}}Attribute{{asUpperCamelCase name}}ID) value:dataValueDictionary expectedValueInterval:expectedValueIntervalMs timedWriteTimeout:timedWriteTimeout]; + [self.device writeAttributeWithEndpointID:@(_endpoint) clusterID:@(MTRClusterIDType{{>cluster}}ID) attributeID:@(MTRAttributeIDTypeCluster{{>cluster}}{{>attribute}}ID) value:dataValueDictionary expectedValueInterval:expectedValueIntervalMs timedWriteTimeout:timedWriteTimeout]; } {{/if}} @@ -150,11 +170,11 @@ using chip::SessionHandle; {{/chip_server_cluster_attributes}} @end -{{#if (isStrEqual (asUpperCamelCase name) "UnitTesting")}} +{{#unless (isStrEqual (asUpperCamelCase name preserveAcronyms=true) (compatClusterNameRemapping name))}} -@implementation MTRClusterTestCluster +@implementation MTRCluster{{compatClusterNameRemapping name}} @end -{{/if}} +{{/unless}} @implementation MTRCluster{{compatClusterNameRemapping name}} (Deprecated) @@ -168,7 +188,7 @@ using chip::SessionHandle; { [self {{asLowerCamelCase name}}WithParams:params expectedValues:expectedDataValueDictionaries expectedValueInterval:expectedValueIntervalMs completion: {{#if hasSpecificResponse}} - ^(MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase responseName}}Params * _Nullable data, NSError * _Nullable error) { + ^(MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase responseName preserveAcronyms=true}}Params * _Nullable data, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. completionHandler(static_cast(data), error); } @@ -184,6 +204,35 @@ using chip::SessionHandle; } {{/unless}} {{/chip_cluster_commands}} +{{~#chip_server_cluster_attributes}} +{{~!Backwards compat for now: Treat DeviceTypeList as DeviceList. That's OK, since all these bits are deprecated. ~}} +{{~#*inline "attribute"}}Attribute{{#if (isStrEqual (asUpperCamelCase parent.name) "Descriptor")}}{{#if (isStrEqual (asUpperCamelCase name) "DeviceTypeList")}}DeviceList{{else}}{{asUpperCamelCase name}}{{/if}}{{else}}{{asUpperCamelCase name}}{{/if}}{{/inline~}} +{{~#*inline "attributeImpls"}} +- (NSDictionary *)read{{>attribute}}WithParams:(MTRReadParams * _Nullable)params +{ + return [self readAttribute{{asUpperCamelCase name preserveAcronyms=true}}WithParams:params]; +} +{{#if isWritableAttribute}} +- (void)write{{>attribute}}WithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs +{ + [self writeAttribute{{asUpperCamelCase name preserveAcronyms=true}}WithValue:dataValueDictionary expectedValueInterval:expectedValueIntervalMs]; +} +- (void)write{{>attribute}}WithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs params:(MTRWriteParams * _Nullable)params +{ + [self writeAttribute{{asUpperCamelCase name preserveAcronyms=true}}WithValue:dataValueDictionary expectedValueInterval:expectedValueIntervalMs params:params]; +} +{{/if}} +{{/inline~}} +{{#if (isStrEqual (asUpperCamelCase name preserveAcronyms=true) (asUpperCamelCase name))}} + {{#if (isStrEqual (asUpperCamelCase parent.name preserveAcronyms=true) "Descriptor")}} + {{#if (isStrEqual (asUpperCamelCase name preserveAcronyms=true) "DeviceTypeList")}} + {{> attributeImpls}} + {{/if}} + {{/if}} +{{else}} + {{> attributeImpls}} +{{/if}} +{{/chip_server_cluster_attributes}} @end {{/chip_client_clusters}} diff --git a/src/darwin/Framework/CHIP/templates/MTRClusters.zapt b/src/darwin/Framework/CHIP/templates/MTRClusters.zapt index fd58638c3bb196..f0878664af1e00 100644 --- a/src/darwin/Framework/CHIP/templates/MTRClusters.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRClusters.zapt @@ -16,30 +16,42 @@ NS_ASSUME_NONNULL_BEGIN * Cluster {{name}} * {{description}} */ -{{#if (isStrEqual (asUpperCamelCase name) "UnitTesting")}} +{{#unless (isStrEqual (asUpperCamelCase name preserveAcronyms=true) (compatClusterNameRemapping name))}} MTR_NEWLY_AVAILABLE -{{/if}} -@interface MTRCluster{{asUpperCamelCase name}} : MTRCluster +{{/unless}} +@interface MTRCluster{{asUpperCamelCase name preserveAcronyms=true}} : MTRCluster - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; {{#chip_cluster_commands}} -- (void){{asLowerCamelCase name}}WithParams:(MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}Params * {{#unless (commandHasRequiredField .)}}_Nullable{{/unless}})params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:({{>command_completion_type command=.}})completion MTR_NEWLY_AVAILABLE; +{{~#*inline "cluster"}}{{asUpperCamelCase parent.name preserveAcronyms=true}}{{/inline~}} +{{~#*inline "command"}}{{asUpperCamelCase name preserveAcronyms=true}}{{/inline~}} +- (void){{asLowerCamelCase name}}WithParams:(MTR{{>cluster}}Cluster{{>command}}Params * {{#unless (commandHasRequiredField .)}}_Nullable{{/unless}})params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:({{>command_completion_type command=.}})completion MTR_NEWLY_AVAILABLE; {{#unless (hasArguments)}} - (void){{asLowerCamelCase name}}WithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:({{>command_completion_type command=.}})completion MTR_NEWLY_AVAILABLE; {{/unless}} {{/chip_cluster_commands}} {{#chip_server_cluster_attributes}} -{{!Backwards compat for now: Treat DeviceTypeList as DeviceList. Ideally we would have both, not just DeviceList. }} -{{#*inline "attribute"}}Attribute{{#if (isStrEqual (asUpperCamelCase parent.name) "Descriptor")}}{{#if (isStrEqual (asUpperCamelCase name) "DeviceTypeList")}}DeviceList{{else}}{{asUpperCamelCase name}}{{/if}}{{else}}{{asUpperCamelCase name}}{{/if}}{{/inline}} -{{! TODO: We need a better setup for the API_AVALABLE annotations here; this does not scale at all sanely. }} -- (NSDictionary *)read{{>attribute}}WithParams:(MTRReadParams * _Nullable)params {{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}}{{#if (isStrEqual (asUpperCamelCase name) "WriteOnlyInt8u")}}API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)){{/if}}{{/if}}; +{{#*inline "attribute"}}Attribute{{asUpperCamelCase name preserveAcronyms=true}}{{/inline}} +{{#*inline "availability"}} +{{#if (isStrEqual (asUpperCamelCase name preserveAcronyms=true) (asUpperCamelCase name))}} + {{#if (isStrEqual (asUpperCamelCase parent.name preserveAcronyms=true) "Descriptor")}} + {{#if (isStrEqual (asUpperCamelCase name preserveAcronyms=true) "DeviceTypeList")}} + MTR_NEWLY_AVAILABLE + {{/if}} + {{/if}} +{{else}} + MTR_NEWLY_AVAILABLE +{{/if}} +{{/inline}} +{{! TODO: We need a better setup for the API_AVAILABLE annotations here; this does not scale at all sanely. }} +- (NSDictionary *)read{{>attribute}}WithParams:(MTRReadParams * _Nullable)params {{> availability}}; {{#if isWritableAttribute}} -- (void)write{{>attribute}}WithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs {{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}}{{#if (isStrEqual (asUpperCamelCase name) "WriteOnlyInt8u")}}API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)){{/if}}{{/if}}; -- (void)write{{>attribute}}WithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs params:(MTRWriteParams * _Nullable)params {{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}}{{#if (isStrEqual (asUpperCamelCase name) "WriteOnlyInt8u")}}API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)){{/if}}{{/if}}; +- (void)write{{>attribute}}WithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs {{> availability}}; +- (void)write{{>attribute}}WithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs params:(MTRWriteParams * _Nullable)params {{> availability}}; {{/if}} {{/chip_server_cluster_attributes}} @@ -50,10 +62,15 @@ MTR_NEWLY_AVAILABLE {{/chip_client_clusters}} -MTR_NEWLY_DEPRECATED("Please use MTRClusterUnitTesting") -@interface MTRClusterTestCluster : MTRClusterUnitTesting +{{#chip_client_clusters includeAll=true}} +{{#unless (isStrEqual (asUpperCamelCase name preserveAcronyms=true) (compatClusterNameRemapping name))}} +MTR_NEWLY_DEPRECATED("Please use MTRCluster{{asUpperCamelCase name preserveAcronyms=true}}") +@interface MTRCluster{{compatClusterNameRemapping name}} : MTRCluster{{asUpperCamelCase name preserveAcronyms=true}} @end +{{/unless}} +{{/chip_client_clusters}} + {{#chip_client_clusters includeAll=true}} @interface MTRCluster{{compatClusterNameRemapping name}} (Deprecated) @@ -67,6 +84,27 @@ MTR_NEWLY_DEPRECATED("Please use MTRClusterUnitTesting") - (void){{asLowerCamelCase name}}WithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completionHandler:({{>command_completion_type command=. compatRemapClusterName=true}})completionHandler MTR_NEWLY_DEPRECATED("Please use {{asLowerCamelCase name}}WithExpectedValues:expectedValueIntervalMs:completion:"); {{/unless}} {{/chip_cluster_commands}} +{{~#chip_server_cluster_attributes}} +{{~!Backwards compat for now: Treat DeviceTypeList as DeviceList. That's OK, since all these bits are deprecated. ~}} +{{~#*inline "attribute"}}Attribute{{#if (isStrEqual (asUpperCamelCase parent.name) "Descriptor")}}{{#if (isStrEqual (asUpperCamelCase name) "DeviceTypeList")}}DeviceList{{else}}{{asUpperCamelCase name}}{{/if}}{{else}}{{asUpperCamelCase name}}{{/if}}{{/inline~}} +{{~! TODO: We need a better setup for the API_AVAILABLE annotations here; this does not scale at all sanely. ~}} +{{~#*inline "attributeDecls"}} +- (NSDictionary *)read{{>attribute}}WithParams:(MTRReadParams * _Nullable)params {{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}}{{#if (isStrEqual (asUpperCamelCase name) "WriteOnlyInt8u")}}API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)){{/if}}{{/if}} MTR_NEWLY_DEPRECATED("Please use readAttribute{{asUpperCamelCase name preserveAcronyms=true}}WithParams on MTRCluster{{asUpperCamelCase parent.name preserveAcronyms=true}}"); +{{#if isWritableAttribute}} +- (void)write{{>attribute}}WithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs {{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}}{{#if (isStrEqual (asUpperCamelCase name) "WriteOnlyInt8u")}}API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)){{/if}}{{/if}} MTR_NEWLY_DEPRECATED("Please use writeAtribute{{asUpperCamelCase name preserveAcronyms=true}}WithValue on MTRCluster{{asUpperCamelCase parent.name preserveAcronyms=true}}"); +- (void)write{{>attribute}}WithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs params:(MTRWriteParams * _Nullable)params {{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}}{{#if (isStrEqual (asUpperCamelCase name) "WriteOnlyInt8u")}}API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)){{/if}}{{/if}} MTR_NEWLY_DEPRECATED("Please use writeAttribute{{asUpperCamelCase name preserveAcronyms=true}}WithValue on MTRCluster{{asUpperCamelCase parent.name preserveAcronyms=true}}"); +{{/if}} +{{/inline~}} +{{#if (isStrEqual (asUpperCamelCase name preserveAcronyms=true) (asUpperCamelCase name))}} + {{#if (isStrEqual (asUpperCamelCase parent.name preserveAcronyms=true) "Descriptor")}} + {{#if (isStrEqual (asUpperCamelCase name preserveAcronyms=true) "DeviceTypeList")}} + {{> attributeDecls}} + {{/if}} + {{/if}} +{{else}} + {{> attributeDecls}} +{{/if}} +{{/chip_server_cluster_attributes}} @end {{/chip_client_clusters}} diff --git a/src/darwin/Framework/CHIP/templates/MTRClusters_internal.zapt b/src/darwin/Framework/CHIP/templates/MTRClusters_internal.zapt index f809ff41b5666e..ccad7c4389101c 100644 --- a/src/darwin/Framework/CHIP/templates/MTRClusters_internal.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRClusters_internal.zapt @@ -10,7 +10,7 @@ {{#chip_client_clusters includeAll=true}} -@interface MTRCluster{{asUpperCamelCase name}} () +@interface MTRCluster{{asUpperCamelCase name preserveAcronyms=true}} () @property (nonatomic, readonly) uint16_t endpoint; @property (nonatomic, readonly) MTRDevice *device; @end diff --git a/src/darwin/Framework/CHIP/templates/MTRCommandPayloadsObjc-src.zapt b/src/darwin/Framework/CHIP/templates/MTRCommandPayloadsObjc-src.zapt index 55b806d24cc03c..c2d4fe17799d61 100644 --- a/src/darwin/Framework/CHIP/templates/MTRCommandPayloadsObjc-src.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRCommandPayloadsObjc-src.zapt @@ -6,7 +6,7 @@ NS_ASSUME_NONNULL_BEGIN {{#zcl_clusters}} {{#zcl_commands}} -@implementation MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}Params +@implementation MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}Params - (instancetype)init { if (self = [super init]) { @@ -21,7 +21,7 @@ NS_ASSUME_NONNULL_BEGIN - (id)copyWithZone:(NSZone * _Nullable)zone; { - auto other = [[MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}Params alloc] init]; + auto other = [[MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}Params alloc] init]; {{#zcl_command_arguments}} other.{{asStructPropertyName label}} = self.{{asStructPropertyName label}}; @@ -38,11 +38,18 @@ NS_ASSUME_NONNULL_BEGIN } @end -{{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}} +{{#*inline "deprecatedImpl"}} -@implementation MTRTestClusterCluster{{asUpperCamelCase name}}Params +@implementation MTR{{compatClusterNameRemapping parent.name}}Cluster{{asUpperCamelCase name}}Params @end -{{/if}} +{{/inline}} +{{#unless (isStrEqual (asUpperCamelCase parent.name preserveAcronyms=true) (compatClusterNameRemapping parent.name))}} +{{> deprecatedImpl}} +{{else}} +{{#unless (isStrEqual (asUpperCamelCase name preserveAcronyms=true) (asUpperCamelCase name))}} +{{> deprecatedImpl}} +{{/unless}} +{{/unless}} {{/zcl_commands}} {{/zcl_clusters}} diff --git a/src/darwin/Framework/CHIP/templates/MTRCommandPayloadsObjc.zapt b/src/darwin/Framework/CHIP/templates/MTRCommandPayloadsObjc.zapt index 3fab331d0edf2c..16f8bf03697008 100644 --- a/src/darwin/Framework/CHIP/templates/MTRCommandPayloadsObjc.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRCommandPayloadsObjc.zapt @@ -7,10 +7,14 @@ NS_ASSUME_NONNULL_BEGIN {{#zcl_clusters}} {{#zcl_commands}} -{{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}} +{{#unless (isStrEqual (asUpperCamelCase parent.name preserveAcronyms=true) (compatClusterNameRemapping parent.name))}} MTR_NEWLY_AVAILABLE -{{/if}} -@interface MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}Params : NSObject +{{else}} +{{#unless (isStrEqual (asUpperCamelCase name preserveAcronyms=true) (asUpperCamelCase name))}} +MTR_NEWLY_AVAILABLE +{{/unless}} +{{/unless}} +@interface MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}Params : NSObject {{#zcl_command_arguments}} {{! Override the getter name because some of our properties start with things @@ -32,17 +36,21 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs {{#if (isStrEqual source "server")}}MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"){{/if}}; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end -{{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}} +{{#*inline "deprecatedDecl"}} -MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingCluster{{asUpperCamelCase name}}Params") -@interface MTRTestClusterCluster{{asUpperCamelCase name}}Params : MTRUnitTestingCluster{{asUpperCamelCase name}}Params +MTR_NEWLY_DEPRECATED("Please use MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}Params") +@interface MTR{{compatClusterNameRemapping parent.name}}Cluster{{asUpperCamelCase name}}Params : MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name}}Params @end -{{/if}} +{{/inline}} +{{#unless (isStrEqual (asUpperCamelCase parent.name preserveAcronyms=true) (compatClusterNameRemapping parent.name))}} +{{> deprecatedDecl}} +{{else}} +{{#unless (isStrEqual (asUpperCamelCase name preserveAcronyms=true) (asUpperCamelCase name))}} +{{> deprecatedDecl}} +{{/unless}} +{{/unless}} {{/zcl_commands}} {{/zcl_clusters}} diff --git a/src/darwin/Framework/CHIP/templates/MTREventTLVValueDecoder-src.zapt b/src/darwin/Framework/CHIP/templates/MTREventTLVValueDecoder-src.zapt index 0d6b38c1a837b4..14a052bbe56d90 100644 --- a/src/darwin/Framework/CHIP/templates/MTREventTLVValueDecoder-src.zapt +++ b/src/darwin/Framework/CHIP/templates/MTREventTLVValueDecoder-src.zapt @@ -38,7 +38,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}Event *value = [MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}Event new]; + __auto_type *value = [MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}Event new]; {{#zcl_event_fields}} do { diff --git a/src/darwin/Framework/CHIP/templates/MTRStructsObjc-src.zapt b/src/darwin/Framework/CHIP/templates/MTRStructsObjc-src.zapt index fe5a9a1a7a19f3..625859d94b92dd 100644 --- a/src/darwin/Framework/CHIP/templates/MTRStructsObjc-src.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRStructsObjc-src.zapt @@ -38,22 +38,24 @@ NS_ASSUME_NONNULL_BEGIN @end {{/inline}} -{{> interfaceImpl interfaceName=(concat "MTR" (asUpperCamelCase parent.name) "Cluster" (asUpperCamelCase name))}} +{{> interfaceImpl interfaceName=(concat "MTR" (asUpperCamelCase parent.name preserveAcronyms=true) "Cluster" (asUpperCamelCase name preserveAcronyms=true))}} {{!Backwards compat for now: Add a DeviceType thing that is API-compatible with DeviceTypeStruct. }} {{#if (isStrEqual (asUpperCamelCase parent.name) "Descriptor")}} {{#if (isStrEqual (asUpperCamelCase name) "DeviceTypeStruct")}} {{> interfaceImpl interfaceName="MTRDescriptorClusterDeviceType"}} {{/if}} -{{else if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}} -@implementation MTRTestClusterCluster{{asUpperCamelCase name}} : MTRUnitTestingCluster{{asUpperCamelCase name}} +{{else}} +{{#unless (isStrEqual (asUpperCamelCase parent.name preserveAcronyms=true) (compatClusterNameRemapping parent.name))}} +@implementation MTR{{compatClusterNameRemapping parent.name}}Cluster{{asUpperCamelCase name}} : MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}} @end +{{/unless}} {{/if}} {{/zcl_structs}} {{#zcl_events}} -@implementation MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}Event +@implementation MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}Event - (instancetype)init { if (self = [super init]) { @@ -66,7 +68,7 @@ NS_ASSUME_NONNULL_BEGIN - (id)copyWithZone:(NSZone * _Nullable)zone { - auto other = [[MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}Event alloc] init]; + auto other = [[MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}Event alloc] init]; {{#zcl_event_fields}} other.{{asStructPropertyName name}} = self.{{asStructPropertyName name}}; @@ -81,12 +83,27 @@ NS_ASSUME_NONNULL_BEGIN return descriptionString; } +{{#if (isStrEqual (asUpperCamelCase parent.name preserveAcronyms=true) "Switch")}} +{{#if (isStrEqual (asUpperCamelCase name preserveAcronyms=true) "MultiPressComplete")}} +{{! Workaround for the name being mis-spelled in XML previously }} +- (void)setNewPosition:(NSNumber * _Nonnull)newPosition +{ + self.previousPosition = newPosition; +} + +- (NSNumber * _Nonnull)newPosition +{ + return self.previousPosition; +} + +{{/if}} +{{/if}} @end -{{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}} +{{#unless (isStrEqual (asUpperCamelCase parent.name preserveAcronyms=true) (compatClusterNameRemapping parent.name))}} -@implementation MTRTestClusterCluster{{asUpperCamelCase name}}Event : MTRUnitTestingCluster{{asUpperCamelCase name}}Event +@implementation MTR{{compatClusterNameRemapping parent.name}}Cluster{{asUpperCamelCase name}}Event : MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}Event @end -{{/if}} +{{/unless}} {{/zcl_events}} diff --git a/src/darwin/Framework/CHIP/templates/MTRStructsObjc.zapt b/src/darwin/Framework/CHIP/templates/MTRStructsObjc.zapt index 20dd2836a21e21..28ace6abc24779 100644 --- a/src/darwin/Framework/CHIP/templates/MTRStructsObjc.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRStructsObjc.zapt @@ -12,19 +12,18 @@ NS_ASSUME_NONNULL_BEGIN {{#zcl_struct_items}} @property (nonatomic, copy{{#unless (isStrEqual (asGetterName label) (asStructPropertyName label))}}, getter={{asGetterName label}}{{/unless}}) {{asObjectiveCType type parent.parent.name}} {{asStructPropertyName label}}; {{/zcl_struct_items}} - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; {{/inline}} {{! TODO: We need a better setup for the API_AVALABLE annotations here; this does not scale at all sanely. }} {{#if (isStrEqual (asUpperCamelCase parent.name) "Descriptor")}} {{#if (isStrEqual (asUpperCamelCase name) "DeviceTypeStruct")}} API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) {{/if}} -{{else if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}} +{{else}} +{{#unless (isStrEqual (asUpperCamelCase parent.name preserveAcronyms=true) (compatClusterNameRemapping parent.name))}} MTR_NEWLY_AVAILABLE +{{/unless}} {{/if}} -@interface MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}} : NSObject +@interface MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}} : NSObject {{> interfaceDecl}} @end @@ -35,31 +34,40 @@ MTR_NEWLY_AVAILABLE {{> interfaceDecl}} @end {{/if}} -{{else if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}} -MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingCluster{{asUpperCamelCase name}}") -@interface MTRTestClusterCluster{{asUpperCamelCase name}} : MTRUnitTestingCluster{{asUpperCamelCase name}} +{{else}} +{{#unless (isStrEqual (asUpperCamelCase parent.name preserveAcronyms=true) (compatClusterNameRemapping parent.name))}} +MTR_NEWLY_DEPRECATED("Please use MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}") +@interface MTR{{compatClusterNameRemapping parent.name}}Cluster{{asUpperCamelCase name}} : MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name}} @end +{{/unless}} {{/if}} {{/zcl_structs}} {{#zcl_events}} -{{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}} +{{#unless (isStrEqual (asUpperCamelCase parent.name preserveAcronyms=true) (compatClusterNameRemapping parent.name))}} MTR_NEWLY_AVAILABLE -{{/if}} -@interface MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}Event : NSObject +{{/unless}} +@interface MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}Event : NSObject {{#zcl_event_fields}} -@property (nonatomic, copy{{#unless (isStrEqual (asGetterName name) (asStructPropertyName name))}}, getter={{asGetterName name}}{{/unless}}) {{asObjectiveCType type parent.parent.name}} {{asStructPropertyName name}}; +@property (nonatomic, copy{{#unless (isStrEqual (asGetterName name) (asStructPropertyName name))}}, getter={{asGetterName name}}{{/unless}}) {{asObjectiveCType type parent.parent.name}} {{asStructPropertyName name}} +{{#if (isStrEqual (asUpperCamelCase ../parent.name preserveAcronyms=true) "Switch")}} +{{#if (isStrEqual (asUpperCamelCase ../name preserveAcronyms=true) "MultiPressComplete")}} +{{#if (isStrEqual (asStructPropertyName name) "previousPosition")}} +{{! Workaround for the name being mis-spelled in XML previously }} +MTR_NEWLY_AVAILABLE; +@property (nonatomic, copy) NSNumber * _Nonnull newPosition MTR_NEWLY_DEPRECATED("Please use previousPosition") +{{/if}} +{{/if}} +{{/if}} +; {{/zcl_event_fields}} - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end -{{#if (isStrEqual (asUpperCamelCase parent.name) "UnitTesting")}} +{{#unless (isStrEqual (asUpperCamelCase parent.name preserveAcronyms=true) (compatClusterNameRemapping parent.name))}} -MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingCluster{{asUpperCamelCase name}}Event") -@interface MTRTestClusterCluster{{asUpperCamelCase name}}Event : MTRUnitTestingCluster{{asUpperCamelCase name}}Event +MTR_NEWLY_DEPRECATED("Please use MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}Event") +@interface MTR{{compatClusterNameRemapping parent.name}}Cluster{{asUpperCamelCase name}}Event : MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}Event @end -{{/if}} +{{/unless}} {{/zcl_events}} diff --git a/src/darwin/Framework/CHIP/templates/partials/MTRCallbackBridge.zapt b/src/darwin/Framework/CHIP/templates/partials/MTRCallbackBridge.zapt index 91e913926505de..71f74dfe3f4c87 100644 --- a/src/darwin/Framework/CHIP/templates/partials/MTRCallbackBridge.zapt +++ b/src/darwin/Framework/CHIP/templates/partials/MTRCallbackBridge.zapt @@ -77,7 +77,7 @@ void MTR{{> @partial-block}}Bridge::OnSuccessFn(void * context {{#if (isStrEqual partial-type "Status")}} DispatchSuccess(context, nil); {{else if (isStrEqual partial-type "Command")}} - auto * response = [MTR{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase name}}Params new]; + auto * response = [MTR{{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase name preserveAcronyms=true}}Params new]; {{#chip_cluster_response_arguments}} { {{>decode_value target=(concat "response." (asStructPropertyName label)) source=(concat "data." (asLowerCamelCase label)) cluster=parent.parent.name errorCode="OnFailureFn(context, err); return;" depth=0}} diff --git a/src/darwin/Framework/CHIP/templates/partials/attribute_data_callback_name.zapt b/src/darwin/Framework/CHIP/templates/partials/attribute_data_callback_name.zapt index 385e4afb338ee9..28ec591edb7a44 100644 --- a/src/darwin/Framework/CHIP/templates/partials/attribute_data_callback_name.zapt +++ b/src/darwin/Framework/CHIP/templates/partials/attribute_data_callback_name.zapt @@ -1,22 +1,22 @@ {{~#if isArray~}} - {{asUpperCamelCase parent.name}}{{asUpperCamelCase name}}List + {{asUpperCamelCase parent.name preserveAcronyms=true}}{{asUpperCamelCase name preserveAcronyms=true}}List {{~else~}} {{~#if_is_struct type~}} {{~! Structs are not used as types of attributes much, so it's less code to generate the callbacks on a per-attribute basis than a per-struct-type basis. ~}} - {{asUpperCamelCase parent.name}}{{asUpperCamelCase name}}Struct + {{asUpperCamelCase parent.name preserveAcronyms=true}}{{asUpperCamelCase name preserveAcronyms=true}}Struct {{~else if_is_strongly_typed_bitmap type~}} - {{asUpperCamelCase parent.name}}{{asUpperCamelCase name}} + {{asUpperCamelCase parent.name preserveAcronyms=true}}{{asUpperCamelCase name preserveAcronyms=true}} {{~else~}} {{~#if isNullable}}Nullable{{/if~}} {{~#if (isStrEqual (asUpperCamelCase type) (asUpperCamelCase "vendor_id"))~}} VendorId {{~else if_is_strongly_typed_chip_enum type~}} - {{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase type}} + {{asUpperCamelCase parent.name preserveAcronyms=true}}Cluster{{asUpperCamelCase type preserveAcronyms=true}} {{~else~}} {{chipCallback.name}} {{~/if~}} {{~/if_is_struct~}} {{~/if~}} -Attribute \ No newline at end of file +Attribute{{~"remove_extra_spaces"~}} diff --git a/src/darwin/Framework/CHIP/templates/partials/command_completion_type.zapt b/src/darwin/Framework/CHIP/templates/partials/command_completion_type.zapt index 124d82564ed926..6616a327a6563a 100644 --- a/src/darwin/Framework/CHIP/templates/partials/command_completion_type.zapt +++ b/src/darwin/Framework/CHIP/templates/partials/command_completion_type.zapt @@ -3,7 +3,7 @@ {{~#if compatRemapClusterName~}} {{compatClusterNameRemapping command.parent.name}} {{~else~}} -{{asUpperCamelCase command.parent.name}} +{{asUpperCamelCase command.parent.name preserveAcronyms=true}} {{~/if~}} {{/inline}} void (^)(MTR{{> clusterName}}Cluster{{asUpperCamelCase command.responseName}}Params * _Nullable data, NSError * _Nullable error) diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRAttributeTLVValueDecoder.mm b/src/darwin/Framework/CHIP/zap-generated/MTRAttributeTLVValueDecoder.mm index 526c715f4d9fd5..48d87deb5a462e 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRAttributeTLVValueDecoder.mm +++ b/src/darwin/Framework/CHIP/zap-generated/MTRAttributeTLVValueDecoder.mm @@ -2538,8 +2538,8 @@ id MTRDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader & auto iter_0 = cppValue.begin(); while (iter_0.Next()) { auto & entry_0 = iter_0.GetValue(); - MTROtaSoftwareUpdateRequestorClusterProviderLocation * newElement_0; - newElement_0 = [MTROtaSoftwareUpdateRequestorClusterProviderLocation new]; + MTROTASoftwareUpdateRequestorClusterProviderLocation * newElement_0; + newElement_0 = [MTROTASoftwareUpdateRequestorClusterProviderLocation new]; newElement_0.providerNodeID = [NSNumber numberWithUnsignedLongLong:entry_0.providerNodeID]; newElement_0.endpoint = [NSNumber numberWithUnsignedShort:entry_0.endpoint]; newElement_0.fabricIndex = [NSNumber numberWithUnsignedChar:entry_0.fabricIndex]; diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h index 2cc6d665b908c7..ddf9058737fce3 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h @@ -26,7 +26,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Identify - * Attributes and commands for putting a device into Identification mode (e.g. flashing a light). + * + * Attributes and commands for putting a device into Identification mode (e.g. flashing a light). */ @interface MTRBaseClusterIdentify : MTRCluster @@ -34,8 +35,18 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command Identify + * + * Command description for Identify + */ - (void)identifyWithParams:(MTRIdentifyClusterIdentifyParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command TriggerEffect + * + * Command description for TriggerEffect + */ - (void)triggerEffectWithParams:(MTRIdentifyClusterTriggerEffectParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -135,7 +146,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Groups - * Attributes and commands for group configuration and manipulation. + * + * Attributes and commands for group configuration and manipulation. */ @interface MTRBaseClusterGroups : MTRCluster @@ -143,21 +155,51 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command AddGroup + * + * Command description for AddGroup + */ - (void)addGroupWithParams:(MTRGroupsClusterAddGroupParams *)params completion:(void (^)(MTRGroupsClusterAddGroupResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command ViewGroup + * + * Command description for ViewGroup + */ - (void)viewGroupWithParams:(MTRGroupsClusterViewGroupParams *)params completion:(void (^)(MTRGroupsClusterViewGroupResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command GetGroupMembership + * + * Command description for GetGroupMembership + */ - (void)getGroupMembershipWithParams:(MTRGroupsClusterGetGroupMembershipParams *)params completion:(void (^)(MTRGroupsClusterGetGroupMembershipResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command RemoveGroup + * + * Command description for RemoveGroup + */ - (void)removeGroupWithParams:(MTRGroupsClusterRemoveGroupParams *)params completion:(void (^)(MTRGroupsClusterRemoveGroupResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command RemoveAllGroups + * + * Command description for RemoveAllGroups + */ - (void)removeAllGroupsWithParams:(MTRGroupsClusterRemoveAllGroupsParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)removeAllGroupsWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command AddGroupIfIdentifying + * + * Command description for AddGroupIfIdentifying + */ - (void)addGroupIfIdentifyingWithParams:(MTRGroupsClusterAddGroupIfIdentifyingParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -240,7 +282,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Scenes - * Attributes and commands for scene configuration and manipulation. + * + * Attributes and commands for scene configuration and manipulation. */ @interface MTRBaseClusterScenes : MTRCluster @@ -248,32 +291,86 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command AddScene + * + * Add a scene to the scene table. Extension field sets are supported, and are inputed as '{"ClusterID": VALUE, + * "AttributeValueList":[{"AttributeId": VALUE, "AttributeValue": VALUE}]}' + */ - (void)addSceneWithParams:(MTRScenesClusterAddSceneParams *)params completion:(void (^)(MTRScenesClusterAddSceneResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command ViewScene + * + * Retrieves the requested scene entry from its Scene table. + */ - (void)viewSceneWithParams:(MTRScenesClusterViewSceneParams *)params completion:(void (^)(MTRScenesClusterViewSceneResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command RemoveScene + * + * Removes the requested scene entry, corresponding to the value of the GroupID field, from its Scene Table + */ - (void)removeSceneWithParams:(MTRScenesClusterRemoveSceneParams *)params completion:(void (^)(MTRScenesClusterRemoveSceneResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command RemoveAllScenes + * + * Remove all scenes, corresponding to the value of the GroupID field, from its Scene Table + */ - (void)removeAllScenesWithParams:(MTRScenesClusterRemoveAllScenesParams *)params completion:(void (^)(MTRScenesClusterRemoveAllScenesResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command StoreScene + * + * Adds the scene entry into its Scene Table along with all extension field sets corresponding to the current state of other + * clusters on the same endpoint + */ - (void)storeSceneWithParams:(MTRScenesClusterStoreSceneParams *)params completion:(void (^)(MTRScenesClusterStoreSceneResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command RecallScene + * + * Set the attributes and corresponding state for each other cluster implemented on the endpoint accordingly to the resquested scene + * entry in the Scene Table + */ - (void)recallSceneWithParams:(MTRScenesClusterRecallSceneParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command GetSceneMembership + * + * Get an unused scene identifier when no commissioning tool is in the network, or for a commissioning tool to get the used scene + * identifiers within a certain group + */ - (void)getSceneMembershipWithParams:(MTRScenesClusterGetSceneMembershipParams *)params completion:(void (^)(MTRScenesClusterGetSceneMembershipResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command EnhancedAddScene + * + * Allows a scene to be added using a finer scene transition time than the AddScene command. + */ - (void)enhancedAddSceneWithParams:(MTRScenesClusterEnhancedAddSceneParams *)params completion:(void (^)(MTRScenesClusterEnhancedAddSceneResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command EnhancedViewScene + * + * Allows a scene to be retrieved using a finer scene transition time than the ViewScene command + */ - (void)enhancedViewSceneWithParams:(MTRScenesClusterEnhancedViewSceneParams *)params completion:(void (^)(MTRScenesClusterEnhancedViewSceneResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command CopyScene + * + * Allows a client to efficiently copy scenes from one group/scene identifier pair to another group/scene identifier pair. + */ - (void)copySceneWithParams:(MTRScenesClusterCopySceneParams *)params completion:(void (^)(MTRScenesClusterCopySceneResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; @@ -417,7 +514,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster On/Off - * Attributes and commands for switching devices between 'On' and 'Off' states. + * + * Attributes and commands for switching devices between 'On' and 'Off' states. */ @interface MTRBaseClusterOnOff : MTRCluster @@ -425,18 +523,56 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command Off + * + * On receipt of this command, a device SHALL enter its ‘Off’ state. This state is device dependent, but it is recommended that it + * is used for power off or similar functions. On receipt of the Off command, the OnTime attribute SHALL be set to 0. + */ - (void)offWithParams:(MTROnOffClusterOffParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)offWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command On + * + * On receipt of this command, a device SHALL enter its ‘On’ state. This state is device dependent, but it is recommended that it is + * used for power on or similar functions. On receipt of the On command, if the value of the OnTime attribute is equal to 0, the + * device SHALL set the OffWaitTime attribute to 0. + */ - (void)onWithParams:(MTROnOffClusterOnParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)onWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command Toggle + * + * On receipt of this command, if a device is in its ‘Off’ state it SHALL enter its ‘On’ state. Otherwise, if it is in its ‘On’ + * state it SHALL enter its ‘Off’ state. On receipt of the Toggle command, if the value of the OnOff attribute is equal to FALSE and + * if the value of the OnTime attribute is equal to 0, the device SHALL set the OffWaitTime attribute to 0. If the value of the + * OnOff attribute is equal to TRUE, the OnTime attribute SHALL be set to 0. + */ - (void)toggleWithParams:(MTROnOffClusterToggleParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)toggleWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command OffWithEffect + * + * The OffWithEffect command allows devices to be turned off using enhanced ways of fading. + */ - (void)offWithEffectWithParams:(MTROnOffClusterOffWithEffectParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command OnWithRecallGlobalScene + * + * The OnWithRecallGlobalScene command allows the recall of the settings when the device was turned off. + */ - (void)onWithRecallGlobalSceneWithParams:(MTROnOffClusterOnWithRecallGlobalSceneParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)onWithRecallGlobalSceneWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command OnWithTimedOff + * + * The OnWithTimedOff command allows devices to be turned on for a specific duration with a guarded off duration so that SHOULD the + * device be subsequently switched off, further OnWithTimedOff commands, received during this time, are prevented from turning the + * devices back on. + */ - (void)onWithTimedOffWithParams:(MTROnOffClusterOnWithTimedOffParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -581,7 +717,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster On/off Switch Configuration - * Attributes and commands for configuring On/Off switching devices. + * + * Attributes and commands for configuring On/Off switching devices. */ @interface MTRBaseClusterOnOffSwitchConfiguration : MTRCluster @@ -685,7 +822,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Level Control - * Attributes and commands for controlling devices that can be set to a level between fully 'On' and fully 'Off.' + * + * Attributes and commands for controlling devices that can be set to a level between fully 'On' and fully 'Off.' */ @interface MTRBaseClusterLevelControl : MTRCluster @@ -693,19 +831,65 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command MoveToLevel + * + * Command description for MoveToLevel + */ - (void)moveToLevelWithParams:(MTRLevelControlClusterMoveToLevelParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command Move + * + * Command description for Move + */ - (void)moveWithParams:(MTRLevelControlClusterMoveParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command Step + * + * Command description for Step + */ - (void)stepWithParams:(MTRLevelControlClusterStepParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command Stop + * + * Command description for Stop + */ - (void)stopWithParams:(MTRLevelControlClusterStopParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command MoveToLevelWithOnOff + * + * Command description for MoveToLevelWithOnOff + */ - (void)moveToLevelWithOnOffWithParams:(MTRLevelControlClusterMoveToLevelWithOnOffParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command MoveWithOnOff + * + * Command description for MoveWithOnOff + */ - (void)moveWithOnOffWithParams:(MTRLevelControlClusterMoveWithOnOffParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command StepWithOnOff + * + * Command description for StepWithOnOff + */ - (void)stepWithOnOffWithParams:(MTRLevelControlClusterStepWithOnOffParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command StopWithOnOff + * + * Command description for StopWithOnOff + */ - (void)stopWithOnOffWithParams:(MTRLevelControlClusterStopWithOnOffParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command MoveToClosestFrequency + * + * Change the currrent frequency to the provided one, or a close + approximation if the exact provided one is not possible. + */ - (void)moveToClosestFrequencyWithParams:(MTRLevelControlClusterMoveToClosestFrequencyParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -977,7 +1161,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Binary Input (Basic) - * An interface for reading the value of a binary measurement and accessing various characteristics of that measurement. + * + * An interface for reading the value of a binary measurement and accessing various characteristics of that measurement. */ @interface MTRBaseClusterBinaryInputBasic : MTRCluster @@ -1189,8 +1374,9 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Descriptor - * The Descriptor Cluster is meant to replace the support from the Zigbee Device Object (ZDO) for describing a node, its - * endpoints and clusters. + * + * The Descriptor Cluster is meant to replace the support from the Zigbee Device Object (ZDO) for describing a node, its endpoints + * and clusters. */ @interface MTRBaseClusterDescriptor : MTRCluster @@ -1313,7 +1499,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Binding - * The Binding Cluster is meant to replace the support from the Zigbee Device Object (ZDO) for supporting the binding table. + * + * The Binding Cluster is meant to replace the support from the Zigbee Device Object (ZDO) for supporting the binding table. */ @interface MTRBaseClusterBinding : MTRCluster @@ -1405,7 +1592,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Access Control - * The Access Control Cluster exposes a data model view of a + * + * The Access Control Cluster exposes a data model view of a Node's Access Control List (ACL), which codifies the rules used to manage and enforce Access Control for the Node's endpoints and their associated cluster instances. @@ -1416,17 +1604,17 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; -- (void)readAttributeAclWithParams:(MTRReadParams * _Nullable)params +- (void)readAttributeACLWithParams:(MTRReadParams * _Nullable)params completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; -- (void)writeAttributeAclWithValue:(NSArray * _Nonnull)value completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; -- (void)writeAttributeAclWithValue:(NSArray * _Nonnull)value +- (void)writeAttributeACLWithValue:(NSArray * _Nonnull)value completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +- (void)writeAttributeACLWithValue:(NSArray * _Nonnull)value params:(MTRWriteParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; -- (void)subscribeAttributeAclWithParams:(MTRSubscribeParams *)params +- (void)subscribeAttributeACLWithParams:(MTRSubscribeParams *)params subscriptionEstablished:(MTRSubscriptionEstablishedHandler _Nullable)subscriptionEstablished reportHandler:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))reportHandler MTR_NEWLY_AVAILABLE; -+ (void)readAttributeAclWithClusterStateCache:(MTRClusterStateCacheContainer *)clusterStateCacheContainer ++ (void)readAttributeACLWithClusterStateCache:(MTRClusterStateCacheContainer *)clusterStateCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -1558,7 +1746,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Actions - * This cluster provides a standardized way for a Node (typically a Bridge, but could be any Node) to expose action information. + * + * This cluster provides a standardized way for a Node (typically a Bridge, but could be any Node) to expose action information. */ @interface MTRBaseClusterActions : MTRCluster @@ -1566,28 +1755,89 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command InstantAction + * + * This command triggers an action (state change) on the involved endpoints. + */ - (void)instantActionWithParams:(MTRActionsClusterInstantActionParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command InstantActionWithTransition + * + * This command triggers an action (state change) on the involved endpoints, with a specified time to transition from the current + * state to the new state. + */ - (void)instantActionWithTransitionWithParams:(MTRActionsClusterInstantActionWithTransitionParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command StartAction + * + * This command triggers the commencement of an action on the involved endpoints. + */ - (void)startActionWithParams:(MTRActionsClusterStartActionParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command StartActionWithDuration + * + * This command triggers the commencement of an action (with a duration) on the involved endpoints. + */ - (void)startActionWithDurationWithParams:(MTRActionsClusterStartActionWithDurationParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command StopAction + * + * This command stops the ongoing action on the involved endpoints. + */ - (void)stopActionWithParams:(MTRActionsClusterStopActionParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command PauseAction + * + * This command pauses an ongoing action. + */ - (void)pauseActionWithParams:(MTRActionsClusterPauseActionParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command PauseActionWithDuration + * + * This command pauses an ongoing action with a duration. + */ - (void)pauseActionWithDurationWithParams:(MTRActionsClusterPauseActionWithDurationParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command ResumeAction + * + * This command resumes a previously paused action. + */ - (void)resumeActionWithParams:(MTRActionsClusterResumeActionParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command EnableAction + * + * This command enables a certain action or automation. + */ - (void)enableActionWithParams:(MTRActionsClusterEnableActionParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command EnableActionWithDuration + * + * This command enables a certain action or automation with a duration. + */ - (void)enableActionWithDurationWithParams:(MTRActionsClusterEnableActionWithDurationParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command DisableAction + * + * This command disables a certain action or automation. + */ - (void)disableActionWithParams:(MTRActionsClusterDisableActionParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command DisableActionWithDuration + * + * This command disables a certain action or automation with a duration. + */ - (void)disableActionWithDurationWithParams:(MTRActionsClusterDisableActionWithDurationParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -1694,7 +1944,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Basic - * This cluster provides attributes and events for determining basic information about Nodes, which supports both + * + * This cluster provides attributes and events for determining basic information about Nodes, which supports both Commissioning and operational determination of Node characteristics, such as Vendor ID, Product ID and serial number, which apply to the whole Node. Also allows setting user device information such as location. */ @@ -1704,6 +1955,11 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command MfgSpecificPing + * + * + */ - (void)mfgSpecificPingWithParams:(MTRBasicClusterMfgSpecificPingParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)mfgSpecificPingWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -2028,21 +2284,38 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster OTA Software Update Provider - * Provides an interface for providing OTA software updates + * + * Provides an interface for providing OTA software updates */ -@interface MTRBaseClusterOtaSoftwareUpdateProvider : MTRCluster +MTR_NEWLY_AVAILABLE +@interface MTRBaseClusterOTASoftwareUpdateProvider : MTRCluster - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; -- (void)queryImageWithParams:(MTROtaSoftwareUpdateProviderClusterQueryImageParams *)params - completion:(void (^)(MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, +/** + * Command QueryImage + * + * Determine availability of a new Software Image + */ +- (void)queryImageWithParams:(MTROTASoftwareUpdateProviderClusterQueryImageParams *)params + completion:(void (^)(MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; -- (void)applyUpdateRequestWithParams:(MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams *)params - completion:(void (^)(MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, +/** + * Command ApplyUpdateRequest + * + * Determine next action to take for a downloaded Software Image + */ +- (void)applyUpdateRequestWithParams:(MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams *)params + completion:(void (^)(MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; -- (void)notifyUpdateAppliedWithParams:(MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams *)params +/** + * Command NotifyUpdateApplied + * + * Notify OTA Provider that an update was applied + */ +- (void)notifyUpdateAppliedWithParams:(MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -2112,15 +2385,22 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster OTA Software Update Requestor - * Provides an interface for downloading and applying OTA software updates + * + * Provides an interface for downloading and applying OTA software updates */ -@interface MTRBaseClusterOtaSoftwareUpdateRequestor : MTRCluster +MTR_NEWLY_AVAILABLE +@interface MTRBaseClusterOTASoftwareUpdateRequestor : MTRCluster - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; -- (void)announceOtaProviderWithParams:(MTROtaSoftwareUpdateRequestorClusterAnnounceOtaProviderParams *)params +/** + * Command AnnounceOtaProvider + * + * Announce the presence of an OTA Provider + */ +- (void)announceOtaProviderWithParams:(MTROTASoftwareUpdateRequestorClusterAnnounceOtaProviderParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)readAttributeDefaultOtaProvidersWithParams:(MTRReadParams * _Nullable)params @@ -2244,7 +2524,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Localization Configuration - * Nodes should be expected to be deployed to any and all regions of the world. These global regions + * + * Nodes should be expected to be deployed to any and all regions of the world. These global regions may have differing common languages, units of measurements, and numerical formatting standards. As such, Nodes that visually or audibly convey information need a mechanism by which they can be configured to use a user’s preferred language, units, etc @@ -2351,7 +2632,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Time Format Localization - * Nodes should be expected to be deployed to any and all regions of the world. These global regions + * + * Nodes should be expected to be deployed to any and all regions of the world. These global regions may have differing preferences for how dates and times are conveyed. As such, Nodes that visually or audibly convey time information need a mechanism by which they can be configured to use a user’s preferred format. @@ -2474,7 +2756,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Unit Localization - * Nodes should be expected to be deployed to any and all regions of the world. These global regions + * + * Nodes should be expected to be deployed to any and all regions of the world. These global regions may have differing preferences for the units in which values are conveyed in communication to a user. As such, Nodes that visually or audibly convey measurable values to the user need a mechanism by which they can be configured to use a user’s preferred unit. @@ -2569,7 +2852,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Power Source Configuration - * This cluster is used to describe the configuration and capabilities of a Device's power system. + * + * This cluster is used to describe the configuration and capabilities of a Device's power system. */ @interface MTRBaseClusterPowerSourceConfiguration : MTRCluster @@ -2656,8 +2940,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Power Source - * This cluster is used to describe the configuration and capabilities of a physical power source that provides power to the - * Node. + * + * This cluster is used to describe the configuration and capabilities of a physical power source that provides power to the Node. */ @interface MTRBaseClusterPowerSource : MTRCluster @@ -3104,7 +3388,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster General Commissioning - * This cluster is used to manage global aspects of the Commissioning flow. + * + * This cluster is used to manage global aspects of the Commissioning flow. */ @interface MTRBaseClusterGeneralCommissioning : MTRCluster @@ -3112,12 +3397,28 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command ArmFailSafe + * + * Arm the persistent fail-safe timer with an expiry time of now + ExpiryLengthSeconds using device clock + */ - (void)armFailSafeWithParams:(MTRGeneralCommissioningClusterArmFailSafeParams *)params completion:(void (^)(MTRGeneralCommissioningClusterArmFailSafeResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command SetRegulatoryConfig + * + * Set the regulatory configuration to be used during commissioning + */ - (void)setRegulatoryConfigWithParams:(MTRGeneralCommissioningClusterSetRegulatoryConfigParams *)params completion:(void (^)(MTRGeneralCommissioningClusterSetRegulatoryConfigResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command CommissioningComplete + * + * Signals the Server that the Client has successfully completed all steps of Commissioning/Recofiguration needed during fail-safe + * period. + */ - (void)commissioningCompleteWithParams:(MTRGeneralCommissioningClusterCommissioningCompleteParams * _Nullable)params completion: (void (^)(MTRGeneralCommissioningClusterCommissioningCompleteResponseParams * _Nullable data, @@ -3264,7 +3565,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Network Commissioning - * Functionality to configure, enable, disable network credentials and access on a Matter device. + * + * Functionality to configure, enable, disable network credentials and access on a Matter device. */ @interface MTRBaseClusterNetworkCommissioning : MTRCluster @@ -3272,21 +3574,51 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command ScanNetworks + * + * Detemine the set of networks the device sees as available. + */ - (void)scanNetworksWithParams:(MTRNetworkCommissioningClusterScanNetworksParams * _Nullable)params completion:(void (^)(MTRNetworkCommissioningClusterScanNetworksResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command AddOrUpdateWiFiNetwork + * + * Add or update the credentials for a given Wi-Fi network. + */ - (void)addOrUpdateWiFiNetworkWithParams:(MTRNetworkCommissioningClusterAddOrUpdateWiFiNetworkParams *)params completion:(void (^)(MTRNetworkCommissioningClusterNetworkConfigResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command AddOrUpdateThreadNetwork + * + * Add or update the credentials for a given Thread network. + */ - (void)addOrUpdateThreadNetworkWithParams:(MTRNetworkCommissioningClusterAddOrUpdateThreadNetworkParams *)params completion:(void (^)(MTRNetworkCommissioningClusterNetworkConfigResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command RemoveNetwork + * + * Remove the definition of a given network (including its credentials). + */ - (void)removeNetworkWithParams:(MTRNetworkCommissioningClusterRemoveNetworkParams *)params completion:(void (^)(MTRNetworkCommissioningClusterNetworkConfigResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command ConnectNetwork + * + * Connect to the specified network, using previously-defined credentials. + */ - (void)connectNetworkWithParams:(MTRNetworkCommissioningClusterConnectNetworkParams *)params completion:(void (^)(MTRNetworkCommissioningClusterConnectNetworkResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command ReorderNetwork + * + * Modify the order in which networks will be presented in the Networks attribute. + */ - (void)reorderNetworkWithParams:(MTRNetworkCommissioningClusterReorderNetworkParams *)params completion:(void (^)(MTRNetworkCommissioningClusterNetworkConfigResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; @@ -3459,7 +3791,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Diagnostic Logs - * The cluster provides commands for retrieving unstructured diagnostic logs from a Node that may be used to aid in diagnostics. + * + * The cluster provides commands for retrieving unstructured diagnostic logs from a Node that may be used to aid in diagnostics. */ @interface MTRBaseClusterDiagnosticLogs : MTRCluster @@ -3467,6 +3800,11 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command RetrieveLogsRequest + * + * Retrieving diagnostic logs from a Node + */ - (void)retrieveLogsRequestWithParams:(MTRDiagnosticLogsClusterRetrieveLogsRequestParams *)params completion:(void (^)(MTRDiagnosticLogsClusterRetrieveLogsResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; @@ -3538,7 +3876,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster General Diagnostics - * The General Diagnostics Cluster, along with other diagnostics clusters, provide a means to acquire standardized diagnostics + * + * The General Diagnostics Cluster, along with other diagnostics clusters, provide a means to acquire standardized diagnostics * metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @interface MTRBaseClusterGeneralDiagnostics : MTRCluster @@ -3547,6 +3886,11 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command TestEventTrigger + * + * Provide a means for certification tests to trigger some test-plan-specific events + */ - (void)testEventTriggerWithParams:(MTRGeneralDiagnosticsClusterTestEventTriggerParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -3725,7 +4069,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Software Diagnostics - * The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to + * + * The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to * assist a user or Administrative Node in diagnosing potential problems. */ @interface MTRBaseClusterSoftwareDiagnostics : MTRCluster @@ -3734,6 +4079,12 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command ResetWatermarks + * + * Reception of this command SHALL reset the values: The StackFreeMinimum field of the ThreadMetrics attribute, + * CurrentHeapHighWaterMark attribute. + */ - (void)resetWatermarksWithParams:(MTRSoftwareDiagnosticsClusterResetWatermarksParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)resetWatermarksWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -3853,8 +4204,9 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Thread Network Diagnostics - * The Thread Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node - * to assist a user or Administrative Node in diagnosing potential problems + * + * The Thread Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to + * assist a user or Administrative Node in diagnosing potential problems */ @interface MTRBaseClusterThreadNetworkDiagnostics : MTRCluster @@ -3862,6 +4214,11 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command ResetCounts + * + * Reception of this command SHALL reset the OverrunCount attributes to 0 + */ - (void)resetCountsWithParams:(MTRThreadNetworkDiagnosticsClusterResetCountsParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)resetCountsWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -4703,8 +5060,9 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster WiFi Network Diagnostics - * The Wi-Fi Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node - * to assist a user or Administrative Node in diagnosing potential problems. + * + * The Wi-Fi Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to + * assist a user or Administrative Node in diagnosing potential problems. */ @interface MTRBaseClusterWiFiNetworkDiagnostics : MTRCluster @@ -4712,6 +5070,11 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command ResetCounts + * + * Reception of this command SHALL reset the Breacon and Packet related count attributes to 0 + */ - (void)resetCountsWithParams:(MTRWiFiNetworkDiagnosticsClusterResetCountsParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)resetCountsWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -4939,8 +5302,9 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Ethernet Network Diagnostics - * The Ethernet Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a - * Node to assist a user or Administrative Node in diagnosing potential problems. + * + * The Ethernet Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node + * to assist a user or Administrative Node in diagnosing potential problems. */ @interface MTRBaseClusterEthernetNetworkDiagnostics : MTRCluster @@ -4948,6 +5312,11 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command ResetCounts + * + * Reception of this command SHALL reset the attributes: PacketRxCount, PacketTxCount, TxErrCount, CollisionCount, OverrunCount to 0 + */ - (void)resetCountsWithParams:(MTREthernetNetworkDiagnosticsClusterResetCountsParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)resetCountsWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -5127,7 +5496,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Bridged Device Basic - * This Cluster serves two purposes towards a Node communicating with a Bridge: indicate that the functionality on + * + * This Cluster serves two purposes towards a Node communicating with a Bridge: indicate that the functionality on the Endpoint where it is placed (and its Parts) is bridged from a non-CHIP technology; and provide a centralized collection of attributes that the Node MAY collect to aid in conveying information regarding the Bridged Device to a user, such as the vendor name, the model name, or user-assigned name. @@ -5389,7 +5759,8 @@ NS_ASSUME_NONNULL_BEGIN /** * Cluster Switch - * This cluster exposes interactions with a switch device, for the purpose of using those interactions by other devices. + * + * This cluster exposes interactions with a switch device, for the purpose of using those interactions by other devices. Two types of switch devices are supported: latching switch (e.g. rocker switch) and momentary switch (e.g. push button), distinguished with their feature flags. Interactions with the switch device are exposed as attributes (for the latching switch) and as events (for both types of switches). An interested party MAY subscribe to these attributes/events and thus be informed of the @@ -5505,7 +5876,8 @@ light or a window shade. /** * Cluster AdministratorCommissioning - * Commands to trigger a Node to allow a new Administrator to commission it. + * + * Commands to trigger a Node to allow a new Administrator to commission it. */ @interface MTRBaseClusterAdministratorCommissioning : MTRCluster @@ -5513,10 +5885,28 @@ light or a window shade. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command OpenCommissioningWindow + * + * This command is used by a current Administrator to instruct a Node to go into commissioning mode using enhanced commissioning + * method. + */ - (void)openCommissioningWindowWithParams:(MTRAdministratorCommissioningClusterOpenCommissioningWindowParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command OpenBasicCommissioningWindow + * + * This command is used by a current Administrator to instruct a Node to go into commissioning mode using basic commissioning + * method, if the node supports it. + */ - (void)openBasicCommissioningWindowWithParams:(MTRAdministratorCommissioningClusterOpenBasicCommissioningWindowParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command RevokeCommissioning + * + * This command is used by a current Administrator to instruct a Node to revoke any active Open Commissioning Window or Open Basic + * Commissioning Window command. + */ - (void)revokeCommissioningWithParams:(MTRAdministratorCommissioningClusterRevokeCommissioningParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)revokeCommissioningWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -5624,7 +6014,8 @@ light or a window shade. /** * Cluster Operational Credentials - * This cluster is used to add or remove Operational Credentials on a Commissionee or Node, as well as manage the associated + * + * This cluster is used to add or remove Operational Credentials on a Commissionee or Node, as well as manage the associated * Fabrics. */ @interface MTRBaseClusterOperationalCredentials : MTRCluster @@ -5633,27 +6024,68 @@ light or a window shade. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command AttestationRequest + * + * Sender is requesting attestation information from the receiver. + */ - (void)attestationRequestWithParams:(MTROperationalCredentialsClusterAttestationRequestParams *)params completion:(void (^)(MTROperationalCredentialsClusterAttestationResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command CertificateChainRequest + * + * Sender is requesting a device attestation certificate from the receiver. + */ - (void)certificateChainRequestWithParams:(MTROperationalCredentialsClusterCertificateChainRequestParams *)params completion:(void (^)(MTROperationalCredentialsClusterCertificateChainResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command CSRRequest + * + * Sender is requesting a certificate signing request (CSR) from the receiver. + */ - (void)CSRRequestWithParams:(MTROperationalCredentialsClusterCSRRequestParams *)params completion:(void (^)(MTROperationalCredentialsClusterCSRResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command AddNOC + * + * Sender is requesting to add the new node operational certificates. + */ - (void)addNOCWithParams:(MTROperationalCredentialsClusterAddNOCParams *)params completion:(void (^)(MTROperationalCredentialsClusterNOCResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command UpdateNOC + * + * Sender is requesting to update the node operational certificates. + */ - (void)updateNOCWithParams:(MTROperationalCredentialsClusterUpdateNOCParams *)params completion:(void (^)(MTROperationalCredentialsClusterNOCResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command UpdateFabricLabel + * + * This command SHALL be used by an Administrative Node to set the user-visible Label field for a given Fabric, as reflected by + * entries in the Fabrics attribute. + */ - (void)updateFabricLabelWithParams:(MTROperationalCredentialsClusterUpdateFabricLabelParams *)params completion:(void (^)(MTROperationalCredentialsClusterNOCResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command RemoveFabric + * + * This command is used by Administrative Nodes to remove a given fabric index and delete all associated fabric-scoped data. + */ - (void)removeFabricWithParams:(MTROperationalCredentialsClusterRemoveFabricParams *)params completion:(void (^)(MTROperationalCredentialsClusterNOCResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command AddTrustedRootCertificate + * + * This command SHALL add a Trusted Root CA Certificate, provided as its CHIP Certificate representation. + */ - (void)addTrustedRootCertificateWithParams:(MTROperationalCredentialsClusterAddTrustedRootCertificateParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -5797,7 +6229,8 @@ light or a window shade. /** * Cluster Group Key Management - * The Group Key Management Cluster is the mechanism by which group keys are managed. + * + * The Group Key Management Cluster is the mechanism by which group keys are managed. */ @interface MTRBaseClusterGroupKeyManagement : MTRCluster @@ -5805,13 +6238,33 @@ light or a window shade. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command KeySetWrite + * + * Write a new set of keys for the given key set id. + */ - (void)keySetWriteWithParams:(MTRGroupKeyManagementClusterKeySetWriteParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command KeySetRead + * + * Read the keys for a given key set id. + */ - (void)keySetReadWithParams:(MTRGroupKeyManagementClusterKeySetReadParams *)params completion:(void (^)(MTRGroupKeyManagementClusterKeySetReadResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command KeySetRemove + * + * Revoke a Root Key from a Group + */ - (void)keySetRemoveWithParams:(MTRGroupKeyManagementClusterKeySetRemoveParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command KeySetReadAllIndices + * + * Return the list of Group Key Sets associated with the accessing fabric + */ - (void)keySetReadAllIndicesWithParams:(MTRGroupKeyManagementClusterKeySetReadAllIndicesParams *)params completion:(void (^)(MTRGroupKeyManagementClusterKeySetReadAllIndicesResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; @@ -5937,7 +6390,8 @@ light or a window shade. /** * Cluster Fixed Label - * The Fixed Label Cluster provides a feature for the device to tag an endpoint with zero or more read only + * + * The Fixed Label Cluster provides a feature for the device to tag an endpoint with zero or more read only labels. */ @interface MTRBaseClusterFixedLabel : MTRCluster @@ -6025,7 +6479,8 @@ labels. /** * Cluster User Label - * The User Label Cluster provides a feature to tag an endpoint with zero or more labels. + * + * The User Label Cluster provides a feature to tag an endpoint with zero or more labels. */ @interface MTRBaseClusterUserLabel : MTRCluster @@ -6116,7 +6571,8 @@ labels. /** * Cluster Boolean State - * This cluster provides an interface to a boolean state called StateValue. + * + * This cluster provides an interface to a boolean state called StateValue. */ @interface MTRBaseClusterBooleanState : MTRCluster @@ -6203,7 +6659,8 @@ labels. /** * Cluster Mode Select - * Attributes and commands for selecting a mode from a list of supported options. + * + * Attributes and commands for selecting a mode from a list of supported options. */ @interface MTRBaseClusterModeSelect : MTRCluster @@ -6211,6 +6668,12 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command ChangeToMode + * + * On receipt of this command, if the NewMode field matches the Mode field in an entry of the SupportedModes list, the server SHALL + * set the CurrentMode attribute to the NewMode value, otherwise, the server SHALL respond with an INVALID_COMMAND status response. + */ - (void)changeToModeWithParams:(MTRModeSelectClusterChangeToModeParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -6362,7 +6825,8 @@ labels. /** * Cluster Door Lock - * An interface to a generic way to secure a door + * + * An interface to a generic way to secure a door */ @interface MTRBaseClusterDoorLock : MTRCluster @@ -6370,45 +6834,135 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command LockDoor + * + * This command causes the lock device to lock the door. + */ - (void)lockDoorWithParams:(MTRDoorLockClusterLockDoorParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command UnlockDoor + * + * This command causes the lock device to unlock the door. + */ - (void)unlockDoorWithParams:(MTRDoorLockClusterUnlockDoorParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command UnlockWithTimeout + * + * This command causes the lock device to unlock the door with a timeout parameter. + */ - (void)unlockWithTimeoutWithParams:(MTRDoorLockClusterUnlockWithTimeoutParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command SetWeekDaySchedule + * + * Set a weekly repeating schedule for a specified user. + */ - (void)setWeekDayScheduleWithParams:(MTRDoorLockClusterSetWeekDayScheduleParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command GetWeekDaySchedule + * + * Retrieve the specific weekly schedule for the specific user. + */ - (void)getWeekDayScheduleWithParams:(MTRDoorLockClusterGetWeekDayScheduleParams *)params completion:(void (^)(MTRDoorLockClusterGetWeekDayScheduleResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command ClearWeekDaySchedule + * + * Clear the specific weekly schedule or all weekly schedules for the specific user. + */ - (void)clearWeekDayScheduleWithParams:(MTRDoorLockClusterClearWeekDayScheduleParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command SetYearDaySchedule + * + * Set a time-specific schedule ID for a specified user. + */ - (void)setYearDayScheduleWithParams:(MTRDoorLockClusterSetYearDayScheduleParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command GetYearDaySchedule + * + * Returns the year day schedule data for the specified schedule and user indexes. + */ - (void)getYearDayScheduleWithParams:(MTRDoorLockClusterGetYearDayScheduleParams *)params completion:(void (^)(MTRDoorLockClusterGetYearDayScheduleResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command ClearYearDaySchedule + * + * Clears the specific year day schedule or all year day schedules for the specific user. + */ - (void)clearYearDayScheduleWithParams:(MTRDoorLockClusterClearYearDayScheduleParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command SetHolidaySchedule + * + * Set the holiday Schedule by specifying local start time and local end time with respect to any Lock Operating Mode. + */ - (void)setHolidayScheduleWithParams:(MTRDoorLockClusterSetHolidayScheduleParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command GetHolidaySchedule + * + * Get the holiday schedule for the specified index. + */ - (void)getHolidayScheduleWithParams:(MTRDoorLockClusterGetHolidayScheduleParams *)params completion:(void (^)(MTRDoorLockClusterGetHolidayScheduleResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command ClearHolidaySchedule + * + * Clears the holiday schedule or all holiday schedules. + */ - (void)clearHolidayScheduleWithParams:(MTRDoorLockClusterClearHolidayScheduleParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command SetUser + * + * Set User into the lock. + */ - (void)setUserWithParams:(MTRDoorLockClusterSetUserParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command GetUser + * + * Retrieve User. + */ - (void)getUserWithParams:(MTRDoorLockClusterGetUserParams *)params completion:(void (^)(MTRDoorLockClusterGetUserResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command ClearUser + * + * Clears a User or all Users. + */ - (void)clearUserWithParams:(MTRDoorLockClusterClearUserParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command SetCredential + * + * Set a credential (e.g. PIN, RFID, Fingerprint, etc.) into the lock for a new user, existing user, or ProgrammingUser. + */ - (void)setCredentialWithParams:(MTRDoorLockClusterSetCredentialParams *)params completion:(void (^)(MTRDoorLockClusterSetCredentialResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command GetCredentialStatus + * + * Retrieve the status of a particular credential (e.g. PIN, RFID, Fingerprint, etc.) by index. + */ - (void)getCredentialStatusWithParams:(MTRDoorLockClusterGetCredentialStatusParams *)params completion:(void (^)(MTRDoorLockClusterGetCredentialStatusResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command ClearCredential + * + * Clear one, one type, or all credentials except ProgrammingPIN credential. + */ - (void)clearCredentialWithParams:(MTRDoorLockClusterClearCredentialParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -7021,7 +7575,8 @@ labels. /** * Cluster Window Covering - * Provides an interface for controlling and adjusting automatic window coverings. + * + * Provides an interface for controlling and adjusting automatic window coverings. */ @interface MTRBaseClusterWindowCovering : MTRCluster @@ -7029,21 +7584,56 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command UpOrOpen + * + * Moves window covering to InstalledOpenLimitLift and InstalledOpenLimitTilt + */ - (void)upOrOpenWithParams:(MTRWindowCoveringClusterUpOrOpenParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)upOrOpenWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command DownOrClose + * + * Moves window covering to InstalledClosedLimitLift and InstalledCloseLimitTilt + */ - (void)downOrCloseWithParams:(MTRWindowCoveringClusterDownOrCloseParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)downOrCloseWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command StopMotion + * + * Stop any adjusting of window covering + */ - (void)stopMotionWithParams:(MTRWindowCoveringClusterStopMotionParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)stopMotionWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command GoToLiftValue + * + * Go to lift value specified + */ - (void)goToLiftValueWithParams:(MTRWindowCoveringClusterGoToLiftValueParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command GoToLiftPercentage + * + * Go to lift percentage specified + */ - (void)goToLiftPercentageWithParams:(MTRWindowCoveringClusterGoToLiftPercentageParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command GoToTiltValue + * + * Go to tilt value specified + */ - (void)goToTiltValueWithParams:(MTRWindowCoveringClusterGoToTiltValueParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command GoToTiltPercentage + * + * Go to tilt percentage specified + */ - (void)goToTiltPercentageWithParams:(MTRWindowCoveringClusterGoToTiltPercentageParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -7402,7 +7992,8 @@ labels. /** * Cluster Barrier Control - * This cluster provides control of a barrier (garage door). + * + * This cluster provides control of a barrier (garage door). */ @interface MTRBaseClusterBarrierControl : MTRCluster @@ -7410,8 +8001,18 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command BarrierControlGoToPercent + * + * Command to instruct a barrier to go to a percent open state. + */ - (void)barrierControlGoToPercentWithParams:(MTRBarrierControlClusterBarrierControlGoToPercentParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command BarrierControlStop + * + * Command that instructs the barrier to stop moving. + */ - (void)barrierControlStopWithParams:(MTRBarrierControlClusterBarrierControlStopParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)barrierControlStopWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -7633,7 +8234,8 @@ labels. /** * Cluster Pump Configuration and Control - * An interface for configuring and controlling pumps. + * + * An interface for configuring and controlling pumps. */ @interface MTRBaseClusterPumpConfigurationAndControl : MTRCluster @@ -8004,7 +8606,8 @@ labels. /** * Cluster Thermostat - * An interface for configuring and controlling the functionality of a thermostat. + * + * An interface for configuring and controlling the functionality of a thermostat. */ @interface MTRBaseClusterThermostat : MTRCluster @@ -8012,13 +8615,33 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command SetpointRaiseLower + * + * Command description for SetpointRaiseLower + */ - (void)setpointRaiseLowerWithParams:(MTRThermostatClusterSetpointRaiseLowerParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command SetWeeklySchedule + * + * Command description for SetWeeklySchedule + */ - (void)setWeeklyScheduleWithParams:(MTRThermostatClusterSetWeeklyScheduleParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command GetWeeklySchedule + * + * Command description for GetWeeklySchedule + */ - (void)getWeeklyScheduleWithParams:(MTRThermostatClusterGetWeeklyScheduleParams *)params completion:(void (^)(MTRThermostatClusterGetWeeklyScheduleResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command ClearWeeklySchedule + * + * The Clear Weekly Schedule command is used to clear the weekly schedule. + */ - (void)clearWeeklyScheduleWithParams:(MTRThermostatClusterClearWeeklyScheduleParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)clearWeeklyScheduleWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -8820,7 +9443,8 @@ labels. /** * Cluster Fan Control - * An interface for controlling a fan in a heating/cooling system. + * + * An interface for controlling a fan in a heating/cooling system. */ @interface MTRBaseClusterFanControl : MTRCluster @@ -9056,7 +9680,8 @@ labels. /** * Cluster Thermostat User Interface Configuration - * An interface for configuring the user interface of a thermostat (which may be remote from the thermostat). + * + * An interface for configuring the user interface of a thermostat (which may be remote from the thermostat). */ @interface MTRBaseClusterThermostatUserInterfaceConfiguration : MTRCluster @@ -9184,7 +9809,8 @@ labels. /** * Cluster Color Control - * Attributes and commands for controlling the color properties of a color-capable light. + * + * Attributes and commands for controlling the color properties of a color-capable light. */ @interface MTRBaseClusterColorControl : MTRCluster @@ -9192,42 +9818,137 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command MoveToHue + * + * Move to specified hue. + */ - (void)moveToHueWithParams:(MTRColorControlClusterMoveToHueParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command MoveHue + * + * Move hue up or down at specified rate. + */ - (void)moveHueWithParams:(MTRColorControlClusterMoveHueParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command StepHue + * + * Step hue up or down by specified size at specified rate. + */ - (void)stepHueWithParams:(MTRColorControlClusterStepHueParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command MoveToSaturation + * + * Move to specified saturation. + */ - (void)moveToSaturationWithParams:(MTRColorControlClusterMoveToSaturationParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command MoveSaturation + * + * Move saturation up or down at specified rate. + */ - (void)moveSaturationWithParams:(MTRColorControlClusterMoveSaturationParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command StepSaturation + * + * Step saturation up or down by specified size at specified rate. + */ - (void)stepSaturationWithParams:(MTRColorControlClusterStepSaturationParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command MoveToHueAndSaturation + * + * Move to hue and saturation. + */ - (void)moveToHueAndSaturationWithParams:(MTRColorControlClusterMoveToHueAndSaturationParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command MoveToColor + * + * Move to specified color. + */ - (void)moveToColorWithParams:(MTRColorControlClusterMoveToColorParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command MoveColor + * + * Moves the color. + */ - (void)moveColorWithParams:(MTRColorControlClusterMoveColorParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command StepColor + * + * Steps the lighting to a specific color. + */ - (void)stepColorWithParams:(MTRColorControlClusterStepColorParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command MoveToColorTemperature + * + * Move to a specific color temperature. + */ - (void)moveToColorTemperatureWithParams:(MTRColorControlClusterMoveToColorTemperatureParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command EnhancedMoveToHue + * + * Command description for EnhancedMoveToHue + */ - (void)enhancedMoveToHueWithParams:(MTRColorControlClusterEnhancedMoveToHueParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command EnhancedMoveHue + * + * Command description for EnhancedMoveHue + */ - (void)enhancedMoveHueWithParams:(MTRColorControlClusterEnhancedMoveHueParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command EnhancedStepHue + * + * Command description for EnhancedStepHue + */ - (void)enhancedStepHueWithParams:(MTRColorControlClusterEnhancedStepHueParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command EnhancedMoveToHueAndSaturation + * + * Command description for EnhancedMoveToHueAndSaturation + */ - (void)enhancedMoveToHueAndSaturationWithParams:(MTRColorControlClusterEnhancedMoveToHueAndSaturationParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command ColorLoopSet + * + * Command description for ColorLoopSet + */ - (void)colorLoopSetWithParams:(MTRColorControlClusterColorLoopSetParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command StopMoveStep + * + * Command description for StopMoveStep + */ - (void)stopMoveStepWithParams:(MTRColorControlClusterStopMoveStepParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command MoveColorTemperature + * + * Command description for MoveColorTemperature + */ - (void)moveColorTemperatureWithParams:(MTRColorControlClusterMoveColorTemperatureParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command StepColorTemperature + * + * Command description for StepColorTemperature + */ - (void)stepColorTemperatureWithParams:(MTRColorControlClusterStepColorTemperatureParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -9992,7 +10713,8 @@ labels. /** * Cluster Ballast Configuration - * Attributes and commands for configuring a lighting ballast. + * + * Attributes and commands for configuring a lighting ballast. */ @interface MTRBaseClusterBallastConfiguration : MTRCluster @@ -10282,7 +11004,8 @@ labels. /** * Cluster Illuminance Measurement - * Attributes and commands for configuring the measurement of illuminance, and reporting illuminance measurements. + * + * Attributes and commands for configuring the measurement of illuminance, and reporting illuminance measurements. */ @interface MTRBaseClusterIlluminanceMeasurement : MTRCluster @@ -10417,7 +11140,8 @@ labels. /** * Cluster Temperature Measurement - * Attributes and commands for configuring the measurement of temperature, and reporting temperature measurements. + * + * Attributes and commands for configuring the measurement of temperature, and reporting temperature measurements. */ @interface MTRBaseClusterTemperatureMeasurement : MTRCluster @@ -10540,7 +11264,8 @@ labels. /** * Cluster Pressure Measurement - * Attributes and commands for configuring the measurement of pressure, and reporting pressure measurements. + * + * Attributes and commands for configuring the measurement of pressure, and reporting pressure measurements. */ @interface MTRBaseClusterPressureMeasurement : MTRCluster @@ -10723,7 +11448,8 @@ labels. /** * Cluster Flow Measurement - * Attributes and commands for configuring the measurement of flow, and reporting flow measurements. + * + * Attributes and commands for configuring the measurement of flow, and reporting flow measurements. */ @interface MTRBaseClusterFlowMeasurement : MTRCluster @@ -10846,7 +11572,8 @@ labels. /** * Cluster Relative Humidity Measurement - * Attributes and commands for configuring the measurement of relative humidity, and reporting relative humidity measurements. + * + * Attributes and commands for configuring the measurement of relative humidity, and reporting relative humidity measurements. */ @interface MTRBaseClusterRelativeHumidityMeasurement : MTRCluster @@ -10969,7 +11696,8 @@ labels. /** * Cluster Occupancy Sensing - * Attributes and commands for configuring occupancy sensing, and reporting occupancy status. + * + * Attributes and commands for configuring occupancy sensing, and reporting occupancy status. */ @interface MTRBaseClusterOccupancySensing : MTRCluster @@ -11013,58 +11741,58 @@ labels. completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; -- (void)readAttributePirOccupiedToUnoccupiedDelayWithCompletion:(void (^)(NSNumber * _Nullable value, +- (void)readAttributePIROccupiedToUnoccupiedDelayWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; -- (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSNumber * _Nonnull)value +- (void)writeAttributePIROccupiedToUnoccupiedDelayWithValue:(NSNumber * _Nonnull)value completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; -- (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSNumber * _Nonnull)value +- (void)writeAttributePIROccupiedToUnoccupiedDelayWithValue:(NSNumber * _Nonnull)value params:(MTRWriteParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; -- (void)subscribeAttributePirOccupiedToUnoccupiedDelayWithParams:(MTRSubscribeParams *)params +- (void)subscribeAttributePIROccupiedToUnoccupiedDelayWithParams:(MTRSubscribeParams *)params subscriptionEstablished: (MTRSubscriptionEstablishedHandler _Nullable)subscriptionEstablished reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler MTR_NEWLY_AVAILABLE; -+ (void)readAttributePirOccupiedToUnoccupiedDelayWithClusterStateCache:(MTRClusterStateCacheContainer *)clusterStateCacheContainer ++ (void)readAttributePIROccupiedToUnoccupiedDelayWithClusterStateCache:(MTRClusterStateCacheContainer *)clusterStateCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; -- (void)readAttributePirUnoccupiedToOccupiedDelayWithCompletion:(void (^)(NSNumber * _Nullable value, +- (void)readAttributePIRUnoccupiedToOccupiedDelayWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; -- (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSNumber * _Nonnull)value +- (void)writeAttributePIRUnoccupiedToOccupiedDelayWithValue:(NSNumber * _Nonnull)value completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; -- (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSNumber * _Nonnull)value +- (void)writeAttributePIRUnoccupiedToOccupiedDelayWithValue:(NSNumber * _Nonnull)value params:(MTRWriteParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; -- (void)subscribeAttributePirUnoccupiedToOccupiedDelayWithParams:(MTRSubscribeParams *)params +- (void)subscribeAttributePIRUnoccupiedToOccupiedDelayWithParams:(MTRSubscribeParams *)params subscriptionEstablished: (MTRSubscriptionEstablishedHandler _Nullable)subscriptionEstablished reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler MTR_NEWLY_AVAILABLE; -+ (void)readAttributePirUnoccupiedToOccupiedDelayWithClusterStateCache:(MTRClusterStateCacheContainer *)clusterStateCacheContainer ++ (void)readAttributePIRUnoccupiedToOccupiedDelayWithClusterStateCache:(MTRClusterStateCacheContainer *)clusterStateCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; -- (void)readAttributePirUnoccupiedToOccupiedThresholdWithCompletion:(void (^)(NSNumber * _Nullable value, +- (void)readAttributePIRUnoccupiedToOccupiedThresholdWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; -- (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSNumber * _Nonnull)value +- (void)writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:(NSNumber * _Nonnull)value completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; -- (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSNumber * _Nonnull)value +- (void)writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:(NSNumber * _Nonnull)value params:(MTRWriteParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; -- (void)subscribeAttributePirUnoccupiedToOccupiedThresholdWithParams:(MTRSubscribeParams *)params +- (void)subscribeAttributePIRUnoccupiedToOccupiedThresholdWithParams:(MTRSubscribeParams *)params subscriptionEstablished: (MTRSubscriptionEstablishedHandler _Nullable)subscriptionEstablished reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler MTR_NEWLY_AVAILABLE; -+ (void)readAttributePirUnoccupiedToOccupiedThresholdWithClusterStateCache: ++ (void)readAttributePIRUnoccupiedToOccupiedThresholdWithClusterStateCache: (MTRClusterStateCacheContainer *)clusterStateCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue @@ -11265,9 +11993,11 @@ labels. /** * Cluster Wake on LAN - * This cluster provides an interface for managing low power mode on a device that supports the Wake On LAN protocol. + * + * This cluster provides an interface for managing low power mode on a device that supports the Wake On LAN protocol. */ -@interface MTRBaseClusterWakeOnLan : MTRCluster +MTR_NEWLY_AVAILABLE +@interface MTRBaseClusterWakeOnLAN : MTRCluster - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID @@ -11352,7 +12082,8 @@ labels. /** * Cluster Channel - * This cluster provides an interface for controlling the current Channel on a device. + * + * This cluster provides an interface for controlling the current Channel on a device. */ @interface MTRBaseClusterChannel : MTRCluster @@ -11360,11 +12091,29 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command ChangeChannel + * + * Change the channel on the media player to the channel case-insensitive exact matching the value passed as an argument. + */ - (void)changeChannelWithParams:(MTRChannelClusterChangeChannelParams *)params completion:(void (^)(MTRChannelClusterChangeChannelResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command ChangeChannelByNumber + * + * Change the channel on the media plaeyer to the channel with the given Number in the ChannelList attribute. + */ - (void)changeChannelByNumberWithParams:(MTRChannelClusterChangeChannelByNumberParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command SkipChannel + * + * This command provides channel up and channel down functionality, but allows channel index jumps of size Count. When the value of + * the increase or decrease is larger than the number of channels remaining in the given direction, then the behavior SHALL be to + * return to the beginning (or end) of the channel list and continue. For example, if the current channel is at index 0 and count + * value of -1 is given, then the current channel should change to the last channel. + */ - (void)skipChannelWithParams:(MTRChannelClusterSkipChannelParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -11471,7 +12220,8 @@ labels. /** * Cluster Target Navigator - * This cluster provides an interface for UX navigation within a set of targets on a device or endpoint. + * + * This cluster provides an interface for UX navigation within a set of targets on a device or endpoint. */ @interface MTRBaseClusterTargetNavigator : MTRCluster @@ -11479,6 +12229,11 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command NavigateTarget + * + * Upon receipt, this SHALL navigation the UX to the target identified. + */ - (void)navigateTargetWithParams:(MTRTargetNavigatorClusterNavigateTargetParams *)params completion:(void (^)(MTRTargetNavigatorClusterNavigateTargetResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; @@ -11574,8 +12329,8 @@ labels. /** * Cluster Media Playback - * This cluster provides an interface for controlling Media Playback (PLAY, PAUSE, etc) on a media device such as a TV or - * Speaker. + * + * This cluster provides an interface for controlling Media Playback (PLAY, PAUSE, etc) on a media device such as a TV or Speaker. */ @interface MTRBaseClusterMediaPlayback : MTRCluster @@ -11583,52 +12338,112 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command Play + * + * Upon receipt, this SHALL play media. + */ - (void)playWithParams:(MTRMediaPlaybackClusterPlayParams * _Nullable)params completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; - (void)playWithCompletion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command Pause + * + * Upon receipt, this SHALL pause media. + */ - (void)pauseWithParams:(MTRMediaPlaybackClusterPauseParams * _Nullable)params completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; - (void)pauseWithCompletion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command StopPlayback + * + * Upon receipt, this SHALL stop media. User experience is context-specific. This will often navigate the user back to the location + * where media was originally launched. + */ - (void)stopPlaybackWithParams:(MTRMediaPlaybackClusterStopPlaybackParams * _Nullable)params completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; - (void)stopPlaybackWithCompletion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command StartOver + * + * Upon receipt, this SHALL Start Over with the current media playback item. + */ - (void)startOverWithParams:(MTRMediaPlaybackClusterStartOverParams * _Nullable)params completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; - (void)startOverWithCompletion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command Previous + * + * Upon receipt, this SHALL cause the handler to be invoked for "Previous". User experience is context-specific. This will often Go + * back to the previous media playback item. + */ - (void)previousWithParams:(MTRMediaPlaybackClusterPreviousParams * _Nullable)params completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; - (void)previousWithCompletion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command Next + * + * Upon receipt, this SHALL cause the handler to be invoked for "Next". User experience is context-specific. This will often Go + * forward to the next media playback item. + */ - (void)nextWithParams:(MTRMediaPlaybackClusterNextParams * _Nullable)params completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; - (void)nextWithCompletion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command Rewind + * + * Upon receipt, this SHALL Rewind through media. Different Rewind speeds can be used on the TV based upon the number of sequential + * calls to this function. This is to avoid needing to define every speed now (multiple fast, slow motion, etc). + */ - (void)rewindWithParams:(MTRMediaPlaybackClusterRewindParams * _Nullable)params completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; - (void)rewindWithCompletion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command FastForward + * + * Upon receipt, this SHALL Advance through media. Different FF speeds can be used on the TV based upon the number of sequential + * calls to this function. This is to avoid needing to define every speed now (multiple fast, slow motion, etc). + */ - (void)fastForwardWithParams:(MTRMediaPlaybackClusterFastForwardParams * _Nullable)params completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; - (void)fastForwardWithCompletion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command SkipForward + * + * Upon receipt, this SHALL Skip forward in the media by the given number of seconds, using the data as follows: + */ - (void)skipForwardWithParams:(MTRMediaPlaybackClusterSkipForwardParams *)params completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command SkipBackward + * + * Upon receipt, this SHALL Skip backward in the media by the given number of seconds, using the data as follows: + */ - (void)skipBackwardWithParams:(MTRMediaPlaybackClusterSkipBackwardParams *)params completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command Seek + * + * Upon receipt, this SHALL Skip backward in the media by the given number of seconds, using the data as follows: + */ - (void)seekWithParams:(MTRMediaPlaybackClusterSeekParams *)params completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; @@ -11784,7 +12599,8 @@ labels. /** * Cluster Media Input - * This cluster provides an interface for controlling the Input Selector on a media device such as a TV. + * + * This cluster provides an interface for controlling the Input Selector on a media device such as a TV. */ @interface MTRBaseClusterMediaInput : MTRCluster @@ -11792,14 +12608,35 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command SelectInput + * + * Upon receipt, this SHALL change the input on the media device to the input at a specific index in the Input List. + */ - (void)selectInputWithParams:(MTRMediaInputClusterSelectInputParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command ShowInputStatus + * + * Upon receipt, this SHALL display the active status of the input list on screen. + */ - (void)showInputStatusWithParams:(MTRMediaInputClusterShowInputStatusParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)showInputStatusWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command HideInputStatus + * + * Upon receipt, this SHALL hide the input list from the screen. + */ - (void)hideInputStatusWithParams:(MTRMediaInputClusterHideInputStatusParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)hideInputStatusWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command RenameInput + * + * Upon receipt, this SHALL rename the input at a specific index in the Input List. Updates to the input name SHALL appear in the TV + * settings menus. + */ - (void)renameInputWithParams:(MTRMediaInputClusterRenameInputParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -11894,7 +12731,8 @@ labels. /** * Cluster Low Power - * This cluster provides an interface for managing low power mode on a device. + * + * This cluster provides an interface for managing low power mode on a device. */ @interface MTRBaseClusterLowPower : MTRCluster @@ -11902,6 +12740,11 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command Sleep + * + * This command shall put the device into low power mode. + */ - (void)sleepWithParams:(MTRLowPowerClusterSleepParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)sleepWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -11973,7 +12816,8 @@ labels. /** * Cluster Keypad Input - * This cluster provides an interface for controlling a device like a TV using action commands such as UP, DOWN, and SELECT. + * + * This cluster provides an interface for controlling a device like a TV using action commands such as UP, DOWN, and SELECT. */ @interface MTRBaseClusterKeypadInput : MTRCluster @@ -11981,6 +12825,11 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command SendKey + * + * Upon receipt, this SHALL process a keycode as input to the media device. + */ - (void)sendKeyWithParams:(MTRKeypadInputClusterSendKeyParams *)params completion:(void (^)(MTRKeypadInputClusterSendKeyResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; @@ -12052,7 +12901,8 @@ labels. /** * Cluster Content Launcher - * This cluster provides an interface for launching content on a media player device such as a TV or Speaker. + * + * This cluster provides an interface for launching content on a media player device such as a TV or Speaker. */ @interface MTRBaseClusterContentLauncher : MTRCluster @@ -12060,9 +12910,19 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command LaunchContent + * + * Upon receipt, this SHALL launch the specified content with optional search criteria. + */ - (void)launchContentWithParams:(MTRContentLauncherClusterLaunchContentParams *)params completion:(void (^)(MTRContentLauncherClusterLaunchResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command LaunchURL + * + * Upon receipt, this SHALL launch content from the specified URL. + */ - (void)launchURLWithParams:(MTRContentLauncherClusterLaunchURLParams *)params completion:(void (^)(MTRContentLauncherClusterLaunchResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; @@ -12163,7 +13023,8 @@ labels. /** * Cluster Audio Output - * This cluster provides an interface for controlling the Output on a media device such as a TV. + * + * This cluster provides an interface for controlling the Output on a media device such as a TV. */ @interface MTRBaseClusterAudioOutput : MTRCluster @@ -12171,8 +13032,19 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command SelectOutput + * + * Upon receipt, this SHALL change the output on the media device to the output at a specific index in the Output List. + */ - (void)selectOutputWithParams:(MTRAudioOutputClusterSelectOutputParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command RenameOutput + * + * Upon receipt, this SHALL rename the output at a specific index in the Output List. Updates to the output name SHALL appear in the + * TV settings menus. + */ - (void)renameOutputWithParams:(MTRAudioOutputClusterRenameOutputParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -12267,7 +13139,8 @@ labels. /** * Cluster Application Launcher - * This cluster provides an interface for launching content on a media player device such as a TV or Speaker. + * + * This cluster provides an interface for launching content on a media player device such as a TV or Speaker. */ @interface MTRBaseClusterApplicationLauncher : MTRCluster @@ -12275,12 +13148,30 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command LaunchApp + * + * Upon receipt, this SHALL launch the specified app with optional data. The TV Device SHALL launch and bring to foreground the + * identified application in the command if the application is not already launched and in foreground. The TV Device SHALL update + * state attribute on the Application Basic cluster of the Endpoint corresponding to the launched application. This command returns + * a Launch Response. + */ - (void)launchAppWithParams:(MTRApplicationLauncherClusterLaunchAppParams *)params completion:(void (^)(MTRApplicationLauncherClusterLauncherResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command StopApp + * + * Upon receipt on a Video Player endpoint this SHALL stop the specified application if it is running. + */ - (void)stopAppWithParams:(MTRApplicationLauncherClusterStopAppParams *)params completion:(void (^)(MTRApplicationLauncherClusterLauncherResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command HideApp + * + * Upon receipt on a Video Player endpoint this SHALL hide the specified application if it is running and visible. + */ - (void)hideAppWithParams:(MTRApplicationLauncherClusterHideAppParams *)params completion:(void (^)(MTRApplicationLauncherClusterLauncherResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; @@ -12381,7 +13272,8 @@ labels. /** * Cluster Application Basic - * This cluster provides information about an application running on a TV or media player device which is represented as an + * + * This cluster provides information about an application running on a TV or media player device which is represented as an * endpoint. */ @interface MTRBaseClusterApplicationBasic : MTRCluster @@ -12554,9 +13446,10 @@ labels. /** * Cluster Account Login - * This cluster provides commands that facilitate user account login on a Content App or a node. For example, a Content App - * running on a Video Player device, which is represented as an endpoint (see [TV Architecture]), can use this cluster to help make - * the user account on the Content App match the user account on the Client. + * + * This cluster provides commands that facilitate user account login on a Content App or a node. For example, a Content App running + * on a Video Player device, which is represented as an endpoint (see [TV Architecture]), can use this cluster to help make the user + * account on the Content App match the user account on the Client. */ @interface MTRBaseClusterAccountLogin : MTRCluster @@ -12564,10 +13457,30 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command GetSetupPIN + * + * Upon receipt, the Content App checks if the account associated with the client Temp Account Identifier Rotating ID is the same + * acount that is active on the given Content App. If the accounts are the same, then the Content App includes the Setup PIN in the + * GetSetupPIN Response. + */ - (void)getSetupPINWithParams:(MTRAccountLoginClusterGetSetupPINParams *)params completion:(void (^)(MTRAccountLoginClusterGetSetupPINResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command Login + * + * Upon receipt, the Content App checks if the account associated with the client’s Temp Account Identifier (Rotating ID) has a + * current active Setup PIN with the given value. If the Setup PIN is valid for the user account associated with the Temp Account + * Identifier, then the Content App MAY make that user account active. + */ - (void)loginWithParams:(MTRAccountLoginClusterLoginParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command Logout + * + * The purpose of this command is to instruct the Content App to clear the current user account. This command SHOULD be used by + * clients of a Content App to indicate the end of a user session. + */ - (void)logoutWithParams:(MTRAccountLoginClusterLogoutParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)logoutWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -12639,8 +13552,9 @@ labels. /** * Cluster Electrical Measurement - * Attributes related to the electrical properties of a device. This cluster is used by power outlets and other devices that need - * to provide instantaneous data as opposed to metrology data which should be retrieved from the metering cluster.. + * + * Attributes related to the electrical properties of a device. This cluster is used by power outlets and other devices that need to + * provide instantaneous data as opposed to metrology data which should be retrieved from the metering cluster.. */ @interface MTRBaseClusterElectricalMeasurement : MTRCluster @@ -12648,9 +13562,20 @@ labels. endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command GetProfileInfoCommand + * + * A function which retrieves the power profiling information from the electrical measurement server. + */ - (void)getProfileInfoCommandWithParams:(MTRElectricalMeasurementClusterGetProfileInfoCommandParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)getProfileInfoCommandWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command GetMeasurementProfileCommand + * + * A function which retrieves an electricity measurement profile from the electricity measurement server for a specific attribute Id + * requested. + */ - (void)getMeasurementProfileCommandWithParams:(MTRElectricalMeasurementClusterGetMeasurementProfileCommandParams *)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -14373,7 +15298,8 @@ labels. /** * Cluster Unit Testing - * The Test Cluster is meant to validate the generated code + * + * The Test Cluster is meant to validate the generated code */ MTR_NEWLY_AVAILABLE @interface MTRBaseClusterUnitTesting : MTRCluster @@ -14382,74 +15308,207 @@ MTR_NEWLY_AVAILABLE endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; +/** + * Command Test + * + * Simple command without any parameters and without a specific response + */ - (void)testWithParams:(MTRUnitTestingClusterTestParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)testWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command TestNotHandled + * + * Simple command without any parameters and without a specific response not handled by the server + */ - (void)testNotHandledWithParams:(MTRUnitTestingClusterTestNotHandledParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)testNotHandledWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command TestSpecific + * + * Simple command without any parameters and with a specific response + */ - (void)testSpecificWithParams:(MTRUnitTestingClusterTestSpecificParams * _Nullable)params completion:(void (^)(MTRUnitTestingClusterTestSpecificResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; - (void)testSpecificWithCompletion:(void (^)(MTRUnitTestingClusterTestSpecificResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command TestUnknownCommand + * + * Simple command that should not be added to the server. + */ - (void)testUnknownCommandWithParams:(MTRUnitTestingClusterTestUnknownCommandParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)testUnknownCommandWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command TestAddArguments + * + * Command that takes two arguments and returns their sum. + */ - (void)testAddArgumentsWithParams:(MTRUnitTestingClusterTestAddArgumentsParams *)params completion:(void (^)(MTRUnitTestingClusterTestAddArgumentsResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command TestSimpleArgumentRequest + * + * Command that takes an argument which is bool + */ - (void)testSimpleArgumentRequestWithParams:(MTRUnitTestingClusterTestSimpleArgumentRequestParams *)params completion:(void (^)(MTRUnitTestingClusterTestSimpleArgumentResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command TestStructArrayArgumentRequest + * + * Command that takes various arguments that are arrays, including an array of structs which have a list member. + */ - (void)testStructArrayArgumentRequestWithParams:(MTRUnitTestingClusterTestStructArrayArgumentRequestParams *)params completion: (void (^)(MTRUnitTestingClusterTestStructArrayArgumentResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command TestStructArgumentRequest + * + * Command that takes an argument which is struct. The response echoes the + 'b' field of the single arg. + */ - (void)testStructArgumentRequestWithParams:(MTRUnitTestingClusterTestStructArgumentRequestParams *)params completion:(void (^)(MTRUnitTestingClusterBooleanResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command TestNestedStructArgumentRequest + * + * Command that takes an argument which is nested struct. The response + echoes the 'b' field of ar1.c. + */ - (void)testNestedStructArgumentRequestWithParams:(MTRUnitTestingClusterTestNestedStructArgumentRequestParams *)params completion:(void (^)(MTRUnitTestingClusterBooleanResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command TestListStructArgumentRequest + * + * 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). + */ - (void)testListStructArgumentRequestWithParams:(MTRUnitTestingClusterTestListStructArgumentRequestParams *)params completion:(void (^)(MTRUnitTestingClusterBooleanResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command TestListInt8UArgumentRequest + * + * 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). + */ - (void)testListInt8UArgumentRequestWithParams:(MTRUnitTestingClusterTestListInt8UArgumentRequestParams *)params completion:(void (^)(MTRUnitTestingClusterBooleanResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command TestNestedStructListArgumentRequest + * + * 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. + */ - (void)testNestedStructListArgumentRequestWithParams:(MTRUnitTestingClusterTestNestedStructListArgumentRequestParams *)params completion:(void (^)(MTRUnitTestingClusterBooleanResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command TestListNestedStructListArgumentRequest + * + * 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). + */ - (void)testListNestedStructListArgumentRequestWithParams: (MTRUnitTestingClusterTestListNestedStructListArgumentRequestParams *)params completion:(void (^)(MTRUnitTestingClusterBooleanResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command TestListInt8UReverseRequest + * + * Command that takes an argument which is a list of INT8U and expects a + response that reverses the list. + */ - (void)testListInt8UReverseRequestWithParams:(MTRUnitTestingClusterTestListInt8UReverseRequestParams *)params completion:(void (^)(MTRUnitTestingClusterTestListInt8UReverseResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command TestEnumsRequest + * + * Command that sends a vendor id and an enum. The server is expected to + echo them back. + */ - (void)testEnumsRequestWithParams:(MTRUnitTestingClusterTestEnumsRequestParams *)params completion:(void (^)(MTRUnitTestingClusterTestEnumsResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command TestNullableOptionalRequest + * + * 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. + */ - (void)testNullableOptionalRequestWithParams:(MTRUnitTestingClusterTestNullableOptionalRequestParams * _Nullable)params completion:(void (^)(MTRUnitTestingClusterTestNullableOptionalResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command TestComplexNullableOptionalRequest + * + * 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. + */ - (void)testComplexNullableOptionalRequestWithParams:(MTRUnitTestingClusterTestComplexNullableOptionalRequestParams *)params completion: (void (^)( MTRUnitTestingClusterTestComplexNullableOptionalResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command SimpleStructEchoRequest + * + * Command that takes an argument which is a struct. The response echoes + the struct back. + */ - (void)simpleStructEchoRequestWithParams:(MTRUnitTestingClusterSimpleStructEchoRequestParams *)params completion:(void (^)(MTRUnitTestingClusterSimpleStructResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command TimedInvokeRequest + * + * Command that just responds with a success status if the timed invoke + conditions are met. + */ - (void)timedInvokeRequestWithParams:(MTRUnitTestingClusterTimedInvokeRequestParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; - (void)timedInvokeRequestWithCompletion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command TestSimpleOptionalArgumentRequest + * + * Command that takes an optional argument which is bool. It responds with a success value if the optional is set to any value. + */ - (void)testSimpleOptionalArgumentRequestWithParams:(MTRUnitTestingClusterTestSimpleOptionalArgumentRequestParams * _Nullable)params completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; +/** + * Command TestEmitTestEventRequest + * + * 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. + */ - (void)testEmitTestEventRequestWithParams:(MTRUnitTestingClusterTestEmitTestEventRequestParams *)params completion:(void (^)(MTRUnitTestingClusterTestEmitTestEventResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; +/** + * Command TestEmitTestFabricScopedEventRequest + * + * 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. + */ - (void) testEmitTestFabricScopedEventRequestWithParams:(MTRUnitTestingClusterTestEmitTestFabricScopedEventRequestParams *)params completion: @@ -15899,6 +16958,18 @@ MTR_NEWLY_AVAILABLE @end +MTR_NEWLY_DEPRECATED("Please use MTRBaseClusterOTASoftwareUpdateProvider") +@interface MTRBaseClusterOtaSoftwareUpdateProvider : MTRBaseClusterOTASoftwareUpdateProvider +@end + +MTR_NEWLY_DEPRECATED("Please use MTRBaseClusterOTASoftwareUpdateRequestor") +@interface MTRBaseClusterOtaSoftwareUpdateRequestor : MTRBaseClusterOTASoftwareUpdateRequestor +@end + +MTR_NEWLY_DEPRECATED("Please use MTRBaseClusterWakeOnLAN") +@interface MTRBaseClusterWakeOnLan : MTRBaseClusterWakeOnLAN +@end + MTR_NEWLY_DEPRECATED("Please use MTRBaseClusterUnitTesting") @interface MTRBaseClusterTestCluster : MTRBaseClusterUnitTesting @end @@ -16050,31 +17121,65 @@ typedef NS_OPTIONS(uint16_t, MTRActionsCommandBits) { MTRActionsCommandBitsDisableActionWithDuration = 0x800, }; +typedef NS_ENUM(uint8_t, MTROTASoftwareUpdateProviderOTAApplyUpdateAction) { + MTROTASoftwareUpdateProviderOTAApplyUpdateActionProceed = 0x00, + MTROTASoftwareUpdateProviderOTAApplyUpdateActionAwaitNextAction = 0x01, + MTROTASoftwareUpdateProviderOTAApplyUpdateActionDiscontinue = 0x02, +} MTR_NEWLY_AVAILABLE; + typedef NS_ENUM(uint8_t, MTROtaSoftwareUpdateProviderOTAApplyUpdateAction) { MTROtaSoftwareUpdateProviderOTAApplyUpdateActionProceed = 0x00, MTROtaSoftwareUpdateProviderOTAApplyUpdateActionAwaitNextAction = 0x01, MTROtaSoftwareUpdateProviderOTAApplyUpdateActionDiscontinue = 0x02, -}; +} MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateProviderOTAApplyUpdateAction"); + +typedef NS_ENUM(uint8_t, MTROTASoftwareUpdateProviderOTADownloadProtocol) { + MTROTASoftwareUpdateProviderOTADownloadProtocolBDXSynchronous = 0x00, + MTROTASoftwareUpdateProviderOTADownloadProtocolBDXAsynchronous = 0x01, + MTROTASoftwareUpdateProviderOTADownloadProtocolHTTPS = 0x02, + MTROTASoftwareUpdateProviderOTADownloadProtocolVendorSpecific = 0x03, +} MTR_NEWLY_AVAILABLE; typedef NS_ENUM(uint8_t, MTROtaSoftwareUpdateProviderOTADownloadProtocol) { MTROtaSoftwareUpdateProviderOTADownloadProtocolBDXSynchronous = 0x00, MTROtaSoftwareUpdateProviderOTADownloadProtocolBDXAsynchronous = 0x01, MTROtaSoftwareUpdateProviderOTADownloadProtocolHTTPS = 0x02, MTROtaSoftwareUpdateProviderOTADownloadProtocolVendorSpecific = 0x03, -}; +} MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateProviderOTADownloadProtocol"); + +typedef NS_ENUM(uint8_t, MTROTASoftwareUpdateProviderOTAQueryStatus) { + MTROTASoftwareUpdateProviderOTAQueryStatusUpdateAvailable = 0x00, + MTROTASoftwareUpdateProviderOTAQueryStatusBusy = 0x01, + MTROTASoftwareUpdateProviderOTAQueryStatusNotAvailable = 0x02, + MTROTASoftwareUpdateProviderOTAQueryStatusDownloadProtocolNotSupported = 0x03, +} MTR_NEWLY_AVAILABLE; typedef NS_ENUM(uint8_t, MTROtaSoftwareUpdateProviderOTAQueryStatus) { MTROtaSoftwareUpdateProviderOTAQueryStatusUpdateAvailable = 0x00, MTROtaSoftwareUpdateProviderOTAQueryStatusBusy = 0x01, MTROtaSoftwareUpdateProviderOTAQueryStatusNotAvailable = 0x02, MTROtaSoftwareUpdateProviderOTAQueryStatusDownloadProtocolNotSupported = 0x03, -}; +} MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateProviderOTAQueryStatus"); + +typedef NS_ENUM(uint8_t, MTROTASoftwareUpdateRequestorOTAAnnouncementReason) { + MTROTASoftwareUpdateRequestorOTAAnnouncementReasonSimpleAnnouncement = 0x00, + MTROTASoftwareUpdateRequestorOTAAnnouncementReasonUpdateAvailable = 0x01, + MTROTASoftwareUpdateRequestorOTAAnnouncementReasonUrgentUpdateAvailable = 0x02, +} MTR_NEWLY_AVAILABLE; typedef NS_ENUM(uint8_t, MTROtaSoftwareUpdateRequestorOTAAnnouncementReason) { MTROtaSoftwareUpdateRequestorOTAAnnouncementReasonSimpleAnnouncement = 0x00, MTROtaSoftwareUpdateRequestorOTAAnnouncementReasonUpdateAvailable = 0x01, MTROtaSoftwareUpdateRequestorOTAAnnouncementReasonUrgentUpdateAvailable = 0x02, -}; +} MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateRequestorOTAAnnouncementReason"); + +typedef NS_ENUM(uint8_t, MTROTASoftwareUpdateRequestorOTAChangeReason) { + MTROTASoftwareUpdateRequestorOTAChangeReasonUnknown = 0x00, + MTROTASoftwareUpdateRequestorOTAChangeReasonSuccess = 0x01, + MTROTASoftwareUpdateRequestorOTAChangeReasonFailure = 0x02, + MTROTASoftwareUpdateRequestorOTAChangeReasonTimeOut = 0x03, + MTROTASoftwareUpdateRequestorOTAChangeReasonDelayByProvider = 0x04, +} MTR_NEWLY_AVAILABLE; typedef NS_ENUM(uint8_t, MTROtaSoftwareUpdateRequestorOTAChangeReason) { MTROtaSoftwareUpdateRequestorOTAChangeReasonUnknown = 0x00, @@ -16082,7 +17187,19 @@ typedef NS_ENUM(uint8_t, MTROtaSoftwareUpdateRequestorOTAChangeReason) { MTROtaSoftwareUpdateRequestorOTAChangeReasonFailure = 0x02, MTROtaSoftwareUpdateRequestorOTAChangeReasonTimeOut = 0x03, MTROtaSoftwareUpdateRequestorOTAChangeReasonDelayByProvider = 0x04, -}; +} MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateRequestorOTAChangeReason"); + +typedef NS_ENUM(uint8_t, MTROTASoftwareUpdateRequestorOTAUpdateState) { + MTROTASoftwareUpdateRequestorOTAUpdateStateUnknown = 0x00, + MTROTASoftwareUpdateRequestorOTAUpdateStateIdle = 0x01, + MTROTASoftwareUpdateRequestorOTAUpdateStateQuerying = 0x02, + MTROTASoftwareUpdateRequestorOTAUpdateStateDelayedOnQuery = 0x03, + MTROTASoftwareUpdateRequestorOTAUpdateStateDownloading = 0x04, + MTROTASoftwareUpdateRequestorOTAUpdateStateApplying = 0x05, + MTROTASoftwareUpdateRequestorOTAUpdateStateDelayedOnApply = 0x06, + MTROTASoftwareUpdateRequestorOTAUpdateStateRollingBack = 0x07, + MTROTASoftwareUpdateRequestorOTAUpdateStateDelayedOnUserConsent = 0x08, +} MTR_NEWLY_AVAILABLE; typedef NS_ENUM(uint8_t, MTROtaSoftwareUpdateRequestorOTAUpdateState) { MTROtaSoftwareUpdateRequestorOTAUpdateStateUnknown = 0x00, @@ -16094,7 +17211,7 @@ typedef NS_ENUM(uint8_t, MTROtaSoftwareUpdateRequestorOTAUpdateState) { MTROtaSoftwareUpdateRequestorOTAUpdateStateDelayedOnApply = 0x06, MTROtaSoftwareUpdateRequestorOTAUpdateStateRollingBack = 0x07, MTROtaSoftwareUpdateRequestorOTAUpdateStateDelayedOnUserConsent = 0x08, -}; +} MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateRequestorOTAUpdateState"); typedef NS_ENUM(uint8_t, MTRTimeFormatLocalizationCalendarType) { MTRTimeFormatLocalizationCalendarTypeBuddhist = 0x00, @@ -18916,18 +20033,18 @@ typedef NS_ENUM(uint8_t, MTRFaultInjectionFaultType) { - (void)readAttributeDeviceListWithCompletionHandler: (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completionHandler - MTR_NEWLY_DEPRECATED("Please use readAttributeDeviceListWithCompletion:"); + MTR_NEWLY_DEPRECATED("Please use readAttributeDeviceTypeListWithCompletion:"); - (void)subscribeAttributeDeviceListWithMinInterval:(NSNumber * _Nonnull)minInterval maxInterval:(NSNumber * _Nonnull)maxInterval params:(MTRSubscribeParams * _Nullable)params subscriptionEstablished:(MTRSubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))reportHandler - MTR_NEWLY_DEPRECATED("Please use subscribeAttributeDeviceListWithParams:subscriptionEstablished:"); + MTR_NEWLY_DEPRECATED("Please use subscribeAttributeDeviceTypeListWithParams:subscriptionEstablished:"); + (void)readAttributeDeviceListWithAttributeCache:(MTRAttributeCacheContainer *)attributeCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue completionHandler:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completionHandler - MTR_NEWLY_DEPRECATED("Please use readAttributeDeviceListWithAttributeCache:endpoint:queue:completion:"); + MTR_NEWLY_DEPRECATED("Please use readAttributeDeviceTypeListWithAttributeCache:endpoint:queue:completion:"); - (void)readAttributeServerListWithCompletionHandler: (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completionHandler @@ -19182,25 +20299,25 @@ typedef NS_ENUM(uint8_t, MTRFaultInjectionFaultType) { - (void)readAttributeAclWithParams:(MTRReadParams * _Nullable)params completionHandler:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completionHandler - MTR_NEWLY_DEPRECATED("Please use readAttributeAclWithParams:completion:"); + MTR_NEWLY_DEPRECATED("Please use readAttributeACLWithParams:completion:"); - (void)writeAttributeAclWithValue:(NSArray * _Nonnull)value completionHandler:(MTRStatusCompletion)completionHandler - MTR_NEWLY_DEPRECATED("Please use writeAttributeAclWithValue:completion:"); + MTR_NEWLY_DEPRECATED("Please use writeAttributeACLWithValue:completion:"); - (void)writeAttributeAclWithValue:(NSArray * _Nonnull)value params:(MTRWriteParams * _Nullable)params completionHandler:(MTRStatusCompletion)completionHandler - MTR_NEWLY_DEPRECATED("Please use writeAttributeAclWithValue:params:completion:"); + MTR_NEWLY_DEPRECATED("Please use writeAttributeACLWithValue:params:completion:"); - (void)subscribeAttributeAclWithMinInterval:(NSNumber * _Nonnull)minInterval maxInterval:(NSNumber * _Nonnull)maxInterval params:(MTRSubscribeParams * _Nullable)params subscriptionEstablished:(MTRSubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))reportHandler - MTR_NEWLY_DEPRECATED("Please use subscribeAttributeAclWithParams:subscriptionEstablished:"); + MTR_NEWLY_DEPRECATED("Please use subscribeAttributeACLWithParams:subscriptionEstablished:"); + (void)readAttributeAclWithAttributeCache:(MTRAttributeCacheContainer *)attributeCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue completionHandler:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completionHandler - MTR_NEWLY_DEPRECATED("Please use readAttributeAclWithAttributeCache:endpoint:queue:completion:"); + MTR_NEWLY_DEPRECATED("Please use readAttributeACLWithAttributeCache:endpoint:queue:completion:"); - (void)readAttributeExtensionWithParams:(MTRReadParams * _Nullable)params completionHandler:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completionHandler @@ -31983,14 +33100,14 @@ typedef NS_ENUM(uint8_t, MTRFaultInjectionFaultType) { - (void)readAttributePirOccupiedToUnoccupiedDelayWithCompletionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler - MTR_NEWLY_DEPRECATED("Please use readAttributePirOccupiedToUnoccupiedDelayWithCompletion:"); + MTR_NEWLY_DEPRECATED("Please use readAttributePIROccupiedToUnoccupiedDelayWithCompletion:"); - (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSNumber * _Nonnull)value completionHandler:(MTRStatusCompletion)completionHandler - MTR_NEWLY_DEPRECATED("Please use writeAttributePirOccupiedToUnoccupiedDelayWithValue:completion:"); + MTR_NEWLY_DEPRECATED("Please use writeAttributePIROccupiedToUnoccupiedDelayWithValue:completion:"); - (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSNumber * _Nonnull)value params:(MTRWriteParams * _Nullable)params completionHandler:(MTRStatusCompletion)completionHandler - MTR_NEWLY_DEPRECATED("Please use writeAttributePirOccupiedToUnoccupiedDelayWithValue:params:completion:"); + MTR_NEWLY_DEPRECATED("Please use writeAttributePIROccupiedToUnoccupiedDelayWithValue:params:completion:"); - (void)subscribeAttributePirOccupiedToUnoccupiedDelayWithMinInterval:(NSNumber * _Nonnull)minInterval maxInterval:(NSNumber * _Nonnull)maxInterval params:(MTRSubscribeParams * _Nullable)params @@ -31998,24 +33115,24 @@ typedef NS_ENUM(uint8_t, MTRFaultInjectionFaultType) { (MTRSubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler - MTR_NEWLY_DEPRECATED("Please use subscribeAttributePirOccupiedToUnoccupiedDelayWithParams:subscriptionEstablished:"); + MTR_NEWLY_DEPRECATED("Please use subscribeAttributePIROccupiedToUnoccupiedDelayWithParams:subscriptionEstablished:"); + (void)readAttributePirOccupiedToUnoccupiedDelayWithAttributeCache:(MTRAttributeCacheContainer *)attributeCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue completionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler - MTR_NEWLY_DEPRECATED("Please use readAttributePirOccupiedToUnoccupiedDelayWithAttributeCache:endpoint:queue:completion:"); + MTR_NEWLY_DEPRECATED("Please use readAttributePIROccupiedToUnoccupiedDelayWithAttributeCache:endpoint:queue:completion:"); - (void)readAttributePirUnoccupiedToOccupiedDelayWithCompletionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler - MTR_NEWLY_DEPRECATED("Please use readAttributePirUnoccupiedToOccupiedDelayWithCompletion:"); + MTR_NEWLY_DEPRECATED("Please use readAttributePIRUnoccupiedToOccupiedDelayWithCompletion:"); - (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSNumber * _Nonnull)value completionHandler:(MTRStatusCompletion)completionHandler - MTR_NEWLY_DEPRECATED("Please use writeAttributePirUnoccupiedToOccupiedDelayWithValue:completion:"); + MTR_NEWLY_DEPRECATED("Please use writeAttributePIRUnoccupiedToOccupiedDelayWithValue:completion:"); - (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSNumber * _Nonnull)value params:(MTRWriteParams * _Nullable)params completionHandler:(MTRStatusCompletion)completionHandler - MTR_NEWLY_DEPRECATED("Please use writeAttributePirUnoccupiedToOccupiedDelayWithValue:params:completion:"); + MTR_NEWLY_DEPRECATED("Please use writeAttributePIRUnoccupiedToOccupiedDelayWithValue:params:completion:"); - (void)subscribeAttributePirUnoccupiedToOccupiedDelayWithMinInterval:(NSNumber * _Nonnull)minInterval maxInterval:(NSNumber * _Nonnull)maxInterval params:(MTRSubscribeParams * _Nullable)params @@ -32023,24 +33140,24 @@ typedef NS_ENUM(uint8_t, MTRFaultInjectionFaultType) { (MTRSubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler - MTR_NEWLY_DEPRECATED("Please use subscribeAttributePirUnoccupiedToOccupiedDelayWithParams:subscriptionEstablished:"); + MTR_NEWLY_DEPRECATED("Please use subscribeAttributePIRUnoccupiedToOccupiedDelayWithParams:subscriptionEstablished:"); + (void)readAttributePirUnoccupiedToOccupiedDelayWithAttributeCache:(MTRAttributeCacheContainer *)attributeCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue completionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler - MTR_NEWLY_DEPRECATED("Please use readAttributePirUnoccupiedToOccupiedDelayWithAttributeCache:endpoint:queue:completion:"); + MTR_NEWLY_DEPRECATED("Please use readAttributePIRUnoccupiedToOccupiedDelayWithAttributeCache:endpoint:queue:completion:"); - (void)readAttributePirUnoccupiedToOccupiedThresholdWithCompletionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler - MTR_NEWLY_DEPRECATED("Please use readAttributePirUnoccupiedToOccupiedThresholdWithCompletion:"); + MTR_NEWLY_DEPRECATED("Please use readAttributePIRUnoccupiedToOccupiedThresholdWithCompletion:"); - (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSNumber * _Nonnull)value completionHandler:(MTRStatusCompletion)completionHandler - MTR_NEWLY_DEPRECATED("Please use writeAttributePirUnoccupiedToOccupiedThresholdWithValue:completion:"); + MTR_NEWLY_DEPRECATED("Please use writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:completion:"); - (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSNumber * _Nonnull)value params:(MTRWriteParams * _Nullable)params completionHandler:(MTRStatusCompletion)completionHandler - MTR_NEWLY_DEPRECATED("Please use writeAttributePirUnoccupiedToOccupiedThresholdWithValue:params:completion:"); + MTR_NEWLY_DEPRECATED("Please use writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:params:completion:"); - (void)subscribeAttributePirUnoccupiedToOccupiedThresholdWithMinInterval:(NSNumber * _Nonnull)minInterval maxInterval:(NSNumber * _Nonnull)maxInterval params:(MTRSubscribeParams * _Nullable)params @@ -32048,13 +33165,13 @@ typedef NS_ENUM(uint8_t, MTRFaultInjectionFaultType) { (MTRSubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler - MTR_NEWLY_DEPRECATED("Please use subscribeAttributePirUnoccupiedToOccupiedThresholdWithParams:subscriptionEstablished:"); + MTR_NEWLY_DEPRECATED("Please use subscribeAttributePIRUnoccupiedToOccupiedThresholdWithParams:subscriptionEstablished:"); + (void)readAttributePirUnoccupiedToOccupiedThresholdWithAttributeCache:(MTRAttributeCacheContainer *)attributeCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue completionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler - MTR_NEWLY_DEPRECATED("Please use readAttributePirUnoccupiedToOccupiedThresholdWithAttributeCache:endpoint:queue:completion:"); + MTR_NEWLY_DEPRECATED("Please use readAttributePIRUnoccupiedToOccupiedThresholdWithAttributeCache:endpoint:queue:completion:"); - (void)readAttributeUltrasonicOccupiedToUnoccupiedDelayWithCompletionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.mm b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.mm index 4af32180e92fe3..1ff77268b3df8d 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.mm +++ b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.mm @@ -173,22 +173,23 @@ + (void)readAttributeIdentifyTimeWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Identify::Attributes::IdentifyTime::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Identify::Attributes::IdentifyTime::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeIdentifyTypeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -215,22 +216,23 @@ + (void)readAttributeIdentifyTypeWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Identify::Attributes::IdentifyType::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Identify::Attributes::IdentifyType::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -259,7 +261,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRIdentifyGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(IdentifyGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -304,7 +306,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRIdentifyAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(IdentifyAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -347,22 +349,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRIdentifyAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(IdentifyAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Identify::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(IdentifyAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Identify::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -389,22 +392,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Identify::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Identify::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -432,22 +436,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Identify::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Identify::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -1013,22 +1018,23 @@ + (void)readAttributeNameSupportWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Groups::Attributes::NameSupport::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Groups::Attributes::NameSupport::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -1057,7 +1063,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGroupsGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GroupsGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -1102,22 +1108,23 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGroupsAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(GroupsAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Groups::Attributes::AcceptedCommandList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(GroupsAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Groups::Attributes::AcceptedCommandList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAttributeListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -1144,22 +1151,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGroupsAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(GroupsAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Groups::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(GroupsAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Groups::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -1186,22 +1194,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Groups::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Groups::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -1229,22 +1238,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Groups::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Groups::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -2050,22 +2060,23 @@ + (void)readAttributeSceneCountWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Scenes::Attributes::SceneCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Scenes::Attributes::SceneCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentSceneWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -2092,22 +2103,23 @@ + (void)readAttributeCurrentSceneWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Scenes::Attributes::CurrentScene::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Scenes::Attributes::CurrentScene::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentGroupWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -2134,22 +2146,23 @@ + (void)readAttributeCurrentGroupWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Scenes::Attributes::CurrentGroup::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Scenes::Attributes::CurrentGroup::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSceneValidWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -2176,22 +2189,23 @@ + (void)readAttributeSceneValidWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Scenes::Attributes::SceneValid::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Scenes::Attributes::SceneValid::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNameSupportWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -2218,22 +2232,23 @@ + (void)readAttributeNameSupportWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Scenes::Attributes::NameSupport::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Scenes::Attributes::NameSupport::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLastConfiguredByWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -2261,22 +2276,23 @@ + (void)readAttributeLastConfiguredByWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Scenes::Attributes::LastConfiguredBy::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Scenes::Attributes::LastConfiguredBy::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -2305,7 +2321,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRScenesGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ScenesGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -2350,22 +2366,23 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRScenesAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(ScenesAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Scenes::Attributes::AcceptedCommandList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(ScenesAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Scenes::Attributes::AcceptedCommandList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAttributeListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -2392,22 +2409,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRScenesAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(ScenesAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Scenes::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(ScenesAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Scenes::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -2434,22 +2452,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Scenes::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Scenes::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -2477,22 +2496,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Scenes::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Scenes::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -3304,22 +3324,23 @@ + (void)readAttributeOnOffWithClusterStateCache:(MTRClusterStateCacheContainer * completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OnOff::Attributes::OnOff::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OnOff::Attributes::OnOff::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGlobalSceneControlWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -3348,22 +3369,23 @@ + (void)readAttributeGlobalSceneControlWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OnOff::Attributes::GlobalSceneControl::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OnOff::Attributes::GlobalSceneControl::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOnTimeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -3427,22 +3449,23 @@ + (void)readAttributeOnTimeWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OnOff::Attributes::OnTime::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OnOff::Attributes::OnTime::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOffWaitTimeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -3506,22 +3529,23 @@ + (void)readAttributeOffWaitTimeWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OnOff::Attributes::OffWaitTime::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OnOff::Attributes::OffWaitTime::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeStartUpOnOffWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -3590,7 +3614,7 @@ + (void)readAttributeStartUpOnOffWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableOnOffClusterOnOffStartUpOnOffAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(NullableOnOffClusterOnOffStartUpOnOffAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -3635,22 +3659,23 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROnOffGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(OnOffGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OnOff::Attributes::GeneratedCommandList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(OnOffGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OnOff::Attributes::GeneratedCommandList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcceptedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -3679,22 +3704,23 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROnOffAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(OnOffAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OnOff::Attributes::AcceptedCommandList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(OnOffAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OnOff::Attributes::AcceptedCommandList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAttributeListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -3721,22 +3747,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROnOffAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(OnOffAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OnOff::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(OnOffAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OnOff::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -3763,22 +3790,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OnOff::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OnOff::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -3806,22 +3834,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OnOff::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OnOff::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -4380,22 +4409,23 @@ + (void)readAttributeSwitchTypeWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OnOffSwitchConfiguration::Attributes::SwitchType::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OnOffSwitchConfiguration::Attributes::SwitchType::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSwitchActionsWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -4459,22 +4489,23 @@ + (void)readAttributeSwitchActionsWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OnOffSwitchConfiguration::Attributes::SwitchActions::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OnOffSwitchConfiguration::Attributes::SwitchActions::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -4504,7 +4535,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROnOffSwitchConfigurationGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(OnOffSwitchConfigurationGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -4550,7 +4581,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROnOffSwitchConfigurationAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(OnOffSwitchConfigurationAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -4593,7 +4624,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROnOffSwitchConfigurationAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(OnOffSwitchConfigurationAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -4636,22 +4667,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OnOffSwitchConfiguration::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OnOffSwitchConfiguration::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -4679,22 +4711,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OnOffSwitchConfiguration::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OnOffSwitchConfiguration::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -5384,22 +5417,23 @@ + (void)readAttributeCurrentLevelWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::CurrentLevel::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::CurrentLevel::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRemainingTimeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -5426,22 +5460,23 @@ + (void)readAttributeRemainingTimeWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::RemainingTime::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::RemainingTime::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinLevelWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -5468,22 +5503,23 @@ + (void)readAttributeMinLevelWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::MinLevel::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::MinLevel::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxLevelWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -5510,22 +5546,23 @@ + (void)readAttributeMaxLevelWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::MaxLevel::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::MaxLevel::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentFrequencyWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -5553,22 +5590,23 @@ + (void)readAttributeCurrentFrequencyWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::CurrentFrequency::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::CurrentFrequency::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinFrequencyWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -5595,22 +5633,23 @@ + (void)readAttributeMinFrequencyWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::MinFrequency::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::MinFrequency::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxFrequencyWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -5637,22 +5676,23 @@ + (void)readAttributeMaxFrequencyWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::MaxFrequency::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::MaxFrequency::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOptionsWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -5716,22 +5756,23 @@ + (void)readAttributeOptionsWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRLevelControlOptionsAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(LevelControlOptionsAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::Options::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(LevelControlOptionsAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::Options::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOnOffTransitionTimeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -5797,22 +5838,23 @@ + (void)readAttributeOnOffTransitionTimeWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::OnOffTransitionTime::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::OnOffTransitionTime::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOnLevelWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -5881,22 +5923,23 @@ + (void)readAttributeOnLevelWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::OnLevel::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::OnLevel::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOnTransitionTimeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -5966,22 +6009,23 @@ + (void)readAttributeOnTransitionTimeWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::OnTransitionTime::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::OnTransitionTime::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOffTransitionTimeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -6051,22 +6095,23 @@ + (void)readAttributeOffTransitionTimeWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::OffTransitionTime::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::OffTransitionTime::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDefaultMoveRateWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -6136,22 +6181,23 @@ + (void)readAttributeDefaultMoveRateWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::DefaultMoveRate::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::DefaultMoveRate::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeStartUpCurrentLevelWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -6222,22 +6268,23 @@ + (void)readAttributeStartUpCurrentLevelWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::StartUpCurrentLevel::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::StartUpCurrentLevel::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -6266,7 +6313,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRLevelControlGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(LevelControlGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -6311,7 +6358,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRLevelControlAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(LevelControlAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -6354,22 +6401,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRLevelControlAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(LevelControlAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(LevelControlAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -6396,22 +6444,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -6439,22 +6488,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LevelControl::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LevelControl::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -7485,22 +7535,23 @@ + (void)readAttributeActiveTextWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BinaryInputBasic::Attributes::ActiveText::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BinaryInputBasic::Attributes::ActiveText::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDescriptionWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -7564,22 +7615,23 @@ + (void)readAttributeDescriptionWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BinaryInputBasic::Attributes::Description::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BinaryInputBasic::Attributes::Description::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInactiveTextWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -7643,22 +7695,23 @@ + (void)readAttributeInactiveTextWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BinaryInputBasic::Attributes::InactiveText::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BinaryInputBasic::Attributes::InactiveText::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOutOfServiceWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -7722,22 +7775,23 @@ + (void)readAttributeOutOfServiceWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BinaryInputBasic::Attributes::OutOfService::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BinaryInputBasic::Attributes::OutOfService::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePolarityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -7764,22 +7818,23 @@ + (void)readAttributePolarityWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BinaryInputBasic::Attributes::Polarity::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BinaryInputBasic::Attributes::Polarity::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePresentValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -7843,22 +7898,23 @@ + (void)readAttributePresentValueWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BinaryInputBasic::Attributes::PresentValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BinaryInputBasic::Attributes::PresentValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeReliabilityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -7922,22 +7978,23 @@ + (void)readAttributeReliabilityWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BinaryInputBasic::Attributes::Reliability::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BinaryInputBasic::Attributes::Reliability::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeStatusFlagsWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -7964,22 +8021,23 @@ + (void)readAttributeStatusFlagsWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BinaryInputBasic::Attributes::StatusFlags::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BinaryInputBasic::Attributes::StatusFlags::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeApplicationTypeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -8007,22 +8065,23 @@ + (void)readAttributeApplicationTypeWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BinaryInputBasic::Attributes::ApplicationType::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BinaryInputBasic::Attributes::ApplicationType::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -8051,7 +8110,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBinaryInputBasicGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BinaryInputBasicGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -8096,7 +8155,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBinaryInputBasicAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BinaryInputBasicAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -8139,7 +8198,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBinaryInputBasicAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BinaryInputBasicAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -8182,22 +8241,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BinaryInputBasic::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BinaryInputBasic::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -8225,22 +8285,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BinaryInputBasic::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BinaryInputBasic::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -8958,22 +9019,23 @@ + (void)readAttributeDeviceTypeListWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDescriptorDeviceTypeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(DescriptorDeviceTypeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Descriptor::Attributes::DeviceTypeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(DescriptorDeviceTypeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Descriptor::Attributes::DeviceTypeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeServerListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -9000,22 +9062,23 @@ + (void)readAttributeServerListWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDescriptorServerListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(DescriptorServerListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Descriptor::Attributes::ServerList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(DescriptorServerListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Descriptor::Attributes::ServerList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClientListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -9042,22 +9105,23 @@ + (void)readAttributeClientListWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDescriptorClientListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(DescriptorClientListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Descriptor::Attributes::ClientList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(DescriptorClientListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Descriptor::Attributes::ClientList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePartsListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -9084,22 +9148,23 @@ + (void)readAttributePartsListWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDescriptorPartsListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(DescriptorPartsListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Descriptor::Attributes::PartsList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(DescriptorPartsListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Descriptor::Attributes::PartsList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -9128,7 +9193,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDescriptorGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(DescriptorGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -9173,7 +9238,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDescriptorAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(DescriptorAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -9216,22 +9281,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDescriptorAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(DescriptorAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Descriptor::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(DescriptorAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Descriptor::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -9258,22 +9324,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Descriptor::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Descriptor::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -9301,22 +9368,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Descriptor::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Descriptor::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -9831,22 +9899,23 @@ + (void)readAttributeBindingWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBindingBindingListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BindingBindingListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Binding::Attributes::Binding::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BindingBindingListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Binding::Attributes::Binding::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -9875,7 +9944,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBindingGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BindingGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -9920,7 +9989,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBindingAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BindingAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -9963,22 +10032,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBindingAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BindingAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Binding::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BindingAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Binding::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -10005,22 +10075,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Binding::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Binding::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -10048,22 +10119,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Binding::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Binding::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -10364,20 +10436,20 @@ - (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)en return self; } -- (void)readAttributeAclWithParams:(MTRReadParams * _Nullable)params +- (void)readAttributeACLWithParams:(MTRReadParams * _Nullable)params completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { // Make a copy of params before we go async. params = [params copy]; using TypeInfo = AccessControl::Attributes::Acl::TypeInfo; - return MTRReadAttribute( + return MTRReadAttribute( params, completion, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } -- (void)writeAttributeAclWithValue:(NSArray * _Nonnull)value completion:(MTRStatusCompletion)completion +- (void)writeAttributeACLWithValue:(NSArray * _Nonnull)value completion:(MTRStatusCompletion)completion { - [self writeAttributeAclWithValue:(NSArray * _Nonnull) value params:nil completion:completion]; + [self writeAttributeACLWithValue:(NSArray * _Nonnull) value params:nil completion:completion]; } -- (void)writeAttributeAclWithValue:(NSArray * _Nonnull)value +- (void)writeAttributeACLWithValue:(NSArray * _Nonnull)value params:(MTRWriteParams * _Nullable)params completion:(MTRStatusCompletion)completion { @@ -10508,38 +10580,39 @@ - (void)writeAttributeAclWithValue:(NSArray * _Nonnull)value std::move(*bridge).DispatchAction(self.device); } -- (void)subscribeAttributeAclWithParams:(MTRSubscribeParams * _Nonnull)params +- (void)subscribeAttributeACLWithParams:(MTRSubscribeParams * _Nonnull)params subscriptionEstablished:(MTRSubscriptionEstablishedHandler _Nullable)subscriptionEstablished reportHandler:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))reportHandler { using TypeInfo = AccessControl::Attributes::Acl::TypeInfo; - MTRSubscribeAttribute(params, + MTRSubscribeAttribute(params, subscriptionEstablished, reportHandler, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } -+ (void)readAttributeAclWithClusterStateCache:(MTRClusterStateCacheContainer *)clusterStateCacheContainer ++ (void)readAttributeACLWithClusterStateCache:(MTRClusterStateCacheContainer *)clusterStateCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { - auto * bridge = new MTRAccessControlAclListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(AccessControlAclListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AccessControl::Attributes::Acl::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + auto * bridge = new MTRAccessControlACLListAttributeCallbackBridge(queue, completion); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(AccessControlACLListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AccessControl::Attributes::Acl::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeExtensionWithParams:(MTRReadParams * _Nullable)params @@ -10626,22 +10699,23 @@ + (void)readAttributeExtensionWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRAccessControlExtensionListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(AccessControlExtensionListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AccessControl::Attributes::Extension::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(AccessControlExtensionListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AccessControl::Attributes::Extension::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSubjectsPerAccessControlEntryWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -10672,22 +10746,23 @@ + (void)readAttributeSubjectsPerAccessControlEntryWithClusterStateCache:(MTRClus NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AccessControl::Attributes::SubjectsPerAccessControlEntry::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AccessControl::Attributes::SubjectsPerAccessControlEntry::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTargetsPerAccessControlEntryWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -10718,22 +10793,23 @@ + (void)readAttributeTargetsPerAccessControlEntryWithClusterStateCache:(MTRClust NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AccessControl::Attributes::TargetsPerAccessControlEntry::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AccessControl::Attributes::TargetsPerAccessControlEntry::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAccessControlEntriesPerFabricWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -10764,22 +10840,23 @@ + (void)readAttributeAccessControlEntriesPerFabricWithClusterStateCache:(MTRClus NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AccessControl::Attributes::AccessControlEntriesPerFabric::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AccessControl::Attributes::AccessControlEntriesPerFabric::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -10808,7 +10885,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRAccessControlGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(AccessControlGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -10853,7 +10930,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRAccessControlAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(AccessControlAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -10896,7 +10973,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRAccessControlAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(AccessControlAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -10939,22 +11016,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AccessControl::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AccessControl::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -10982,22 +11060,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AccessControl::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AccessControl::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -11007,7 +11086,7 @@ @implementation MTRBaseClusterAccessControl (Deprecated) - (void)readAttributeAclWithParams:(MTRReadParams * _Nullable)params completionHandler:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completionHandler { - [self readAttributeAclWithParams:params + [self readAttributeACLWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. completionHandler(static_cast(value), error); @@ -11015,13 +11094,13 @@ - (void)readAttributeAclWithParams:(MTRReadParams * _Nullable)params } - (void)writeAttributeAclWithValue:(NSArray * _Nonnull)value completionHandler:(MTRStatusCompletion)completionHandler { - [self writeAttributeAclWithValue:value params:nil completion:completionHandler]; + [self writeAttributeACLWithValue:value params:nil completion:completionHandler]; } - (void)writeAttributeAclWithValue:(NSArray * _Nonnull)value params:(MTRWriteParams * _Nullable)params completionHandler:(MTRStatusCompletion)completionHandler { - [self writeAttributeAclWithValue:value params:params completion:completionHandler]; + [self writeAttributeACLWithValue:value params:params completion:completionHandler]; } - (void)subscribeAttributeAclWithMinInterval:(NSNumber * _Nonnull)minInterval maxInterval:(NSNumber * _Nonnull)maxInterval @@ -11036,7 +11115,7 @@ - (void)subscribeAttributeAclWithMinInterval:(NSNumber * _Nonnull)minInterval subscribeParams.minInterval = minInterval; subscribeParams.maxInterval = maxInterval; } - [self subscribeAttributeAclWithParams:subscribeParams + [self subscribeAttributeACLWithParams:subscribeParams subscriptionEstablished:subscriptionEstablishedHandler reportHandler:^(NSArray * _Nullable value, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. @@ -11048,7 +11127,7 @@ + (void)readAttributeAclWithAttributeCache:(MTRAttributeCacheContainer *)attribu queue:(dispatch_queue_t)queue completionHandler:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completionHandler { - [self readAttributeAclWithClusterStateCache:attributeCacheContainer.realContainer + [self readAttributeACLWithClusterStateCache:attributeCacheContainer.realContainer endpoint:endpoint queue:queue completion:^(NSArray * _Nullable value, NSError * _Nullable error) { @@ -11904,22 +11983,23 @@ + (void)readAttributeActionListWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRActionsActionListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(ActionsActionListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Actions::Attributes::ActionList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(ActionsActionListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Actions::Attributes::ActionList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeEndpointListsWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -11946,22 +12026,23 @@ + (void)readAttributeEndpointListsWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRActionsEndpointListsListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(ActionsEndpointListsListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Actions::Attributes::EndpointLists::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(ActionsEndpointListsListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Actions::Attributes::EndpointLists::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSetupURLWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -11988,22 +12069,23 @@ + (void)readAttributeSetupURLWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Actions::Attributes::SetupURL::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Actions::Attributes::SetupURL::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -12032,7 +12114,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRActionsGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ActionsGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -12077,7 +12159,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRActionsAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ActionsAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -12120,22 +12202,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRActionsAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(ActionsAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Actions::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(ActionsAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Actions::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -12162,22 +12245,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Actions::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Actions::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -12205,22 +12289,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Actions::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Actions::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -12710,22 +12795,23 @@ + (void)readAttributeDataModelRevisionWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::DataModelRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::DataModelRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeVendorNameWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -12752,22 +12838,23 @@ + (void)readAttributeVendorNameWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::VendorName::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::VendorName::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeVendorIDWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -12794,22 +12881,23 @@ + (void)readAttributeVendorIDWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRVendorIdAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(VendorIdAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::VendorID::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(VendorIdAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::VendorID::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeProductNameWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -12836,22 +12924,23 @@ + (void)readAttributeProductNameWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::ProductName::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::ProductName::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeProductIDWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -12878,22 +12967,23 @@ + (void)readAttributeProductIDWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::ProductID::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::ProductID::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNodeLabelWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -12957,22 +13047,23 @@ + (void)readAttributeNodeLabelWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::NodeLabel::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::NodeLabel::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLocationWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -13036,22 +13127,23 @@ + (void)readAttributeLocationWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::Location::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::Location::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeHardwareVersionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -13079,22 +13171,23 @@ + (void)readAttributeHardwareVersionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::HardwareVersion::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::HardwareVersion::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeHardwareVersionStringWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -13123,22 +13216,23 @@ + (void)readAttributeHardwareVersionStringWithClusterStateCache:(MTRClusterState (void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::HardwareVersionString::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::HardwareVersionString::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSoftwareVersionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -13166,22 +13260,23 @@ + (void)readAttributeSoftwareVersionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::SoftwareVersion::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::SoftwareVersion::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSoftwareVersionStringWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -13210,22 +13305,23 @@ + (void)readAttributeSoftwareVersionStringWithClusterStateCache:(MTRClusterState (void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::SoftwareVersionString::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::SoftwareVersionString::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeManufacturingDateWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -13253,22 +13349,23 @@ + (void)readAttributeManufacturingDateWithClusterStateCache:(MTRClusterStateCach (void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::ManufacturingDate::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::ManufacturingDate::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePartNumberWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -13295,22 +13392,23 @@ + (void)readAttributePartNumberWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::PartNumber::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::PartNumber::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeProductURLWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -13337,22 +13435,23 @@ + (void)readAttributeProductURLWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::ProductURL::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::ProductURL::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeProductLabelWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -13379,22 +13478,23 @@ + (void)readAttributeProductLabelWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::ProductLabel::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::ProductLabel::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSerialNumberWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -13421,22 +13521,23 @@ + (void)readAttributeSerialNumberWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::SerialNumber::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::SerialNumber::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLocalConfigDisabledWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -13502,22 +13603,23 @@ + (void)readAttributeLocalConfigDisabledWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::LocalConfigDisabled::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::LocalConfigDisabled::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeReachableWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -13544,22 +13646,23 @@ + (void)readAttributeReachableWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::Reachable::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::Reachable::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeUniqueIDWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -13586,22 +13689,23 @@ + (void)readAttributeUniqueIDWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::UniqueID::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::UniqueID::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCapabilityMinimaWithCompletion:(void (^)(MTRBasicClusterCapabilityMinimaStruct * _Nullable value, @@ -13632,22 +13736,23 @@ + (void)readAttributeCapabilityMinimaWithClusterStateCache:(MTRClusterStateCache NSError * _Nullable error))completion { auto * bridge = new MTRBasicCapabilityMinimaStructAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BasicCapabilityMinimaStructAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::CapabilityMinima::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(BasicCapabilityMinimaStructAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::CapabilityMinima::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -13676,22 +13781,23 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBasicGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BasicGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::GeneratedCommandList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(BasicGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::GeneratedCommandList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcceptedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -13720,22 +13826,23 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBasicAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BasicAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::AcceptedCommandList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(BasicAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::AcceptedCommandList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAttributeListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -13762,22 +13869,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBasicAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BasicAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BasicAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -13804,22 +13912,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -13847,22 +13956,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Basic::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Basic::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -15005,7 +15115,7 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device endpoint:(uint16 @end -@implementation MTRBaseClusterOtaSoftwareUpdateProvider +@implementation MTRBaseClusterOTASoftwareUpdateProvider - (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue { @@ -15020,17 +15130,17 @@ - (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)en return self; } -- (void)queryImageWithParams:(MTROtaSoftwareUpdateProviderClusterQueryImageParams *)params - completion:(void (^)(MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, +- (void)queryImageWithParams:(MTROTASoftwareUpdateProviderClusterQueryImageParams *)params + completion:(void (^)(MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error))completion { // Make a copy of params before we go async. params = [params copy]; - auto * bridge = new MTROtaSoftwareUpdateProviderClusterQueryImageResponseCallbackBridge(self.callbackQueue, completion, + auto * bridge = new MTROTASoftwareUpdateProviderClusterQueryImageResponseCallbackBridge(self.callbackQueue, completion, ^(ExchangeManager & exchangeManager, const SessionHandle & session, - OtaSoftwareUpdateProviderClusterQueryImageResponseCallbackType successCb, MTRErrorCallback failureCb, + OTASoftwareUpdateProviderClusterQueryImageResponseCallbackType successCb, MTRErrorCallback failureCb, MTRCallbackBridgeBase * bridge) { - auto * typedBridge = static_cast(bridge); + auto * typedBridge = static_cast(bridge); chip::Optional timedInvokeTimeoutMs; ListFreer listFreer; OtaSoftwareUpdateProvider::Commands::QueryImage::Type request; @@ -15088,17 +15198,17 @@ - (void)queryImageWithParams:(MTROtaSoftwareUpdateProviderClusterQueryImageParam std::move(*bridge).DispatchAction(self.device); } -- (void)applyUpdateRequestWithParams:(MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams *)params - completion:(void (^)(MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, +- (void)applyUpdateRequestWithParams:(MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams *)params + completion:(void (^)(MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, NSError * _Nullable error))completion { // Make a copy of params before we go async. params = [params copy]; - auto * bridge = new MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseCallbackBridge(self.callbackQueue, completion, + auto * bridge = new MTROTASoftwareUpdateProviderClusterApplyUpdateResponseCallbackBridge(self.callbackQueue, completion, ^(ExchangeManager & exchangeManager, const SessionHandle & session, - OtaSoftwareUpdateProviderClusterApplyUpdateResponseCallbackType successCb, MTRErrorCallback failureCb, + OTASoftwareUpdateProviderClusterApplyUpdateResponseCallbackType successCb, MTRErrorCallback failureCb, MTRCallbackBridgeBase * bridge) { - auto * typedBridge = static_cast(bridge); + auto * typedBridge = static_cast(bridge); chip::Optional timedInvokeTimeoutMs; ListFreer listFreer; OtaSoftwareUpdateProvider::Commands::ApplyUpdateRequest::Type request; @@ -15116,7 +15226,7 @@ - (void)applyUpdateRequestWithParams:(MTROtaSoftwareUpdateProviderClusterApplyUp std::move(*bridge).DispatchAction(self.device); } -- (void)notifyUpdateAppliedWithParams:(MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams *)params +- (void)notifyUpdateAppliedWithParams:(MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams *)params completion:(MTRStatusCompletion)completion { // Make a copy of params before we go async. @@ -15150,7 +15260,7 @@ - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nul { MTRReadParams * params = [[MTRReadParams alloc] init]; using TypeInfo = OtaSoftwareUpdateProvider::Attributes::GeneratedCommandList::TypeInfo; - return MTRReadAttribute( params, completion, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -15161,7 +15271,7 @@ - (void)subscribeAttributeGeneratedCommandListWithParams:(MTRSubscribeParams * _ (void (^)(NSArray * _Nullable value, NSError * _Nullable error))reportHandler { using TypeInfo = OtaSoftwareUpdateProvider::Attributes::GeneratedCommandList::TypeInfo; - MTRSubscribeAttribute(params, subscriptionEstablished, reportHandler, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -15172,9 +15282,9 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC completion: (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { - auto * bridge = new MTROtaSoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( - ^(OtaSoftwareUpdateProviderGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { + auto * bridge = new MTROTASoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge(queue, completion); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(OTASoftwareUpdateProviderGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; using TypeInfo = OtaSoftwareUpdateProvider::Attributes::GeneratedCommandList::TypeInfo; @@ -15196,7 +15306,7 @@ - (void)readAttributeAcceptedCommandListWithCompletion:(void (^)(NSArray * _Null { MTRReadParams * params = [[MTRReadParams alloc] init]; using TypeInfo = OtaSoftwareUpdateProvider::Attributes::AcceptedCommandList::TypeInfo; - return MTRReadAttribute( params, completion, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -15207,7 +15317,7 @@ - (void)subscribeAttributeAcceptedCommandListWithParams:(MTRSubscribeParams * _N (void (^)(NSArray * _Nullable value, NSError * _Nullable error))reportHandler { using TypeInfo = OtaSoftwareUpdateProvider::Attributes::AcceptedCommandList::TypeInfo; - MTRSubscribeAttribute(params, subscriptionEstablished, reportHandler, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -15218,9 +15328,9 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa completion: (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { - auto * bridge = new MTROtaSoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( - ^(OtaSoftwareUpdateProviderAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { + auto * bridge = new MTROTASoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge(queue, completion); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(OTASoftwareUpdateProviderAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; using TypeInfo = OtaSoftwareUpdateProvider::Attributes::AcceptedCommandList::TypeInfo; @@ -15242,7 +15352,7 @@ - (void)readAttributeAttributeListWithCompletion:(void (^)(NSArray * _Nullable v { MTRReadParams * params = [[MTRReadParams alloc] init]; using TypeInfo = OtaSoftwareUpdateProvider::Attributes::AttributeList::TypeInfo; - return MTRReadAttribute( + return MTRReadAttribute( params, completion, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -15251,7 +15361,7 @@ - (void)subscribeAttributeAttributeListWithParams:(MTRSubscribeParams * _Nonnull reportHandler:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))reportHandler { using TypeInfo = OtaSoftwareUpdateProvider::Attributes::AttributeList::TypeInfo; - MTRSubscribeAttribute(params, subscriptionEstablished, reportHandler, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -15261,9 +15371,9 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon queue:(dispatch_queue_t)queue completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { - auto * bridge = new MTROtaSoftwareUpdateProviderAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( - ^(OtaSoftwareUpdateProviderAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + auto * bridge = new MTROTASoftwareUpdateProviderAttributeListListAttributeCallbackBridge(queue, completion); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(OTASoftwareUpdateProviderAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; using TypeInfo = OtaSoftwareUpdateProvider::Attributes::AttributeList::TypeInfo; @@ -15305,22 +15415,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OtaSoftwareUpdateProvider::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OtaSoftwareUpdateProvider::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -15348,26 +15459,30 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OtaSoftwareUpdateProvider::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OtaSoftwareUpdateProvider::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end +@implementation MTRBaseClusterOtaSoftwareUpdateProvider +@end + @implementation MTRBaseClusterOtaSoftwareUpdateProvider (Deprecated) - (void)queryImageWithParams:(MTROtaSoftwareUpdateProviderClusterQueryImageParams *)params @@ -15376,7 +15491,7 @@ - (void)queryImageWithParams:(MTROtaSoftwareUpdateProviderClusterQueryImageParam { [self queryImageWithParams:params completion:^( - MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error) { + MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. completionHandler(static_cast(data), error); }]; @@ -15386,7 +15501,7 @@ - (void)applyUpdateRequestWithParams:(MTROtaSoftwareUpdateProviderClusterApplyUp NSError * _Nullable error))completionHandler { [self applyUpdateRequestWithParams:params - completion:^(MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, + completion:^(MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. completionHandler( @@ -15625,7 +15740,7 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device endpoint:(uint16 @end -@implementation MTRBaseClusterOtaSoftwareUpdateRequestor +@implementation MTRBaseClusterOTASoftwareUpdateRequestor - (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue { @@ -15640,7 +15755,7 @@ - (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)en return self; } -- (void)announceOtaProviderWithParams:(MTROtaSoftwareUpdateRequestorClusterAnnounceOtaProviderParams *)params +- (void)announceOtaProviderWithParams:(MTROTASoftwareUpdateRequestorClusterAnnounceOtaProviderParams *)params completion:(MTRStatusCompletion)completion { // Make a copy of params before we go async. @@ -15682,7 +15797,7 @@ - (void)readAttributeDefaultOtaProvidersWithParams:(MTRReadParams * _Nullable)pa { // Make a copy of params before we go async. params = [params copy]; using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::DefaultOtaProviders::TypeInfo; - return MTRReadAttribute( params, completion, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -15726,11 +15841,11 @@ - (void)writeAttributeDefaultOtaProvidersWithValue:(NSArray * _Nonnull)value } listFreer.add(listHolder_0); for (size_t i_0 = 0; i_0 < value.count; ++i_0) { - if (![value[i_0] isKindOfClass:[MTROtaSoftwareUpdateRequestorClusterProviderLocation class]]) { + if (![value[i_0] isKindOfClass:[MTROTASoftwareUpdateRequestorClusterProviderLocation class]]) { // Wrong kind of value. return CHIP_ERROR_INVALID_ARGUMENT; } - auto element_0 = (MTROtaSoftwareUpdateRequestorClusterProviderLocation *) value[i_0]; + auto element_0 = (MTROTASoftwareUpdateRequestorClusterProviderLocation *) value[i_0]; listHolder_0->mList[i_0].providerNodeID = element_0.providerNodeID.unsignedLongLongValue; listHolder_0->mList[i_0].endpoint = element_0.endpoint.unsignedShortValue; listHolder_0->mList[i_0].fabricIndex = element_0.fabricIndex.unsignedCharValue; @@ -15753,7 +15868,7 @@ - (void)subscribeAttributeDefaultOtaProvidersWithParams:(MTRSubscribeParams * _N (void (^)(NSArray * _Nullable value, NSError * _Nullable error))reportHandler { using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::DefaultOtaProviders::TypeInfo; - MTRSubscribeAttribute(params, subscriptionEstablished, reportHandler, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -15764,9 +15879,9 @@ + (void)readAttributeDefaultOtaProvidersWithClusterStateCache:(MTRClusterStateCa completion: (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { - auto * bridge = new MTROtaSoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( - ^(OtaSoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallback successCb, MTRErrorCallback failureCb) { + auto * bridge = new MTROTASoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge(queue, completion); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(OTASoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::DefaultOtaProviders::TypeInfo; @@ -15808,29 +15923,30 @@ + (void)readAttributeUpdatePossibleWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::UpdatePossible::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::UpdatePossible::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeUpdateStateWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { MTRReadParams * params = [[MTRReadParams alloc] init]; using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::UpdateState::TypeInfo; - return MTRReadAttribute( params, completion, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -15840,7 +15956,7 @@ - (void)subscribeAttributeUpdateStateWithParams:(MTRSubscribeParams * _Nonnull)p reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::UpdateState::TypeInfo; - MTRSubscribeAttribute(params, subscriptionEstablished, reportHandler, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -15850,9 +15966,9 @@ + (void)readAttributeUpdateStateWithClusterStateCache:(MTRClusterStateCacheConta queue:(dispatch_queue_t)queue completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { - auto * bridge = new MTROtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( - ^(OtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallback successCb, MTRErrorCallback failureCb) { + auto * bridge = new MTROTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge(queue, completion); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(OTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::UpdateState::TypeInfo; @@ -15896,29 +16012,30 @@ + (void)readAttributeUpdateStateProgressWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::UpdateStateProgress::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::UpdateStateProgress::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { MTRReadParams * params = [[MTRReadParams alloc] init]; using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::GeneratedCommandList::TypeInfo; - return MTRReadAttribute( params, completion, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -15929,7 +16046,7 @@ - (void)subscribeAttributeGeneratedCommandListWithParams:(MTRSubscribeParams * _ (void (^)(NSArray * _Nullable value, NSError * _Nullable error))reportHandler { using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::GeneratedCommandList::TypeInfo; - MTRSubscribeAttribute(params, subscriptionEstablished, reportHandler, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -15940,9 +16057,9 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC completion: (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { - auto * bridge = new MTROtaSoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( - ^(OtaSoftwareUpdateRequestorGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { + auto * bridge = new MTROTASoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge(queue, completion); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(OTASoftwareUpdateRequestorGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::GeneratedCommandList::TypeInfo; @@ -15964,7 +16081,7 @@ - (void)readAttributeAcceptedCommandListWithCompletion:(void (^)(NSArray * _Null { MTRReadParams * params = [[MTRReadParams alloc] init]; using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::AcceptedCommandList::TypeInfo; - return MTRReadAttribute( params, completion, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -15975,7 +16092,7 @@ - (void)subscribeAttributeAcceptedCommandListWithParams:(MTRSubscribeParams * _N (void (^)(NSArray * _Nullable value, NSError * _Nullable error))reportHandler { using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::AcceptedCommandList::TypeInfo; - MTRSubscribeAttribute(params, subscriptionEstablished, reportHandler, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -15986,9 +16103,9 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa completion: (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { - auto * bridge = new MTROtaSoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( - ^(OtaSoftwareUpdateRequestorAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { + auto * bridge = new MTROTASoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge(queue, completion); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(OTASoftwareUpdateRequestorAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::AcceptedCommandList::TypeInfo; @@ -16010,7 +16127,7 @@ - (void)readAttributeAttributeListWithCompletion:(void (^)(NSArray * _Nullable v { MTRReadParams * params = [[MTRReadParams alloc] init]; using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::AttributeList::TypeInfo; - return MTRReadAttribute( params, completion, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -16020,7 +16137,7 @@ - (void)subscribeAttributeAttributeListWithParams:(MTRSubscribeParams * _Nonnull reportHandler:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))reportHandler { using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::AttributeList::TypeInfo; - MTRSubscribeAttribute(params, subscriptionEstablished, reportHandler, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -16030,9 +16147,9 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon queue:(dispatch_queue_t)queue completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { - auto * bridge = new MTROtaSoftwareUpdateRequestorAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( - ^(OtaSoftwareUpdateRequestorAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + auto * bridge = new MTROTASoftwareUpdateRequestorAttributeListListAttributeCallbackBridge(queue, completion); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(OTASoftwareUpdateRequestorAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::AttributeList::TypeInfo; @@ -16074,22 +16191,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -16117,26 +16235,30 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OtaSoftwareUpdateRequestor::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end +@implementation MTRBaseClusterOtaSoftwareUpdateRequestor +@end + @implementation MTRBaseClusterOtaSoftwareUpdateRequestor (Deprecated) - (void)announceOtaProviderWithParams:(MTROtaSoftwareUpdateRequestorClusterAnnounceOtaProviderParams *)params @@ -16636,22 +16758,23 @@ + (void)readAttributeActiveLocaleWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LocalizationConfiguration::Attributes::ActiveLocale::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LocalizationConfiguration::Attributes::ActiveLocale::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSupportedLocalesWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -16680,7 +16803,7 @@ + (void)readAttributeSupportedLocalesWithClusterStateCache:(MTRClusterStateCache (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRLocalizationConfigurationSupportedLocalesListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(LocalizationConfigurationSupportedLocalesListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -16726,7 +16849,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRLocalizationConfigurationGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(LocalizationConfigurationGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -16772,7 +16895,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRLocalizationConfigurationAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(LocalizationConfigurationAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -16815,7 +16938,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRLocalizationConfigurationAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(LocalizationConfigurationAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -16858,22 +16981,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LocalizationConfiguration::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LocalizationConfiguration::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -16901,22 +17025,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LocalizationConfiguration::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LocalizationConfiguration::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -17322,7 +17447,7 @@ + (void)readAttributeHourFormatWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRTimeFormatLocalizationClusterHourFormatAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(TimeFormatLocalizationClusterHourFormatAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -17404,7 +17529,7 @@ + (void)readAttributeActiveCalendarTypeWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRTimeFormatLocalizationClusterCalendarTypeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(TimeFormatLocalizationClusterCalendarTypeAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -17450,7 +17575,7 @@ + (void)readAttributeSupportedCalendarTypesWithClusterStateCache:(MTRClusterStat (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRTimeFormatLocalizationSupportedCalendarTypesListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(TimeFormatLocalizationSupportedCalendarTypesListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -17496,7 +17621,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRTimeFormatLocalizationGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(TimeFormatLocalizationGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -17542,7 +17667,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRTimeFormatLocalizationAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(TimeFormatLocalizationAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -17585,7 +17710,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRTimeFormatLocalizationAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(TimeFormatLocalizationAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -17628,22 +17753,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = TimeFormatLocalization::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = TimeFormatLocalization::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -17671,22 +17797,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = TimeFormatLocalization::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = TimeFormatLocalization::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -18149,7 +18276,7 @@ + (void)readAttributeTemperatureUnitWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitLocalizationClusterTempUnitAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(UnitLocalizationClusterTempUnitAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -18194,7 +18321,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitLocalizationGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(UnitLocalizationGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -18239,7 +18366,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitLocalizationAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(UnitLocalizationAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -18282,7 +18409,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitLocalizationAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(UnitLocalizationAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -18325,22 +18452,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitLocalization::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitLocalization::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -18368,22 +18496,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitLocalization::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitLocalization::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -18709,7 +18838,7 @@ + (void)readAttributeSourcesWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPowerSourceConfigurationSourcesListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PowerSourceConfigurationSourcesListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -18755,7 +18884,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPowerSourceConfigurationGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PowerSourceConfigurationGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -18801,7 +18930,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPowerSourceConfigurationAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PowerSourceConfigurationAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -18844,7 +18973,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPowerSourceConfigurationAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PowerSourceConfigurationAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -18887,22 +19016,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSourceConfiguration::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSourceConfiguration::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -18930,22 +19060,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSourceConfiguration::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSourceConfiguration::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -19258,7 +19389,7 @@ + (void)readAttributeStatusWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPowerSourceClusterPowerSourceStatusAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PowerSourceClusterPowerSourceStatusAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -19301,22 +19432,23 @@ + (void)readAttributeOrderWithClusterStateCache:(MTRClusterStateCacheContainer * completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::Order::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::Order::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDescriptionWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -19343,22 +19475,23 @@ + (void)readAttributeDescriptionWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::Description::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::Description::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeWiredAssessedInputVoltageWithCompletion:(void (^)( @@ -19388,22 +19521,23 @@ + (void)readAttributeWiredAssessedInputVoltageWithClusterStateCache:(MTRClusterS NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::WiredAssessedInputVoltage::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::WiredAssessedInputVoltage::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeWiredAssessedInputFrequencyWithCompletion:(void (^)( @@ -19433,22 +19567,23 @@ + (void)readAttributeWiredAssessedInputFrequencyWithClusterStateCache:(MTRCluste NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::WiredAssessedInputFrequency::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::WiredAssessedInputFrequency::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeWiredCurrentTypeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -19476,7 +19611,7 @@ + (void)readAttributeWiredCurrentTypeWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPowerSourceClusterWiredCurrentTypeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PowerSourceClusterWiredCurrentTypeAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -19521,22 +19656,23 @@ + (void)readAttributeWiredAssessedCurrentWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::WiredAssessedCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::WiredAssessedCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeWiredNominalVoltageWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -19565,22 +19701,23 @@ + (void)readAttributeWiredNominalVoltageWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::WiredNominalVoltage::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::WiredNominalVoltage::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeWiredMaximumCurrentWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -19609,22 +19746,23 @@ + (void)readAttributeWiredMaximumCurrentWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::WiredMaximumCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::WiredMaximumCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeWiredPresentWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -19651,22 +19789,23 @@ + (void)readAttributeWiredPresentWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::WiredPresent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::WiredPresent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActiveWiredFaultsWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -19694,7 +19833,7 @@ + (void)readAttributeActiveWiredFaultsWithClusterStateCache:(MTRClusterStateCach (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPowerSourceActiveWiredFaultsListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PowerSourceActiveWiredFaultsListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -19737,22 +19876,23 @@ + (void)readAttributeBatVoltageWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::BatVoltage::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::BatVoltage::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBatPercentRemainingWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -19781,22 +19921,23 @@ + (void)readAttributeBatPercentRemainingWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::BatPercentRemaining::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::BatPercentRemaining::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBatTimeRemainingWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -19824,22 +19965,23 @@ + (void)readAttributeBatTimeRemainingWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::BatTimeRemaining::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::BatTimeRemaining::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBatChargeLevelWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -19866,7 +20008,7 @@ + (void)readAttributeBatChargeLevelWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPowerSourceClusterBatChargeLevelAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PowerSourceClusterBatChargeLevelAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -19911,22 +20053,23 @@ + (void)readAttributeBatReplacementNeededWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::BatReplacementNeeded::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::BatReplacementNeeded::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBatReplaceabilityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -19954,7 +20097,7 @@ + (void)readAttributeBatReplaceabilityWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPowerSourceClusterBatReplaceabilityAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PowerSourceClusterBatReplaceabilityAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -19997,22 +20140,23 @@ + (void)readAttributeBatPresentWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::BatPresent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::BatPresent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActiveBatFaultsWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -20039,7 +20183,7 @@ + (void)readAttributeActiveBatFaultsWithClusterStateCache:(MTRClusterStateCacheC completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPowerSourceActiveBatFaultsListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PowerSourceActiveBatFaultsListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -20085,22 +20229,23 @@ + (void)readAttributeBatReplacementDescriptionWithClusterStateCache:(MTRClusterS NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::BatReplacementDescription::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::BatReplacementDescription::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBatCommonDesignationWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -20129,22 +20274,23 @@ + (void)readAttributeBatCommonDesignationWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::BatCommonDesignation::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::BatCommonDesignation::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBatANSIDesignationWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -20173,22 +20319,23 @@ + (void)readAttributeBatANSIDesignationWithClusterStateCache:(MTRClusterStateCac (void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::BatANSIDesignation::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::BatANSIDesignation::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBatIECDesignationWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -20216,22 +20363,23 @@ + (void)readAttributeBatIECDesignationWithClusterStateCache:(MTRClusterStateCach (void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::BatIECDesignation::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::BatIECDesignation::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBatApprovedChemistryWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -20260,22 +20408,23 @@ + (void)readAttributeBatApprovedChemistryWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::BatApprovedChemistry::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::BatApprovedChemistry::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBatCapacityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -20302,22 +20451,23 @@ + (void)readAttributeBatCapacityWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::BatCapacity::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::BatCapacity::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBatQuantityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -20344,22 +20494,23 @@ + (void)readAttributeBatQuantityWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::BatQuantity::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::BatQuantity::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBatChargeStateWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -20386,7 +20537,7 @@ + (void)readAttributeBatChargeStateWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPowerSourceClusterBatChargeStateAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PowerSourceClusterBatChargeStateAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -20431,22 +20582,23 @@ + (void)readAttributeBatTimeToFullChargeWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::BatTimeToFullCharge::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::BatTimeToFullCharge::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBatFunctionalWhileChargingWithCompletion:(void (^)( @@ -20476,22 +20628,23 @@ + (void)readAttributeBatFunctionalWhileChargingWithClusterStateCache:(MTRCluster NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::BatFunctionalWhileCharging::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::BatFunctionalWhileCharging::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBatChargingCurrentWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -20520,22 +20673,23 @@ + (void)readAttributeBatChargingCurrentWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::BatChargingCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::BatChargingCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActiveBatChargeFaultsWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -20564,7 +20718,7 @@ + (void)readAttributeActiveBatChargeFaultsWithClusterStateCache:(MTRClusterState (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPowerSourceActiveBatChargeFaultsListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PowerSourceActiveBatChargeFaultsListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -20609,7 +20763,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPowerSourceGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PowerSourceGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -20654,7 +20808,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPowerSourceAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PowerSourceAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -20697,22 +20851,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPowerSourceAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(PowerSourceAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(PowerSourceAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -20739,22 +20894,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -20782,22 +20938,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PowerSource::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PowerSource::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -22564,22 +22721,23 @@ + (void)readAttributeBreadcrumbWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = GeneralCommissioning::Attributes::Breadcrumb::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = GeneralCommissioning::Attributes::Breadcrumb::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBasicCommissioningInfoWithCompletion: @@ -22614,7 +22772,7 @@ - (void)subscribeAttributeBasicCommissioningInfoWithParams:(MTRSubscribeParams * NSError * _Nullable error))completion { auto * bridge = new MTRGeneralCommissioningBasicCommissioningInfoStructAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GeneralCommissioningBasicCommissioningInfoStructAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -22659,7 +22817,7 @@ + (void)readAttributeRegulatoryConfigWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGeneralCommissioningClusterRegulatoryLocationTypeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GeneralCommissioningClusterRegulatoryLocationTypeAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -22705,7 +22863,7 @@ + (void)readAttributeLocationCapabilityWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGeneralCommissioningClusterRegulatoryLocationTypeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GeneralCommissioningClusterRegulatoryLocationTypeAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -22752,22 +22910,23 @@ + (void)readAttributeSupportsConcurrentConnectionWithClusterStateCache:(MTRClust NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = GeneralCommissioning::Attributes::SupportsConcurrentConnection::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = GeneralCommissioning::Attributes::SupportsConcurrentConnection::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -22797,7 +22956,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGeneralCommissioningGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GeneralCommissioningGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -22843,7 +23002,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGeneralCommissioningAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GeneralCommissioningAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -22886,7 +23045,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGeneralCommissioningAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GeneralCommissioningAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -22929,22 +23088,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = GeneralCommissioning::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = GeneralCommissioning::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -22972,22 +23132,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = GeneralCommissioning::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = GeneralCommissioning::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -23745,22 +23906,23 @@ + (void)readAttributeMaxNetworksWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = NetworkCommissioning::Attributes::MaxNetworks::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = NetworkCommissioning::Attributes::MaxNetworks::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNetworksWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -23787,7 +23949,7 @@ + (void)readAttributeNetworksWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNetworkCommissioningNetworksListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(NetworkCommissioningNetworksListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -23832,22 +23994,23 @@ + (void)readAttributeScanMaxTimeSecondsWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = NetworkCommissioning::Attributes::ScanMaxTimeSeconds::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = NetworkCommissioning::Attributes::ScanMaxTimeSeconds::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeConnectMaxTimeSecondsWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -23876,22 +24039,23 @@ + (void)readAttributeConnectMaxTimeSecondsWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = NetworkCommissioning::Attributes::ConnectMaxTimeSeconds::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = NetworkCommissioning::Attributes::ConnectMaxTimeSeconds::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInterfaceEnabledWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -23956,22 +24120,23 @@ + (void)readAttributeInterfaceEnabledWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = NetworkCommissioning::Attributes::InterfaceEnabled::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = NetworkCommissioning::Attributes::InterfaceEnabled::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLastNetworkingStatusWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -24001,7 +24166,7 @@ + (void)readAttributeLastNetworkingStatusWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableNetworkCommissioningClusterNetworkCommissioningStatusAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(NullableNetworkCommissioningClusterNetworkCommissioningStatusAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -24044,22 +24209,23 @@ + (void)readAttributeLastNetworkIDWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSData * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableOctetStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableOctetStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = NetworkCommissioning::Attributes::LastNetworkID::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableOctetStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = NetworkCommissioning::Attributes::LastNetworkID::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLastConnectErrorValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -24088,22 +24254,23 @@ + (void)readAttributeLastConnectErrorValueWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = NetworkCommissioning::Attributes::LastConnectErrorValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = NetworkCommissioning::Attributes::LastConnectErrorValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -24133,7 +24300,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNetworkCommissioningGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(NetworkCommissioningGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -24179,7 +24346,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNetworkCommissioningAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(NetworkCommissioningAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -24222,7 +24389,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNetworkCommissioningAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(NetworkCommissioningAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -24265,22 +24432,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = NetworkCommissioning::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = NetworkCommissioning::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -24308,22 +24476,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = NetworkCommissioning::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = NetworkCommissioning::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -25059,7 +25228,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDiagnosticLogsGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(DiagnosticLogsGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -25104,7 +25273,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDiagnosticLogsAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(DiagnosticLogsAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -25147,7 +25316,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDiagnosticLogsAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(DiagnosticLogsAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -25190,22 +25359,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DiagnosticLogs::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DiagnosticLogs::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -25233,22 +25403,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DiagnosticLogs::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DiagnosticLogs::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -25563,7 +25734,7 @@ + (void)readAttributeNetworkInterfacesWithClusterStateCache:(MTRClusterStateCach (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGeneralDiagnosticsNetworkInterfacesListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GeneralDiagnosticsNetworkInterfacesListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -25606,22 +25777,23 @@ + (void)readAttributeRebootCountWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = GeneralDiagnostics::Attributes::RebootCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = GeneralDiagnostics::Attributes::RebootCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeUpTimeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -25648,22 +25820,23 @@ + (void)readAttributeUpTimeWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = GeneralDiagnostics::Attributes::UpTime::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = GeneralDiagnostics::Attributes::UpTime::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTotalOperationalHoursWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -25692,22 +25865,23 @@ + (void)readAttributeTotalOperationalHoursWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = GeneralDiagnostics::Attributes::TotalOperationalHours::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = GeneralDiagnostics::Attributes::TotalOperationalHours::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBootReasonsWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -25734,22 +25908,23 @@ + (void)readAttributeBootReasonsWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = GeneralDiagnostics::Attributes::BootReasons::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = GeneralDiagnostics::Attributes::BootReasons::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActiveHardwareFaultsWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -25778,7 +25953,7 @@ + (void)readAttributeActiveHardwareFaultsWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGeneralDiagnosticsActiveHardwareFaultsListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GeneralDiagnosticsActiveHardwareFaultsListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -25822,7 +25997,7 @@ + (void)readAttributeActiveRadioFaultsWithClusterStateCache:(MTRClusterStateCach (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGeneralDiagnosticsActiveRadioFaultsListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GeneralDiagnosticsActiveRadioFaultsListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -25867,7 +26042,7 @@ + (void)readAttributeActiveNetworkFaultsWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGeneralDiagnosticsActiveNetworkFaultsListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GeneralDiagnosticsActiveNetworkFaultsListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -25913,22 +26088,23 @@ + (void)readAttributeTestEventTriggersEnabledWithClusterStateCache:(MTRClusterSt NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = GeneralDiagnostics::Attributes::TestEventTriggersEnabled::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = GeneralDiagnostics::Attributes::TestEventTriggersEnabled::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -25957,7 +26133,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGeneralDiagnosticsGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GeneralDiagnosticsGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -26002,7 +26178,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGeneralDiagnosticsAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GeneralDiagnosticsAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -26045,7 +26221,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGeneralDiagnosticsAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GeneralDiagnosticsAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -26088,22 +26264,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = GeneralDiagnostics::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = GeneralDiagnostics::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -26131,22 +26308,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = GeneralDiagnostics::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = GeneralDiagnostics::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -26851,7 +27029,7 @@ + (void)readAttributeThreadMetricsWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRSoftwareDiagnosticsThreadMetricsListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(SoftwareDiagnosticsThreadMetricsListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -26895,22 +27073,23 @@ + (void)readAttributeCurrentHeapFreeWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = SoftwareDiagnostics::Attributes::CurrentHeapFree::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = SoftwareDiagnostics::Attributes::CurrentHeapFree::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentHeapUsedWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -26938,22 +27117,23 @@ + (void)readAttributeCurrentHeapUsedWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = SoftwareDiagnostics::Attributes::CurrentHeapUsed::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = SoftwareDiagnostics::Attributes::CurrentHeapUsed::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentHeapHighWatermarkWithCompletion:(void (^)( @@ -26983,22 +27163,23 @@ + (void)readAttributeCurrentHeapHighWatermarkWithClusterStateCache:(MTRClusterSt NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = SoftwareDiagnostics::Attributes::CurrentHeapHighWatermark::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = SoftwareDiagnostics::Attributes::CurrentHeapHighWatermark::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -27028,7 +27209,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRSoftwareDiagnosticsGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(SoftwareDiagnosticsGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -27073,7 +27254,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRSoftwareDiagnosticsAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(SoftwareDiagnosticsAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -27116,7 +27297,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRSoftwareDiagnosticsAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(SoftwareDiagnosticsAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -27159,22 +27340,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = SoftwareDiagnostics::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = SoftwareDiagnostics::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -27202,22 +27384,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = SoftwareDiagnostics::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = SoftwareDiagnostics::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -27707,22 +27890,23 @@ + (void)readAttributeChannelWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::Channel::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::Channel::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRoutingRoleWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -27750,7 +27934,7 @@ + (void)readAttributeRoutingRoleWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableThreadNetworkDiagnosticsClusterRoutingRoleAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(NullableThreadNetworkDiagnosticsClusterRoutingRoleAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -27793,22 +27977,23 @@ + (void)readAttributeNetworkNameWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableCharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::NetworkName::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableCharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::NetworkName::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePanIdWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -27835,22 +28020,23 @@ + (void)readAttributePanIdWithClusterStateCache:(MTRClusterStateCacheContainer * completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::PanId::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::PanId::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeExtendedPanIdWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -27877,22 +28063,23 @@ + (void)readAttributeExtendedPanIdWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::ExtendedPanId::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::ExtendedPanId::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMeshLocalPrefixWithCompletion:(void (^)(NSData * _Nullable value, NSError * _Nullable error))completion @@ -27919,22 +28106,23 @@ + (void)readAttributeMeshLocalPrefixWithClusterStateCache:(MTRClusterStateCacheC completion:(void (^)(NSData * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableOctetStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableOctetStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::MeshLocalPrefix::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableOctetStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::MeshLocalPrefix::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOverrunCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -27961,22 +28149,23 @@ + (void)readAttributeOverrunCountWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::OverrunCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::OverrunCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNeighborTableListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -28005,7 +28194,7 @@ + (void)readAttributeNeighborTableListWithClusterStateCache:(MTRClusterStateCach (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRThreadNetworkDiagnosticsNeighborTableListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ThreadNetworkDiagnosticsNeighborTableListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -28048,7 +28237,7 @@ + (void)readAttributeRouteTableListWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRThreadNetworkDiagnosticsRouteTableListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ThreadNetworkDiagnosticsRouteTableListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -28091,22 +28280,23 @@ + (void)readAttributePartitionIdWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::PartitionId::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::PartitionId::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeWeightingWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28133,22 +28323,23 @@ + (void)readAttributeWeightingWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::Weighting::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::Weighting::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDataVersionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28175,22 +28366,23 @@ + (void)readAttributeDataVersionWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::DataVersion::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::DataVersion::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeStableDataVersionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28218,22 +28410,23 @@ + (void)readAttributeStableDataVersionWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::StableDataVersion::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::StableDataVersion::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLeaderRouterIdWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28260,22 +28453,23 @@ + (void)readAttributeLeaderRouterIdWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::LeaderRouterId::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::LeaderRouterId::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDetachedRoleCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28303,22 +28497,23 @@ + (void)readAttributeDetachedRoleCountWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::DetachedRoleCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::DetachedRoleCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeChildRoleCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28345,22 +28540,23 @@ + (void)readAttributeChildRoleCountWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::ChildRoleCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::ChildRoleCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRouterRoleCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28388,22 +28584,23 @@ + (void)readAttributeRouterRoleCountWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RouterRoleCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RouterRoleCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLeaderRoleCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28431,22 +28628,23 @@ + (void)readAttributeLeaderRoleCountWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::LeaderRoleCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::LeaderRoleCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAttachAttemptCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28475,22 +28673,23 @@ + (void)readAttributeAttachAttemptCountWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::AttachAttemptCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::AttachAttemptCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePartitionIdChangeCountWithCompletion:(void (^)( @@ -28520,22 +28719,23 @@ + (void)readAttributePartitionIdChangeCountWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::PartitionIdChangeCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::PartitionIdChangeCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBetterPartitionAttachAttemptCountWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -28567,22 +28767,23 @@ + (void)readAttributeBetterPartitionAttachAttemptCountWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::BetterPartitionAttachAttemptCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::BetterPartitionAttachAttemptCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeParentChangeCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28610,22 +28811,23 @@ + (void)readAttributeParentChangeCountWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::ParentChangeCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::ParentChangeCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxTotalCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28652,22 +28854,23 @@ + (void)readAttributeTxTotalCountWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxTotalCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxTotalCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxUnicastCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28694,22 +28897,23 @@ + (void)readAttributeTxUnicastCountWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxUnicastCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxUnicastCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxBroadcastCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28737,22 +28941,23 @@ + (void)readAttributeTxBroadcastCountWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxBroadcastCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxBroadcastCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxAckRequestedCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28781,22 +28986,23 @@ + (void)readAttributeTxAckRequestedCountWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxAckRequestedCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxAckRequestedCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxAckedCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28823,22 +29029,23 @@ + (void)readAttributeTxAckedCountWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxAckedCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxAckedCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxNoAckRequestedCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28867,22 +29074,23 @@ + (void)readAttributeTxNoAckRequestedCountWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxNoAckRequestedCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxNoAckRequestedCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxDataCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28909,22 +29117,23 @@ + (void)readAttributeTxDataCountWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxDataCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxDataCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxDataPollCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28952,22 +29161,23 @@ + (void)readAttributeTxDataPollCountWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxDataPollCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxDataPollCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxBeaconCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -28994,22 +29204,23 @@ + (void)readAttributeTxBeaconCountWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxBeaconCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxBeaconCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxBeaconRequestCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29038,22 +29249,23 @@ + (void)readAttributeTxBeaconRequestCountWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxBeaconRequestCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxBeaconRequestCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxOtherCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29080,22 +29292,23 @@ + (void)readAttributeTxOtherCountWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxOtherCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxOtherCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxRetryCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29122,22 +29335,23 @@ + (void)readAttributeTxRetryCountWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxRetryCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxRetryCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxDirectMaxRetryExpiryCountWithCompletion:(void (^)( @@ -29167,22 +29381,23 @@ + (void)readAttributeTxDirectMaxRetryExpiryCountWithClusterStateCache:(MTRCluste NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxDirectMaxRetryExpiryCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxDirectMaxRetryExpiryCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxIndirectMaxRetryExpiryCountWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -29213,22 +29428,23 @@ + (void)readAttributeTxIndirectMaxRetryExpiryCountWithClusterStateCache:(MTRClus NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxIndirectMaxRetryExpiryCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxIndirectMaxRetryExpiryCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxErrCcaCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29255,22 +29471,23 @@ + (void)readAttributeTxErrCcaCountWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxErrCcaCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxErrCcaCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxErrAbortCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29298,22 +29515,23 @@ + (void)readAttributeTxErrAbortCountWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxErrAbortCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxErrAbortCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxErrBusyChannelCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29342,22 +29560,23 @@ + (void)readAttributeTxErrBusyChannelCountWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxErrBusyChannelCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::TxErrBusyChannelCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxTotalCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29384,22 +29603,23 @@ + (void)readAttributeRxTotalCountWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxTotalCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxTotalCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxUnicastCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29426,22 +29646,23 @@ + (void)readAttributeRxUnicastCountWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxUnicastCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxUnicastCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxBroadcastCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29469,22 +29690,23 @@ + (void)readAttributeRxBroadcastCountWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxBroadcastCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxBroadcastCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxDataCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29511,22 +29733,23 @@ + (void)readAttributeRxDataCountWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxDataCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxDataCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxDataPollCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29554,22 +29777,23 @@ + (void)readAttributeRxDataPollCountWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxDataPollCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxDataPollCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxBeaconCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29596,22 +29820,23 @@ + (void)readAttributeRxBeaconCountWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxBeaconCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxBeaconCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxBeaconRequestCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29640,22 +29865,23 @@ + (void)readAttributeRxBeaconRequestCountWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxBeaconRequestCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxBeaconRequestCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxOtherCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29682,22 +29908,23 @@ + (void)readAttributeRxOtherCountWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxOtherCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxOtherCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxAddressFilteredCountWithCompletion:(void (^)( @@ -29727,22 +29954,23 @@ + (void)readAttributeRxAddressFilteredCountWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxAddressFilteredCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxAddressFilteredCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxDestAddrFilteredCountWithCompletion:(void (^)( @@ -29772,22 +30000,23 @@ + (void)readAttributeRxDestAddrFilteredCountWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxDestAddrFilteredCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxDestAddrFilteredCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxDuplicatedCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29815,22 +30044,23 @@ + (void)readAttributeRxDuplicatedCountWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxDuplicatedCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxDuplicatedCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxErrNoFrameCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29858,22 +30088,23 @@ + (void)readAttributeRxErrNoFrameCountWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxErrNoFrameCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxErrNoFrameCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxErrUnknownNeighborCountWithCompletion:(void (^)( @@ -29903,22 +30134,23 @@ + (void)readAttributeRxErrUnknownNeighborCountWithClusterStateCache:(MTRClusterS NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxErrUnknownNeighborCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxErrUnknownNeighborCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxErrInvalidSrcAddrCountWithCompletion:(void (^)( @@ -29948,22 +30180,23 @@ + (void)readAttributeRxErrInvalidSrcAddrCountWithClusterStateCache:(MTRClusterSt NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxErrInvalidSrcAddrCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxErrInvalidSrcAddrCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxErrSecCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -29990,22 +30223,23 @@ + (void)readAttributeRxErrSecCountWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxErrSecCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxErrSecCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxErrFcsCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -30032,22 +30266,23 @@ + (void)readAttributeRxErrFcsCountWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxErrFcsCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxErrFcsCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRxErrOtherCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -30075,22 +30310,23 @@ + (void)readAttributeRxErrOtherCountWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxErrOtherCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::RxErrOtherCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActiveTimestampWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -30118,22 +30354,23 @@ + (void)readAttributeActiveTimestampWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::ActiveTimestamp::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::ActiveTimestamp::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePendingTimestampWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -30161,22 +30398,23 @@ + (void)readAttributePendingTimestampWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::PendingTimestamp::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::PendingTimestamp::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDelayWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -30203,22 +30441,23 @@ + (void)readAttributeDelayWithClusterStateCache:(MTRClusterStateCacheContainer * completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::Delay::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::Delay::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSecurityPolicyWithCompletion:(void (^)(MTRThreadNetworkDiagnosticsClusterSecurityPolicy * _Nullable value, @@ -30250,7 +30489,7 @@ + (void)readAttributeSecurityPolicyWithClusterStateCache:(MTRClusterStateCacheCo NSError * _Nullable error))completion { auto * bridge = new MTRThreadNetworkDiagnosticsSecurityPolicyStructAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ThreadNetworkDiagnosticsSecurityPolicyStructAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -30293,22 +30532,23 @@ + (void)readAttributeChannelPage0MaskWithClusterStateCache:(MTRClusterStateCache completion:(void (^)(NSData * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableOctetStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableOctetStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::ChannelPage0Mask::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableOctetStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::ChannelPage0Mask::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOperationalDatasetComponentsWithCompletion: @@ -30346,7 +30586,7 @@ - (void)readAttributeOperationalDatasetComponentsWithCompletion: NSError * _Nullable error))completion { auto * bridge = new MTRThreadNetworkDiagnosticsOperationalDatasetComponentsStructAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ThreadNetworkDiagnosticsOperationalDatasetComponentsStructAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -30393,7 +30633,7 @@ + (void)readAttributeActiveNetworkFaultsListWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTRThreadNetworkDiagnosticsActiveNetworkFaultsListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ThreadNetworkDiagnosticsActiveNetworkFaultsListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -30439,7 +30679,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRThreadNetworkDiagnosticsGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ThreadNetworkDiagnosticsGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -30485,7 +30725,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRThreadNetworkDiagnosticsAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ThreadNetworkDiagnosticsAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -30528,7 +30768,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRThreadNetworkDiagnosticsAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ThreadNetworkDiagnosticsAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -30571,22 +30811,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -30614,22 +30855,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThreadNetworkDiagnostics::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThreadNetworkDiagnostics::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -33742,22 +33984,23 @@ + (void)readAttributeBssidWithClusterStateCache:(MTRClusterStateCacheContainer * completion:(void (^)(NSData * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableOctetStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableOctetStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WiFiNetworkDiagnostics::Attributes::Bssid::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableOctetStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WiFiNetworkDiagnostics::Attributes::Bssid::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSecurityTypeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -33785,7 +34028,7 @@ + (void)readAttributeSecurityTypeWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableWiFiNetworkDiagnosticsClusterSecurityTypeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(NullableWiFiNetworkDiagnosticsClusterSecurityTypeAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -33829,7 +34072,7 @@ + (void)readAttributeWiFiVersionWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableWiFiNetworkDiagnosticsClusterWiFiVersionTypeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(NullableWiFiNetworkDiagnosticsClusterWiFiVersionTypeAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -33872,22 +34115,23 @@ + (void)readAttributeChannelNumberWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WiFiNetworkDiagnostics::Attributes::ChannelNumber::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WiFiNetworkDiagnostics::Attributes::ChannelNumber::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRssiWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -33914,22 +34158,23 @@ + (void)readAttributeRssiWithClusterStateCache:(MTRClusterStateCacheContainer *) completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WiFiNetworkDiagnostics::Attributes::Rssi::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WiFiNetworkDiagnostics::Attributes::Rssi::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBeaconLostCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -33957,22 +34202,23 @@ + (void)readAttributeBeaconLostCountWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WiFiNetworkDiagnostics::Attributes::BeaconLostCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WiFiNetworkDiagnostics::Attributes::BeaconLostCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBeaconRxCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -33999,22 +34245,23 @@ + (void)readAttributeBeaconRxCountWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WiFiNetworkDiagnostics::Attributes::BeaconRxCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WiFiNetworkDiagnostics::Attributes::BeaconRxCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePacketMulticastRxCountWithCompletion:(void (^)( @@ -34044,22 +34291,23 @@ + (void)readAttributePacketMulticastRxCountWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WiFiNetworkDiagnostics::Attributes::PacketMulticastRxCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WiFiNetworkDiagnostics::Attributes::PacketMulticastRxCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePacketMulticastTxCountWithCompletion:(void (^)( @@ -34089,22 +34337,23 @@ + (void)readAttributePacketMulticastTxCountWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WiFiNetworkDiagnostics::Attributes::PacketMulticastTxCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WiFiNetworkDiagnostics::Attributes::PacketMulticastTxCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePacketUnicastRxCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -34133,22 +34382,23 @@ + (void)readAttributePacketUnicastRxCountWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WiFiNetworkDiagnostics::Attributes::PacketUnicastRxCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WiFiNetworkDiagnostics::Attributes::PacketUnicastRxCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePacketUnicastTxCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -34177,22 +34427,23 @@ + (void)readAttributePacketUnicastTxCountWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WiFiNetworkDiagnostics::Attributes::PacketUnicastTxCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WiFiNetworkDiagnostics::Attributes::PacketUnicastTxCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentMaxRateWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -34219,22 +34470,23 @@ + (void)readAttributeCurrentMaxRateWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WiFiNetworkDiagnostics::Attributes::CurrentMaxRate::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WiFiNetworkDiagnostics::Attributes::CurrentMaxRate::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOverrunCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -34261,22 +34513,23 @@ + (void)readAttributeOverrunCountWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WiFiNetworkDiagnostics::Attributes::OverrunCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WiFiNetworkDiagnostics::Attributes::OverrunCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -34306,7 +34559,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRWiFiNetworkDiagnosticsGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(WiFiNetworkDiagnosticsGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -34352,7 +34605,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRWiFiNetworkDiagnosticsAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(WiFiNetworkDiagnosticsAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -34395,7 +34648,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRWiFiNetworkDiagnosticsAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(WiFiNetworkDiagnosticsAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -34438,22 +34691,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WiFiNetworkDiagnostics::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WiFiNetworkDiagnostics::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -34481,22 +34735,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WiFiNetworkDiagnostics::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WiFiNetworkDiagnostics::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -35378,7 +35633,7 @@ + (void)readAttributePHYRateWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableEthernetNetworkDiagnosticsClusterPHYRateTypeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(NullableEthernetNetworkDiagnosticsClusterPHYRateTypeAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -35421,22 +35676,23 @@ + (void)readAttributeFullDuplexWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableBooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = EthernetNetworkDiagnostics::Attributes::FullDuplex::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableBooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = EthernetNetworkDiagnostics::Attributes::FullDuplex::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePacketRxCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -35463,22 +35719,23 @@ + (void)readAttributePacketRxCountWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = EthernetNetworkDiagnostics::Attributes::PacketRxCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = EthernetNetworkDiagnostics::Attributes::PacketRxCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePacketTxCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -35505,22 +35762,23 @@ + (void)readAttributePacketTxCountWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = EthernetNetworkDiagnostics::Attributes::PacketTxCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = EthernetNetworkDiagnostics::Attributes::PacketTxCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTxErrCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -35547,22 +35805,23 @@ + (void)readAttributeTxErrCountWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = EthernetNetworkDiagnostics::Attributes::TxErrCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = EthernetNetworkDiagnostics::Attributes::TxErrCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCollisionCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -35589,22 +35848,23 @@ + (void)readAttributeCollisionCountWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = EthernetNetworkDiagnostics::Attributes::CollisionCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = EthernetNetworkDiagnostics::Attributes::CollisionCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOverrunCountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -35631,22 +35891,23 @@ + (void)readAttributeOverrunCountWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = EthernetNetworkDiagnostics::Attributes::OverrunCount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = EthernetNetworkDiagnostics::Attributes::OverrunCount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCarrierDetectWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -35673,22 +35934,23 @@ + (void)readAttributeCarrierDetectWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableBooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = EthernetNetworkDiagnostics::Attributes::CarrierDetect::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableBooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = EthernetNetworkDiagnostics::Attributes::CarrierDetect::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTimeSinceResetWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -35715,22 +35977,23 @@ + (void)readAttributeTimeSinceResetWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = EthernetNetworkDiagnostics::Attributes::TimeSinceReset::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = EthernetNetworkDiagnostics::Attributes::TimeSinceReset::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -35760,7 +36023,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTREthernetNetworkDiagnosticsGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(EthernetNetworkDiagnosticsGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -35806,7 +36069,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTREthernetNetworkDiagnosticsAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(EthernetNetworkDiagnosticsAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -35850,7 +36113,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTREthernetNetworkDiagnosticsAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(EthernetNetworkDiagnosticsAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -35893,22 +36156,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = EthernetNetworkDiagnostics::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = EthernetNetworkDiagnostics::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -35936,22 +36200,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = EthernetNetworkDiagnostics::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = EthernetNetworkDiagnostics::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -36621,22 +36886,23 @@ + (void)readAttributeVendorNameWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::VendorName::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::VendorName::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeVendorIDWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -36663,22 +36929,23 @@ + (void)readAttributeVendorIDWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRVendorIdAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(VendorIdAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::VendorID::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(VendorIdAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::VendorID::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeProductNameWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -36705,22 +36972,23 @@ + (void)readAttributeProductNameWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::ProductName::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::ProductName::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNodeLabelWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -36784,22 +37052,23 @@ + (void)readAttributeNodeLabelWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::NodeLabel::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::NodeLabel::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeHardwareVersionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -36827,22 +37096,23 @@ + (void)readAttributeHardwareVersionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::HardwareVersion::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::HardwareVersion::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeHardwareVersionStringWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -36871,22 +37141,23 @@ + (void)readAttributeHardwareVersionStringWithClusterStateCache:(MTRClusterState (void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::HardwareVersionString::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::HardwareVersionString::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSoftwareVersionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -36914,22 +37185,23 @@ + (void)readAttributeSoftwareVersionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::SoftwareVersion::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::SoftwareVersion::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSoftwareVersionStringWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -36958,22 +37230,23 @@ + (void)readAttributeSoftwareVersionStringWithClusterStateCache:(MTRClusterState (void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::SoftwareVersionString::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::SoftwareVersionString::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeManufacturingDateWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -37001,22 +37274,23 @@ + (void)readAttributeManufacturingDateWithClusterStateCache:(MTRClusterStateCach (void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::ManufacturingDate::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::ManufacturingDate::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePartNumberWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -37043,22 +37317,23 @@ + (void)readAttributePartNumberWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::PartNumber::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::PartNumber::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeProductURLWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -37085,22 +37360,23 @@ + (void)readAttributeProductURLWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::ProductURL::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::ProductURL::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeProductLabelWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -37127,22 +37403,23 @@ + (void)readAttributeProductLabelWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::ProductLabel::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::ProductLabel::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSerialNumberWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -37169,22 +37446,23 @@ + (void)readAttributeSerialNumberWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::SerialNumber::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::SerialNumber::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeReachableWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -37211,22 +37489,23 @@ + (void)readAttributeReachableWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::Reachable::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::Reachable::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeUniqueIDWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -37253,22 +37532,23 @@ + (void)readAttributeUniqueIDWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::UniqueID::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::UniqueID::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -37297,7 +37577,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBridgedDeviceBasicGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BridgedDeviceBasicGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -37342,7 +37622,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBridgedDeviceBasicAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BridgedDeviceBasicAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -37385,7 +37665,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBridgedDeviceBasicAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BridgedDeviceBasicAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -37428,22 +37708,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -37471,22 +37752,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BridgedDeviceBasic::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BridgedDeviceBasic::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -38415,22 +38697,23 @@ + (void)readAttributeNumberOfPositionsWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Switch::Attributes::NumberOfPositions::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Switch::Attributes::NumberOfPositions::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentPositionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -38458,22 +38741,23 @@ + (void)readAttributeCurrentPositionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Switch::Attributes::CurrentPosition::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Switch::Attributes::CurrentPosition::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMultiPressMaxWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -38500,22 +38784,23 @@ + (void)readAttributeMultiPressMaxWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Switch::Attributes::MultiPressMax::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Switch::Attributes::MultiPressMax::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -38544,7 +38829,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRSwitchGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(SwitchGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -38589,22 +38874,23 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRSwitchAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(SwitchAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Switch::Attributes::AcceptedCommandList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(SwitchAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Switch::Attributes::AcceptedCommandList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAttributeListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -38631,22 +38917,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRSwitchAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(SwitchAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Switch::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(SwitchAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Switch::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -38673,22 +38960,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Switch::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Switch::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -38716,22 +39004,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Switch::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Switch::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -39240,7 +39529,7 @@ + (void)readAttributeWindowStatusWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRAdministratorCommissioningClusterCommissioningWindowStatusAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(AdministratorCommissioningClusterCommissioningWindowStatusAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -39284,22 +39573,23 @@ + (void)readAttributeAdminFabricIndexWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AdministratorCommissioning::Attributes::AdminFabricIndex::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AdministratorCommissioning::Attributes::AdminFabricIndex::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAdminVendorIdWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -39326,22 +39616,23 @@ + (void)readAttributeAdminVendorIdWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AdministratorCommissioning::Attributes::AdminVendorId::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AdministratorCommissioning::Attributes::AdminVendorId::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -39371,7 +39662,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRAdministratorCommissioningGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(AdministratorCommissioningGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -39417,7 +39708,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRAdministratorCommissioningAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(AdministratorCommissioningAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -39461,7 +39752,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRAdministratorCommissioningAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(AdministratorCommissioningAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -39504,22 +39795,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AdministratorCommissioning::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AdministratorCommissioning::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -39547,22 +39839,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AdministratorCommissioning::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AdministratorCommissioning::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -40220,7 +40513,7 @@ + (void)readAttributeNOCsWithClusterStateCache:(MTRClusterStateCacheContainer *) completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROperationalCredentialsNOCsListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(OperationalCredentialsNOCsListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -40264,7 +40557,7 @@ + (void)readAttributeFabricsWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROperationalCredentialsFabricsListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(OperationalCredentialsFabricsListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -40308,22 +40601,23 @@ + (void)readAttributeSupportedFabricsWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OperationalCredentials::Attributes::SupportedFabrics::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OperationalCredentials::Attributes::SupportedFabrics::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCommissionedFabricsWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -40352,22 +40646,23 @@ + (void)readAttributeCommissionedFabricsWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OperationalCredentials::Attributes::CommissionedFabrics::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OperationalCredentials::Attributes::CommissionedFabrics::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTrustedRootCertificatesWithCompletion:(void (^)( @@ -40398,7 +40693,7 @@ + (void)readAttributeTrustedRootCertificatesWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTROperationalCredentialsTrustedRootCertificatesListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(OperationalCredentialsTrustedRootCertificatesListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -40443,22 +40738,23 @@ + (void)readAttributeCurrentFabricIndexWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OperationalCredentials::Attributes::CurrentFabricIndex::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OperationalCredentials::Attributes::CurrentFabricIndex::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -40488,7 +40784,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROperationalCredentialsGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(OperationalCredentialsGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -40534,7 +40830,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROperationalCredentialsAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(OperationalCredentialsAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -40577,7 +40873,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROperationalCredentialsAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(OperationalCredentialsAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -40620,22 +40916,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OperationalCredentials::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OperationalCredentials::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -40663,22 +40960,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OperationalCredentials::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OperationalCredentials::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -41528,7 +41826,7 @@ + (void)readAttributeGroupKeyMapWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGroupKeyManagementGroupKeyMapListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GroupKeyManagementGroupKeyMapListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -41572,7 +41870,7 @@ + (void)readAttributeGroupTableWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGroupKeyManagementGroupTableListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GroupKeyManagementGroupTableListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -41617,22 +41915,23 @@ + (void)readAttributeMaxGroupsPerFabricWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = GroupKeyManagement::Attributes::MaxGroupsPerFabric::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = GroupKeyManagement::Attributes::MaxGroupsPerFabric::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxGroupKeysPerFabricWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -41661,22 +41960,23 @@ + (void)readAttributeMaxGroupKeysPerFabricWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = GroupKeyManagement::Attributes::MaxGroupKeysPerFabric::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = GroupKeyManagement::Attributes::MaxGroupKeysPerFabric::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -41705,7 +42005,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGroupKeyManagementGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GroupKeyManagementGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -41750,7 +42050,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGroupKeyManagementAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GroupKeyManagementAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -41793,7 +42093,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRGroupKeyManagementAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(GroupKeyManagementAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -41836,22 +42136,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = GroupKeyManagement::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = GroupKeyManagement::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -41879,22 +42180,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = GroupKeyManagement::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = GroupKeyManagement::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -42385,22 +42687,23 @@ + (void)readAttributeLabelListWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRFixedLabelLabelListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(FixedLabelLabelListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FixedLabel::Attributes::LabelList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(FixedLabelLabelListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FixedLabel::Attributes::LabelList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -42429,7 +42732,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRFixedLabelGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(FixedLabelGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -42474,7 +42777,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRFixedLabelAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(FixedLabelAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -42517,22 +42820,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRFixedLabelAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(FixedLabelAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FixedLabel::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(FixedLabelAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FixedLabel::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -42559,22 +42863,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FixedLabel::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FixedLabel::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -42602,22 +42907,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FixedLabel::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FixedLabel::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -42990,22 +43296,23 @@ + (void)readAttributeLabelListWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUserLabelLabelListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(UserLabelLabelListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UserLabel::Attributes::LabelList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(UserLabelLabelListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UserLabel::Attributes::LabelList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -43034,7 +43341,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUserLabelGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(UserLabelGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -43079,7 +43386,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUserLabelAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(UserLabelAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -43122,22 +43429,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUserLabelAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(UserLabelAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UserLabel::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(UserLabelAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UserLabel::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -43164,22 +43472,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UserLabel::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UserLabel::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -43207,22 +43516,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UserLabel::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UserLabel::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -43546,22 +43856,23 @@ + (void)readAttributeStateValueWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BooleanState::Attributes::StateValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BooleanState::Attributes::StateValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -43590,7 +43901,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanStateGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BooleanStateGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -43635,7 +43946,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanStateAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BooleanStateAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -43678,22 +43989,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanStateAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanStateAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BooleanState::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(BooleanStateAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BooleanState::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -43720,22 +44032,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BooleanState::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BooleanState::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -43763,22 +44076,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BooleanState::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BooleanState::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -44120,22 +44434,23 @@ + (void)readAttributeDescriptionWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ModeSelect::Attributes::Description::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ModeSelect::Attributes::Description::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeStandardNamespaceWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -44163,22 +44478,23 @@ + (void)readAttributeStandardNamespaceWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ModeSelect::Attributes::StandardNamespace::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ModeSelect::Attributes::StandardNamespace::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSupportedModesWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -44205,22 +44521,23 @@ + (void)readAttributeSupportedModesWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRModeSelectSupportedModesListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(ModeSelectSupportedModesListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ModeSelect::Attributes::SupportedModes::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(ModeSelectSupportedModesListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ModeSelect::Attributes::SupportedModes::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentModeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -44247,22 +44564,23 @@ + (void)readAttributeCurrentModeWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ModeSelect::Attributes::CurrentMode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ModeSelect::Attributes::CurrentMode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeStartUpModeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -44331,22 +44649,23 @@ + (void)readAttributeStartUpModeWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ModeSelect::Attributes::StartUpMode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ModeSelect::Attributes::StartUpMode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOnModeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -44415,22 +44734,23 @@ + (void)readAttributeOnModeWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ModeSelect::Attributes::OnMode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ModeSelect::Attributes::OnMode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -44459,7 +44779,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRModeSelectGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ModeSelectGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -44504,7 +44824,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRModeSelectAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ModeSelectAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -44547,22 +44867,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRModeSelectAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(ModeSelectAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ModeSelect::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(ModeSelectAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ModeSelect::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -44589,22 +44910,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ModeSelect::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ModeSelect::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -44632,22 +44954,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ModeSelect::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ModeSelect::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -45822,7 +46145,7 @@ + (void)readAttributeLockStateWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableDoorLockClusterDlLockStateAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(NullableDoorLockClusterDlLockStateAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -45865,22 +46188,23 @@ + (void)readAttributeLockTypeWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDoorLockClusterDlLockTypeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(DoorLockClusterDlLockTypeAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::LockType::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(DoorLockClusterDlLockTypeAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::LockType::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActuatorEnabledWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -45908,22 +46232,23 @@ + (void)readAttributeActuatorEnabledWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::ActuatorEnabled::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::ActuatorEnabled::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDoorStateWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -45950,7 +46275,7 @@ + (void)readAttributeDoorStateWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableDoorLockClusterDlDoorStateAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(NullableDoorLockClusterDlDoorStateAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -46030,22 +46355,23 @@ + (void)readAttributeDoorOpenEventsWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::DoorOpenEvents::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::DoorOpenEvents::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDoorClosedEventsWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -46110,22 +46436,23 @@ + (void)readAttributeDoorClosedEventsWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::DoorClosedEvents::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::DoorClosedEvents::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOpenPeriodWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -46189,22 +46516,23 @@ + (void)readAttributeOpenPeriodWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::OpenPeriod::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::OpenPeriod::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNumberOfTotalUsersSupportedWithCompletion:(void (^)( @@ -46234,22 +46562,23 @@ + (void)readAttributeNumberOfTotalUsersSupportedWithClusterStateCache:(MTRCluste NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::NumberOfTotalUsersSupported::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::NumberOfTotalUsersSupported::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNumberOfPINUsersSupportedWithCompletion:(void (^)( @@ -46279,22 +46608,23 @@ + (void)readAttributeNumberOfPINUsersSupportedWithClusterStateCache:(MTRClusterS NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::NumberOfPINUsersSupported::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::NumberOfPINUsersSupported::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNumberOfRFIDUsersSupportedWithCompletion:(void (^)( @@ -46324,22 +46654,23 @@ + (void)readAttributeNumberOfRFIDUsersSupportedWithClusterStateCache:(MTRCluster NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::NumberOfRFIDUsersSupported::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::NumberOfRFIDUsersSupported::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNumberOfWeekDaySchedulesSupportedPerUserWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -46371,22 +46702,23 @@ + (void)readAttributeNumberOfWeekDaySchedulesSupportedPerUserWithClusterStateCac NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::NumberOfWeekDaySchedulesSupportedPerUser::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::NumberOfWeekDaySchedulesSupportedPerUser::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNumberOfYearDaySchedulesSupportedPerUserWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -46418,22 +46750,23 @@ + (void)readAttributeNumberOfYearDaySchedulesSupportedPerUserWithClusterStateCac NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::NumberOfYearDaySchedulesSupportedPerUser::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::NumberOfYearDaySchedulesSupportedPerUser::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNumberOfHolidaySchedulesSupportedWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -46465,22 +46798,23 @@ + (void)readAttributeNumberOfHolidaySchedulesSupportedWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::NumberOfHolidaySchedulesSupported::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::NumberOfHolidaySchedulesSupported::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxPINCodeLengthWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -46508,22 +46842,23 @@ + (void)readAttributeMaxPINCodeLengthWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::MaxPINCodeLength::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::MaxPINCodeLength::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinPINCodeLengthWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -46551,22 +46886,23 @@ + (void)readAttributeMinPINCodeLengthWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::MinPINCodeLength::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::MinPINCodeLength::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxRFIDCodeLengthWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -46594,22 +46930,23 @@ + (void)readAttributeMaxRFIDCodeLengthWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::MaxRFIDCodeLength::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::MaxRFIDCodeLength::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinRFIDCodeLengthWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -46637,22 +46974,23 @@ + (void)readAttributeMinRFIDCodeLengthWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::MinRFIDCodeLength::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::MinRFIDCodeLength::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCredentialRulesSupportWithCompletion:(void (^)( @@ -46682,7 +47020,7 @@ + (void)readAttributeCredentialRulesSupportWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRDoorLockCredentialRulesSupportAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(DoorLockCredentialRulesSupportAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -46730,22 +47068,23 @@ + (void)readAttributeNumberOfCredentialsSupportedPerUserWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::NumberOfCredentialsSupportedPerUser::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::NumberOfCredentialsSupportedPerUser::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLanguageWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -46809,22 +47148,23 @@ + (void)readAttributeLanguageWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::Language::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::Language::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLEDSettingsWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -46888,22 +47228,23 @@ + (void)readAttributeLEDSettingsWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::LEDSettings::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::LEDSettings::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAutoRelockTimeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -46967,22 +47308,23 @@ + (void)readAttributeAutoRelockTimeWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::AutoRelockTime::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::AutoRelockTime::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSoundVolumeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -47046,22 +47388,23 @@ + (void)readAttributeSoundVolumeWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::SoundVolume::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::SoundVolume::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOperatingModeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -47125,7 +47468,7 @@ + (void)readAttributeOperatingModeWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDoorLockClusterDlOperatingModeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(DoorLockClusterDlOperatingModeAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -47171,7 +47514,7 @@ + (void)readAttributeSupportedOperatingModesWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTRDoorLockSupportedOperatingModesAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(DoorLockSupportedOperatingModesAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -47218,7 +47561,7 @@ + (void)readAttributeDefaultConfigurationRegisterWithClusterStateCache:(MTRClust NSError * _Nullable error))completion { auto * bridge = new MTRDoorLockDefaultConfigurationRegisterAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(DoorLockDefaultConfigurationRegisterAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -47301,22 +47644,23 @@ + (void)readAttributeEnableLocalProgrammingWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::EnableLocalProgramming::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::EnableLocalProgramming::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeEnableOneTouchLockingWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -47382,22 +47726,23 @@ + (void)readAttributeEnableOneTouchLockingWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::EnableOneTouchLocking::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::EnableOneTouchLocking::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeEnableInsideStatusLEDWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -47463,22 +47808,23 @@ + (void)readAttributeEnableInsideStatusLEDWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::EnableInsideStatusLED::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::EnableInsideStatusLED::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeEnablePrivacyModeButtonWithCompletion:(void (^)( @@ -47545,22 +47891,23 @@ + (void)readAttributeEnablePrivacyModeButtonWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::EnablePrivacyModeButton::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::EnablePrivacyModeButton::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLocalProgrammingFeaturesWithCompletion:(void (^)( @@ -47627,7 +47974,7 @@ + (void)readAttributeLocalProgrammingFeaturesWithClusterStateCache:(MTRClusterSt NSError * _Nullable error))completion { auto * bridge = new MTRDoorLockLocalProgrammingFeaturesAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(DoorLockLocalProgrammingFeaturesAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -47709,22 +48056,23 @@ + (void)readAttributeWrongCodeEntryLimitWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::WrongCodeEntryLimit::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::WrongCodeEntryLimit::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeUserCodeTemporaryDisableTimeWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -47792,22 +48140,23 @@ + (void)readAttributeUserCodeTemporaryDisableTimeWithClusterStateCache:(MTRClust NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::UserCodeTemporaryDisableTime::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::UserCodeTemporaryDisableTime::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSendPINOverTheAirWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -47872,22 +48221,23 @@ + (void)readAttributeSendPINOverTheAirWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::SendPINOverTheAir::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::SendPINOverTheAir::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRequirePINforRemoteOperationWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -47955,22 +48305,23 @@ + (void)readAttributeRequirePINforRemoteOperationWithClusterStateCache:(MTRClust NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::RequirePINforRemoteOperation::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::RequirePINforRemoteOperation::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeExpiringUserTimeoutWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -48036,22 +48387,23 @@ + (void)readAttributeExpiringUserTimeoutWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::ExpiringUserTimeout::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::ExpiringUserTimeout::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -48080,7 +48432,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDoorLockGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(DoorLockGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -48125,7 +48477,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDoorLockAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(DoorLockAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -48168,22 +48520,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDoorLockAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(DoorLockAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(DoorLockAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -48210,22 +48563,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -48253,22 +48607,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -50669,22 +51024,23 @@ + (void)readAttributeTypeWithClusterStateCache:(MTRClusterStateCacheContainer *) completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRWindowCoveringClusterTypeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(WindowCoveringClusterTypeAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::Type::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(WindowCoveringClusterTypeAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::Type::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePhysicalClosedLimitLiftWithCompletion:(void (^)( @@ -50714,22 +51070,23 @@ + (void)readAttributePhysicalClosedLimitLiftWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::PhysicalClosedLimitLift::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::PhysicalClosedLimitLift::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePhysicalClosedLimitTiltWithCompletion:(void (^)( @@ -50759,22 +51116,23 @@ + (void)readAttributePhysicalClosedLimitTiltWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::PhysicalClosedLimitTilt::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::PhysicalClosedLimitTilt::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentPositionLiftWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -50803,22 +51161,23 @@ + (void)readAttributeCurrentPositionLiftWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::CurrentPositionLift::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::CurrentPositionLift::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentPositionTiltWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -50847,22 +51206,23 @@ + (void)readAttributeCurrentPositionTiltWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::CurrentPositionTilt::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::CurrentPositionTilt::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNumberOfActuationsLiftWithCompletion:(void (^)( @@ -50892,22 +51252,23 @@ + (void)readAttributeNumberOfActuationsLiftWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::NumberOfActuationsLift::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::NumberOfActuationsLift::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNumberOfActuationsTiltWithCompletion:(void (^)( @@ -50937,22 +51298,23 @@ + (void)readAttributeNumberOfActuationsTiltWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::NumberOfActuationsTilt::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::NumberOfActuationsTilt::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeConfigStatusWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -50979,22 +51341,23 @@ + (void)readAttributeConfigStatusWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRWindowCoveringConfigStatusAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(WindowCoveringConfigStatusAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::ConfigStatus::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(WindowCoveringConfigStatusAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::ConfigStatus::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentPositionLiftPercentageWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -51025,22 +51388,23 @@ + (void)readAttributeCurrentPositionLiftPercentageWithClusterStateCache:(MTRClus NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::CurrentPositionLiftPercentage::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::CurrentPositionLiftPercentage::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentPositionTiltPercentageWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -51071,22 +51435,23 @@ + (void)readAttributeCurrentPositionTiltPercentageWithClusterStateCache:(MTRClus NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::CurrentPositionTiltPercentage::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::CurrentPositionTiltPercentage::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOperationalStatusWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -51114,7 +51479,7 @@ + (void)readAttributeOperationalStatusWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRWindowCoveringOperationalStatusAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(WindowCoveringOperationalStatusAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -51162,22 +51527,23 @@ + (void)readAttributeTargetPositionLiftPercent100thsWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::TargetPositionLiftPercent100ths::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::TargetPositionLiftPercent100ths::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTargetPositionTiltPercent100thsWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -51209,22 +51575,23 @@ + (void)readAttributeTargetPositionTiltPercent100thsWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::TargetPositionTiltPercent100ths::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::TargetPositionTiltPercent100ths::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeEndProductTypeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -51251,7 +51618,7 @@ + (void)readAttributeEndProductTypeWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRWindowCoveringClusterEndProductTypeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(WindowCoveringClusterEndProductTypeAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -51299,22 +51666,23 @@ + (void)readAttributeCurrentPositionLiftPercent100thsWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::CurrentPositionLiftPercent100ths::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::CurrentPositionLiftPercent100ths::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentPositionTiltPercent100thsWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -51346,22 +51714,23 @@ + (void)readAttributeCurrentPositionTiltPercent100thsWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::CurrentPositionTiltPercent100ths::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::CurrentPositionTiltPercent100ths::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInstalledOpenLimitLiftWithCompletion:(void (^)( @@ -51391,22 +51760,23 @@ + (void)readAttributeInstalledOpenLimitLiftWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::InstalledOpenLimitLift::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::InstalledOpenLimitLift::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInstalledClosedLimitLiftWithCompletion:(void (^)( @@ -51436,22 +51806,23 @@ + (void)readAttributeInstalledClosedLimitLiftWithClusterStateCache:(MTRClusterSt NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::InstalledClosedLimitLift::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::InstalledClosedLimitLift::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInstalledOpenLimitTiltWithCompletion:(void (^)( @@ -51481,22 +51852,23 @@ + (void)readAttributeInstalledOpenLimitTiltWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::InstalledOpenLimitTilt::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::InstalledOpenLimitTilt::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInstalledClosedLimitTiltWithCompletion:(void (^)( @@ -51526,22 +51898,23 @@ + (void)readAttributeInstalledClosedLimitTiltWithClusterStateCache:(MTRClusterSt NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::InstalledClosedLimitTilt::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::InstalledClosedLimitTilt::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeModeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -51605,22 +51978,23 @@ + (void)readAttributeModeWithClusterStateCache:(MTRClusterStateCacheContainer *) completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRWindowCoveringModeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(WindowCoveringModeAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::Mode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(WindowCoveringModeAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::Mode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSafetyStatusWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -51647,22 +52021,23 @@ + (void)readAttributeSafetyStatusWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRWindowCoveringSafetyStatusAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(WindowCoveringSafetyStatusAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::SafetyStatus::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(WindowCoveringSafetyStatusAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::SafetyStatus::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -51691,7 +52066,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRWindowCoveringGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(WindowCoveringGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -51736,7 +52111,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRWindowCoveringAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(WindowCoveringAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -51779,7 +52154,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRWindowCoveringAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(WindowCoveringAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -51822,22 +52197,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -51865,22 +52241,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WindowCovering::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WindowCovering::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -53254,22 +53631,23 @@ + (void)readAttributeBarrierMovingStateWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BarrierControl::Attributes::BarrierMovingState::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BarrierControl::Attributes::BarrierMovingState::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBarrierSafetyStatusWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -53298,22 +53676,23 @@ + (void)readAttributeBarrierSafetyStatusWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BarrierControl::Attributes::BarrierSafetyStatus::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BarrierControl::Attributes::BarrierSafetyStatus::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBarrierCapabilitiesWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -53342,22 +53721,23 @@ + (void)readAttributeBarrierCapabilitiesWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BarrierControl::Attributes::BarrierCapabilities::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BarrierControl::Attributes::BarrierCapabilities::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBarrierOpenEventsWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -53422,22 +53802,23 @@ + (void)readAttributeBarrierOpenEventsWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BarrierControl::Attributes::BarrierOpenEvents::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BarrierControl::Attributes::BarrierOpenEvents::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBarrierCloseEventsWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -53503,22 +53884,23 @@ + (void)readAttributeBarrierCloseEventsWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BarrierControl::Attributes::BarrierCloseEvents::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BarrierControl::Attributes::BarrierCloseEvents::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBarrierCommandOpenEventsWithCompletion:(void (^)( @@ -53585,22 +53967,23 @@ + (void)readAttributeBarrierCommandOpenEventsWithClusterStateCache:(MTRClusterSt NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BarrierControl::Attributes::BarrierCommandOpenEvents::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BarrierControl::Attributes::BarrierCommandOpenEvents::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBarrierCommandCloseEventsWithCompletion:(void (^)( @@ -53667,22 +54050,23 @@ + (void)readAttributeBarrierCommandCloseEventsWithClusterStateCache:(MTRClusterS NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BarrierControl::Attributes::BarrierCommandCloseEvents::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BarrierControl::Attributes::BarrierCommandCloseEvents::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBarrierOpenPeriodWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -53747,22 +54131,23 @@ + (void)readAttributeBarrierOpenPeriodWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BarrierControl::Attributes::BarrierOpenPeriod::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BarrierControl::Attributes::BarrierOpenPeriod::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBarrierClosePeriodWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -53828,22 +54213,23 @@ + (void)readAttributeBarrierClosePeriodWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BarrierControl::Attributes::BarrierClosePeriod::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BarrierControl::Attributes::BarrierClosePeriod::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBarrierPositionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -53871,22 +54257,23 @@ + (void)readAttributeBarrierPositionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BarrierControl::Attributes::BarrierPosition::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BarrierControl::Attributes::BarrierPosition::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -53915,7 +54302,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBarrierControlGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BarrierControlGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -53960,7 +54347,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBarrierControlAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BarrierControlAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -54003,7 +54390,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBarrierControlAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BarrierControlAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -54046,22 +54433,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BarrierControl::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BarrierControl::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -54089,22 +54477,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BarrierControl::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BarrierControl::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -54904,22 +55293,23 @@ + (void)readAttributeMaxPressureWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxPressure::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxPressure::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxSpeedWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -54946,22 +55336,23 @@ + (void)readAttributeMaxSpeedWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxSpeed::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxSpeed::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxFlowWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -54988,22 +55379,23 @@ + (void)readAttributeMaxFlowWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxFlow::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxFlow::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinConstPressureWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -55031,22 +55423,23 @@ + (void)readAttributeMinConstPressureWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstPressure::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstPressure::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxConstPressureWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -55074,22 +55467,23 @@ + (void)readAttributeMaxConstPressureWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstPressure::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstPressure::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinCompPressureWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -55117,22 +55511,23 @@ + (void)readAttributeMinCompPressureWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::MinCompPressure::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::MinCompPressure::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxCompPressureWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -55160,22 +55555,23 @@ + (void)readAttributeMaxCompPressureWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxCompPressure::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxCompPressure::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinConstSpeedWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -55202,22 +55598,23 @@ + (void)readAttributeMinConstSpeedWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstSpeed::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstSpeed::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxConstSpeedWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -55244,22 +55641,23 @@ + (void)readAttributeMaxConstSpeedWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstSpeed::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstSpeed::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinConstFlowWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -55286,22 +55684,23 @@ + (void)readAttributeMinConstFlowWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstFlow::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstFlow::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxConstFlowWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -55328,22 +55727,23 @@ + (void)readAttributeMaxConstFlowWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstFlow::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstFlow::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinConstTempWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -55370,22 +55770,23 @@ + (void)readAttributeMinConstTempWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstTemp::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstTemp::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxConstTempWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -55412,22 +55813,23 @@ + (void)readAttributeMaxConstTempWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstTemp::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstTemp::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePumpStatusWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -55454,7 +55856,7 @@ + (void)readAttributePumpStatusWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPumpConfigurationAndControlPumpStatusAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PumpConfigurationAndControlPumpStatusAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -55501,7 +55903,7 @@ + (void)readAttributeEffectiveOperationModeWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRPumpConfigurationAndControlClusterPumpOperationModeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PumpConfigurationAndControlClusterPumpOperationModeAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -55547,7 +55949,7 @@ + (void)readAttributeEffectiveControlModeWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPumpConfigurationAndControlClusterPumpControlModeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PumpConfigurationAndControlClusterPumpControlModeAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -55590,22 +55992,23 @@ + (void)readAttributeCapacityWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::Capacity::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::Capacity::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSpeedWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -55632,22 +56035,23 @@ + (void)readAttributeSpeedWithClusterStateCache:(MTRClusterStateCacheContainer * completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::Speed::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::Speed::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLifetimeRunningHoursWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -55718,22 +56122,23 @@ + (void)readAttributeLifetimeRunningHoursWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::LifetimeRunningHours::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::LifetimeRunningHours::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePowerWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -55760,22 +56165,23 @@ + (void)readAttributePowerWithClusterStateCache:(MTRClusterStateCacheContainer * completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::Power::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::Power::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLifetimeEnergyConsumedWithCompletion:(void (^)( @@ -55847,22 +56253,23 @@ + (void)readAttributeLifetimeEnergyConsumedWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::LifetimeEnergyConsumed::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::LifetimeEnergyConsumed::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOperationModeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -55927,7 +56334,7 @@ + (void)readAttributeOperationModeWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPumpConfigurationAndControlClusterPumpOperationModeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PumpConfigurationAndControlClusterPumpOperationModeAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -56008,7 +56415,7 @@ + (void)readAttributeControlModeWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPumpConfigurationAndControlClusterPumpControlModeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PumpConfigurationAndControlClusterPumpControlModeAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -56054,7 +56461,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPumpConfigurationAndControlGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PumpConfigurationAndControlGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -56100,7 +56507,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPumpConfigurationAndControlAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PumpConfigurationAndControlAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -56144,7 +56551,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPumpConfigurationAndControlAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PumpConfigurationAndControlAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -56187,22 +56594,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -56230,22 +56638,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -57713,22 +58122,23 @@ + (void)readAttributeLocalTemperatureWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::LocalTemperature::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::LocalTemperature::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOutdoorTemperatureWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -57757,22 +58167,23 @@ + (void)readAttributeOutdoorTemperatureWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::OutdoorTemperature::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::OutdoorTemperature::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOccupancyWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -57799,22 +58210,23 @@ + (void)readAttributeOccupancyWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::Occupancy::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::Occupancy::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAbsMinHeatSetpointLimitWithCompletion:(void (^)( @@ -57844,22 +58256,23 @@ + (void)readAttributeAbsMinHeatSetpointLimitWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::AbsMinHeatSetpointLimit::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::AbsMinHeatSetpointLimit::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAbsMaxHeatSetpointLimitWithCompletion:(void (^)( @@ -57889,22 +58302,23 @@ + (void)readAttributeAbsMaxHeatSetpointLimitWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::AbsMaxHeatSetpointLimit::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::AbsMaxHeatSetpointLimit::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAbsMinCoolSetpointLimitWithCompletion:(void (^)( @@ -57934,22 +58348,23 @@ + (void)readAttributeAbsMinCoolSetpointLimitWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::AbsMinCoolSetpointLimit::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::AbsMinCoolSetpointLimit::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAbsMaxCoolSetpointLimitWithCompletion:(void (^)( @@ -57979,22 +58394,23 @@ + (void)readAttributeAbsMaxCoolSetpointLimitWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::AbsMaxCoolSetpointLimit::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::AbsMaxCoolSetpointLimit::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePICoolingDemandWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -58022,22 +58438,23 @@ + (void)readAttributePICoolingDemandWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::PICoolingDemand::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::PICoolingDemand::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePIHeatingDemandWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -58065,22 +58482,23 @@ + (void)readAttributePIHeatingDemandWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::PIHeatingDemand::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::PIHeatingDemand::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeHVACSystemTypeConfigurationWithCompletion:(void (^)( @@ -58147,22 +58565,23 @@ + (void)readAttributeHVACSystemTypeConfigurationWithClusterStateCache:(MTRCluste NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::HVACSystemTypeConfiguration::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::HVACSystemTypeConfiguration::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLocalTemperatureCalibrationWithCompletion:(void (^)( @@ -58229,22 +58648,23 @@ + (void)readAttributeLocalTemperatureCalibrationWithClusterStateCache:(MTRCluste NSError * _Nullable error))completion { auto * bridge = new MTRInt8sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::LocalTemperatureCalibration::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::LocalTemperatureCalibration::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOccupiedCoolingSetpointWithCompletion:(void (^)( @@ -58311,22 +58731,23 @@ + (void)readAttributeOccupiedCoolingSetpointWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::OccupiedCoolingSetpoint::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::OccupiedCoolingSetpoint::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOccupiedHeatingSetpointWithCompletion:(void (^)( @@ -58393,22 +58814,23 @@ + (void)readAttributeOccupiedHeatingSetpointWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::OccupiedHeatingSetpoint::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::OccupiedHeatingSetpoint::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeUnoccupiedCoolingSetpointWithCompletion:(void (^)( @@ -58475,22 +58897,23 @@ + (void)readAttributeUnoccupiedCoolingSetpointWithClusterStateCache:(MTRClusterS NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::UnoccupiedCoolingSetpoint::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::UnoccupiedCoolingSetpoint::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeUnoccupiedHeatingSetpointWithCompletion:(void (^)( @@ -58557,22 +58980,23 @@ + (void)readAttributeUnoccupiedHeatingSetpointWithClusterStateCache:(MTRClusterS NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::UnoccupiedHeatingSetpoint::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::UnoccupiedHeatingSetpoint::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinHeatSetpointLimitWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -58638,22 +59062,23 @@ + (void)readAttributeMinHeatSetpointLimitWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::MinHeatSetpointLimit::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::MinHeatSetpointLimit::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxHeatSetpointLimitWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -58719,22 +59144,23 @@ + (void)readAttributeMaxHeatSetpointLimitWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::MaxHeatSetpointLimit::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::MaxHeatSetpointLimit::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinCoolSetpointLimitWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -58800,22 +59226,23 @@ + (void)readAttributeMinCoolSetpointLimitWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::MinCoolSetpointLimit::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::MinCoolSetpointLimit::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxCoolSetpointLimitWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -58881,22 +59308,23 @@ + (void)readAttributeMaxCoolSetpointLimitWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::MaxCoolSetpointLimit::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::MaxCoolSetpointLimit::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinSetpointDeadBandWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -58962,22 +59390,23 @@ + (void)readAttributeMinSetpointDeadBandWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::MinSetpointDeadBand::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::MinSetpointDeadBand::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRemoteSensingWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -59041,22 +59470,23 @@ + (void)readAttributeRemoteSensingWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::RemoteSensing::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::RemoteSensing::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeControlSequenceOfOperationWithCompletion:(void (^)( @@ -59124,7 +59554,7 @@ + (void)readAttributeControlSequenceOfOperationWithClusterStateCache:(MTRCluster NSError * _Nullable error))completion { auto * bridge = new MTRThermostatClusterThermostatControlSequenceAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ThermostatClusterThermostatControlSequenceAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -59204,22 +59634,23 @@ + (void)readAttributeSystemModeWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::SystemMode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::SystemMode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeThermostatRunningModeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -59248,22 +59679,23 @@ + (void)readAttributeThermostatRunningModeWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::ThermostatRunningMode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::ThermostatRunningMode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeStartOfWeekWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -59290,22 +59722,23 @@ + (void)readAttributeStartOfWeekWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::StartOfWeek::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::StartOfWeek::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNumberOfWeeklyTransitionsWithCompletion:(void (^)( @@ -59335,22 +59768,23 @@ + (void)readAttributeNumberOfWeeklyTransitionsWithClusterStateCache:(MTRClusterS NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::NumberOfWeeklyTransitions::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::NumberOfWeeklyTransitions::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNumberOfDailyTransitionsWithCompletion:(void (^)( @@ -59380,22 +59814,23 @@ + (void)readAttributeNumberOfDailyTransitionsWithClusterStateCache:(MTRClusterSt NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::NumberOfDailyTransitions::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::NumberOfDailyTransitions::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTemperatureSetpointHoldWithCompletion:(void (^)( @@ -59462,22 +59897,23 @@ + (void)readAttributeTemperatureSetpointHoldWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::TemperatureSetpointHold::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::TemperatureSetpointHold::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTemperatureSetpointHoldDurationWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -59552,22 +59988,23 @@ + (void)readAttributeTemperatureSetpointHoldDurationWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::TemperatureSetpointHoldDuration::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::TemperatureSetpointHoldDuration::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeThermostatProgrammingOperationModeWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -59637,22 +60074,23 @@ + (void)readAttributeThermostatProgrammingOperationModeWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::ThermostatProgrammingOperationMode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::ThermostatProgrammingOperationMode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeThermostatRunningStateWithCompletion:(void (^)( @@ -59682,22 +60120,23 @@ + (void)readAttributeThermostatRunningStateWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::ThermostatRunningState::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::ThermostatRunningState::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSetpointChangeSourceWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -59726,22 +60165,23 @@ + (void)readAttributeSetpointChangeSourceWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::SetpointChangeSource::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::SetpointChangeSource::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSetpointChangeAmountWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -59770,22 +60210,23 @@ + (void)readAttributeSetpointChangeAmountWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::SetpointChangeAmount::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::SetpointChangeAmount::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSetpointChangeSourceTimestampWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -59816,22 +60257,23 @@ + (void)readAttributeSetpointChangeSourceTimestampWithClusterStateCache:(MTRClus NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::SetpointChangeSourceTimestamp::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::SetpointChangeSourceTimestamp::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOccupiedSetbackWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -59901,22 +60343,23 @@ + (void)readAttributeOccupiedSetbackWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::OccupiedSetback::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::OccupiedSetback::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOccupiedSetbackMinWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -59945,22 +60388,23 @@ + (void)readAttributeOccupiedSetbackMinWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::OccupiedSetbackMin::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::OccupiedSetbackMin::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOccupiedSetbackMaxWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -59989,22 +60433,23 @@ + (void)readAttributeOccupiedSetbackMaxWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::OccupiedSetbackMax::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::OccupiedSetbackMax::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeUnoccupiedSetbackWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -60074,22 +60519,23 @@ + (void)readAttributeUnoccupiedSetbackWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::UnoccupiedSetback::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::UnoccupiedSetback::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeUnoccupiedSetbackMinWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -60118,22 +60564,23 @@ + (void)readAttributeUnoccupiedSetbackMinWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::UnoccupiedSetbackMin::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::UnoccupiedSetbackMin::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeUnoccupiedSetbackMaxWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -60162,22 +60609,23 @@ + (void)readAttributeUnoccupiedSetbackMaxWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::UnoccupiedSetbackMax::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::UnoccupiedSetbackMax::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeEmergencyHeatDeltaWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -60243,22 +60691,23 @@ + (void)readAttributeEmergencyHeatDeltaWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::EmergencyHeatDelta::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::EmergencyHeatDelta::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeACTypeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -60322,22 +60771,23 @@ + (void)readAttributeACTypeWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::ACType::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::ACType::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeACCapacityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -60401,22 +60851,23 @@ + (void)readAttributeACCapacityWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::ACCapacity::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::ACCapacity::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeACRefrigerantTypeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -60481,22 +60932,23 @@ + (void)readAttributeACRefrigerantTypeWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::ACRefrigerantType::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::ACRefrigerantType::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeACCompressorTypeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -60561,22 +61013,23 @@ + (void)readAttributeACCompressorTypeWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::ACCompressorType::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::ACCompressorType::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeACErrorCodeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -60640,22 +61093,23 @@ + (void)readAttributeACErrorCodeWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::ACErrorCode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::ACErrorCode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeACLouverPositionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -60720,22 +61174,23 @@ + (void)readAttributeACLouverPositionWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::ACLouverPosition::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::ACLouverPosition::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeACCoilTemperatureWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -60763,22 +61218,23 @@ + (void)readAttributeACCoilTemperatureWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::ACCoilTemperature::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::ACCoilTemperature::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeACCapacityformatWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -60843,22 +61299,23 @@ + (void)readAttributeACCapacityformatWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::ACCapacityformat::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::ACCapacityformat::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -60887,7 +61344,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRThermostatGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ThermostatGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -60932,7 +61389,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRThermostatAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ThermostatAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -60975,22 +61432,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRThermostatAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(ThermostatAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(ThermostatAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -61017,22 +61475,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -61060,22 +61519,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Thermostat::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Thermostat::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -63884,22 +64344,23 @@ + (void)readAttributeFanModeWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRFanControlClusterFanModeTypeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(FanControlClusterFanModeTypeAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FanControl::Attributes::FanMode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(FanControlClusterFanModeTypeAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FanControl::Attributes::FanMode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFanModeSequenceWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -63964,7 +64425,7 @@ + (void)readAttributeFanModeSequenceWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRFanControlClusterFanModeSequenceTypeAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(FanControlClusterFanModeSequenceTypeAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -64049,22 +64510,23 @@ + (void)readAttributePercentSettingWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FanControl::Attributes::PercentSetting::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FanControl::Attributes::PercentSetting::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePercentCurrentWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -64091,22 +64553,23 @@ + (void)readAttributePercentCurrentWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FanControl::Attributes::PercentCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FanControl::Attributes::PercentCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSpeedMaxWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -64133,22 +64596,23 @@ + (void)readAttributeSpeedMaxWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FanControl::Attributes::SpeedMax::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FanControl::Attributes::SpeedMax::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSpeedSettingWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -64217,22 +64681,23 @@ + (void)readAttributeSpeedSettingWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FanControl::Attributes::SpeedSetting::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FanControl::Attributes::SpeedSetting::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSpeedCurrentWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -64259,22 +64724,23 @@ + (void)readAttributeSpeedCurrentWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FanControl::Attributes::SpeedCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FanControl::Attributes::SpeedCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRockSupportWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -64301,22 +64767,23 @@ + (void)readAttributeRockSupportWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FanControl::Attributes::RockSupport::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FanControl::Attributes::RockSupport::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRockSettingWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -64380,22 +64847,23 @@ + (void)readAttributeRockSettingWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FanControl::Attributes::RockSetting::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FanControl::Attributes::RockSetting::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeWindSupportWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -64422,22 +64890,23 @@ + (void)readAttributeWindSupportWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FanControl::Attributes::WindSupport::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FanControl::Attributes::WindSupport::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeWindSettingWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -64501,22 +64970,23 @@ + (void)readAttributeWindSettingWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FanControl::Attributes::WindSetting::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FanControl::Attributes::WindSetting::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -64545,7 +65015,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRFanControlGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(FanControlGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -64590,7 +65060,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRFanControlAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(FanControlAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -64633,22 +65103,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRFanControlAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(FanControlAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FanControl::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(FanControlAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FanControl::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -64675,22 +65146,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FanControl::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FanControl::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -64718,22 +65190,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FanControl::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FanControl::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -65578,22 +66051,23 @@ + (void)readAttributeTemperatureDisplayModeWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThermostatUserInterfaceConfiguration::Attributes::TemperatureDisplayMode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThermostatUserInterfaceConfiguration::Attributes::TemperatureDisplayMode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeKeypadLockoutWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -65657,22 +66131,23 @@ + (void)readAttributeKeypadLockoutWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThermostatUserInterfaceConfiguration::Attributes::KeypadLockout::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThermostatUserInterfaceConfiguration::Attributes::KeypadLockout::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeScheduleProgrammingVisibilityWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -65740,22 +66215,23 @@ + (void)readAttributeScheduleProgrammingVisibilityWithClusterStateCache:(MTRClus NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThermostatUserInterfaceConfiguration::Attributes::ScheduleProgrammingVisibility::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThermostatUserInterfaceConfiguration::Attributes::ScheduleProgrammingVisibility::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -65785,7 +66261,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRThermostatUserInterfaceConfigurationGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ThermostatUserInterfaceConfigurationGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -65831,7 +66307,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRThermostatUserInterfaceConfigurationAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ThermostatUserInterfaceConfigurationAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -65875,7 +66351,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRThermostatUserInterfaceConfigurationAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ThermostatUserInterfaceConfigurationAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -65918,22 +66394,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThermostatUserInterfaceConfiguration::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThermostatUserInterfaceConfiguration::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -65961,22 +66438,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ThermostatUserInterfaceConfiguration::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ThermostatUserInterfaceConfiguration::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -67028,22 +67506,23 @@ + (void)readAttributeCurrentHueWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::CurrentHue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::CurrentHue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentSaturationWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67071,22 +67550,23 @@ + (void)readAttributeCurrentSaturationWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::CurrentSaturation::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::CurrentSaturation::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRemainingTimeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67113,22 +67593,23 @@ + (void)readAttributeRemainingTimeWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::RemainingTime::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::RemainingTime::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentXWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67155,22 +67636,23 @@ + (void)readAttributeCurrentXWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::CurrentX::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::CurrentX::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentYWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67197,22 +67679,23 @@ + (void)readAttributeCurrentYWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::CurrentY::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::CurrentY::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDriftCompensationWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67240,22 +67723,23 @@ + (void)readAttributeDriftCompensationWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::DriftCompensation::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::DriftCompensation::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCompensationTextWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -67283,22 +67767,23 @@ + (void)readAttributeCompensationTextWithClusterStateCache:(MTRClusterStateCache (void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::CompensationText::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::CompensationText::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorTemperatureMiredsWithCompletion:(void (^)( @@ -67328,22 +67813,23 @@ + (void)readAttributeColorTemperatureMiredsWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorTemperatureMireds::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorTemperatureMireds::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorModeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67370,22 +67856,23 @@ + (void)readAttributeColorModeWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorMode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorMode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOptionsWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67449,22 +67936,23 @@ + (void)readAttributeOptionsWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Options::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Options::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNumberOfPrimariesWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67492,22 +67980,23 @@ + (void)readAttributeNumberOfPrimariesWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::NumberOfPrimaries::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::NumberOfPrimaries::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary1XWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67534,22 +68023,23 @@ + (void)readAttributePrimary1XWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary1X::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary1X::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary1YWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67576,22 +68066,23 @@ + (void)readAttributePrimary1YWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary1Y::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary1Y::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary1IntensityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67619,22 +68110,23 @@ + (void)readAttributePrimary1IntensityWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary1Intensity::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary1Intensity::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary2XWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67661,22 +68153,23 @@ + (void)readAttributePrimary2XWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary2X::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary2X::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary2YWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67703,22 +68196,23 @@ + (void)readAttributePrimary2YWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary2Y::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary2Y::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary2IntensityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67746,22 +68240,23 @@ + (void)readAttributePrimary2IntensityWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary2Intensity::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary2Intensity::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary3XWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67788,22 +68283,23 @@ + (void)readAttributePrimary3XWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary3X::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary3X::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary3YWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67830,22 +68326,23 @@ + (void)readAttributePrimary3YWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary3Y::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary3Y::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary3IntensityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67873,22 +68370,23 @@ + (void)readAttributePrimary3IntensityWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary3Intensity::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary3Intensity::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary4XWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67915,22 +68413,23 @@ + (void)readAttributePrimary4XWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary4X::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary4X::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary4YWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -67957,22 +68456,23 @@ + (void)readAttributePrimary4YWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary4Y::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary4Y::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary4IntensityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68000,22 +68500,23 @@ + (void)readAttributePrimary4IntensityWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary4Intensity::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary4Intensity::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary5XWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68042,22 +68543,23 @@ + (void)readAttributePrimary5XWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary5X::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary5X::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary5YWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68084,22 +68586,23 @@ + (void)readAttributePrimary5YWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary5Y::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary5Y::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary5IntensityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68127,22 +68630,23 @@ + (void)readAttributePrimary5IntensityWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary5Intensity::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary5Intensity::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary6XWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68169,22 +68673,23 @@ + (void)readAttributePrimary6XWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary6X::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary6X::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary6YWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68211,22 +68716,23 @@ + (void)readAttributePrimary6YWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary6Y::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary6Y::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePrimary6IntensityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68254,22 +68760,23 @@ + (void)readAttributePrimary6IntensityWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::Primary6Intensity::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::Primary6Intensity::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeWhitePointXWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68333,22 +68840,23 @@ + (void)readAttributeWhitePointXWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::WhitePointX::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::WhitePointX::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeWhitePointYWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68412,22 +68920,23 @@ + (void)readAttributeWhitePointYWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::WhitePointY::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::WhitePointY::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorPointRXWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68491,22 +69000,23 @@ + (void)readAttributeColorPointRXWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorPointRX::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorPointRX::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorPointRYWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68570,22 +69080,23 @@ + (void)readAttributeColorPointRYWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorPointRY::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorPointRY::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorPointRIntensityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68656,22 +69167,23 @@ + (void)readAttributeColorPointRIntensityWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorPointRIntensity::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorPointRIntensity::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorPointGXWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68735,22 +69247,23 @@ + (void)readAttributeColorPointGXWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorPointGX::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorPointGX::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorPointGYWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68814,22 +69327,23 @@ + (void)readAttributeColorPointGYWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorPointGY::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorPointGY::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorPointGIntensityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68900,22 +69414,23 @@ + (void)readAttributeColorPointGIntensityWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorPointGIntensity::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorPointGIntensity::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorPointBXWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -68979,22 +69494,23 @@ + (void)readAttributeColorPointBXWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorPointBX::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorPointBX::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorPointBYWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -69058,22 +69574,23 @@ + (void)readAttributeColorPointBYWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorPointBY::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorPointBY::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorPointBIntensityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -69144,22 +69661,23 @@ + (void)readAttributeColorPointBIntensityWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorPointBIntensity::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorPointBIntensity::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeEnhancedCurrentHueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -69188,22 +69706,23 @@ + (void)readAttributeEnhancedCurrentHueWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::EnhancedCurrentHue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::EnhancedCurrentHue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeEnhancedColorModeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -69231,22 +69750,23 @@ + (void)readAttributeEnhancedColorModeWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::EnhancedColorMode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::EnhancedColorMode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorLoopActiveWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -69274,22 +69794,23 @@ + (void)readAttributeColorLoopActiveWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorLoopActive::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorLoopActive::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorLoopDirectionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -69318,22 +69839,23 @@ + (void)readAttributeColorLoopDirectionWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorLoopDirection::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorLoopDirection::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorLoopTimeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -69360,22 +69882,23 @@ + (void)readAttributeColorLoopTimeWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorLoopTime::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorLoopTime::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorLoopStartEnhancedHueWithCompletion:(void (^)( @@ -69405,22 +69928,23 @@ + (void)readAttributeColorLoopStartEnhancedHueWithClusterStateCache:(MTRClusterS NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorLoopStartEnhancedHue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorLoopStartEnhancedHue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorLoopStoredEnhancedHueWithCompletion:(void (^)( @@ -69450,22 +69974,23 @@ + (void)readAttributeColorLoopStoredEnhancedHueWithClusterStateCache:(MTRCluster NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorLoopStoredEnhancedHue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorLoopStoredEnhancedHue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorCapabilitiesWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -69493,22 +70018,23 @@ + (void)readAttributeColorCapabilitiesWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorCapabilities::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorCapabilities::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorTempPhysicalMinMiredsWithCompletion:(void (^)( @@ -69538,22 +70064,23 @@ + (void)readAttributeColorTempPhysicalMinMiredsWithClusterStateCache:(MTRCluster NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorTempPhysicalMinMireds::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorTempPhysicalMinMireds::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeColorTempPhysicalMaxMiredsWithCompletion:(void (^)( @@ -69583,22 +70110,23 @@ + (void)readAttributeColorTempPhysicalMaxMiredsWithClusterStateCache:(MTRCluster NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ColorTempPhysicalMaxMireds::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ColorTempPhysicalMaxMireds::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCoupleColorTempToLevelMinMiredsWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -69630,22 +70158,23 @@ + (void)readAttributeCoupleColorTempToLevelMinMiredsWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::CoupleColorTempToLevelMinMireds::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::CoupleColorTempToLevelMinMireds::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeStartUpColorTemperatureMiredsWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -69718,22 +70247,23 @@ + (void)readAttributeStartUpColorTemperatureMiredsWithClusterStateCache:(MTRClus NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::StartUpColorTemperatureMireds::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::StartUpColorTemperatureMireds::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -69762,7 +70292,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRColorControlGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ColorControlGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -69807,7 +70337,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRColorControlAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ColorControlAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -69850,22 +70380,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRColorControlAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(ColorControlAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(ColorControlAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -69892,22 +70423,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -69935,22 +70467,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ColorControl::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ColorControl::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -72717,22 +73250,23 @@ + (void)readAttributePhysicalMinLevelWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::PhysicalMinLevel::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::PhysicalMinLevel::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePhysicalMaxLevelWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -72760,22 +73294,23 @@ + (void)readAttributePhysicalMaxLevelWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::PhysicalMaxLevel::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::PhysicalMaxLevel::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBallastStatusWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -72802,22 +73337,23 @@ + (void)readAttributeBallastStatusWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::BallastStatus::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::BallastStatus::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinLevelWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -72881,22 +73417,23 @@ + (void)readAttributeMinLevelWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::MinLevel::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::MinLevel::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxLevelWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -72960,22 +73497,23 @@ + (void)readAttributeMaxLevelWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::MaxLevel::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::MaxLevel::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeIntrinsicBalanceFactorWithCompletion:(void (^)( @@ -73047,22 +73585,23 @@ + (void)readAttributeIntrinsicBalanceFactorWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::IntrinsicBalanceFactor::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::IntrinsicBalanceFactor::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBallastFactorAdjustmentWithCompletion:(void (^)( @@ -73134,22 +73673,23 @@ + (void)readAttributeBallastFactorAdjustmentWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::BallastFactorAdjustment::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::BallastFactorAdjustment::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLampQuantityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -73176,22 +73716,23 @@ + (void)readAttributeLampQuantityWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::LampQuantity::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::LampQuantity::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLampTypeWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -73255,22 +73796,23 @@ + (void)readAttributeLampTypeWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::LampType::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::LampType::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLampManufacturerWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -73335,22 +73877,23 @@ + (void)readAttributeLampManufacturerWithClusterStateCache:(MTRClusterStateCache (void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::LampManufacturer::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::LampManufacturer::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLampRatedHoursWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -73419,22 +73962,23 @@ + (void)readAttributeLampRatedHoursWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::LampRatedHours::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::LampRatedHours::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLampBurnHoursWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -73503,22 +74047,23 @@ + (void)readAttributeLampBurnHoursWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::LampBurnHours::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::LampBurnHours::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLampAlarmModeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -73582,22 +74127,23 @@ + (void)readAttributeLampAlarmModeWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::LampAlarmMode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::LampAlarmMode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLampBurnHoursTripPointWithCompletion:(void (^)( @@ -73669,22 +74215,23 @@ + (void)readAttributeLampBurnHoursTripPointWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::LampBurnHoursTripPoint::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::LampBurnHoursTripPoint::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -73714,7 +74261,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBallastConfigurationGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BallastConfigurationGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -73760,7 +74307,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBallastConfigurationAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BallastConfigurationAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -73803,7 +74350,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBallastConfigurationAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(BallastConfigurationAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -73846,22 +74393,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -73889,22 +74437,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = BallastConfiguration::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = BallastConfiguration::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -74891,22 +75440,23 @@ + (void)readAttributeMeasuredValueWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = IlluminanceMeasurement::Attributes::MeasuredValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = IlluminanceMeasurement::Attributes::MeasuredValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -74934,22 +75484,23 @@ + (void)readAttributeMinMeasuredValueWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = IlluminanceMeasurement::Attributes::MinMeasuredValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = IlluminanceMeasurement::Attributes::MinMeasuredValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -74977,22 +75528,23 @@ + (void)readAttributeMaxMeasuredValueWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = IlluminanceMeasurement::Attributes::MaxMeasuredValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = IlluminanceMeasurement::Attributes::MaxMeasuredValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeToleranceWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -75019,22 +75571,23 @@ + (void)readAttributeToleranceWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = IlluminanceMeasurement::Attributes::Tolerance::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = IlluminanceMeasurement::Attributes::Tolerance::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLightSensorTypeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -75062,22 +75615,23 @@ + (void)readAttributeLightSensorTypeWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = IlluminanceMeasurement::Attributes::LightSensorType::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = IlluminanceMeasurement::Attributes::LightSensorType::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -75107,7 +75661,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRIlluminanceMeasurementGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(IlluminanceMeasurementGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -75153,7 +75707,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRIlluminanceMeasurementAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(IlluminanceMeasurementAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -75196,7 +75750,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRIlluminanceMeasurementAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(IlluminanceMeasurementAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -75239,22 +75793,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = IlluminanceMeasurement::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = IlluminanceMeasurement::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -75282,22 +75837,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = IlluminanceMeasurement::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = IlluminanceMeasurement::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -75787,22 +76343,23 @@ + (void)readAttributeMeasuredValueWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = TemperatureMeasurement::Attributes::MeasuredValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = TemperatureMeasurement::Attributes::MeasuredValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -75830,22 +76387,23 @@ + (void)readAttributeMinMeasuredValueWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = TemperatureMeasurement::Attributes::MinMeasuredValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = TemperatureMeasurement::Attributes::MinMeasuredValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -75873,22 +76431,23 @@ + (void)readAttributeMaxMeasuredValueWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = TemperatureMeasurement::Attributes::MaxMeasuredValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = TemperatureMeasurement::Attributes::MaxMeasuredValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeToleranceWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -75915,22 +76474,23 @@ + (void)readAttributeToleranceWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = TemperatureMeasurement::Attributes::Tolerance::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = TemperatureMeasurement::Attributes::Tolerance::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -75960,7 +76520,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRTemperatureMeasurementGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(TemperatureMeasurementGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -76006,7 +76566,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRTemperatureMeasurementAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(TemperatureMeasurementAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -76049,7 +76609,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRTemperatureMeasurementAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(TemperatureMeasurementAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -76092,22 +76652,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = TemperatureMeasurement::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = TemperatureMeasurement::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -76135,22 +76696,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = TemperatureMeasurement::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = TemperatureMeasurement::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -76596,22 +77158,23 @@ + (void)readAttributeMeasuredValueWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PressureMeasurement::Attributes::MeasuredValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PressureMeasurement::Attributes::MeasuredValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -76639,22 +77202,23 @@ + (void)readAttributeMinMeasuredValueWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PressureMeasurement::Attributes::MinMeasuredValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PressureMeasurement::Attributes::MinMeasuredValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -76682,22 +77246,23 @@ + (void)readAttributeMaxMeasuredValueWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PressureMeasurement::Attributes::MaxMeasuredValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PressureMeasurement::Attributes::MaxMeasuredValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeToleranceWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -76724,22 +77289,23 @@ + (void)readAttributeToleranceWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PressureMeasurement::Attributes::Tolerance::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PressureMeasurement::Attributes::Tolerance::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeScaledValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -76766,22 +77332,23 @@ + (void)readAttributeScaledValueWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PressureMeasurement::Attributes::ScaledValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PressureMeasurement::Attributes::ScaledValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinScaledValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -76808,22 +77375,23 @@ + (void)readAttributeMinScaledValueWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PressureMeasurement::Attributes::MinScaledValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PressureMeasurement::Attributes::MinScaledValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxScaledValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -76850,22 +77418,23 @@ + (void)readAttributeMaxScaledValueWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PressureMeasurement::Attributes::MaxScaledValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PressureMeasurement::Attributes::MaxScaledValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeScaledToleranceWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -76893,22 +77462,23 @@ + (void)readAttributeScaledToleranceWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PressureMeasurement::Attributes::ScaledTolerance::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PressureMeasurement::Attributes::ScaledTolerance::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeScaleWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -76935,22 +77505,23 @@ + (void)readAttributeScaleWithClusterStateCache:(MTRClusterStateCacheContainer * completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PressureMeasurement::Attributes::Scale::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PressureMeasurement::Attributes::Scale::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -76980,7 +77551,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPressureMeasurementGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PressureMeasurementGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -77025,7 +77596,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPressureMeasurementAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PressureMeasurementAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -77068,7 +77639,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRPressureMeasurementAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(PressureMeasurementAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -77111,22 +77682,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PressureMeasurement::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PressureMeasurement::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -77154,22 +77726,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PressureMeasurement::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PressureMeasurement::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -77831,22 +78404,23 @@ + (void)readAttributeMeasuredValueWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FlowMeasurement::Attributes::MeasuredValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FlowMeasurement::Attributes::MeasuredValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -77874,22 +78448,23 @@ + (void)readAttributeMinMeasuredValueWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FlowMeasurement::Attributes::MinMeasuredValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FlowMeasurement::Attributes::MinMeasuredValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -77917,22 +78492,23 @@ + (void)readAttributeMaxMeasuredValueWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FlowMeasurement::Attributes::MaxMeasuredValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FlowMeasurement::Attributes::MaxMeasuredValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeToleranceWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -77959,22 +78535,23 @@ + (void)readAttributeToleranceWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FlowMeasurement::Attributes::Tolerance::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FlowMeasurement::Attributes::Tolerance::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -78003,7 +78580,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRFlowMeasurementGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(FlowMeasurementGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -78048,7 +78625,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRFlowMeasurementAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(FlowMeasurementAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -78091,7 +78668,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRFlowMeasurementAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(FlowMeasurementAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -78134,22 +78711,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FlowMeasurement::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FlowMeasurement::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -78177,22 +78755,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = FlowMeasurement::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = FlowMeasurement::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -78638,22 +79217,23 @@ + (void)readAttributeMeasuredValueWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = RelativeHumidityMeasurement::Attributes::MeasuredValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = RelativeHumidityMeasurement::Attributes::MeasuredValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMinMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -78681,22 +79261,23 @@ + (void)readAttributeMinMeasuredValueWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = RelativeHumidityMeasurement::Attributes::MinMeasuredValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = RelativeHumidityMeasurement::Attributes::MinMeasuredValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMaxMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -78724,22 +79305,23 @@ + (void)readAttributeMaxMeasuredValueWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = RelativeHumidityMeasurement::Attributes::MaxMeasuredValue::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = RelativeHumidityMeasurement::Attributes::MaxMeasuredValue::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeToleranceWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -78766,22 +79348,23 @@ + (void)readAttributeToleranceWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = RelativeHumidityMeasurement::Attributes::Tolerance::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = RelativeHumidityMeasurement::Attributes::Tolerance::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -78811,7 +79394,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRRelativeHumidityMeasurementGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(RelativeHumidityMeasurementGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -78857,7 +79440,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRRelativeHumidityMeasurementAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(RelativeHumidityMeasurementAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -78901,7 +79484,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRRelativeHumidityMeasurementAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(RelativeHumidityMeasurementAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -78944,22 +79527,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = RelativeHumidityMeasurement::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = RelativeHumidityMeasurement::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -78987,22 +79571,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = RelativeHumidityMeasurement::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = RelativeHumidityMeasurement::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -79448,22 +80033,23 @@ + (void)readAttributeOccupancyWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OccupancySensing::Attributes::Occupancy::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OccupancySensing::Attributes::Occupancy::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOccupancySensorTypeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -79492,22 +80078,23 @@ + (void)readAttributeOccupancySensorTypeWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OccupancySensing::Attributes::OccupancySensorType::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OccupancySensing::Attributes::OccupancySensorType::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOccupancySensorTypeBitmapWithCompletion:(void (^)( @@ -79537,25 +80124,26 @@ + (void)readAttributeOccupancySensorTypeBitmapWithClusterStateCache:(MTRClusterS NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OccupancySensing::Attributes::OccupancySensorTypeBitmap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OccupancySensing::Attributes::OccupancySensorTypeBitmap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } -- (void)readAttributePirOccupiedToUnoccupiedDelayWithCompletion:(void (^)(NSNumber * _Nullable value, +- (void)readAttributePIROccupiedToUnoccupiedDelayWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { MTRReadParams * params = [[MTRReadParams alloc] init]; @@ -79564,11 +80152,11 @@ - (void)readAttributePirOccupiedToUnoccupiedDelayWithCompletion:(void (^)(NSNumb params, completion, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } -- (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSNumber * _Nonnull)value completion:(MTRStatusCompletion)completion +- (void)writeAttributePIROccupiedToUnoccupiedDelayWithValue:(NSNumber * _Nonnull)value completion:(MTRStatusCompletion)completion { - [self writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSNumber * _Nonnull) value params:nil completion:completion]; + [self writeAttributePIROccupiedToUnoccupiedDelayWithValue:(NSNumber * _Nonnull) value params:nil completion:completion]; } -- (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSNumber * _Nonnull)value +- (void)writeAttributePIROccupiedToUnoccupiedDelayWithValue:(NSNumber * _Nonnull)value params:(MTRWriteParams * _Nullable)params completion:(MTRStatusCompletion)completion { @@ -79601,7 +80189,7 @@ - (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSNumber * _Nonnull std::move(*bridge).DispatchAction(self.device); } -- (void)subscribeAttributePirOccupiedToUnoccupiedDelayWithParams:(MTRSubscribeParams * _Nonnull)params +- (void)subscribeAttributePIROccupiedToUnoccupiedDelayWithParams:(MTRSubscribeParams * _Nonnull)params subscriptionEstablished: (MTRSubscriptionEstablishedHandler _Nullable)subscriptionEstablished reportHandler:(void (^)(NSNumber * _Nullable value, @@ -79613,32 +80201,33 @@ - (void)subscribeAttributePirOccupiedToUnoccupiedDelayWithParams:(MTRSubscribePa TypeInfo::GetAttributeId()); } -+ (void)readAttributePirOccupiedToUnoccupiedDelayWithClusterStateCache:(MTRClusterStateCacheContainer *)clusterStateCacheContainer ++ (void)readAttributePIROccupiedToUnoccupiedDelayWithClusterStateCache:(MTRClusterStateCacheContainer *)clusterStateCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OccupancySensing::Attributes::PirOccupiedToUnoccupiedDelay::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OccupancySensing::Attributes::PirOccupiedToUnoccupiedDelay::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } -- (void)readAttributePirUnoccupiedToOccupiedDelayWithCompletion:(void (^)(NSNumber * _Nullable value, +- (void)readAttributePIRUnoccupiedToOccupiedDelayWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { MTRReadParams * params = [[MTRReadParams alloc] init]; @@ -79647,11 +80236,11 @@ - (void)readAttributePirUnoccupiedToOccupiedDelayWithCompletion:(void (^)(NSNumb params, completion, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } -- (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSNumber * _Nonnull)value completion:(MTRStatusCompletion)completion +- (void)writeAttributePIRUnoccupiedToOccupiedDelayWithValue:(NSNumber * _Nonnull)value completion:(MTRStatusCompletion)completion { - [self writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSNumber * _Nonnull) value params:nil completion:completion]; + [self writeAttributePIRUnoccupiedToOccupiedDelayWithValue:(NSNumber * _Nonnull) value params:nil completion:completion]; } -- (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSNumber * _Nonnull)value +- (void)writeAttributePIRUnoccupiedToOccupiedDelayWithValue:(NSNumber * _Nonnull)value params:(MTRWriteParams * _Nullable)params completion:(MTRStatusCompletion)completion { @@ -79684,7 +80273,7 @@ - (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSNumber * _Nonnull std::move(*bridge).DispatchAction(self.device); } -- (void)subscribeAttributePirUnoccupiedToOccupiedDelayWithParams:(MTRSubscribeParams * _Nonnull)params +- (void)subscribeAttributePIRUnoccupiedToOccupiedDelayWithParams:(MTRSubscribeParams * _Nonnull)params subscriptionEstablished: (MTRSubscriptionEstablishedHandler _Nullable)subscriptionEstablished reportHandler:(void (^)(NSNumber * _Nullable value, @@ -79696,32 +80285,33 @@ - (void)subscribeAttributePirUnoccupiedToOccupiedDelayWithParams:(MTRSubscribePa TypeInfo::GetAttributeId()); } -+ (void)readAttributePirUnoccupiedToOccupiedDelayWithClusterStateCache:(MTRClusterStateCacheContainer *)clusterStateCacheContainer ++ (void)readAttributePIRUnoccupiedToOccupiedDelayWithClusterStateCache:(MTRClusterStateCacheContainer *)clusterStateCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OccupancySensing::Attributes::PirUnoccupiedToOccupiedDelay::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OccupancySensing::Attributes::PirUnoccupiedToOccupiedDelay::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } -- (void)readAttributePirUnoccupiedToOccupiedThresholdWithCompletion:(void (^)(NSNumber * _Nullable value, +- (void)readAttributePIRUnoccupiedToOccupiedThresholdWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { MTRReadParams * params = [[MTRReadParams alloc] init]; @@ -79730,12 +80320,12 @@ - (void)readAttributePirUnoccupiedToOccupiedThresholdWithCompletion:(void (^)(NS params, completion, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } -- (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSNumber * _Nonnull)value +- (void)writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:(NSNumber * _Nonnull)value completion:(MTRStatusCompletion)completion { - [self writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSNumber * _Nonnull) value params:nil completion:completion]; + [self writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:(NSNumber * _Nonnull) value params:nil completion:completion]; } -- (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSNumber * _Nonnull)value +- (void)writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:(NSNumber * _Nonnull)value params:(MTRWriteParams * _Nullable)params completion:(MTRStatusCompletion)completion { @@ -79768,7 +80358,7 @@ - (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSNumber * _Non std::move(*bridge).DispatchAction(self.device); } -- (void)subscribeAttributePirUnoccupiedToOccupiedThresholdWithParams:(MTRSubscribeParams * _Nonnull)params +- (void)subscribeAttributePIRUnoccupiedToOccupiedThresholdWithParams:(MTRSubscribeParams * _Nonnull)params subscriptionEstablished: (MTRSubscriptionEstablishedHandler _Nullable)subscriptionEstablished reportHandler:(void (^)(NSNumber * _Nullable value, @@ -79780,7 +80370,7 @@ - (void)subscribeAttributePirUnoccupiedToOccupiedThresholdWithParams:(MTRSubscri TypeInfo::GetAttributeId()); } -+ (void)readAttributePirUnoccupiedToOccupiedThresholdWithClusterStateCache: ++ (void)readAttributePIRUnoccupiedToOccupiedThresholdWithClusterStateCache: (MTRClusterStateCacheContainer *)clusterStateCacheContainer endpoint:(NSNumber *)endpoint queue:(dispatch_queue_t)queue @@ -79788,22 +80378,23 @@ + (void)readAttributePirUnoccupiedToOccupiedThresholdWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OccupancySensing::Attributes::PirUnoccupiedToOccupiedThreshold::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OccupancySensing::Attributes::PirUnoccupiedToOccupiedThreshold::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeUltrasonicOccupiedToUnoccupiedDelayWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -79873,22 +80464,23 @@ + (void)readAttributeUltrasonicOccupiedToUnoccupiedDelayWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OccupancySensing::Attributes::UltrasonicOccupiedToUnoccupiedDelay::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OccupancySensing::Attributes::UltrasonicOccupiedToUnoccupiedDelay::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeUltrasonicUnoccupiedToOccupiedDelayWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -79958,22 +80550,23 @@ + (void)readAttributeUltrasonicUnoccupiedToOccupiedDelayWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OccupancySensing::Attributes::UltrasonicUnoccupiedToOccupiedDelay::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OccupancySensing::Attributes::UltrasonicUnoccupiedToOccupiedDelay::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeUltrasonicUnoccupiedToOccupiedThresholdWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -80045,22 +80638,23 @@ + (void)readAttributeUltrasonicUnoccupiedToOccupiedThresholdWithClusterStateCach NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OccupancySensing::Attributes::UltrasonicUnoccupiedToOccupiedThreshold::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OccupancySensing::Attributes::UltrasonicUnoccupiedToOccupiedThreshold::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePhysicalContactOccupiedToUnoccupiedDelayWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -80132,22 +80726,23 @@ + (void)readAttributePhysicalContactOccupiedToUnoccupiedDelayWithClusterStateCac NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OccupancySensing::Attributes::PhysicalContactOccupiedToUnoccupiedDelay::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OccupancySensing::Attributes::PhysicalContactOccupiedToUnoccupiedDelay::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePhysicalContactUnoccupiedToOccupiedDelayWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -80219,22 +80814,23 @@ + (void)readAttributePhysicalContactUnoccupiedToOccupiedDelayWithClusterStateCac NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OccupancySensing::Attributes::PhysicalContactUnoccupiedToOccupiedDelay::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OccupancySensing::Attributes::PhysicalContactUnoccupiedToOccupiedDelay::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePhysicalContactUnoccupiedToOccupiedThresholdWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -80306,22 +80902,23 @@ + (void)readAttributePhysicalContactUnoccupiedToOccupiedThresholdWithClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OccupancySensing::Attributes::PhysicalContactUnoccupiedToOccupiedThreshold::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OccupancySensing::Attributes::PhysicalContactUnoccupiedToOccupiedThreshold::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -80350,7 +80947,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROccupancySensingGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(OccupancySensingGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -80395,7 +80992,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROccupancySensingAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(OccupancySensingAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -80438,7 +81035,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROccupancySensingAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(OccupancySensingAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -80481,22 +81078,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OccupancySensing::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OccupancySensing::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -80524,22 +81122,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = OccupancySensing::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = OccupancySensing::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -80681,7 +81280,7 @@ + (void)readAttributeOccupancySensorTypeBitmapWithAttributeCache:(MTRAttributeCa - (void)readAttributePirOccupiedToUnoccupiedDelayWithCompletionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - [self readAttributePirOccupiedToUnoccupiedDelayWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { + [self readAttributePIROccupiedToUnoccupiedDelayWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. completionHandler(static_cast(value), error); }]; @@ -80689,13 +81288,13 @@ - (void)readAttributePirOccupiedToUnoccupiedDelayWithCompletionHandler:(void (^) - (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSNumber * _Nonnull)value completionHandler:(MTRStatusCompletion)completionHandler { - [self writeAttributePirOccupiedToUnoccupiedDelayWithValue:value params:nil completion:completionHandler]; + [self writeAttributePIROccupiedToUnoccupiedDelayWithValue:value params:nil completion:completionHandler]; } - (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSNumber * _Nonnull)value params:(MTRWriteParams * _Nullable)params completionHandler:(MTRStatusCompletion)completionHandler { - [self writeAttributePirOccupiedToUnoccupiedDelayWithValue:value params:params completion:completionHandler]; + [self writeAttributePIROccupiedToUnoccupiedDelayWithValue:value params:params completion:completionHandler]; } - (void)subscribeAttributePirOccupiedToUnoccupiedDelayWithMinInterval:(NSNumber * _Nonnull)minInterval maxInterval:(NSNumber * _Nonnull)maxInterval @@ -80712,7 +81311,7 @@ - (void)subscribeAttributePirOccupiedToUnoccupiedDelayWithMinInterval:(NSNumber subscribeParams.minInterval = minInterval; subscribeParams.maxInterval = maxInterval; } - [self subscribeAttributePirOccupiedToUnoccupiedDelayWithParams:subscribeParams + [self subscribeAttributePIROccupiedToUnoccupiedDelayWithParams:subscribeParams subscriptionEstablished:subscriptionEstablishedHandler reportHandler:^(NSNumber * _Nullable value, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. @@ -80725,7 +81324,7 @@ + (void)readAttributePirOccupiedToUnoccupiedDelayWithAttributeCache:(MTRAttribut completionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - [self readAttributePirOccupiedToUnoccupiedDelayWithClusterStateCache:attributeCacheContainer.realContainer + [self readAttributePIROccupiedToUnoccupiedDelayWithClusterStateCache:attributeCacheContainer.realContainer endpoint:endpoint queue:queue completion:^(NSNumber * _Nullable value, NSError * _Nullable error) { @@ -80737,7 +81336,7 @@ + (void)readAttributePirOccupiedToUnoccupiedDelayWithAttributeCache:(MTRAttribut - (void)readAttributePirUnoccupiedToOccupiedDelayWithCompletionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - [self readAttributePirUnoccupiedToOccupiedDelayWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { + [self readAttributePIRUnoccupiedToOccupiedDelayWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. completionHandler(static_cast(value), error); }]; @@ -80745,13 +81344,13 @@ - (void)readAttributePirUnoccupiedToOccupiedDelayWithCompletionHandler:(void (^) - (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSNumber * _Nonnull)value completionHandler:(MTRStatusCompletion)completionHandler { - [self writeAttributePirUnoccupiedToOccupiedDelayWithValue:value params:nil completion:completionHandler]; + [self writeAttributePIRUnoccupiedToOccupiedDelayWithValue:value params:nil completion:completionHandler]; } - (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSNumber * _Nonnull)value params:(MTRWriteParams * _Nullable)params completionHandler:(MTRStatusCompletion)completionHandler { - [self writeAttributePirUnoccupiedToOccupiedDelayWithValue:value params:params completion:completionHandler]; + [self writeAttributePIRUnoccupiedToOccupiedDelayWithValue:value params:params completion:completionHandler]; } - (void)subscribeAttributePirUnoccupiedToOccupiedDelayWithMinInterval:(NSNumber * _Nonnull)minInterval maxInterval:(NSNumber * _Nonnull)maxInterval @@ -80768,7 +81367,7 @@ - (void)subscribeAttributePirUnoccupiedToOccupiedDelayWithMinInterval:(NSNumber subscribeParams.minInterval = minInterval; subscribeParams.maxInterval = maxInterval; } - [self subscribeAttributePirUnoccupiedToOccupiedDelayWithParams:subscribeParams + [self subscribeAttributePIRUnoccupiedToOccupiedDelayWithParams:subscribeParams subscriptionEstablished:subscriptionEstablishedHandler reportHandler:^(NSNumber * _Nullable value, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. @@ -80781,7 +81380,7 @@ + (void)readAttributePirUnoccupiedToOccupiedDelayWithAttributeCache:(MTRAttribut completionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - [self readAttributePirUnoccupiedToOccupiedDelayWithClusterStateCache:attributeCacheContainer.realContainer + [self readAttributePIRUnoccupiedToOccupiedDelayWithClusterStateCache:attributeCacheContainer.realContainer endpoint:endpoint queue:queue completion:^(NSNumber * _Nullable value, NSError * _Nullable error) { @@ -80793,7 +81392,7 @@ + (void)readAttributePirUnoccupiedToOccupiedDelayWithAttributeCache:(MTRAttribut - (void)readAttributePirUnoccupiedToOccupiedThresholdWithCompletionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - [self readAttributePirUnoccupiedToOccupiedThresholdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { + [self readAttributePIRUnoccupiedToOccupiedThresholdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. completionHandler(static_cast(value), error); }]; @@ -80801,13 +81400,13 @@ - (void)readAttributePirUnoccupiedToOccupiedThresholdWithCompletionHandler:(void - (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSNumber * _Nonnull)value completionHandler:(MTRStatusCompletion)completionHandler { - [self writeAttributePirUnoccupiedToOccupiedThresholdWithValue:value params:nil completion:completionHandler]; + [self writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:value params:nil completion:completionHandler]; } - (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSNumber * _Nonnull)value params:(MTRWriteParams * _Nullable)params completionHandler:(MTRStatusCompletion)completionHandler { - [self writeAttributePirUnoccupiedToOccupiedThresholdWithValue:value params:params completion:completionHandler]; + [self writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:value params:params completion:completionHandler]; } - (void)subscribeAttributePirUnoccupiedToOccupiedThresholdWithMinInterval:(NSNumber * _Nonnull)minInterval maxInterval:(NSNumber * _Nonnull)maxInterval @@ -80824,7 +81423,7 @@ - (void)subscribeAttributePirUnoccupiedToOccupiedThresholdWithMinInterval:(NSNum subscribeParams.minInterval = minInterval; subscribeParams.maxInterval = maxInterval; } - [self subscribeAttributePirUnoccupiedToOccupiedThresholdWithParams:subscribeParams + [self subscribeAttributePIRUnoccupiedToOccupiedThresholdWithParams:subscribeParams subscriptionEstablished:subscriptionEstablishedHandler reportHandler:^(NSNumber * _Nullable value, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. @@ -80837,7 +81436,7 @@ + (void)readAttributePirUnoccupiedToOccupiedThresholdWithAttributeCache:(MTRAttr completionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - [self readAttributePirUnoccupiedToOccupiedThresholdWithClusterStateCache:attributeCacheContainer.realContainer + [self readAttributePIRUnoccupiedToOccupiedThresholdWithClusterStateCache:attributeCacheContainer.realContainer endpoint:endpoint queue:queue completion:^( @@ -81437,7 +82036,7 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device endpoint:(uint16 @end -@implementation MTRBaseClusterWakeOnLan +@implementation MTRBaseClusterWakeOnLAN - (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue { @@ -81476,29 +82075,30 @@ + (void)readAttributeMACAddressWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WakeOnLan::Attributes::MACAddress::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WakeOnLan::Attributes::MACAddress::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { MTRReadParams * params = [[MTRReadParams alloc] init]; using TypeInfo = WakeOnLan::Attributes::GeneratedCommandList::TypeInfo; - return MTRReadAttribute( + return MTRReadAttribute( params, completion, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -81508,7 +82108,7 @@ - (void)subscribeAttributeGeneratedCommandListWithParams:(MTRSubscribeParams * _ (void (^)(NSArray * _Nullable value, NSError * _Nullable error))reportHandler { using TypeInfo = WakeOnLan::Attributes::GeneratedCommandList::TypeInfo; - MTRSubscribeAttribute(params, subscriptionEstablished, reportHandler, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -81519,9 +82119,9 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC completion: (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { - auto * bridge = new MTRWakeOnLanGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( - ^(WakeOnLanGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { + auto * bridge = new MTRWakeOnLANGeneratedCommandListListAttributeCallbackBridge(queue, completion); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(WakeOnLANGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; using TypeInfo = WakeOnLan::Attributes::GeneratedCommandList::TypeInfo; @@ -81543,7 +82143,7 @@ - (void)readAttributeAcceptedCommandListWithCompletion:(void (^)(NSArray * _Null { MTRReadParams * params = [[MTRReadParams alloc] init]; using TypeInfo = WakeOnLan::Attributes::AcceptedCommandList::TypeInfo; - return MTRReadAttribute( + return MTRReadAttribute( params, completion, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -81553,7 +82153,7 @@ - (void)subscribeAttributeAcceptedCommandListWithParams:(MTRSubscribeParams * _N (void (^)(NSArray * _Nullable value, NSError * _Nullable error))reportHandler { using TypeInfo = WakeOnLan::Attributes::AcceptedCommandList::TypeInfo; - MTRSubscribeAttribute( + MTRSubscribeAttribute( params, subscriptionEstablished, reportHandler, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -81564,9 +82164,9 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa completion: (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { - auto * bridge = new MTRWakeOnLanAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( - ^(WakeOnLanAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { + auto * bridge = new MTRWakeOnLANAcceptedCommandListListAttributeCallbackBridge(queue, completion); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(WakeOnLANAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; using TypeInfo = WakeOnLan::Attributes::AcceptedCommandList::TypeInfo; @@ -81588,7 +82188,7 @@ - (void)readAttributeAttributeListWithCompletion:(void (^)(NSArray * _Nullable v { MTRReadParams * params = [[MTRReadParams alloc] init]; using TypeInfo = WakeOnLan::Attributes::AttributeList::TypeInfo; - return MTRReadAttribute( + return MTRReadAttribute( params, completion, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -81597,7 +82197,7 @@ - (void)subscribeAttributeAttributeListWithParams:(MTRSubscribeParams * _Nonnull reportHandler:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))reportHandler { using TypeInfo = WakeOnLan::Attributes::AttributeList::TypeInfo; - MTRSubscribeAttribute( + MTRSubscribeAttribute( params, subscriptionEstablished, reportHandler, self.callbackQueue, self.device, self->_endpoint, TypeInfo::GetClusterId(), TypeInfo::GetAttributeId()); } @@ -81607,23 +82207,24 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon queue:(dispatch_queue_t)queue completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { - auto * bridge = new MTRWakeOnLanAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(WakeOnLanAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WakeOnLan::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + auto * bridge = new MTRWakeOnLANAttributeListListAttributeCallbackBridge(queue, completion); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(WakeOnLANAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WakeOnLan::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -81650,22 +82251,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WakeOnLan::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WakeOnLan::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -81693,26 +82295,30 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = WakeOnLan::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = WakeOnLan::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end +@implementation MTRBaseClusterWakeOnLan +@end + @implementation MTRBaseClusterWakeOnLan (Deprecated) - (void)readAttributeMACAddressWithCompletionHandler:(void (^)( @@ -82106,22 +82712,23 @@ + (void)readAttributeChannelListWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRChannelChannelListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(ChannelChannelListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Channel::Attributes::ChannelList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(ChannelChannelListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Channel::Attributes::ChannelList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLineupWithCompletion:(void (^)( @@ -82151,22 +82758,23 @@ + (void)readAttributeLineupWithClusterStateCache:(MTRClusterStateCacheContainer NSError * _Nullable error))completion { auto * bridge = new MTRChannelLineupStructAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(ChannelLineupStructAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Channel::Attributes::Lineup::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(ChannelLineupStructAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Channel::Attributes::Lineup::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentChannelWithCompletion:(void (^)(MTRChannelClusterChannelInfo * _Nullable value, @@ -82197,22 +82805,23 @@ + (void)readAttributeCurrentChannelWithClusterStateCache:(MTRClusterStateCacheCo NSError * _Nullable error))completion { auto * bridge = new MTRChannelCurrentChannelStructAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(ChannelCurrentChannelStructAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Channel::Attributes::CurrentChannel::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(ChannelCurrentChannelStructAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Channel::Attributes::CurrentChannel::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -82241,7 +82850,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRChannelGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ChannelGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -82286,7 +82895,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRChannelAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ChannelAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -82329,22 +82938,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRChannelAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(ChannelAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Channel::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(ChannelAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Channel::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -82371,22 +82981,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Channel::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Channel::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -82414,22 +83025,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = Channel::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = Channel::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -82883,22 +83495,23 @@ + (void)readAttributeTargetListWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRTargetNavigatorTargetListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(TargetNavigatorTargetListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = TargetNavigator::Attributes::TargetList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(TargetNavigatorTargetListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = TargetNavigator::Attributes::TargetList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentTargetWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -82925,22 +83538,23 @@ + (void)readAttributeCurrentTargetWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = TargetNavigator::Attributes::CurrentTarget::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = TargetNavigator::Attributes::CurrentTarget::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -82969,7 +83583,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRTargetNavigatorGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(TargetNavigatorGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -83014,7 +83628,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRTargetNavigatorAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(TargetNavigatorAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -83057,7 +83671,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRTargetNavigatorAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(TargetNavigatorAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -83100,22 +83714,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = TargetNavigator::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = TargetNavigator::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -83143,22 +83758,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = TargetNavigator::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = TargetNavigator::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -83857,7 +84473,7 @@ + (void)readAttributeCurrentStateWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRMediaPlaybackClusterPlaybackStateEnumAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(MediaPlaybackClusterPlaybackStateEnumAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -83900,22 +84516,23 @@ + (void)readAttributeStartTimeWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = MediaPlayback::Attributes::StartTime::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = MediaPlayback::Attributes::StartTime::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDurationWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -83942,22 +84559,23 @@ + (void)readAttributeDurationWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = MediaPlayback::Attributes::Duration::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = MediaPlayback::Attributes::Duration::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSampledPositionWithCompletion:(void (^)(MTRMediaPlaybackClusterPlaybackPosition * _Nullable value, @@ -83988,7 +84606,7 @@ + (void)readAttributeSampledPositionWithClusterStateCache:(MTRClusterStateCacheC NSError * _Nullable error))completion { auto * bridge = new MTRMediaPlaybackSampledPositionStructAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(MediaPlaybackSampledPositionStructAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -84031,22 +84649,23 @@ + (void)readAttributePlaybackSpeedWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRFloatAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(FloatAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = MediaPlayback::Attributes::PlaybackSpeed::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(FloatAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = MediaPlayback::Attributes::PlaybackSpeed::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSeekRangeEndWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -84073,22 +84692,23 @@ + (void)readAttributeSeekRangeEndWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = MediaPlayback::Attributes::SeekRangeEnd::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = MediaPlayback::Attributes::SeekRangeEnd::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeSeekRangeStartWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -84115,22 +84735,23 @@ + (void)readAttributeSeekRangeStartWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = MediaPlayback::Attributes::SeekRangeStart::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = MediaPlayback::Attributes::SeekRangeStart::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -84159,7 +84780,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRMediaPlaybackGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(MediaPlaybackGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -84204,7 +84825,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRMediaPlaybackAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(MediaPlaybackAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -84247,7 +84868,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRMediaPlaybackAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(MediaPlaybackAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -84290,22 +84911,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = MediaPlayback::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = MediaPlayback::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -84333,22 +84955,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = MediaPlayback::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = MediaPlayback::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -85198,22 +85821,23 @@ + (void)readAttributeInputListWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRMediaInputInputListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(MediaInputInputListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = MediaInput::Attributes::InputList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(MediaInputInputListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = MediaInput::Attributes::InputList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentInputWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -85240,22 +85864,23 @@ + (void)readAttributeCurrentInputWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = MediaInput::Attributes::CurrentInput::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = MediaInput::Attributes::CurrentInput::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -85284,7 +85909,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRMediaInputGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(MediaInputGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -85329,7 +85954,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRMediaInputAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(MediaInputAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -85372,22 +85997,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRMediaInputAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(MediaInputAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = MediaInput::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(MediaInputAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = MediaInput::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -85414,22 +86040,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = MediaInput::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = MediaInput::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -85457,22 +86084,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = MediaInput::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = MediaInput::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -85891,7 +86519,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRLowPowerGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(LowPowerGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -85936,7 +86564,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRLowPowerAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(LowPowerAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -85979,22 +86607,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRLowPowerAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(LowPowerAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LowPower::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(LowPowerAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LowPower::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -86021,22 +86650,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LowPower::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LowPower::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -86064,22 +86694,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = LowPower::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = LowPower::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -86388,7 +87019,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRKeypadInputGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(KeypadInputGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -86433,7 +87064,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRKeypadInputAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(KeypadInputAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -86476,22 +87107,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRKeypadInputAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(KeypadInputAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = KeypadInput::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(KeypadInputAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = KeypadInput::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -86518,22 +87150,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = KeypadInput::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = KeypadInput::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -86561,22 +87194,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = KeypadInput::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = KeypadInput::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -87067,7 +87701,7 @@ + (void)readAttributeAcceptHeaderWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRContentLauncherAcceptHeaderListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ContentLauncherAcceptHeaderListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -87150,22 +87784,23 @@ + (void)readAttributeSupportedStreamingProtocolsWithClusterStateCache:(MTRCluste NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ContentLauncher::Attributes::SupportedStreamingProtocols::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ContentLauncher::Attributes::SupportedStreamingProtocols::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -87194,7 +87829,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRContentLauncherGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ContentLauncherGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -87239,7 +87874,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRContentLauncherAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ContentLauncherAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -87282,7 +87917,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRContentLauncherAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ContentLauncherAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -87325,22 +87960,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ContentLauncher::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ContentLauncher::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -87368,22 +88004,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ContentLauncher::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ContentLauncher::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -87832,22 +88469,23 @@ + (void)readAttributeOutputListWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRAudioOutputOutputListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(AudioOutputOutputListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AudioOutput::Attributes::OutputList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(AudioOutputOutputListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AudioOutput::Attributes::OutputList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentOutputWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -87874,22 +88512,23 @@ + (void)readAttributeCurrentOutputWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AudioOutput::Attributes::CurrentOutput::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AudioOutput::Attributes::CurrentOutput::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -87918,7 +88557,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRAudioOutputGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(AudioOutputGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -87963,7 +88602,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRAudioOutputAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(AudioOutputAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -88006,22 +88645,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRAudioOutputAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(AudioOutputAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AudioOutput::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(AudioOutputAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AudioOutput::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -88048,22 +88688,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AudioOutput::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AudioOutput::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -88091,22 +88732,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AudioOutput::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AudioOutput::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -88563,7 +89205,7 @@ + (void)readAttributeCatalogListWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRApplicationLauncherCatalogListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ApplicationLauncherCatalogListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -88660,7 +89302,7 @@ + (void)readAttributeCurrentAppWithClusterStateCache:(MTRClusterStateCacheContai NSError * _Nullable error))completion { auto * bridge = new MTRApplicationLauncherCurrentAppStructAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ApplicationLauncherCurrentAppStructAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -88706,7 +89348,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRApplicationLauncherGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ApplicationLauncherGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -88751,7 +89393,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRApplicationLauncherAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ApplicationLauncherAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -88794,7 +89436,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRApplicationLauncherAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ApplicationLauncherAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -88837,22 +89479,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ApplicationLauncher::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ApplicationLauncher::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -88880,22 +89523,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ApplicationLauncher::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ApplicationLauncher::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -89299,22 +89943,23 @@ + (void)readAttributeVendorNameWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ApplicationBasic::Attributes::VendorName::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ApplicationBasic::Attributes::VendorName::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeVendorIDWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -89341,22 +89986,23 @@ + (void)readAttributeVendorIDWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRVendorIdAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(VendorIdAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ApplicationBasic::Attributes::VendorID::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(VendorIdAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ApplicationBasic::Attributes::VendorID::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeApplicationNameWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -89384,22 +90030,23 @@ + (void)readAttributeApplicationNameWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ApplicationBasic::Attributes::ApplicationName::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ApplicationBasic::Attributes::ApplicationName::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeProductIDWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -89426,22 +90073,23 @@ + (void)readAttributeProductIDWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ApplicationBasic::Attributes::ProductID::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ApplicationBasic::Attributes::ProductID::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeApplicationWithCompletion:(void (^)(MTRApplicationBasicClusterApplicationBasicApplication * _Nullable value, @@ -89473,7 +90121,7 @@ + (void)readAttributeApplicationWithClusterStateCache:(MTRClusterStateCacheConta NSError * _Nullable error))completion { auto * bridge = new MTRApplicationBasicApplicationStructAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ApplicationBasicApplicationStructAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -89517,7 +90165,7 @@ + (void)readAttributeStatusWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRApplicationBasicClusterApplicationStatusEnumAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ApplicationBasicClusterApplicationStatusEnumAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -89562,22 +90210,23 @@ + (void)readAttributeApplicationVersionWithClusterStateCache:(MTRClusterStateCac (void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ApplicationBasic::Attributes::ApplicationVersion::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ApplicationBasic::Attributes::ApplicationVersion::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAllowedVendorListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -89605,7 +90254,7 @@ + (void)readAttributeAllowedVendorListWithClusterStateCache:(MTRClusterStateCach (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRApplicationBasicAllowedVendorListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ApplicationBasicAllowedVendorListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -89650,7 +90299,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRApplicationBasicGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ApplicationBasicGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -89695,7 +90344,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRApplicationBasicAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ApplicationBasicAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -89738,7 +90387,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRApplicationBasicAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ApplicationBasicAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -89781,22 +90430,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ApplicationBasic::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ApplicationBasic::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -89824,22 +90474,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ApplicationBasic::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ApplicationBasic::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -90561,7 +91212,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRAccountLoginGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(AccountLoginGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -90606,7 +91257,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRAccountLoginAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(AccountLoginAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -90649,22 +91300,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRAccountLoginAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(AccountLoginAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AccountLogin::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(AccountLoginAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AccountLogin::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -90691,22 +91343,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AccountLogin::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AccountLogin::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -90734,22 +91387,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = AccountLogin::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = AccountLogin::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -91109,22 +91763,23 @@ + (void)readAttributeMeasurementTypeWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::MeasurementType::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::MeasurementType::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDcVoltageWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91151,22 +91806,23 @@ + (void)readAttributeDcVoltageWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::DcVoltage::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::DcVoltage::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDcVoltageMinWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91193,22 +91849,23 @@ + (void)readAttributeDcVoltageMinWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::DcVoltageMin::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::DcVoltageMin::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDcVoltageMaxWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91235,22 +91892,23 @@ + (void)readAttributeDcVoltageMaxWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::DcVoltageMax::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::DcVoltageMax::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDcCurrentWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91277,22 +91935,23 @@ + (void)readAttributeDcCurrentWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::DcCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::DcCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDcCurrentMinWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91319,22 +91978,23 @@ + (void)readAttributeDcCurrentMinWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::DcCurrentMin::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::DcCurrentMin::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDcCurrentMaxWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91361,22 +92021,23 @@ + (void)readAttributeDcCurrentMaxWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::DcCurrentMax::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::DcCurrentMax::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDcPowerWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91403,22 +92064,23 @@ + (void)readAttributeDcPowerWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::DcPower::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::DcPower::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDcPowerMinWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91445,22 +92107,23 @@ + (void)readAttributeDcPowerMinWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::DcPowerMin::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::DcPowerMin::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDcPowerMaxWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91487,22 +92150,23 @@ + (void)readAttributeDcPowerMaxWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::DcPowerMax::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::DcPowerMax::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDcVoltageMultiplierWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91531,22 +92195,23 @@ + (void)readAttributeDcVoltageMultiplierWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::DcVoltageMultiplier::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::DcVoltageMultiplier::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDcVoltageDivisorWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91574,22 +92239,23 @@ + (void)readAttributeDcVoltageDivisorWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::DcVoltageDivisor::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::DcVoltageDivisor::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDcCurrentMultiplierWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91618,22 +92284,23 @@ + (void)readAttributeDcCurrentMultiplierWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::DcCurrentMultiplier::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::DcCurrentMultiplier::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDcCurrentDivisorWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91661,22 +92328,23 @@ + (void)readAttributeDcCurrentDivisorWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::DcCurrentDivisor::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::DcCurrentDivisor::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDcPowerMultiplierWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91704,22 +92372,23 @@ + (void)readAttributeDcPowerMultiplierWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::DcPowerMultiplier::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::DcPowerMultiplier::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeDcPowerDivisorWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91746,22 +92415,23 @@ + (void)readAttributeDcPowerDivisorWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::DcPowerDivisor::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::DcPowerDivisor::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcFrequencyWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91788,22 +92458,23 @@ + (void)readAttributeAcFrequencyWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcFrequency::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcFrequency::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcFrequencyMinWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91830,22 +92501,23 @@ + (void)readAttributeAcFrequencyMinWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcFrequencyMin::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcFrequencyMin::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcFrequencyMaxWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91872,22 +92544,23 @@ + (void)readAttributeAcFrequencyMaxWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcFrequencyMax::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcFrequencyMax::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNeutralCurrentWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91914,22 +92587,23 @@ + (void)readAttributeNeutralCurrentWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::NeutralCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::NeutralCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTotalActivePowerWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -91957,22 +92631,23 @@ + (void)readAttributeTotalActivePowerWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::TotalActivePower::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::TotalActivePower::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTotalReactivePowerWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -92001,22 +92676,23 @@ + (void)readAttributeTotalReactivePowerWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::TotalReactivePower::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::TotalReactivePower::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeTotalApparentPowerWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -92045,22 +92721,23 @@ + (void)readAttributeTotalApparentPowerWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::TotalApparentPower::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::TotalApparentPower::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMeasured1stHarmonicCurrentWithCompletion:(void (^)( @@ -92090,22 +92767,23 @@ + (void)readAttributeMeasured1stHarmonicCurrentWithClusterStateCache:(MTRCluster NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::Measured1stHarmonicCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::Measured1stHarmonicCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMeasured3rdHarmonicCurrentWithCompletion:(void (^)( @@ -92135,22 +92813,23 @@ + (void)readAttributeMeasured3rdHarmonicCurrentWithClusterStateCache:(MTRCluster NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::Measured3rdHarmonicCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::Measured3rdHarmonicCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMeasured5thHarmonicCurrentWithCompletion:(void (^)( @@ -92180,22 +92859,23 @@ + (void)readAttributeMeasured5thHarmonicCurrentWithClusterStateCache:(MTRCluster NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::Measured5thHarmonicCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::Measured5thHarmonicCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMeasured7thHarmonicCurrentWithCompletion:(void (^)( @@ -92225,22 +92905,23 @@ + (void)readAttributeMeasured7thHarmonicCurrentWithClusterStateCache:(MTRCluster NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::Measured7thHarmonicCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::Measured7thHarmonicCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMeasured9thHarmonicCurrentWithCompletion:(void (^)( @@ -92270,22 +92951,23 @@ + (void)readAttributeMeasured9thHarmonicCurrentWithClusterStateCache:(MTRCluster NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::Measured9thHarmonicCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::Measured9thHarmonicCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMeasured11thHarmonicCurrentWithCompletion:(void (^)( @@ -92315,22 +92997,23 @@ + (void)readAttributeMeasured11thHarmonicCurrentWithClusterStateCache:(MTRCluste NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::Measured11thHarmonicCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::Measured11thHarmonicCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMeasuredPhase1stHarmonicCurrentWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -92362,22 +93045,23 @@ + (void)readAttributeMeasuredPhase1stHarmonicCurrentWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::MeasuredPhase1stHarmonicCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::MeasuredPhase1stHarmonicCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMeasuredPhase3rdHarmonicCurrentWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -92409,22 +93093,23 @@ + (void)readAttributeMeasuredPhase3rdHarmonicCurrentWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::MeasuredPhase3rdHarmonicCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::MeasuredPhase3rdHarmonicCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMeasuredPhase5thHarmonicCurrentWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -92456,22 +93141,23 @@ + (void)readAttributeMeasuredPhase5thHarmonicCurrentWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::MeasuredPhase5thHarmonicCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::MeasuredPhase5thHarmonicCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMeasuredPhase7thHarmonicCurrentWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -92503,22 +93189,23 @@ + (void)readAttributeMeasuredPhase7thHarmonicCurrentWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::MeasuredPhase7thHarmonicCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::MeasuredPhase7thHarmonicCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMeasuredPhase9thHarmonicCurrentWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -92550,22 +93237,23 @@ + (void)readAttributeMeasuredPhase9thHarmonicCurrentWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::MeasuredPhase9thHarmonicCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::MeasuredPhase9thHarmonicCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeMeasuredPhase11thHarmonicCurrentWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -92597,22 +93285,23 @@ + (void)readAttributeMeasuredPhase11thHarmonicCurrentWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::MeasuredPhase11thHarmonicCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::MeasuredPhase11thHarmonicCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcFrequencyMultiplierWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -92641,22 +93330,23 @@ + (void)readAttributeAcFrequencyMultiplierWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcFrequencyMultiplier::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcFrequencyMultiplier::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcFrequencyDivisorWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -92685,22 +93375,23 @@ + (void)readAttributeAcFrequencyDivisorWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcFrequencyDivisor::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcFrequencyDivisor::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePowerMultiplierWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -92728,22 +93419,23 @@ + (void)readAttributePowerMultiplierWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::PowerMultiplier::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::PowerMultiplier::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePowerDivisorWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -92770,22 +93462,23 @@ + (void)readAttributePowerDivisorWithClusterStateCache:(MTRClusterStateCacheCont completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::PowerDivisor::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::PowerDivisor::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeHarmonicCurrentMultiplierWithCompletion:(void (^)( @@ -92815,22 +93508,23 @@ + (void)readAttributeHarmonicCurrentMultiplierWithClusterStateCache:(MTRClusterS NSError * _Nullable error))completion { auto * bridge = new MTRInt8sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::HarmonicCurrentMultiplier::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::HarmonicCurrentMultiplier::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePhaseHarmonicCurrentMultiplierWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -92861,22 +93555,23 @@ + (void)readAttributePhaseHarmonicCurrentMultiplierWithClusterStateCache:(MTRClu NSError * _Nullable error))completion { auto * bridge = new MTRInt8sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::PhaseHarmonicCurrentMultiplier::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::PhaseHarmonicCurrentMultiplier::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInstantaneousVoltageWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -92905,22 +93600,23 @@ + (void)readAttributeInstantaneousVoltageWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::InstantaneousVoltage::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::InstantaneousVoltage::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInstantaneousLineCurrentWithCompletion:(void (^)( @@ -92950,22 +93646,23 @@ + (void)readAttributeInstantaneousLineCurrentWithClusterStateCache:(MTRClusterSt NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::InstantaneousLineCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::InstantaneousLineCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInstantaneousActiveCurrentWithCompletion:(void (^)( @@ -92995,22 +93692,23 @@ + (void)readAttributeInstantaneousActiveCurrentWithClusterStateCache:(MTRCluster NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::InstantaneousActiveCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::InstantaneousActiveCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInstantaneousReactiveCurrentWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -93041,22 +93739,23 @@ + (void)readAttributeInstantaneousReactiveCurrentWithClusterStateCache:(MTRClust NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::InstantaneousReactiveCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::InstantaneousReactiveCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInstantaneousPowerWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -93085,22 +93784,23 @@ + (void)readAttributeInstantaneousPowerWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::InstantaneousPower::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::InstantaneousPower::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltageWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -93127,22 +93827,23 @@ + (void)readAttributeRmsVoltageWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltage::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltage::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltageMinWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -93169,22 +93870,23 @@ + (void)readAttributeRmsVoltageMinWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageMin::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageMin::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltageMaxWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -93211,22 +93913,23 @@ + (void)readAttributeRmsVoltageMaxWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageMax::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageMax::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsCurrentWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -93253,22 +93956,23 @@ + (void)readAttributeRmsCurrentWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrent::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrent::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsCurrentMinWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -93295,22 +93999,23 @@ + (void)readAttributeRmsCurrentMinWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentMin::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentMin::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsCurrentMaxWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -93337,22 +94042,23 @@ + (void)readAttributeRmsCurrentMaxWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentMax::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentMax::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActivePowerWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -93379,22 +94085,23 @@ + (void)readAttributeActivePowerWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ActivePower::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ActivePower::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActivePowerMinWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -93421,22 +94128,23 @@ + (void)readAttributeActivePowerMinWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerMin::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerMin::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActivePowerMaxWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -93463,22 +94171,23 @@ + (void)readAttributeActivePowerMaxWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerMax::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerMax::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeReactivePowerWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -93505,22 +94214,23 @@ + (void)readAttributeReactivePowerWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ReactivePower::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ReactivePower::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeApparentPowerWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -93547,22 +94257,23 @@ + (void)readAttributeApparentPowerWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ApparentPower::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ApparentPower::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePowerFactorWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -93589,22 +94300,23 @@ + (void)readAttributePowerFactorWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::PowerFactor::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::PowerFactor::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAverageRmsVoltageMeasurementPeriodWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -93674,22 +94386,23 @@ + (void)readAttributeAverageRmsVoltageMeasurementPeriodWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsVoltageMeasurementPeriod::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsVoltageMeasurementPeriod::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAverageRmsUnderVoltageCounterWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -93757,22 +94470,23 @@ + (void)readAttributeAverageRmsUnderVoltageCounterWithClusterStateCache:(MTRClus NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsUnderVoltageCounter::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsUnderVoltageCounter::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsExtremeOverVoltagePeriodWithCompletion:(void (^)( @@ -93839,22 +94553,23 @@ + (void)readAttributeRmsExtremeOverVoltagePeriodWithClusterStateCache:(MTRCluste NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeOverVoltagePeriod::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeOverVoltagePeriod::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsExtremeUnderVoltagePeriodWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -93922,22 +94637,23 @@ + (void)readAttributeRmsExtremeUnderVoltagePeriodWithClusterStateCache:(MTRClust NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeUnderVoltagePeriod::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeUnderVoltagePeriod::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltageSagPeriodWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94003,22 +94719,23 @@ + (void)readAttributeRmsVoltageSagPeriodWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSagPeriod::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSagPeriod::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltageSwellPeriodWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94084,22 +94801,23 @@ + (void)readAttributeRmsVoltageSwellPeriodWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSwellPeriod::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSwellPeriod::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcVoltageMultiplierWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94128,22 +94846,23 @@ + (void)readAttributeAcVoltageMultiplierWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcVoltageMultiplier::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcVoltageMultiplier::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcVoltageDivisorWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94171,22 +94890,23 @@ + (void)readAttributeAcVoltageDivisorWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcVoltageDivisor::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcVoltageDivisor::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcCurrentMultiplierWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94215,22 +94935,23 @@ + (void)readAttributeAcCurrentMultiplierWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcCurrentMultiplier::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcCurrentMultiplier::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcCurrentDivisorWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94258,22 +94979,23 @@ + (void)readAttributeAcCurrentDivisorWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcCurrentDivisor::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcCurrentDivisor::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcPowerMultiplierWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94301,22 +95023,23 @@ + (void)readAttributeAcPowerMultiplierWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcPowerMultiplier::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcPowerMultiplier::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcPowerDivisorWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94343,22 +95066,23 @@ + (void)readAttributeAcPowerDivisorWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcPowerDivisor::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcPowerDivisor::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOverloadAlarmsMaskWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94424,22 +95148,23 @@ + (void)readAttributeOverloadAlarmsMaskWithClusterStateCache:(MTRClusterStateCac (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::OverloadAlarmsMask::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::OverloadAlarmsMask::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeVoltageOverloadWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94467,22 +95192,23 @@ + (void)readAttributeVoltageOverloadWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::VoltageOverload::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::VoltageOverload::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCurrentOverloadWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94510,22 +95236,23 @@ + (void)readAttributeCurrentOverloadWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::CurrentOverload::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::CurrentOverload::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcOverloadAlarmsMaskWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94591,22 +95318,23 @@ + (void)readAttributeAcOverloadAlarmsMaskWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcOverloadAlarmsMask::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcOverloadAlarmsMask::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcVoltageOverloadWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94634,22 +95362,23 @@ + (void)readAttributeAcVoltageOverloadWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcVoltageOverload::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcVoltageOverload::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcCurrentOverloadWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94677,22 +95406,23 @@ + (void)readAttributeAcCurrentOverloadWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcCurrentOverload::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcCurrentOverload::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcActivePowerOverloadWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94721,22 +95451,23 @@ + (void)readAttributeAcActivePowerOverloadWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcActivePowerOverload::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcActivePowerOverload::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAcReactivePowerOverloadWithCompletion:(void (^)( @@ -94766,22 +95497,23 @@ + (void)readAttributeAcReactivePowerOverloadWithClusterStateCache:(MTRClusterSta NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AcReactivePowerOverload::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AcReactivePowerOverload::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAverageRmsOverVoltageWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94810,22 +95542,23 @@ + (void)readAttributeAverageRmsOverVoltageWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsOverVoltage::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsOverVoltage::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAverageRmsUnderVoltageWithCompletion:(void (^)( @@ -94855,22 +95588,23 @@ + (void)readAttributeAverageRmsUnderVoltageWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsUnderVoltage::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsUnderVoltage::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsExtremeOverVoltageWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94899,22 +95633,23 @@ + (void)readAttributeRmsExtremeOverVoltageWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeOverVoltage::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeOverVoltage::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsExtremeUnderVoltageWithCompletion:(void (^)( @@ -94944,22 +95679,23 @@ + (void)readAttributeRmsExtremeUnderVoltageWithClusterStateCache:(MTRClusterStat NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeUnderVoltage::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeUnderVoltage::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltageSagWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -94986,22 +95722,23 @@ + (void)readAttributeRmsVoltageSagWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSag::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSag::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltageSwellWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95029,22 +95766,23 @@ + (void)readAttributeRmsVoltageSwellWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSwell::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSwell::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLineCurrentPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95072,22 +95810,23 @@ + (void)readAttributeLineCurrentPhaseBWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::LineCurrentPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::LineCurrentPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActiveCurrentPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95116,22 +95855,23 @@ + (void)readAttributeActiveCurrentPhaseBWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ActiveCurrentPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ActiveCurrentPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeReactiveCurrentPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95160,22 +95900,23 @@ + (void)readAttributeReactiveCurrentPhaseBWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ReactiveCurrentPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ReactiveCurrentPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltagePhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95203,22 +95944,23 @@ + (void)readAttributeRmsVoltagePhaseBWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltagePhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltagePhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltageMinPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95247,22 +95989,23 @@ + (void)readAttributeRmsVoltageMinPhaseBWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageMinPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageMinPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltageMaxPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95291,22 +96034,23 @@ + (void)readAttributeRmsVoltageMaxPhaseBWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageMaxPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageMaxPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsCurrentPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95334,22 +96078,23 @@ + (void)readAttributeRmsCurrentPhaseBWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsCurrentMinPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95378,22 +96123,23 @@ + (void)readAttributeRmsCurrentMinPhaseBWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentMinPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentMinPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsCurrentMaxPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95422,22 +96168,23 @@ + (void)readAttributeRmsCurrentMaxPhaseBWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentMaxPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentMaxPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActivePowerPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95465,22 +96212,23 @@ + (void)readAttributeActivePowerPhaseBWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActivePowerMinPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95509,22 +96257,23 @@ + (void)readAttributeActivePowerMinPhaseBWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerMinPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerMinPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActivePowerMaxPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95553,22 +96302,23 @@ + (void)readAttributeActivePowerMaxPhaseBWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerMaxPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerMaxPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeReactivePowerPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95597,22 +96347,23 @@ + (void)readAttributeReactivePowerPhaseBWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ReactivePowerPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ReactivePowerPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeApparentPowerPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95641,22 +96392,23 @@ + (void)readAttributeApparentPowerPhaseBWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ApparentPowerPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ApparentPowerPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePowerFactorPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -95684,22 +96436,23 @@ + (void)readAttributePowerFactorPhaseBWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::PowerFactorPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::PowerFactorPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAverageRmsVoltageMeasurementPeriodPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -95731,22 +96484,23 @@ + (void)readAttributeAverageRmsVoltageMeasurementPeriodPhaseBWithClusterStateCac NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsVoltageMeasurementPeriodPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsVoltageMeasurementPeriodPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAverageRmsOverVoltageCounterPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -95778,22 +96532,23 @@ + (void)readAttributeAverageRmsOverVoltageCounterPhaseBWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsOverVoltageCounterPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsOverVoltageCounterPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAverageRmsUnderVoltageCounterPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -95825,22 +96580,23 @@ + (void)readAttributeAverageRmsUnderVoltageCounterPhaseBWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsUnderVoltageCounterPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsUnderVoltageCounterPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsExtremeOverVoltagePeriodPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -95872,22 +96628,23 @@ + (void)readAttributeRmsExtremeOverVoltagePeriodPhaseBWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeOverVoltagePeriodPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeOverVoltagePeriodPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsExtremeUnderVoltagePeriodPhaseBWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -95919,22 +96676,23 @@ + (void)readAttributeRmsExtremeUnderVoltagePeriodPhaseBWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeUnderVoltagePeriodPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeUnderVoltagePeriodPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltageSagPeriodPhaseBWithCompletion:(void (^)( @@ -95964,22 +96722,23 @@ + (void)readAttributeRmsVoltageSagPeriodPhaseBWithClusterStateCache:(MTRClusterS NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSagPeriodPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSagPeriodPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltageSwellPeriodPhaseBWithCompletion:(void (^)( @@ -96009,22 +96768,23 @@ + (void)readAttributeRmsVoltageSwellPeriodPhaseBWithClusterStateCache:(MTRCluste NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSwellPeriodPhaseB::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSwellPeriodPhaseB::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLineCurrentPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -96052,22 +96812,23 @@ + (void)readAttributeLineCurrentPhaseCWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::LineCurrentPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::LineCurrentPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActiveCurrentPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -96096,22 +96857,23 @@ + (void)readAttributeActiveCurrentPhaseCWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ActiveCurrentPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ActiveCurrentPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeReactiveCurrentPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -96140,22 +96902,23 @@ + (void)readAttributeReactiveCurrentPhaseCWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ReactiveCurrentPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ReactiveCurrentPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltagePhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -96183,22 +96946,23 @@ + (void)readAttributeRmsVoltagePhaseCWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltagePhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltagePhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltageMinPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -96227,22 +96991,23 @@ + (void)readAttributeRmsVoltageMinPhaseCWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageMinPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageMinPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltageMaxPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -96271,22 +97036,23 @@ + (void)readAttributeRmsVoltageMaxPhaseCWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageMaxPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageMaxPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsCurrentPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -96314,22 +97080,23 @@ + (void)readAttributeRmsCurrentPhaseCWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsCurrentMinPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -96358,22 +97125,23 @@ + (void)readAttributeRmsCurrentMinPhaseCWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentMinPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentMinPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsCurrentMaxPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -96402,22 +97170,23 @@ + (void)readAttributeRmsCurrentMaxPhaseCWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentMaxPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsCurrentMaxPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActivePowerPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -96445,22 +97214,23 @@ + (void)readAttributeActivePowerPhaseCWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActivePowerMinPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -96489,22 +97259,23 @@ + (void)readAttributeActivePowerMinPhaseCWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerMinPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerMinPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeActivePowerMaxPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -96533,22 +97304,23 @@ + (void)readAttributeActivePowerMaxPhaseCWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerMaxPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ActivePowerMaxPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeReactivePowerPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -96577,22 +97349,23 @@ + (void)readAttributeReactivePowerPhaseCWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ReactivePowerPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ReactivePowerPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeApparentPowerPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -96621,22 +97394,23 @@ + (void)readAttributeApparentPowerPhaseCWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ApparentPowerPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ApparentPowerPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributePowerFactorPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -96664,22 +97438,23 @@ + (void)readAttributePowerFactorPhaseCWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::PowerFactorPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::PowerFactorPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAverageRmsVoltageMeasurementPeriodPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -96711,22 +97486,23 @@ + (void)readAttributeAverageRmsVoltageMeasurementPeriodPhaseCWithClusterStateCac NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsVoltageMeasurementPeriodPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsVoltageMeasurementPeriodPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAverageRmsOverVoltageCounterPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -96758,22 +97534,23 @@ + (void)readAttributeAverageRmsOverVoltageCounterPhaseCWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsOverVoltageCounterPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsOverVoltageCounterPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAverageRmsUnderVoltageCounterPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -96805,22 +97582,23 @@ + (void)readAttributeAverageRmsUnderVoltageCounterPhaseCWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsUnderVoltageCounterPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::AverageRmsUnderVoltageCounterPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsExtremeOverVoltagePeriodPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -96852,22 +97630,23 @@ + (void)readAttributeRmsExtremeOverVoltagePeriodPhaseCWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeOverVoltagePeriodPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeOverVoltagePeriodPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsExtremeUnderVoltagePeriodPhaseCWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -96899,22 +97678,23 @@ + (void)readAttributeRmsExtremeUnderVoltagePeriodPhaseCWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeUnderVoltagePeriodPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsExtremeUnderVoltagePeriodPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltageSagPeriodPhaseCWithCompletion:(void (^)( @@ -96944,22 +97724,23 @@ + (void)readAttributeRmsVoltageSagPeriodPhaseCWithClusterStateCache:(MTRClusterS NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSagPeriodPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSagPeriodPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRmsVoltageSwellPeriodPhaseCWithCompletion:(void (^)( @@ -96989,22 +97770,23 @@ + (void)readAttributeRmsVoltageSwellPeriodPhaseCWithClusterStateCache:(MTRCluste NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSwellPeriodPhaseC::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::RmsVoltageSwellPeriodPhaseC::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -97034,7 +97816,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRElectricalMeasurementGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ElectricalMeasurementGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -97080,7 +97862,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRElectricalMeasurementAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ElectricalMeasurementAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -97123,7 +97905,7 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRElectricalMeasurementAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(ElectricalMeasurementAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -97166,22 +97948,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -97209,22 +97992,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = ElectricalMeasurement::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = ElectricalMeasurement::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end @@ -104710,22 +105494,23 @@ + (void)readAttributeBooleanWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Boolean::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Boolean::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBitmap8WithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -104789,22 +105574,23 @@ + (void)readAttributeBitmap8WithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingBitmap8AttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(UnitTestingBitmap8AttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Bitmap8::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(UnitTestingBitmap8AttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Bitmap8::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBitmap16WithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -104868,22 +105654,23 @@ + (void)readAttributeBitmap16WithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingBitmap16AttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(UnitTestingBitmap16AttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Bitmap16::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(UnitTestingBitmap16AttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Bitmap16::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBitmap32WithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -104947,22 +105734,23 @@ + (void)readAttributeBitmap32WithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingBitmap32AttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(UnitTestingBitmap32AttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Bitmap32::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(UnitTestingBitmap32AttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Bitmap32::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeBitmap64WithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -105026,22 +105814,23 @@ + (void)readAttributeBitmap64WithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingBitmap64AttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(UnitTestingBitmap64AttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Bitmap64::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(UnitTestingBitmap64AttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Bitmap64::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt8uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -105105,22 +105894,23 @@ + (void)readAttributeInt8uWithClusterStateCache:(MTRClusterStateCacheContainer * completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int8u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int8u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt16uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -105184,22 +105974,23 @@ + (void)readAttributeInt16uWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int16u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int16u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt24uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -105263,22 +106054,23 @@ + (void)readAttributeInt24uWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int24u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int24u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt32uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -105342,22 +106134,23 @@ + (void)readAttributeInt32uWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int32u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int32u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt40uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -105421,22 +106214,23 @@ + (void)readAttributeInt40uWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int40u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int40u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt48uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -105500,22 +106294,23 @@ + (void)readAttributeInt48uWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int48u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int48u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt56uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -105579,22 +106374,23 @@ + (void)readAttributeInt56uWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int56u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int56u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt64uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -105658,22 +106454,23 @@ + (void)readAttributeInt64uWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int64u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int64u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt8sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -105737,22 +106534,23 @@ + (void)readAttributeInt8sWithClusterStateCache:(MTRClusterStateCacheContainer * completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int8s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int8s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt16sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -105816,22 +106614,23 @@ + (void)readAttributeInt16sWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int16s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int16s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt24sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -105895,22 +106694,23 @@ + (void)readAttributeInt24sWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int24s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int24s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt32sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -105974,22 +106774,23 @@ + (void)readAttributeInt32sWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int32s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int32s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt40sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -106053,22 +106854,23 @@ + (void)readAttributeInt40sWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int40s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int40s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt48sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -106132,22 +106934,23 @@ + (void)readAttributeInt48sWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int48s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int48s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt56sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -106211,22 +107014,23 @@ + (void)readAttributeInt56sWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int56s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int56s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeInt64sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -106290,22 +107094,23 @@ + (void)readAttributeInt64sWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Int64s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Int64s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeEnum8WithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -106369,22 +107174,23 @@ + (void)readAttributeEnum8WithClusterStateCache:(MTRClusterStateCacheContainer * completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Enum8::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Enum8::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeEnum16WithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -106448,22 +107254,23 @@ + (void)readAttributeEnum16WithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Enum16::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Enum16::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFloatSingleWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -106527,22 +107334,23 @@ + (void)readAttributeFloatSingleWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRFloatAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(FloatAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::FloatSingle::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(FloatAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::FloatSingle::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFloatDoubleWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -106606,22 +107414,23 @@ + (void)readAttributeFloatDoubleWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRDoubleAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(DoubleAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::FloatDouble::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(DoubleAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::FloatDouble::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeOctetStringWithCompletion:(void (^)(NSData * _Nullable value, NSError * _Nullable error))completion @@ -106685,22 +107494,23 @@ + (void)readAttributeOctetStringWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSData * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROctetStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(OctetStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::OctetString::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(OctetStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::OctetString::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeListInt8uWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -106785,22 +107595,23 @@ + (void)readAttributeListInt8uWithClusterStateCache:(MTRClusterStateCacheContain completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingListInt8uListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(UnitTestingListInt8uListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::ListInt8u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(UnitTestingListInt8uListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::ListInt8u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeListOctetStringWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -106885,7 +107696,7 @@ + (void)readAttributeListOctetStringWithClusterStateCache:(MTRClusterStateCacheC completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingListOctetStringListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(UnitTestingListOctetStringListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -106989,7 +107800,7 @@ + (void)readAttributeListStructOctetStringWithClusterStateCache:(MTRClusterState (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingListStructOctetStringListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(UnitTestingListStructOctetStringListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -107069,22 +107880,23 @@ + (void)readAttributeLongOctetStringWithClusterStateCache:(MTRClusterStateCacheC completion:(void (^)(NSData * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTROctetStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(OctetStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::LongOctetString::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(OctetStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::LongOctetString::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCharStringWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -107148,22 +107960,23 @@ + (void)readAttributeCharStringWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::CharString::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::CharString::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeLongCharStringWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -107227,22 +108040,23 @@ + (void)readAttributeLongCharStringWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::LongCharString::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(CharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::LongCharString::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeEpochUsWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -107306,22 +108120,23 @@ + (void)readAttributeEpochUsWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::EpochUs::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::EpochUs::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeEpochSWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -107385,22 +108200,23 @@ + (void)readAttributeEpochSWithClusterStateCache:(MTRClusterStateCacheContainer completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::EpochS::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::EpochS::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeVendorIdWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -107464,22 +108280,23 @@ + (void)readAttributeVendorIdWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRVendorIdAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(VendorIdAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::VendorId::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(VendorIdAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::VendorId::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeListNullablesAndOptionalsStructWithCompletion:(void (^)(NSArray * _Nullable value, @@ -107742,7 +108559,7 @@ + (void)readAttributeListNullablesAndOptionalsStructWithClusterStateCache: NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingListNullablesAndOptionalsStructListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(UnitTestingListNullablesAndOptionalsStructListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -107822,22 +108639,23 @@ + (void)readAttributeEnumAttrWithClusterStateCache:(MTRClusterStateCacheContaine completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingClusterSimpleEnumAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(UnitTestingClusterSimpleEnumAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::EnumAttr::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(UnitTestingClusterSimpleEnumAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::EnumAttr::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeStructAttrWithCompletion:(void (^)(MTRUnitTestingClusterSimpleStruct * _Nullable value, @@ -107913,22 +108731,23 @@ + (void)readAttributeStructAttrWithClusterStateCache:(MTRClusterStateCacheContai NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingStructAttrStructAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(UnitTestingStructAttrStructAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::StructAttr::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(UnitTestingStructAttrStructAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::StructAttr::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRangeRestrictedInt8uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -107994,22 +108813,23 @@ + (void)readAttributeRangeRestrictedInt8uWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::RangeRestrictedInt8u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::RangeRestrictedInt8u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRangeRestrictedInt8sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -108075,22 +108895,23 @@ + (void)readAttributeRangeRestrictedInt8sWithClusterStateCache:(MTRClusterStateC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::RangeRestrictedInt8s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::RangeRestrictedInt8s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRangeRestrictedInt16uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -108156,22 +108977,23 @@ + (void)readAttributeRangeRestrictedInt16uWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::RangeRestrictedInt16u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::RangeRestrictedInt16u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeRangeRestrictedInt16sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -108237,22 +109059,23 @@ + (void)readAttributeRangeRestrictedInt16sWithClusterStateCache:(MTRClusterState (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::RangeRestrictedInt16s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::RangeRestrictedInt16s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeListLongOctetStringWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -108339,7 +109162,7 @@ + (void)readAttributeListLongOctetStringWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingListLongOctetStringListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(UnitTestingListLongOctetStringListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -108498,7 +109321,7 @@ + (void)readAttributeListFabricScopedWithClusterStateCache:(MTRClusterStateCache (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingListFabricScopedListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(UnitTestingListFabricScopedListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -108579,22 +109402,23 @@ + (void)readAttributeTimedWriteBooleanWithClusterStateCache:(MTRClusterStateCach (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::TimedWriteBoolean::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::TimedWriteBoolean::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneralErrorBooleanWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -108660,22 +109484,23 @@ + (void)readAttributeGeneralErrorBooleanWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::GeneralErrorBoolean::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::GeneralErrorBoolean::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterErrorBooleanWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -108741,22 +109566,23 @@ + (void)readAttributeClusterErrorBooleanWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::ClusterErrorBoolean::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::ClusterErrorBoolean::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeUnsupportedWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -108820,22 +109646,23 @@ + (void)readAttributeUnsupportedWithClusterStateCache:(MTRClusterStateCacheConta completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::Unsupported::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(BooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::Unsupported::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableBooleanWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -108905,22 +109732,23 @@ + (void)readAttributeNullableBooleanWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableBooleanAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableBooleanAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableBoolean::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableBooleanAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableBoolean::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableBitmap8WithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -108990,22 +109818,23 @@ + (void)readAttributeNullableBitmap8WithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingNullableBitmap8AttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(UnitTestingNullableBitmap8AttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableBitmap8::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(UnitTestingNullableBitmap8AttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableBitmap8::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableBitmap16WithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -109075,22 +109904,23 @@ + (void)readAttributeNullableBitmap16WithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingNullableBitmap16AttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(UnitTestingNullableBitmap16AttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableBitmap16::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(UnitTestingNullableBitmap16AttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableBitmap16::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableBitmap32WithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -109160,22 +109990,23 @@ + (void)readAttributeNullableBitmap32WithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingNullableBitmap32AttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(UnitTestingNullableBitmap32AttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableBitmap32::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(UnitTestingNullableBitmap32AttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableBitmap32::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableBitmap64WithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -109245,22 +110076,23 @@ + (void)readAttributeNullableBitmap64WithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingNullableBitmap64AttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(UnitTestingNullableBitmap64AttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableBitmap64::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(UnitTestingNullableBitmap64AttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableBitmap64::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt8uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -109329,22 +110161,23 @@ + (void)readAttributeNullableInt8uWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt8u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt8u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt16uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -109413,22 +110246,23 @@ + (void)readAttributeNullableInt16uWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt16u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt16u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt24uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -109497,22 +110331,23 @@ + (void)readAttributeNullableInt24uWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt24u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt24u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt32uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -109581,22 +110416,23 @@ + (void)readAttributeNullableInt32uWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt32u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt32u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt40uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -109665,22 +110501,23 @@ + (void)readAttributeNullableInt40uWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt40u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt40u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt48uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -109749,22 +110586,23 @@ + (void)readAttributeNullableInt48uWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt48u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt48u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt56uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -109833,22 +110671,23 @@ + (void)readAttributeNullableInt56uWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt56u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt56u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt64uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -109917,22 +110756,23 @@ + (void)readAttributeNullableInt64uWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt64u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt64u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt8sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -110001,22 +110841,23 @@ + (void)readAttributeNullableInt8sWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt8s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt8s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt16sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -110085,22 +110926,23 @@ + (void)readAttributeNullableInt16sWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt16s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt16s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt24sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -110169,22 +111011,23 @@ + (void)readAttributeNullableInt24sWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt24s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt24s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt32sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -110253,22 +111096,23 @@ + (void)readAttributeNullableInt32sWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt32sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt32sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt32s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt32sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt32s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt40sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -110337,22 +111181,23 @@ + (void)readAttributeNullableInt40sWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt40s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt40s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt48sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -110421,22 +111266,23 @@ + (void)readAttributeNullableInt48sWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt48s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt48s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt56sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -110505,22 +111351,23 @@ + (void)readAttributeNullableInt56sWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt56s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt56s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableInt64sWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -110589,22 +111436,23 @@ + (void)readAttributeNullableInt64sWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt64sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt64sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableInt64s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt64sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableInt64s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableEnum8WithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -110673,22 +111521,23 @@ + (void)readAttributeNullableEnum8WithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableEnum8::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableEnum8::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableEnum16WithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -110757,22 +111606,23 @@ + (void)readAttributeNullableEnum16WithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableEnum16::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableEnum16::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableFloatSingleWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -110843,22 +111693,23 @@ + (void)readAttributeNullableFloatSingleWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableFloatAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableFloatAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableFloatSingle::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableFloatAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableFloatSingle::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableFloatDoubleWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -110929,22 +111780,23 @@ + (void)readAttributeNullableFloatDoubleWithClusterStateCache:(MTRClusterStateCa (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableDoubleAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableDoubleAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableFloatDouble::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableDoubleAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableFloatDouble::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableOctetStringWithCompletion:(void (^)(NSData * _Nullable value, NSError * _Nullable error))completion @@ -111014,22 +111866,23 @@ + (void)readAttributeNullableOctetStringWithClusterStateCache:(MTRClusterStateCa (void (^)(NSData * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableOctetStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableOctetStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableOctetString::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableOctetStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableOctetString::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableCharStringWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion @@ -111100,22 +111953,23 @@ + (void)readAttributeNullableCharStringWithClusterStateCache:(MTRClusterStateCac (void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableCharStringAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableCharStringAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableCharString::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableCharStringAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableCharString::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableEnumAttrWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -111185,7 +112039,7 @@ + (void)readAttributeNullableEnumAttrWithClusterStateCache:(MTRClusterStateCache (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRNullableUnitTestingClusterSimpleEnumAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(NullableUnitTestingClusterSimpleEnumAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -111284,7 +112138,7 @@ + (void)readAttributeNullableStructWithClusterStateCache:(MTRClusterStateCacheCo NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingNullableStructStructAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(UnitTestingNullableStructStructAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -111373,22 +112227,23 @@ + (void)readAttributeNullableRangeRestrictedInt8uWithClusterStateCache:(MTRClust NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableRangeRestrictedInt8u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableRangeRestrictedInt8u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableRangeRestrictedInt8sWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -111461,22 +112316,23 @@ + (void)readAttributeNullableRangeRestrictedInt8sWithClusterStateCache:(MTRClust NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt8sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt8sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableRangeRestrictedInt8s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt8sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableRangeRestrictedInt8s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableRangeRestrictedInt16uWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -111549,22 +112405,23 @@ + (void)readAttributeNullableRangeRestrictedInt16uWithClusterStateCache:(MTRClus NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableRangeRestrictedInt16u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableRangeRestrictedInt16u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeNullableRangeRestrictedInt16sWithCompletion:(void (^)(NSNumber * _Nullable value, @@ -111637,22 +112494,23 @@ + (void)readAttributeNullableRangeRestrictedInt16sWithClusterStateCache:(MTRClus NSError * _Nullable error))completion { auto * bridge = new MTRNullableInt16sAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::NullableRangeRestrictedInt16s::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(NullableInt16sAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::NullableRangeRestrictedInt16s::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeWriteOnlyInt8uWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -111716,22 +112574,23 @@ + (void)readAttributeWriteOnlyInt8uWithClusterStateCache:(MTRClusterStateCacheCo completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt8uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::WriteOnlyInt8u::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int8uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::WriteOnlyInt8u::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion @@ -111760,7 +112619,7 @@ + (void)readAttributeGeneratedCommandListWithClusterStateCache:(MTRClusterStateC (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingGeneratedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(UnitTestingGeneratedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -111805,7 +112664,7 @@ + (void)readAttributeAcceptedCommandListWithClusterStateCache:(MTRClusterStateCa (void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingAcceptedCommandListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction( + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, ^(UnitTestingAcceptedCommandListListAttributeCallback successCb, MTRErrorCallback failureCb) { if (clusterStateCacheContainer.cppClusterStateCache) { chip::app::ConcreteAttributePath path; @@ -111848,22 +112707,23 @@ + (void)readAttributeAttributeListWithClusterStateCache:(MTRClusterStateCacheCon completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRUnitTestingAttributeListListAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(UnitTestingAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::AttributeList::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction(clusterStateCacheContainer.baseDevice, + ^(UnitTestingAttributeListListAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::AttributeList::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeFeatureMapWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -111890,22 +112750,23 @@ + (void)readAttributeFeatureMapWithClusterStateCache:(MTRClusterStateCacheContai completion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt32uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::FeatureMap::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int32uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::FeatureMap::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeClusterRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion @@ -111933,22 +112794,23 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { auto * bridge = new MTRInt16uAttributeCallbackBridge(queue, completion); - std::move(*bridge).DispatchLocalAction(^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { - if (clusterStateCacheContainer.cppClusterStateCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = UnitTesting::Attributes::ClusterRevision::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); - if (err == CHIP_NO_ERROR) { - successCb(bridge, value); - } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + std::move(*bridge).DispatchLocalAction( + clusterStateCacheContainer.baseDevice, ^(Int16uAttributeCallback successCb, MTRErrorCallback failureCb) { + if (clusterStateCacheContainer.cppClusterStateCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = UnitTesting::Attributes::ClusterRevision::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = clusterStateCacheContainer.cppClusterStateCache->Get(path, value); + if (err == CHIP_NO_ERROR) { + successCb(bridge, value); + } + return err; + } + return CHIP_ERROR_NOT_FOUND; + }); } @end diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters_internal.h b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters_internal.h index 56dc08571a84d2..1e65a8bc3d942a 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters_internal.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters_internal.h @@ -82,12 +82,12 @@ @property (nonatomic, assign, readonly) chip::EndpointId endpoint; @end -@interface MTRBaseClusterOtaSoftwareUpdateProvider () +@interface MTRBaseClusterOTASoftwareUpdateProvider () @property (nonatomic, strong, readonly) MTRBaseDevice * device; @property (nonatomic, assign, readonly) chip::EndpointId endpoint; @end -@interface MTRBaseClusterOtaSoftwareUpdateRequestor () +@interface MTRBaseClusterOTASoftwareUpdateRequestor () @property (nonatomic, strong, readonly) MTRBaseDevice * device; @property (nonatomic, assign, readonly) chip::EndpointId endpoint; @end @@ -277,7 +277,7 @@ @property (nonatomic, assign, readonly) chip::EndpointId endpoint; @end -@interface MTRBaseClusterWakeOnLan () +@interface MTRBaseClusterWakeOnLAN () @property (nonatomic, strong, readonly) MTRBaseDevice * device; @property (nonatomic, assign, readonly) chip::EndpointId endpoint; @end diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRCallbackBridge.mm b/src/darwin/Framework/CHIP/zap-generated/MTRCallbackBridge.mm index 5a83eb0b4efd58..afbaae6f549afd 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRCallbackBridge.mm +++ b/src/darwin/Framework/CHIP/zap-generated/MTRCallbackBridge.mm @@ -1965,7 +1965,7 @@ } } -void MTRAccessControlAclListAttributeCallbackBridge::OnSuccessFn(void * context, +void MTRAccessControlACLListAttributeCallbackBridge::OnSuccessFn(void * context, const chip::app::DataModel::DecodableList & value) { @@ -2047,7 +2047,7 @@ DispatchSuccess(context, objCValue); }; -void MTRAccessControlAclListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTRAccessControlACLListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -2574,7 +2574,7 @@ } } -void MTROtaSoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge::OnSuccessFn( +void MTROTASoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge::OnSuccessFn( void * context, const chip::app::DataModel::DecodableList & value) { NSArray * _Nonnull objCValue; @@ -2597,7 +2597,7 @@ DispatchSuccess(context, objCValue); }; -void MTROtaSoftwareUpdateProviderGeneratedCommandListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTROTASoftwareUpdateProviderGeneratedCommandListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -2612,7 +2612,7 @@ } } -void MTROtaSoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge::OnSuccessFn( +void MTROTASoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge::OnSuccessFn( void * context, const chip::app::DataModel::DecodableList & value) { NSArray * _Nonnull objCValue; @@ -2635,7 +2635,7 @@ DispatchSuccess(context, objCValue); }; -void MTROtaSoftwareUpdateProviderAcceptedCommandListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTROTASoftwareUpdateProviderAcceptedCommandListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -2650,7 +2650,7 @@ } } -void MTROtaSoftwareUpdateProviderAttributeListListAttributeCallbackBridge::OnSuccessFn( +void MTROTASoftwareUpdateProviderAttributeListListAttributeCallbackBridge::OnSuccessFn( void * context, const chip::app::DataModel::DecodableList & value) { NSArray * _Nonnull objCValue; @@ -2673,7 +2673,7 @@ DispatchSuccess(context, objCValue); }; -void MTROtaSoftwareUpdateProviderAttributeListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTROTASoftwareUpdateProviderAttributeListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -2688,7 +2688,7 @@ } } -void MTROtaSoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge::OnSuccessFn(void * context, +void MTROTASoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge::OnSuccessFn(void * context, const chip::app::DataModel::DecodableList< chip::app::Clusters::OtaSoftwareUpdateRequestor::Structs::ProviderLocation::DecodableType> & value) { @@ -2698,8 +2698,8 @@ auto iter_0 = value.begin(); while (iter_0.Next()) { auto & entry_0 = iter_0.GetValue(); - MTROtaSoftwareUpdateRequestorClusterProviderLocation * newElement_0; - newElement_0 = [MTROtaSoftwareUpdateRequestorClusterProviderLocation new]; + MTROTASoftwareUpdateRequestorClusterProviderLocation * newElement_0; + newElement_0 = [MTROTASoftwareUpdateRequestorClusterProviderLocation new]; newElement_0.providerNodeID = [NSNumber numberWithUnsignedLongLong:entry_0.providerNodeID]; newElement_0.endpoint = [NSNumber numberWithUnsignedShort:entry_0.endpoint]; newElement_0.fabricIndex = [NSNumber numberWithUnsignedChar:entry_0.fabricIndex]; @@ -2715,7 +2715,7 @@ DispatchSuccess(context, objCValue); }; -void MTROtaSoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTROTASoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -2730,7 +2730,7 @@ } } -void MTROtaSoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge::OnSuccessFn( +void MTROTASoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge::OnSuccessFn( void * context, const chip::app::DataModel::DecodableList & value) { NSArray * _Nonnull objCValue; @@ -2753,7 +2753,7 @@ DispatchSuccess(context, objCValue); }; -void MTROtaSoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTROTASoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -2768,7 +2768,7 @@ } } -void MTROtaSoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge::OnSuccessFn( +void MTROTASoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge::OnSuccessFn( void * context, const chip::app::DataModel::DecodableList & value) { NSArray * _Nonnull objCValue; @@ -2791,7 +2791,7 @@ DispatchSuccess(context, objCValue); }; -void MTROtaSoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTROTASoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -2806,7 +2806,7 @@ } } -void MTROtaSoftwareUpdateRequestorAttributeListListAttributeCallbackBridge::OnSuccessFn( +void MTROTASoftwareUpdateRequestorAttributeListListAttributeCallbackBridge::OnSuccessFn( void * context, const chip::app::DataModel::DecodableList & value) { NSArray * _Nonnull objCValue; @@ -2829,7 +2829,7 @@ DispatchSuccess(context, objCValue); }; -void MTROtaSoftwareUpdateRequestorAttributeListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTROTASoftwareUpdateRequestorAttributeListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -8432,7 +8432,7 @@ } } -void MTRWakeOnLanGeneratedCommandListListAttributeCallbackBridge::OnSuccessFn( +void MTRWakeOnLANGeneratedCommandListListAttributeCallbackBridge::OnSuccessFn( void * context, const chip::app::DataModel::DecodableList & value) { NSArray * _Nonnull objCValue; @@ -8455,7 +8455,7 @@ DispatchSuccess(context, objCValue); }; -void MTRWakeOnLanGeneratedCommandListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTRWakeOnLANGeneratedCommandListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -8470,7 +8470,7 @@ } } -void MTRWakeOnLanAcceptedCommandListListAttributeCallbackBridge::OnSuccessFn( +void MTRWakeOnLANAcceptedCommandListListAttributeCallbackBridge::OnSuccessFn( void * context, const chip::app::DataModel::DecodableList & value) { NSArray * _Nonnull objCValue; @@ -8493,7 +8493,7 @@ DispatchSuccess(context, objCValue); }; -void MTRWakeOnLanAcceptedCommandListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTRWakeOnLANAcceptedCommandListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -8508,7 +8508,7 @@ } } -void MTRWakeOnLanAttributeListListAttributeCallbackBridge::OnSuccessFn( +void MTRWakeOnLANAttributeListListAttributeCallbackBridge::OnSuccessFn( void * context, const chip::app::DataModel::DecodableList & value) { NSArray * _Nonnull objCValue; @@ -8531,7 +8531,7 @@ DispatchSuccess(context, objCValue); }; -void MTRWakeOnLanAttributeListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTRWakeOnLANAttributeListListAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -11649,10 +11649,10 @@ DispatchSuccess(context, response); }; -void MTROtaSoftwareUpdateProviderClusterQueryImageResponseCallbackBridge::OnSuccessFn( +void MTROTASoftwareUpdateProviderClusterQueryImageResponseCallbackBridge::OnSuccessFn( void * context, const chip::app::Clusters::OtaSoftwareUpdateProvider::Commands::QueryImageResponse::DecodableType & data) { - auto * response = [MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams new]; + auto * response = [MTROTASoftwareUpdateProviderClusterQueryImageResponseParams new]; { response.status = [NSNumber numberWithUnsignedChar:chip::to_underlying(data.status)]; } @@ -11713,10 +11713,10 @@ DispatchSuccess(context, response); }; -void MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseCallbackBridge::OnSuccessFn( +void MTROTASoftwareUpdateProviderClusterApplyUpdateResponseCallbackBridge::OnSuccessFn( void * context, const chip::app::Clusters::OtaSoftwareUpdateProvider::Commands::ApplyUpdateResponse::DecodableType & data) { - auto * response = [MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams new]; + auto * response = [MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams new]; { response.action = [NSNumber numberWithUnsignedChar:chip::to_underlying(data.action)]; } @@ -13856,7 +13856,7 @@ } } -void MTROtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge::OnSuccessFn( +void MTROTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge::OnSuccessFn( void * context, chip::app::Clusters::OtaSoftwareUpdateProvider::OTAApplyUpdateAction value) { NSNumber * _Nonnull objCValue; @@ -13864,7 +13864,7 @@ DispatchSuccess(context, objCValue); }; -void MTROtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTROTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -13879,7 +13879,7 @@ } } -void MTRNullableOtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge::OnSuccessFn(void * context, +void MTRNullableOTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge::OnSuccessFn(void * context, const chip::app::DataModel::Nullable & value) { NSNumber * _Nullable objCValue; @@ -13891,7 +13891,7 @@ DispatchSuccess(context, objCValue); }; -void MTRNullableOtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTRNullableOTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -13906,7 +13906,7 @@ } } -void MTROtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge::OnSuccessFn( +void MTROTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge::OnSuccessFn( void * context, chip::app::Clusters::OtaSoftwareUpdateProvider::OTADownloadProtocol value) { NSNumber * _Nonnull objCValue; @@ -13914,7 +13914,7 @@ DispatchSuccess(context, objCValue); }; -void MTROtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTROTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -13929,7 +13929,7 @@ } } -void MTRNullableOtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge::OnSuccessFn(void * context, +void MTRNullableOTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge::OnSuccessFn(void * context, const chip::app::DataModel::Nullable & value) { NSNumber * _Nullable objCValue; @@ -13941,7 +13941,7 @@ DispatchSuccess(context, objCValue); }; -void MTRNullableOtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTRNullableOTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -13956,7 +13956,7 @@ } } -void MTROtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge::OnSuccessFn( +void MTROTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge::OnSuccessFn( void * context, chip::app::Clusters::OtaSoftwareUpdateProvider::OTAQueryStatus value) { NSNumber * _Nonnull objCValue; @@ -13964,7 +13964,7 @@ DispatchSuccess(context, objCValue); }; -void MTROtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTROTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -13979,7 +13979,7 @@ } } -void MTRNullableOtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge::OnSuccessFn( +void MTRNullableOTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge::OnSuccessFn( void * context, const chip::app::DataModel::Nullable & value) { NSNumber * _Nullable objCValue; @@ -13991,7 +13991,7 @@ DispatchSuccess(context, objCValue); }; -void MTRNullableOtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTRNullableOTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -14006,7 +14006,7 @@ } } -void MTROtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge::OnSuccessFn( +void MTROTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge::OnSuccessFn( void * context, chip::app::Clusters::OtaSoftwareUpdateRequestor::OTAAnnouncementReason value) { NSNumber * _Nonnull objCValue; @@ -14014,7 +14014,7 @@ DispatchSuccess(context, objCValue); }; -void MTROtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTROTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -14029,7 +14029,7 @@ } } -void MTRNullableOtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge::OnSuccessFn(void * context, +void MTRNullableOTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge::OnSuccessFn(void * context, const chip::app::DataModel::Nullable & value) { NSNumber * _Nullable objCValue; @@ -14041,7 +14041,7 @@ DispatchSuccess(context, objCValue); }; -void MTRNullableOtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackSubscriptionBridge:: +void MTRNullableOTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackSubscriptionBridge:: OnSubscriptionEstablished() { if (!mQueue) { @@ -14057,7 +14057,7 @@ } } -void MTROtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge::OnSuccessFn( +void MTROTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge::OnSuccessFn( void * context, chip::app::Clusters::OtaSoftwareUpdateRequestor::OTAChangeReasonEnum value) { NSNumber * _Nonnull objCValue; @@ -14065,7 +14065,7 @@ DispatchSuccess(context, objCValue); }; -void MTROtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTROTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -14080,7 +14080,7 @@ } } -void MTRNullableOtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge::OnSuccessFn(void * context, +void MTRNullableOTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge::OnSuccessFn(void * context, const chip::app::DataModel::Nullable & value) { NSNumber * _Nullable objCValue; @@ -14092,7 +14092,7 @@ DispatchSuccess(context, objCValue); }; -void MTRNullableOtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTRNullableOTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -14107,7 +14107,7 @@ } } -void MTROtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge::OnSuccessFn( +void MTROTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge::OnSuccessFn( void * context, chip::app::Clusters::OtaSoftwareUpdateRequestor::OTAUpdateStateEnum value) { NSNumber * _Nonnull objCValue; @@ -14115,7 +14115,7 @@ DispatchSuccess(context, objCValue); }; -void MTROtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTROTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; @@ -14130,7 +14130,7 @@ } } -void MTRNullableOtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge::OnSuccessFn(void * context, +void MTRNullableOTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge::OnSuccessFn(void * context, const chip::app::DataModel::Nullable & value) { NSNumber * _Nullable objCValue; @@ -14142,7 +14142,7 @@ DispatchSuccess(context, objCValue); }; -void MTRNullableOtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() +void MTRNullableOTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished() { if (!mQueue) { return; diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRCallbackBridge_internal.h b/src/darwin/Framework/CHIP/zap-generated/MTRCallbackBridge_internal.h index 98cfb00771354e..eff36ea0d17c6b 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRCallbackBridge_internal.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRCallbackBridge_internal.h @@ -55,9 +55,9 @@ typedef void (*ScenesClusterEnhancedViewSceneResponseCallbackType)( void *, const chip::app::Clusters::Scenes::Commands::EnhancedViewSceneResponse::DecodableType &); typedef void (*ScenesClusterCopySceneResponseCallbackType)( void *, const chip::app::Clusters::Scenes::Commands::CopySceneResponse::DecodableType &); -typedef void (*OtaSoftwareUpdateProviderClusterQueryImageResponseCallbackType)( +typedef void (*OTASoftwareUpdateProviderClusterQueryImageResponseCallbackType)( void *, const chip::app::Clusters::OtaSoftwareUpdateProvider::Commands::QueryImageResponse::DecodableType &); -typedef void (*OtaSoftwareUpdateProviderClusterApplyUpdateResponseCallbackType)( +typedef void (*OTASoftwareUpdateProviderClusterApplyUpdateResponseCallbackType)( void *, const chip::app::Clusters::OtaSoftwareUpdateProvider::Commands::ApplyUpdateResponse::DecodableType &); typedef void (*GeneralCommissioningClusterArmFailSafeResponseCallbackType)( void *, const chip::app::Clusters::GeneralCommissioning::Commands::ArmFailSafeResponse::DecodableType &); @@ -189,29 +189,29 @@ typedef void (*NullableActionsClusterActionTypeEnumAttributeCallback)( typedef void (*ActionsClusterEndpointListTypeEnumAttributeCallback)(void *, chip::app::Clusters::Actions::EndpointListTypeEnum); typedef void (*NullableActionsClusterEndpointListTypeEnumAttributeCallback)( void *, const chip::app::DataModel::Nullable &); -typedef void (*OtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallback)( +typedef void (*OTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallback)( void *, chip::app::Clusters::OtaSoftwareUpdateProvider::OTAApplyUpdateAction); -typedef void (*NullableOtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallback)( +typedef void (*NullableOTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallback)( void *, const chip::app::DataModel::Nullable &); -typedef void (*OtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallback)( +typedef void (*OTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallback)( void *, chip::app::Clusters::OtaSoftwareUpdateProvider::OTADownloadProtocol); -typedef void (*NullableOtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallback)( +typedef void (*NullableOTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallback)( void *, const chip::app::DataModel::Nullable &); -typedef void (*OtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallback)( +typedef void (*OTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallback)( void *, chip::app::Clusters::OtaSoftwareUpdateProvider::OTAQueryStatus); -typedef void (*NullableOtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallback)( +typedef void (*NullableOTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallback)( void *, const chip::app::DataModel::Nullable &); -typedef void (*OtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallback)( +typedef void (*OTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallback)( void *, chip::app::Clusters::OtaSoftwareUpdateRequestor::OTAAnnouncementReason); -typedef void (*NullableOtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallback)( +typedef void (*NullableOTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallback)( void *, const chip::app::DataModel::Nullable &); -typedef void (*OtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallback)( +typedef void (*OTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallback)( void *, chip::app::Clusters::OtaSoftwareUpdateRequestor::OTAChangeReasonEnum); -typedef void (*NullableOtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallback)( +typedef void (*NullableOTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallback)( void *, const chip::app::DataModel::Nullable &); -typedef void (*OtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallback)( +typedef void (*OTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallback)( void *, chip::app::Clusters::OtaSoftwareUpdateRequestor::OTAUpdateStateEnum); -typedef void (*NullableOtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallback)( +typedef void (*NullableOTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallback)( void *, const chip::app::DataModel::Nullable &); typedef void (*TimeFormatLocalizationClusterCalendarTypeAttributeCallback)( void *, chip::app::Clusters::TimeFormatLocalization::CalendarType); @@ -601,7 +601,7 @@ typedef void (*BindingAcceptedCommandListListAttributeCallback)(void * context, const chip::app::DataModel::DecodableList & data); typedef void (*BindingAttributeListListAttributeCallback)(void * context, const chip::app::DataModel::DecodableList & data); -typedef void (*AccessControlAclListAttributeCallback)( +typedef void (*AccessControlACLListAttributeCallback)( void * context, const chip::app::DataModel::DecodableList & data); @@ -634,21 +634,21 @@ typedef void (*BasicAcceptedCommandListListAttributeCallback)(void * context, const chip::app::DataModel::DecodableList & data); typedef void (*BasicAttributeListListAttributeCallback)(void * context, const chip::app::DataModel::DecodableList & data); -typedef void (*OtaSoftwareUpdateProviderGeneratedCommandListListAttributeCallback)( +typedef void (*OTASoftwareUpdateProviderGeneratedCommandListListAttributeCallback)( void * context, const chip::app::DataModel::DecodableList & data); -typedef void (*OtaSoftwareUpdateProviderAcceptedCommandListListAttributeCallback)( +typedef void (*OTASoftwareUpdateProviderAcceptedCommandListListAttributeCallback)( void * context, const chip::app::DataModel::DecodableList & data); -typedef void (*OtaSoftwareUpdateProviderAttributeListListAttributeCallback)( +typedef void (*OTASoftwareUpdateProviderAttributeListListAttributeCallback)( void * context, const chip::app::DataModel::DecodableList & data); -typedef void (*OtaSoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallback)( +typedef void (*OTASoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallback)( void * context, const chip::app::DataModel::DecodableList< chip::app::Clusters::OtaSoftwareUpdateRequestor::Structs::ProviderLocation::DecodableType> & data); -typedef void (*OtaSoftwareUpdateRequestorGeneratedCommandListListAttributeCallback)( +typedef void (*OTASoftwareUpdateRequestorGeneratedCommandListListAttributeCallback)( void * context, const chip::app::DataModel::DecodableList & data); -typedef void (*OtaSoftwareUpdateRequestorAcceptedCommandListListAttributeCallback)( +typedef void (*OTASoftwareUpdateRequestorAcceptedCommandListListAttributeCallback)( void * context, const chip::app::DataModel::DecodableList & data); -typedef void (*OtaSoftwareUpdateRequestorAttributeListListAttributeCallback)( +typedef void (*OTASoftwareUpdateRequestorAttributeListListAttributeCallback)( void * context, const chip::app::DataModel::DecodableList & data); typedef void (*LocalizationConfigurationSupportedLocalesListAttributeCallback)( void * context, const chip::app::DataModel::DecodableList & data); @@ -965,11 +965,11 @@ typedef void (*OccupancySensingAcceptedCommandListListAttributeCallback)( void * context, const chip::app::DataModel::DecodableList & data); typedef void (*OccupancySensingAttributeListListAttributeCallback)( void * context, const chip::app::DataModel::DecodableList & data); -typedef void (*WakeOnLanGeneratedCommandListListAttributeCallback)( +typedef void (*WakeOnLANGeneratedCommandListListAttributeCallback)( void * context, const chip::app::DataModel::DecodableList & data); -typedef void (*WakeOnLanAcceptedCommandListListAttributeCallback)( +typedef void (*WakeOnLANAcceptedCommandListListAttributeCallback)( void * context, const chip::app::DataModel::DecodableList & data); -typedef void (*WakeOnLanAttributeListListAttributeCallback)(void * context, +typedef void (*WakeOnLANAttributeListListAttributeCallback)(void * context, const chip::app::DataModel::DecodableList & data); typedef void (*ChannelChannelListListAttributeCallback)( void * context, @@ -3008,14 +3008,14 @@ class MTRBindingAttributeListListAttributeCallbackSubscriptionBridge : public MT MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTRAccessControlAclListAttributeCallbackBridge : public MTRCallbackBridge +class MTRAccessControlACLListAttributeCallbackBridge : public MTRCallbackBridge { public: - MTRAccessControlAclListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTRAccessControlACLListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTRAccessControlAclListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; + MTRAccessControlACLListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn( void * context, @@ -3023,19 +3023,19 @@ class MTRAccessControlAclListAttributeCallbackBridge : public MTRCallbackBridge< value); }; -class MTRAccessControlAclListAttributeCallbackSubscriptionBridge : public MTRAccessControlAclListAttributeCallbackBridge +class MTRAccessControlACLListAttributeCallbackSubscriptionBridge : public MTRAccessControlACLListAttributeCallbackBridge { public: - MTRAccessControlAclListAttributeCallbackSubscriptionBridge(dispatch_queue_t queue, ResponseHandler handler, + MTRAccessControlACLListAttributeCallbackSubscriptionBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTRAccessControlAclListAttributeCallbackBridge(queue, handler, action), + MTRAccessControlACLListAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTRAccessControlAclListAttributeCallbackBridge::KeepAliveOnCallback; - using MTRAccessControlAclListAttributeCallbackBridge::OnDone; + using MTRAccessControlACLListAttributeCallbackBridge::KeepAliveOnCallback; + using MTRAccessControlACLListAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; @@ -3461,116 +3461,116 @@ class MTRBasicAttributeListListAttributeCallbackSubscriptionBridge : public MTRB MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTROtaSoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge - : public MTRCallbackBridge +class MTROTASoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTROtaSoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTROTASoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTROtaSoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTROTASoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, const chip::app::DataModel::DecodableList & value); }; -class MTROtaSoftwareUpdateProviderGeneratedCommandListListAttributeCallbackSubscriptionBridge - : public MTROtaSoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge +class MTROTASoftwareUpdateProviderGeneratedCommandListListAttributeCallbackSubscriptionBridge + : public MTROTASoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge { public: - MTROtaSoftwareUpdateProviderGeneratedCommandListListAttributeCallbackSubscriptionBridge( + MTROTASoftwareUpdateProviderGeneratedCommandListListAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTROtaSoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge(queue, handler, action), + MTROTASoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTROtaSoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge::KeepAliveOnCallback; - using MTROtaSoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge::OnDone; + using MTROTASoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge::KeepAliveOnCallback; + using MTROTASoftwareUpdateProviderGeneratedCommandListListAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTROtaSoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge - : public MTRCallbackBridge +class MTROTASoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTROtaSoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTROTASoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTROtaSoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTROTASoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, const chip::app::DataModel::DecodableList & value); }; -class MTROtaSoftwareUpdateProviderAcceptedCommandListListAttributeCallbackSubscriptionBridge - : public MTROtaSoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge +class MTROTASoftwareUpdateProviderAcceptedCommandListListAttributeCallbackSubscriptionBridge + : public MTROTASoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge { public: - MTROtaSoftwareUpdateProviderAcceptedCommandListListAttributeCallbackSubscriptionBridge( + MTROTASoftwareUpdateProviderAcceptedCommandListListAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTROtaSoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge(queue, handler, action), + MTROTASoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTROtaSoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge::KeepAliveOnCallback; - using MTROtaSoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge::OnDone; + using MTROTASoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge::KeepAliveOnCallback; + using MTROTASoftwareUpdateProviderAcceptedCommandListListAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTROtaSoftwareUpdateProviderAttributeListListAttributeCallbackBridge - : public MTRCallbackBridge +class MTROTASoftwareUpdateProviderAttributeListListAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTROtaSoftwareUpdateProviderAttributeListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTROTASoftwareUpdateProviderAttributeListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTROtaSoftwareUpdateProviderAttributeListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTROTASoftwareUpdateProviderAttributeListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, const chip::app::DataModel::DecodableList & value); }; -class MTROtaSoftwareUpdateProviderAttributeListListAttributeCallbackSubscriptionBridge - : public MTROtaSoftwareUpdateProviderAttributeListListAttributeCallbackBridge +class MTROTASoftwareUpdateProviderAttributeListListAttributeCallbackSubscriptionBridge + : public MTROTASoftwareUpdateProviderAttributeListListAttributeCallbackBridge { public: - MTROtaSoftwareUpdateProviderAttributeListListAttributeCallbackSubscriptionBridge( + MTROTASoftwareUpdateProviderAttributeListListAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTROtaSoftwareUpdateProviderAttributeListListAttributeCallbackBridge(queue, handler, action), + MTROTASoftwareUpdateProviderAttributeListListAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTROtaSoftwareUpdateProviderAttributeListListAttributeCallbackBridge::KeepAliveOnCallback; - using MTROtaSoftwareUpdateProviderAttributeListListAttributeCallbackBridge::OnDone; + using MTROTASoftwareUpdateProviderAttributeListListAttributeCallbackBridge::KeepAliveOnCallback; + using MTROTASoftwareUpdateProviderAttributeListListAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTROtaSoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge - : public MTRCallbackBridge +class MTROTASoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTROtaSoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTROTASoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTROtaSoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTROTASoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, @@ -3578,121 +3578,121 @@ class MTROtaSoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridg chip::app::Clusters::OtaSoftwareUpdateRequestor::Structs::ProviderLocation::DecodableType> & value); }; -class MTROtaSoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackSubscriptionBridge - : public MTROtaSoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge +class MTROTASoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackSubscriptionBridge + : public MTROTASoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge { public: - MTROtaSoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackSubscriptionBridge( + MTROTASoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTROtaSoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge(queue, handler, action), + MTROTASoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTROtaSoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge::KeepAliveOnCallback; - using MTROtaSoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge::OnDone; + using MTROTASoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge::KeepAliveOnCallback; + using MTROTASoftwareUpdateRequestorDefaultOtaProvidersListAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTROtaSoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge - : public MTRCallbackBridge +class MTROTASoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTROtaSoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTROTASoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTROtaSoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTROTASoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, const chip::app::DataModel::DecodableList & value); }; -class MTROtaSoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackSubscriptionBridge - : public MTROtaSoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge +class MTROTASoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackSubscriptionBridge + : public MTROTASoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge { public: - MTROtaSoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackSubscriptionBridge( + MTROTASoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTROtaSoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge(queue, handler, action), + MTROTASoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTROtaSoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge::KeepAliveOnCallback; - using MTROtaSoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge::OnDone; + using MTROTASoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge::KeepAliveOnCallback; + using MTROTASoftwareUpdateRequestorGeneratedCommandListListAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTROtaSoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge - : public MTRCallbackBridge +class MTROTASoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTROtaSoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTROTASoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTROtaSoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTROTASoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, const chip::app::DataModel::DecodableList & value); }; -class MTROtaSoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackSubscriptionBridge - : public MTROtaSoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge +class MTROTASoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackSubscriptionBridge + : public MTROTASoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge { public: - MTROtaSoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackSubscriptionBridge( + MTROTASoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTROtaSoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge(queue, handler, action), + MTROTASoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTROtaSoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge::KeepAliveOnCallback; - using MTROtaSoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge::OnDone; + using MTROTASoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge::KeepAliveOnCallback; + using MTROTASoftwareUpdateRequestorAcceptedCommandListListAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTROtaSoftwareUpdateRequestorAttributeListListAttributeCallbackBridge - : public MTRCallbackBridge +class MTROTASoftwareUpdateRequestorAttributeListListAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTROtaSoftwareUpdateRequestorAttributeListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTROTASoftwareUpdateRequestorAttributeListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTROtaSoftwareUpdateRequestorAttributeListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTROTASoftwareUpdateRequestorAttributeListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, const chip::app::DataModel::DecodableList & value); }; -class MTROtaSoftwareUpdateRequestorAttributeListListAttributeCallbackSubscriptionBridge - : public MTROtaSoftwareUpdateRequestorAttributeListListAttributeCallbackBridge +class MTROTASoftwareUpdateRequestorAttributeListListAttributeCallbackSubscriptionBridge + : public MTROTASoftwareUpdateRequestorAttributeListListAttributeCallbackBridge { public: - MTROtaSoftwareUpdateRequestorAttributeListListAttributeCallbackSubscriptionBridge( + MTROTASoftwareUpdateRequestorAttributeListListAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTROtaSoftwareUpdateRequestorAttributeListListAttributeCallbackBridge(queue, handler, action), + MTROTASoftwareUpdateRequestorAttributeListListAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTROtaSoftwareUpdateRequestorAttributeListListAttributeCallbackBridge::KeepAliveOnCallback; - using MTROtaSoftwareUpdateRequestorAttributeListListAttributeCallbackBridge::OnDone; + using MTROTASoftwareUpdateRequestorAttributeListListAttributeCallbackBridge::KeepAliveOnCallback; + using MTROTASoftwareUpdateRequestorAttributeListListAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; @@ -8548,97 +8548,97 @@ class MTROccupancySensingAttributeListListAttributeCallbackSubscriptionBridge MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTRWakeOnLanGeneratedCommandListListAttributeCallbackBridge - : public MTRCallbackBridge +class MTRWakeOnLANGeneratedCommandListListAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTRWakeOnLanGeneratedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTRWakeOnLANGeneratedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTRWakeOnLanGeneratedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTRWakeOnLANGeneratedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, const chip::app::DataModel::DecodableList & value); }; -class MTRWakeOnLanGeneratedCommandListListAttributeCallbackSubscriptionBridge - : public MTRWakeOnLanGeneratedCommandListListAttributeCallbackBridge +class MTRWakeOnLANGeneratedCommandListListAttributeCallbackSubscriptionBridge + : public MTRWakeOnLANGeneratedCommandListListAttributeCallbackBridge { public: - MTRWakeOnLanGeneratedCommandListListAttributeCallbackSubscriptionBridge(dispatch_queue_t queue, ResponseHandler handler, + MTRWakeOnLANGeneratedCommandListListAttributeCallbackSubscriptionBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTRWakeOnLanGeneratedCommandListListAttributeCallbackBridge(queue, handler, action), + MTRWakeOnLANGeneratedCommandListListAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTRWakeOnLanGeneratedCommandListListAttributeCallbackBridge::KeepAliveOnCallback; - using MTRWakeOnLanGeneratedCommandListListAttributeCallbackBridge::OnDone; + using MTRWakeOnLANGeneratedCommandListListAttributeCallbackBridge::KeepAliveOnCallback; + using MTRWakeOnLANGeneratedCommandListListAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTRWakeOnLanAcceptedCommandListListAttributeCallbackBridge - : public MTRCallbackBridge +class MTRWakeOnLANAcceptedCommandListListAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTRWakeOnLanAcceptedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTRWakeOnLANAcceptedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTRWakeOnLanAcceptedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTRWakeOnLANAcceptedCommandListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, const chip::app::DataModel::DecodableList & value); }; -class MTRWakeOnLanAcceptedCommandListListAttributeCallbackSubscriptionBridge - : public MTRWakeOnLanAcceptedCommandListListAttributeCallbackBridge +class MTRWakeOnLANAcceptedCommandListListAttributeCallbackSubscriptionBridge + : public MTRWakeOnLANAcceptedCommandListListAttributeCallbackBridge { public: - MTRWakeOnLanAcceptedCommandListListAttributeCallbackSubscriptionBridge(dispatch_queue_t queue, ResponseHandler handler, + MTRWakeOnLANAcceptedCommandListListAttributeCallbackSubscriptionBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTRWakeOnLanAcceptedCommandListListAttributeCallbackBridge(queue, handler, action), + MTRWakeOnLANAcceptedCommandListListAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTRWakeOnLanAcceptedCommandListListAttributeCallbackBridge::KeepAliveOnCallback; - using MTRWakeOnLanAcceptedCommandListListAttributeCallbackBridge::OnDone; + using MTRWakeOnLANAcceptedCommandListListAttributeCallbackBridge::KeepAliveOnCallback; + using MTRWakeOnLANAcceptedCommandListListAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTRWakeOnLanAttributeListListAttributeCallbackBridge : public MTRCallbackBridge +class MTRWakeOnLANAttributeListListAttributeCallbackBridge : public MTRCallbackBridge { public: - MTRWakeOnLanAttributeListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTRWakeOnLANAttributeListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTRWakeOnLanAttributeListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; + MTRWakeOnLANAttributeListListAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, const chip::app::DataModel::DecodableList & value); }; -class MTRWakeOnLanAttributeListListAttributeCallbackSubscriptionBridge : public MTRWakeOnLanAttributeListListAttributeCallbackBridge +class MTRWakeOnLANAttributeListListAttributeCallbackSubscriptionBridge : public MTRWakeOnLANAttributeListListAttributeCallbackBridge { public: - MTRWakeOnLanAttributeListListAttributeCallbackSubscriptionBridge(dispatch_queue_t queue, ResponseHandler handler, + MTRWakeOnLANAttributeListListAttributeCallbackSubscriptionBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTRWakeOnLanAttributeListListAttributeCallbackBridge(queue, handler, action), + MTRWakeOnLANAttributeListListAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTRWakeOnLanAttributeListListAttributeCallbackBridge::KeepAliveOnCallback; - using MTRWakeOnLanAttributeListListAttributeCallbackBridge::OnDone; + using MTRWakeOnLANAttributeListListAttributeCallbackBridge::KeepAliveOnCallback; + using MTRWakeOnLANAttributeListListAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; @@ -11010,32 +11010,32 @@ class MTRScenesClusterCopySceneResponseCallbackBridge : public MTRCallbackBridge static void OnSuccessFn(void * context, const chip::app::Clusters::Scenes::Commands::CopySceneResponse::DecodableType & data); }; -class MTROtaSoftwareUpdateProviderClusterQueryImageResponseCallbackBridge - : public MTRCallbackBridge +class MTROTASoftwareUpdateProviderClusterQueryImageResponseCallbackBridge + : public MTRCallbackBridge { public: - MTROtaSoftwareUpdateProviderClusterQueryImageResponseCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTROTASoftwareUpdateProviderClusterQueryImageResponseCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTROtaSoftwareUpdateProviderClusterQueryImageResponseCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTROTASoftwareUpdateProviderClusterQueryImageResponseCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, const chip::app::Clusters::OtaSoftwareUpdateProvider::Commands::QueryImageResponse::DecodableType & data); }; -class MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseCallbackBridge - : public MTRCallbackBridge +class MTROTASoftwareUpdateProviderClusterApplyUpdateResponseCallbackBridge + : public MTRCallbackBridge { public: - MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTROTASoftwareUpdateProviderClusterApplyUpdateResponseCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTROTASoftwareUpdateProviderClusterApplyUpdateResponseCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, @@ -12694,54 +12694,54 @@ class MTRNullableActionsClusterEndpointListTypeEnumAttributeCallbackSubscription MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTROtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge - : public MTRCallbackBridge +class MTROTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTROtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge(dispatch_queue_t queue, + MTROTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTROtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTROTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, chip::app::Clusters::OtaSoftwareUpdateProvider::OTAApplyUpdateAction value); }; -class MTROtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackSubscriptionBridge - : public MTROtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge +class MTROTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackSubscriptionBridge + : public MTROTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge { public: - MTROtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackSubscriptionBridge( + MTROTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTROtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge(queue, handler, action), + MTROTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTROtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge::KeepAliveOnCallback; - using MTROtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge::OnDone; + using MTROTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge::KeepAliveOnCallback; + using MTROTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTRNullableOtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge - : public MTRCallbackBridge +class MTRNullableOTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTRNullableOtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge(dispatch_queue_t queue, + MTRNullableOTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTRNullableOtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge(dispatch_queue_t queue, + MTRNullableOTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void @@ -12749,72 +12749,72 @@ class MTRNullableOtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCa const chip::app::DataModel::Nullable & value); }; -class MTRNullableOtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackSubscriptionBridge - : public MTRNullableOtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge +class MTRNullableOTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackSubscriptionBridge + : public MTRNullableOTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge { public: - MTRNullableOtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackSubscriptionBridge( + MTRNullableOTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTRNullableOtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge(queue, handler, action), + MTRNullableOTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTRNullableOtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge::KeepAliveOnCallback; - using MTRNullableOtaSoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge::OnDone; + using MTRNullableOTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge::KeepAliveOnCallback; + using MTRNullableOTASoftwareUpdateProviderClusterOTAApplyUpdateActionAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTROtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge - : public MTRCallbackBridge +class MTROTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTROtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTROTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTROtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTROTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, chip::app::Clusters::OtaSoftwareUpdateProvider::OTADownloadProtocol value); }; -class MTROtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackSubscriptionBridge - : public MTROtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge +class MTROTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackSubscriptionBridge + : public MTROTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge { public: - MTROtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackSubscriptionBridge( + MTROTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTROtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge(queue, handler, action), + MTROTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTROtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge::KeepAliveOnCallback; - using MTROtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge::OnDone; + using MTROTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge::KeepAliveOnCallback; + using MTROTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTRNullableOtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge - : public MTRCallbackBridge +class MTRNullableOTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTRNullableOtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge(dispatch_queue_t queue, + MTRNullableOTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTRNullableOtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge(dispatch_queue_t queue, + MTRNullableOTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void @@ -12822,70 +12822,70 @@ class MTRNullableOtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCal const chip::app::DataModel::Nullable & value); }; -class MTRNullableOtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackSubscriptionBridge - : public MTRNullableOtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge +class MTRNullableOTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackSubscriptionBridge + : public MTRNullableOTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge { public: - MTRNullableOtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackSubscriptionBridge( + MTRNullableOTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTRNullableOtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge(queue, handler, action), + MTRNullableOTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTRNullableOtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge::KeepAliveOnCallback; - using MTRNullableOtaSoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge::OnDone; + using MTRNullableOTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge::KeepAliveOnCallback; + using MTRNullableOTASoftwareUpdateProviderClusterOTADownloadProtocolAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTROtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge - : public MTRCallbackBridge +class MTROTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTROtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTROTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTROtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTROTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, chip::app::Clusters::OtaSoftwareUpdateProvider::OTAQueryStatus value); }; -class MTROtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackSubscriptionBridge - : public MTROtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge +class MTROTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackSubscriptionBridge + : public MTROTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge { public: - MTROtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackSubscriptionBridge( + MTROTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTROtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge(queue, handler, action), + MTROTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTROtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge::KeepAliveOnCallback; - using MTROtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge::OnDone; + using MTROTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge::KeepAliveOnCallback; + using MTROTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTRNullableOtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge - : public MTRCallbackBridge +class MTRNullableOTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTRNullableOtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge(dispatch_queue_t queue, + MTRNullableOTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTRNullableOtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge(dispatch_queue_t queue, + MTRNullableOTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void @@ -12893,74 +12893,74 @@ class MTRNullableOtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallback const chip::app::DataModel::Nullable & value); }; -class MTRNullableOtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackSubscriptionBridge - : public MTRNullableOtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge +class MTRNullableOTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackSubscriptionBridge + : public MTRNullableOTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge { public: - MTRNullableOtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackSubscriptionBridge( + MTRNullableOTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTRNullableOtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge(queue, handler, action), + MTRNullableOTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTRNullableOtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge::KeepAliveOnCallback; - using MTRNullableOtaSoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge::OnDone; + using MTRNullableOTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge::KeepAliveOnCallback; + using MTRNullableOTASoftwareUpdateProviderClusterOTAQueryStatusAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTROtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge - : public MTRCallbackBridge +class MTROTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTROtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge(dispatch_queue_t queue, + MTROTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTROtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge(dispatch_queue_t queue, + MTROTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, chip::app::Clusters::OtaSoftwareUpdateRequestor::OTAAnnouncementReason value); }; -class MTROtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackSubscriptionBridge - : public MTROtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge +class MTROTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackSubscriptionBridge + : public MTROTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge { public: - MTROtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackSubscriptionBridge( + MTROTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTROtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge(queue, handler, action), + MTROTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTROtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge::KeepAliveOnCallback; - using MTROtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge::OnDone; + using MTROTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge::KeepAliveOnCallback; + using MTROTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTRNullableOtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge - : public MTRCallbackBridge +class MTRNullableOTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTRNullableOtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge(dispatch_queue_t queue, + MTRNullableOTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTRNullableOtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge(dispatch_queue_t queue, + MTRNullableOTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn( @@ -12968,73 +12968,73 @@ class MTRNullableOtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttribute const chip::app::DataModel::Nullable & value); }; -class MTRNullableOtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackSubscriptionBridge - : public MTRNullableOtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge +class MTRNullableOTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackSubscriptionBridge + : public MTRNullableOTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge { public: - MTRNullableOtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackSubscriptionBridge( + MTRNullableOTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTRNullableOtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge(queue, handler, action), + MTRNullableOTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTRNullableOtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge::KeepAliveOnCallback; - using MTRNullableOtaSoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge::OnDone; + using MTRNullableOTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge::KeepAliveOnCallback; + using MTRNullableOTASoftwareUpdateRequestorClusterOTAAnnouncementReasonAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTROtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge - : public MTRCallbackBridge +class MTROTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTROtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge(dispatch_queue_t queue, + MTROTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTROtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTROTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, chip::app::Clusters::OtaSoftwareUpdateRequestor::OTAChangeReasonEnum value); }; -class MTROtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackSubscriptionBridge - : public MTROtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge +class MTROTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackSubscriptionBridge + : public MTROTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge { public: - MTROtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackSubscriptionBridge( + MTROTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTROtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge(queue, handler, action), + MTROTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTROtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge::KeepAliveOnCallback; - using MTROtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge::OnDone; + using MTROTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge::KeepAliveOnCallback; + using MTROTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTRNullableOtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge - : public MTRCallbackBridge +class MTRNullableOTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTRNullableOtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge(dispatch_queue_t queue, + MTRNullableOTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTRNullableOtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge(dispatch_queue_t queue, + MTRNullableOTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void @@ -13042,72 +13042,72 @@ class MTRNullableOtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCa const chip::app::DataModel::Nullable & value); }; -class MTRNullableOtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackSubscriptionBridge - : public MTRNullableOtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge +class MTRNullableOTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackSubscriptionBridge + : public MTRNullableOTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge { public: - MTRNullableOtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackSubscriptionBridge( + MTRNullableOTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTRNullableOtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge(queue, handler, action), + MTRNullableOTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTRNullableOtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge::KeepAliveOnCallback; - using MTRNullableOtaSoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge::OnDone; + using MTRNullableOTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge::KeepAliveOnCallback; + using MTRNullableOTASoftwareUpdateRequestorClusterOTAChangeReasonEnumAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTROtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge - : public MTRCallbackBridge +class MTROTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTROtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, OnSuccessFn){}; + MTROTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTROtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + MTROTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void OnSuccessFn(void * context, chip::app::Clusters::OtaSoftwareUpdateRequestor::OTAUpdateStateEnum value); }; -class MTROtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackSubscriptionBridge - : public MTROtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge +class MTROTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackSubscriptionBridge + : public MTROTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge { public: - MTROtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackSubscriptionBridge( + MTROTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTROtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge(queue, handler, action), + MTROTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTROtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge::KeepAliveOnCallback; - using MTROtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge::OnDone; + using MTROTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge::KeepAliveOnCallback; + using MTROTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; }; -class MTRNullableOtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge - : public MTRCallbackBridge +class MTRNullableOTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge + : public MTRCallbackBridge { public: - MTRNullableOtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge(dispatch_queue_t queue, + MTRNullableOTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler) : - MTRCallbackBridge(queue, handler, + MTRCallbackBridge(queue, handler, OnSuccessFn){}; - MTRNullableOtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge(dispatch_queue_t queue, + MTRNullableOTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action) : - MTRCallbackBridge(queue, handler, action, + MTRCallbackBridge(queue, handler, action, OnSuccessFn){}; static void @@ -13115,20 +13115,20 @@ class MTRNullableOtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCal const chip::app::DataModel::Nullable & value); }; -class MTRNullableOtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackSubscriptionBridge - : public MTRNullableOtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge +class MTRNullableOTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackSubscriptionBridge + : public MTRNullableOTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge { public: - MTRNullableOtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackSubscriptionBridge( + MTRNullableOTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackSubscriptionBridge( dispatch_queue_t queue, ResponseHandler handler, MTRActionBlock action, MTRSubscriptionEstablishedHandler establishedHandler) : - MTRNullableOtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge(queue, handler, action), + MTRNullableOTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge(queue, handler, action), mEstablishedHandler(establishedHandler) {} void OnSubscriptionEstablished(); - using MTRNullableOtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge::KeepAliveOnCallback; - using MTRNullableOtaSoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge::OnDone; + using MTRNullableOTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge::KeepAliveOnCallback; + using MTRNullableOTASoftwareUpdateRequestorClusterOTAUpdateStateEnumAttributeCallbackBridge::OnDone; private: MTRSubscriptionEstablishedHandler mEstablishedHandler; diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRClusterConstants.h b/src/darwin/Framework/CHIP/zap-generated/MTRClusterConstants.h index a4a8a00a76fc30..d6b5c27d560ac4 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRClusterConstants.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRClusterConstants.h @@ -99,6 +99,7 @@ typedef NS_ENUM(uint32_t, MTRClusterIDType) { MTRClusterApplicationBasicID MTR_NEWLY_DEPRECATED("Please use MTRClusterIDTypeApplicationBasicID") = 0x0000050D, MTRClusterAccountLoginID MTR_NEWLY_DEPRECATED("Please use MTRClusterIDTypeAccountLoginID") = 0x0000050E, MTRClusterElectricalMeasurementID MTR_NEWLY_DEPRECATED("Please use MTRClusterIDTypeElectricalMeasurementID") = 0x00000B04, + MTRClusterClientMonitoringID MTR_NEWLY_DEPRECATED("Please use MTRClusterIDTypeClientMonitoringID") = 0x00001046, MTRClusterTestClusterID MTR_NEWLY_DEPRECATED("Please use MTRClusterIDTypeUnitTestingID") = 0xFFF1FC05, MTRClusterFaultInjectionID MTR_NEWLY_DEPRECATED("Please use MTRClusterIDTypeFaultInjectionID") = 0xFFF1FC06, MTRClusterIDTypeIdentifyID MTR_NEWLY_AVAILABLE = 0x00000003, @@ -114,8 +115,8 @@ typedef NS_ENUM(uint32_t, MTRClusterIDType) { MTRClusterIDTypeAccessControlID MTR_NEWLY_AVAILABLE = 0x0000001F, MTRClusterIDTypeActionsID MTR_NEWLY_AVAILABLE = 0x00000025, MTRClusterIDTypeBasicID MTR_NEWLY_AVAILABLE = 0x00000028, - MTRClusterIDTypeOtaSoftwareUpdateProviderID MTR_NEWLY_AVAILABLE = 0x00000029, - MTRClusterIDTypeOtaSoftwareUpdateRequestorID MTR_NEWLY_AVAILABLE = 0x0000002A, + MTRClusterIDTypeOTASoftwareUpdateProviderID MTR_NEWLY_AVAILABLE = 0x00000029, + MTRClusterIDTypeOTASoftwareUpdateRequestorID MTR_NEWLY_AVAILABLE = 0x0000002A, MTRClusterIDTypeLocalizationConfigurationID MTR_NEWLY_AVAILABLE = 0x0000002B, MTRClusterIDTypeTimeFormatLocalizationID MTR_NEWLY_AVAILABLE = 0x0000002C, MTRClusterIDTypeUnitLocalizationID MTR_NEWLY_AVAILABLE = 0x0000002D, @@ -157,7 +158,7 @@ typedef NS_ENUM(uint32_t, MTRClusterIDType) { MTRClusterIDTypeFlowMeasurementID MTR_NEWLY_AVAILABLE = 0x00000404, MTRClusterIDTypeRelativeHumidityMeasurementID MTR_NEWLY_AVAILABLE = 0x00000405, MTRClusterIDTypeOccupancySensingID MTR_NEWLY_AVAILABLE = 0x00000406, - MTRClusterIDTypeWakeOnLanID MTR_NEWLY_AVAILABLE = 0x00000503, + MTRClusterIDTypeWakeOnLANID MTR_NEWLY_AVAILABLE = 0x00000503, MTRClusterIDTypeChannelID MTR_NEWLY_AVAILABLE = 0x00000504, MTRClusterIDTypeTargetNavigatorID MTR_NEWLY_AVAILABLE = 0x00000505, MTRClusterIDTypeMediaPlaybackID MTR_NEWLY_AVAILABLE = 0x00000506, @@ -170,6 +171,7 @@ typedef NS_ENUM(uint32_t, MTRClusterIDType) { MTRClusterIDTypeApplicationBasicID MTR_NEWLY_AVAILABLE = 0x0000050D, MTRClusterIDTypeAccountLoginID MTR_NEWLY_AVAILABLE = 0x0000050E, MTRClusterIDTypeElectricalMeasurementID MTR_NEWLY_AVAILABLE = 0x00000B04, + MTRClusterIDTypeClientMonitoringID MTR_NEWLY_AVAILABLE = 0x00001046, MTRClusterIDTypeUnitTestingID MTR_NEWLY_AVAILABLE = 0xFFF1FC05, MTRClusterIDTypeFaultInjectionID MTR_NEWLY_AVAILABLE = 0xFFF1FC06, }; @@ -675,7 +677,7 @@ typedef NS_ENUM(uint32_t, MTRAttributeIDType) { = MTRClusterGlobalAttributeClusterRevisionID, // Cluster AccessControl attributes - MTRAttributeIDTypeClusterAccessControlAttributeAclID MTR_NEWLY_AVAILABLE = 0x00000000, + MTRAttributeIDTypeClusterAccessControlAttributeACLID MTR_NEWLY_AVAILABLE = 0x00000000, MTRAttributeIDTypeClusterAccessControlAttributeExtensionID MTR_NEWLY_AVAILABLE = 0x00000001, MTRAttributeIDTypeClusterAccessControlAttributeSubjectsPerAccessControlEntryID MTR_NEWLY_AVAILABLE = 0x00000002, MTRAttributeIDTypeClusterAccessControlAttributeTargetsPerAccessControlEntryID MTR_NEWLY_AVAILABLE = 0x00000003, @@ -837,16 +839,16 @@ typedef NS_ENUM(uint32_t, MTRAttributeIDType) { "Please use MTRAttributeIDTypeClusterOtaSoftwareUpdateProviderAttributeClusterRevisionID") = MTRClusterGlobalAttributeClusterRevisionID, - // Cluster OtaSoftwareUpdateProvider attributes - MTRAttributeIDTypeClusterOtaSoftwareUpdateProviderAttributeGeneratedCommandListID MTR_NEWLY_AVAILABLE + // Cluster OTASoftwareUpdateProvider attributes + MTRAttributeIDTypeClusterOTASoftwareUpdateProviderAttributeGeneratedCommandListID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeGeneratedCommandListID, - MTRAttributeIDTypeClusterOtaSoftwareUpdateProviderAttributeAcceptedCommandListID MTR_NEWLY_AVAILABLE + MTRAttributeIDTypeClusterOTASoftwareUpdateProviderAttributeAcceptedCommandListID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeAcceptedCommandListID, - MTRAttributeIDTypeClusterOtaSoftwareUpdateProviderAttributeAttributeListID MTR_NEWLY_AVAILABLE + MTRAttributeIDTypeClusterOTASoftwareUpdateProviderAttributeAttributeListID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeAttributeListID, - MTRAttributeIDTypeClusterOtaSoftwareUpdateProviderAttributeFeatureMapID MTR_NEWLY_AVAILABLE + MTRAttributeIDTypeClusterOTASoftwareUpdateProviderAttributeFeatureMapID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeFeatureMapID, - MTRAttributeIDTypeClusterOtaSoftwareUpdateProviderAttributeClusterRevisionID MTR_NEWLY_AVAILABLE + MTRAttributeIDTypeClusterOTASoftwareUpdateProviderAttributeClusterRevisionID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeClusterRevisionID, // Cluster OtaSoftwareUpdateRequestor deprecated attribute names @@ -878,20 +880,20 @@ typedef NS_ENUM(uint32_t, MTRAttributeIDType) { "Please use MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeClusterRevisionID") = MTRClusterGlobalAttributeClusterRevisionID, - // Cluster OtaSoftwareUpdateRequestor attributes - MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeDefaultOtaProvidersID MTR_NEWLY_AVAILABLE = 0x00000000, - MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeUpdatePossibleID MTR_NEWLY_AVAILABLE = 0x00000001, - MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeUpdateStateID MTR_NEWLY_AVAILABLE = 0x00000002, - MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeUpdateStateProgressID MTR_NEWLY_AVAILABLE = 0x00000003, - MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeGeneratedCommandListID MTR_NEWLY_AVAILABLE + // Cluster OTASoftwareUpdateRequestor attributes + MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeDefaultOtaProvidersID MTR_NEWLY_AVAILABLE = 0x00000000, + MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeUpdatePossibleID MTR_NEWLY_AVAILABLE = 0x00000001, + MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeUpdateStateID MTR_NEWLY_AVAILABLE = 0x00000002, + MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeUpdateStateProgressID MTR_NEWLY_AVAILABLE = 0x00000003, + MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeGeneratedCommandListID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeGeneratedCommandListID, - MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeAcceptedCommandListID MTR_NEWLY_AVAILABLE + MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeAcceptedCommandListID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeAcceptedCommandListID, - MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeAttributeListID MTR_NEWLY_AVAILABLE + MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeAttributeListID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeAttributeListID, - MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeFeatureMapID MTR_NEWLY_AVAILABLE + MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeFeatureMapID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeFeatureMapID, - MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeClusterRevisionID MTR_NEWLY_AVAILABLE + MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeClusterRevisionID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeClusterRevisionID, // Cluster LocalizationConfiguration deprecated attribute names @@ -3870,9 +3872,9 @@ typedef NS_ENUM(uint32_t, MTRAttributeIDType) { MTRAttributeIDTypeClusterOccupancySensingAttributeOccupancyID MTR_NEWLY_AVAILABLE = 0x00000000, MTRAttributeIDTypeClusterOccupancySensingAttributeOccupancySensorTypeID MTR_NEWLY_AVAILABLE = 0x00000001, MTRAttributeIDTypeClusterOccupancySensingAttributeOccupancySensorTypeBitmapID MTR_NEWLY_AVAILABLE = 0x00000002, - MTRAttributeIDTypeClusterOccupancySensingAttributePirOccupiedToUnoccupiedDelayID MTR_NEWLY_AVAILABLE = 0x00000010, - MTRAttributeIDTypeClusterOccupancySensingAttributePirUnoccupiedToOccupiedDelayID MTR_NEWLY_AVAILABLE = 0x00000011, - MTRAttributeIDTypeClusterOccupancySensingAttributePirUnoccupiedToOccupiedThresholdID MTR_NEWLY_AVAILABLE = 0x00000012, + MTRAttributeIDTypeClusterOccupancySensingAttributePIROccupiedToUnoccupiedDelayID MTR_NEWLY_AVAILABLE = 0x00000010, + MTRAttributeIDTypeClusterOccupancySensingAttributePIRUnoccupiedToOccupiedDelayID MTR_NEWLY_AVAILABLE = 0x00000011, + MTRAttributeIDTypeClusterOccupancySensingAttributePIRUnoccupiedToOccupiedThresholdID MTR_NEWLY_AVAILABLE = 0x00000012, MTRAttributeIDTypeClusterOccupancySensingAttributeUltrasonicOccupiedToUnoccupiedDelayID MTR_NEWLY_AVAILABLE = 0x00000020, MTRAttributeIDTypeClusterOccupancySensingAttributeUltrasonicUnoccupiedToOccupiedDelayID MTR_NEWLY_AVAILABLE = 0x00000021, MTRAttributeIDTypeClusterOccupancySensingAttributeUltrasonicUnoccupiedToOccupiedThresholdID MTR_NEWLY_AVAILABLE = 0x00000022, @@ -3911,16 +3913,16 @@ typedef NS_ENUM(uint32_t, MTRAttributeIDType) { "Please use MTRAttributeIDTypeClusterWakeOnLanAttributeClusterRevisionID") = MTRClusterGlobalAttributeClusterRevisionID, - // Cluster WakeOnLan attributes - MTRAttributeIDTypeClusterWakeOnLanAttributeMACAddressID MTR_NEWLY_AVAILABLE = 0x00000000, - MTRAttributeIDTypeClusterWakeOnLanAttributeGeneratedCommandListID MTR_NEWLY_AVAILABLE + // Cluster WakeOnLAN attributes + MTRAttributeIDTypeClusterWakeOnLANAttributeMACAddressID MTR_NEWLY_AVAILABLE = 0x00000000, + MTRAttributeIDTypeClusterWakeOnLANAttributeGeneratedCommandListID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeGeneratedCommandListID, - MTRAttributeIDTypeClusterWakeOnLanAttributeAcceptedCommandListID MTR_NEWLY_AVAILABLE + MTRAttributeIDTypeClusterWakeOnLANAttributeAcceptedCommandListID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeAcceptedCommandListID, - MTRAttributeIDTypeClusterWakeOnLanAttributeAttributeListID MTR_NEWLY_AVAILABLE + MTRAttributeIDTypeClusterWakeOnLANAttributeAttributeListID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeAttributeListID, - MTRAttributeIDTypeClusterWakeOnLanAttributeFeatureMapID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeFeatureMapID, - MTRAttributeIDTypeClusterWakeOnLanAttributeClusterRevisionID MTR_NEWLY_AVAILABLE + MTRAttributeIDTypeClusterWakeOnLANAttributeFeatureMapID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeFeatureMapID, + MTRAttributeIDTypeClusterWakeOnLANAttributeClusterRevisionID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeClusterRevisionID, // Cluster Channel deprecated attribute names @@ -4887,6 +4889,51 @@ typedef NS_ENUM(uint32_t, MTRAttributeIDType) { MTRAttributeIDTypeClusterElectricalMeasurementAttributeClusterRevisionID MTR_NEWLY_AVAILABLE = MTRAttributeIDTypeGlobalAttributeClusterRevisionID, + // Cluster ClientMonitoring deprecated attribute names + MTRClusterClientMonitoringAttributeIdleModeIntervalID MTR_NEWLY_DEPRECATED( + "Please use MTRAttributeIDTypeClusterClientMonitoringAttributeIdleModeIntervalID") + = 0x00000000, + MTRClusterClientMonitoringAttributeActiveModeIntervalID MTR_NEWLY_DEPRECATED( + "Please use MTRAttributeIDTypeClusterClientMonitoringAttributeActiveModeIntervalID") + = 0x00000001, + MTRClusterClientMonitoringAttributeActiveModeThresholdID MTR_NEWLY_DEPRECATED( + "Please use MTRAttributeIDTypeClusterClientMonitoringAttributeActiveModeThresholdID") + = 0x00000002, + MTRClusterClientMonitoringAttributeExpectedClientsID MTR_NEWLY_DEPRECATED( + "Please use MTRAttributeIDTypeClusterClientMonitoringAttributeExpectedClientsID") + = 0x00000003, + MTRClusterClientMonitoringAttributeGeneratedCommandListID MTR_NEWLY_DEPRECATED( + "Please use MTRAttributeIDTypeClusterClientMonitoringAttributeGeneratedCommandListID") + = MTRClusterGlobalAttributeGeneratedCommandListID, + MTRClusterClientMonitoringAttributeAcceptedCommandListID MTR_NEWLY_DEPRECATED( + "Please use MTRAttributeIDTypeClusterClientMonitoringAttributeAcceptedCommandListID") + = MTRClusterGlobalAttributeAcceptedCommandListID, + MTRClusterClientMonitoringAttributeAttributeListID MTR_NEWLY_DEPRECATED( + "Please use MTRAttributeIDTypeClusterClientMonitoringAttributeAttributeListID") + = MTRClusterGlobalAttributeAttributeListID, + MTRClusterClientMonitoringAttributeFeatureMapID MTR_NEWLY_DEPRECATED( + "Please use MTRAttributeIDTypeClusterClientMonitoringAttributeFeatureMapID") + = MTRClusterGlobalAttributeFeatureMapID, + MTRClusterClientMonitoringAttributeClusterRevisionID MTR_NEWLY_DEPRECATED( + "Please use MTRAttributeIDTypeClusterClientMonitoringAttributeClusterRevisionID") + = MTRClusterGlobalAttributeClusterRevisionID, + + // Cluster ClientMonitoring attributes + MTRAttributeIDTypeClusterClientMonitoringAttributeIdleModeIntervalID MTR_NEWLY_AVAILABLE = 0x00000000, + MTRAttributeIDTypeClusterClientMonitoringAttributeActiveModeIntervalID MTR_NEWLY_AVAILABLE = 0x00000001, + MTRAttributeIDTypeClusterClientMonitoringAttributeActiveModeThresholdID MTR_NEWLY_AVAILABLE = 0x00000002, + MTRAttributeIDTypeClusterClientMonitoringAttributeExpectedClientsID MTR_NEWLY_AVAILABLE = 0x00000003, + MTRAttributeIDTypeClusterClientMonitoringAttributeGeneratedCommandListID MTR_NEWLY_AVAILABLE + = MTRAttributeIDTypeGlobalAttributeGeneratedCommandListID, + MTRAttributeIDTypeClusterClientMonitoringAttributeAcceptedCommandListID MTR_NEWLY_AVAILABLE + = MTRAttributeIDTypeGlobalAttributeAcceptedCommandListID, + MTRAttributeIDTypeClusterClientMonitoringAttributeAttributeListID MTR_NEWLY_AVAILABLE + = MTRAttributeIDTypeGlobalAttributeAttributeListID, + MTRAttributeIDTypeClusterClientMonitoringAttributeFeatureMapID MTR_NEWLY_AVAILABLE + = MTRAttributeIDTypeGlobalAttributeFeatureMapID, + MTRAttributeIDTypeClusterClientMonitoringAttributeClusterRevisionID MTR_NEWLY_AVAILABLE + = MTRAttributeIDTypeGlobalAttributeClusterRevisionID, + // Cluster TestCluster deprecated attribute names MTRClusterTestClusterAttributeBooleanID MTR_NEWLY_DEPRECATED( "Please use MTRAttributeIDTypeClusterUnitTestingAttributeBooleanID") @@ -5511,20 +5558,20 @@ typedef NS_ENUM(uint32_t, MTRCommandIDType) { "Please use MTRCommandIDTypeClusterOtaSoftwareUpdateProviderCommandNotifyUpdateAppliedID") = 0x00000004, - // Cluster OtaSoftwareUpdateProvider commands - MTRCommandIDTypeClusterOtaSoftwareUpdateProviderCommandQueryImageID MTR_NEWLY_AVAILABLE = 0x00000000, - MTRCommandIDTypeClusterOtaSoftwareUpdateProviderCommandQueryImageResponseID MTR_NEWLY_AVAILABLE = 0x00000001, - MTRCommandIDTypeClusterOtaSoftwareUpdateProviderCommandApplyUpdateRequestID MTR_NEWLY_AVAILABLE = 0x00000002, - MTRCommandIDTypeClusterOtaSoftwareUpdateProviderCommandApplyUpdateResponseID MTR_NEWLY_AVAILABLE = 0x00000003, - MTRCommandIDTypeClusterOtaSoftwareUpdateProviderCommandNotifyUpdateAppliedID MTR_NEWLY_AVAILABLE = 0x00000004, + // Cluster OTASoftwareUpdateProvider commands + MTRCommandIDTypeClusterOTASoftwareUpdateProviderCommandQueryImageID MTR_NEWLY_AVAILABLE = 0x00000000, + MTRCommandIDTypeClusterOTASoftwareUpdateProviderCommandQueryImageResponseID MTR_NEWLY_AVAILABLE = 0x00000001, + MTRCommandIDTypeClusterOTASoftwareUpdateProviderCommandApplyUpdateRequestID MTR_NEWLY_AVAILABLE = 0x00000002, + MTRCommandIDTypeClusterOTASoftwareUpdateProviderCommandApplyUpdateResponseID MTR_NEWLY_AVAILABLE = 0x00000003, + MTRCommandIDTypeClusterOTASoftwareUpdateProviderCommandNotifyUpdateAppliedID MTR_NEWLY_AVAILABLE = 0x00000004, // Cluster OtaSoftwareUpdateRequestor deprecated command id names MTRClusterOtaSoftwareUpdateRequestorCommandAnnounceOtaProviderID MTR_NEWLY_DEPRECATED( "Please use MTRCommandIDTypeClusterOtaSoftwareUpdateRequestorCommandAnnounceOtaProviderID") = 0x00000000, - // Cluster OtaSoftwareUpdateRequestor commands - MTRCommandIDTypeClusterOtaSoftwareUpdateRequestorCommandAnnounceOtaProviderID MTR_NEWLY_AVAILABLE = 0x00000000, + // Cluster OTASoftwareUpdateRequestor commands + MTRCommandIDTypeClusterOTASoftwareUpdateRequestorCommandAnnounceOtaProviderID MTR_NEWLY_AVAILABLE = 0x00000000, // Cluster GeneralCommissioning deprecated command id names MTRClusterGeneralCommissioningCommandArmFailSafeID MTR_NEWLY_DEPRECATED( @@ -6199,6 +6246,18 @@ typedef NS_ENUM(uint32_t, MTRCommandIDType) { MTRCommandIDTypeClusterElectricalMeasurementCommandGetMeasurementProfileResponseCommandID MTR_NEWLY_AVAILABLE = 0x00000001, MTRCommandIDTypeClusterElectricalMeasurementCommandGetMeasurementProfileCommandID MTR_NEWLY_AVAILABLE = 0x00000001, + // Cluster ClientMonitoring deprecated command id names + MTRClusterClientMonitoringCommandRegisterClientMonitoringID MTR_NEWLY_DEPRECATED( + "Please use MTRCommandIDTypeClusterClientMonitoringCommandRegisterClientMonitoringID") + = 0x00000000, + MTRClusterClientMonitoringCommandStayAwakeRequestID MTR_NEWLY_DEPRECATED( + "Please use MTRCommandIDTypeClusterClientMonitoringCommandStayAwakeRequestID") + = 0x00000001, + + // Cluster ClientMonitoring commands + MTRCommandIDTypeClusterClientMonitoringCommandRegisterClientMonitoringID MTR_NEWLY_AVAILABLE = 0x00000000, + MTRCommandIDTypeClusterClientMonitoringCommandStayAwakeRequestID MTR_NEWLY_AVAILABLE = 0x00000001, + // Cluster TestCluster deprecated command id names MTRClusterTestClusterCommandTestID MTR_NEWLY_DEPRECATED("Please use MTRCommandIDTypeClusterUnitTestingCommandTestID") = 0x00000000, @@ -6402,10 +6461,10 @@ typedef NS_ENUM(uint32_t, MTREventIDType) { "Please use MTREventIDTypeClusterOtaSoftwareUpdateRequestorEventDownloadErrorID") = 0x00000002, - // Cluster OtaSoftwareUpdateRequestor events - MTREventIDTypeClusterOtaSoftwareUpdateRequestorEventStateTransitionID MTR_NEWLY_AVAILABLE = 0x00000000, - MTREventIDTypeClusterOtaSoftwareUpdateRequestorEventVersionAppliedID MTR_NEWLY_AVAILABLE = 0x00000001, - MTREventIDTypeClusterOtaSoftwareUpdateRequestorEventDownloadErrorID MTR_NEWLY_AVAILABLE = 0x00000002, + // Cluster OTASoftwareUpdateRequestor events + MTREventIDTypeClusterOTASoftwareUpdateRequestorEventStateTransitionID MTR_NEWLY_AVAILABLE = 0x00000000, + MTREventIDTypeClusterOTASoftwareUpdateRequestorEventVersionAppliedID MTR_NEWLY_AVAILABLE = 0x00000001, + MTREventIDTypeClusterOTASoftwareUpdateRequestorEventDownloadErrorID MTR_NEWLY_AVAILABLE = 0x00000002, // Cluster GeneralDiagnostics deprecated event names MTRClusterGeneralDiagnosticsEventHardwareFaultChangeID MTR_NEWLY_DEPRECATED( diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRClusters.h b/src/darwin/Framework/CHIP/zap-generated/MTRClusters.h index 17c833607407ea..5abf133140384d 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRClusters.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRClusters.h @@ -543,7 +543,7 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; -- (NSDictionary *)readAttributeDeviceListWithParams:(MTRReadParams * _Nullable)params; +- (NSDictionary *)readAttributeDeviceTypeListWithParams:(MTRReadParams * _Nullable)params MTR_NEWLY_AVAILABLE; - (NSDictionary *)readAttributeServerListWithParams:(MTRReadParams * _Nullable)params; @@ -611,12 +611,12 @@ NS_ASSUME_NONNULL_BEGIN endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; -- (NSDictionary *)readAttributeAclWithParams:(MTRReadParams * _Nullable)params; -- (void)writeAttributeAclWithValue:(NSDictionary *)dataValueDictionary - expectedValueInterval:(NSNumber *)expectedValueIntervalMs; -- (void)writeAttributeAclWithValue:(NSDictionary *)dataValueDictionary +- (NSDictionary *)readAttributeACLWithParams:(MTRReadParams * _Nullable)params MTR_NEWLY_AVAILABLE; +- (void)writeAttributeACLWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs MTR_NEWLY_AVAILABLE; +- (void)writeAttributeACLWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs - params:(MTRWriteParams * _Nullable)params; + params:(MTRWriteParams * _Nullable)params MTR_NEWLY_AVAILABLE; - (NSDictionary *)readAttributeExtensionWithParams:(MTRReadParams * _Nullable)params; - (void)writeAttributeExtensionWithValue:(NSDictionary *)dataValueDictionary @@ -820,23 +820,24 @@ NS_ASSUME_NONNULL_BEGIN * Cluster OTA Software Update Provider * Provides an interface for providing OTA software updates */ -@interface MTRClusterOtaSoftwareUpdateProvider : MTRCluster +MTR_NEWLY_AVAILABLE +@interface MTRClusterOTASoftwareUpdateProvider : MTRCluster - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; -- (void)queryImageWithParams:(MTROtaSoftwareUpdateProviderClusterQueryImageParams *)params +- (void)queryImageWithParams:(MTROTASoftwareUpdateProviderClusterQueryImageParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs - completion:(void (^)(MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, + completion:(void (^)(MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; -- (void)applyUpdateRequestWithParams:(MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams *)params +- (void)applyUpdateRequestWithParams:(MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs - completion:(void (^)(MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, + completion:(void (^)(MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_NEWLY_AVAILABLE; -- (void)notifyUpdateAppliedWithParams:(MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams *)params +- (void)notifyUpdateAppliedWithParams:(MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -860,13 +861,14 @@ NS_ASSUME_NONNULL_BEGIN * Cluster OTA Software Update Requestor * Provides an interface for downloading and applying OTA software updates */ -@interface MTRClusterOtaSoftwareUpdateRequestor : MTRCluster +MTR_NEWLY_AVAILABLE +@interface MTRClusterOTASoftwareUpdateRequestor : MTRCluster - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_NEWLY_AVAILABLE; -- (void)announceOtaProviderWithParams:(MTROtaSoftwareUpdateRequestorClusterAnnounceOtaProviderParams *)params +- (void)announceOtaProviderWithParams:(MTROTASoftwareUpdateRequestorClusterAnnounceOtaProviderParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_NEWLY_AVAILABLE; @@ -3609,26 +3611,29 @@ labels. - (NSDictionary *)readAttributeOccupancySensorTypeBitmapWithParams:(MTRReadParams * _Nullable)params; -- (NSDictionary *)readAttributePirOccupiedToUnoccupiedDelayWithParams:(MTRReadParams * _Nullable)params; -- (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSDictionary *)dataValueDictionary - expectedValueInterval:(NSNumber *)expectedValueIntervalMs; -- (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSDictionary *)dataValueDictionary +- (NSDictionary *)readAttributePIROccupiedToUnoccupiedDelayWithParams:(MTRReadParams * _Nullable)params + MTR_NEWLY_AVAILABLE; +- (void)writeAttributePIROccupiedToUnoccupiedDelayWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs MTR_NEWLY_AVAILABLE; +- (void)writeAttributePIROccupiedToUnoccupiedDelayWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs - params:(MTRWriteParams * _Nullable)params; + params:(MTRWriteParams * _Nullable)params MTR_NEWLY_AVAILABLE; -- (NSDictionary *)readAttributePirUnoccupiedToOccupiedDelayWithParams:(MTRReadParams * _Nullable)params; -- (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSDictionary *)dataValueDictionary - expectedValueInterval:(NSNumber *)expectedValueIntervalMs; -- (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSDictionary *)dataValueDictionary +- (NSDictionary *)readAttributePIRUnoccupiedToOccupiedDelayWithParams:(MTRReadParams * _Nullable)params + MTR_NEWLY_AVAILABLE; +- (void)writeAttributePIRUnoccupiedToOccupiedDelayWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs MTR_NEWLY_AVAILABLE; +- (void)writeAttributePIRUnoccupiedToOccupiedDelayWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs - params:(MTRWriteParams * _Nullable)params; + params:(MTRWriteParams * _Nullable)params MTR_NEWLY_AVAILABLE; -- (NSDictionary *)readAttributePirUnoccupiedToOccupiedThresholdWithParams:(MTRReadParams * _Nullable)params; -- (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSDictionary *)dataValueDictionary - expectedValueInterval:(NSNumber *)expectedValueIntervalMs; -- (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSDictionary *)dataValueDictionary +- (NSDictionary *)readAttributePIRUnoccupiedToOccupiedThresholdWithParams:(MTRReadParams * _Nullable)params + MTR_NEWLY_AVAILABLE; +- (void)writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs MTR_NEWLY_AVAILABLE; +- (void)writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs - params:(MTRWriteParams * _Nullable)params; + params:(MTRWriteParams * _Nullable)params MTR_NEWLY_AVAILABLE; - (NSDictionary *)readAttributeUltrasonicOccupiedToUnoccupiedDelayWithParams:(MTRReadParams * _Nullable)params; - (void)writeAttributeUltrasonicOccupiedToUnoccupiedDelayWithValue:(NSDictionary *)dataValueDictionary @@ -3692,7 +3697,8 @@ labels. * Cluster Wake on LAN * This cluster provides an interface for managing low power mode on a device that supports the Wake On LAN protocol. */ -@interface MTRClusterWakeOnLan : MTRCluster +MTR_NEWLY_AVAILABLE +@interface MTRClusterWakeOnLAN : MTRCluster - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID @@ -5303,15 +5309,12 @@ MTR_NEWLY_AVAILABLE expectedValueInterval:(NSNumber *)expectedValueIntervalMs params:(MTRWriteParams * _Nullable)params; -- (NSDictionary *)readAttributeWriteOnlyInt8uWithParams:(MTRReadParams * _Nullable)params - API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)); +- (NSDictionary *)readAttributeWriteOnlyInt8uWithParams:(MTRReadParams * _Nullable)params; - (void)writeAttributeWriteOnlyInt8uWithValue:(NSDictionary *)dataValueDictionary - expectedValueInterval:(NSNumber *)expectedValueIntervalMs - API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)); + expectedValueInterval:(NSNumber *)expectedValueIntervalMs; - (void)writeAttributeWriteOnlyInt8uWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs - params:(MTRWriteParams * _Nullable)params - API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)); + params:(MTRWriteParams * _Nullable)params; - (NSDictionary *)readAttributeGeneratedCommandListWithParams:(MTRReadParams * _Nullable)params; @@ -5328,6 +5331,18 @@ MTR_NEWLY_AVAILABLE @end +MTR_NEWLY_DEPRECATED("Please use MTRClusterOTASoftwareUpdateProvider") +@interface MTRClusterOtaSoftwareUpdateProvider : MTRClusterOTASoftwareUpdateProvider +@end + +MTR_NEWLY_DEPRECATED("Please use MTRClusterOTASoftwareUpdateRequestor") +@interface MTRClusterOtaSoftwareUpdateRequestor : MTRClusterOTASoftwareUpdateRequestor +@end + +MTR_NEWLY_DEPRECATED("Please use MTRClusterWakeOnLAN") +@interface MTRClusterWakeOnLan : MTRClusterWakeOnLAN +@end + MTR_NEWLY_DEPRECATED("Please use MTRClusterUnitTesting") @interface MTRClusterTestCluster : MTRClusterUnitTesting @end @@ -5592,6 +5607,8 @@ MTR_NEWLY_DEPRECATED("Please use MTRClusterUnitTesting") endpoint:(uint16_t)endpoint queue:(dispatch_queue_t)queue MTR_NEWLY_DEPRECATED("Please use initWithDevice:endpoindID:queue:"); +- (NSDictionary *)readAttributeDeviceListWithParams:(MTRReadParams * _Nullable)params + MTR_NEWLY_DEPRECATED("Please use readAttributeDeviceTypeListWithParams on MTRClusterDescriptor"); @end @interface MTRClusterBinding (Deprecated) @@ -5608,6 +5625,15 @@ MTR_NEWLY_DEPRECATED("Please use MTRClusterUnitTesting") endpoint:(uint16_t)endpoint queue:(dispatch_queue_t)queue MTR_NEWLY_DEPRECATED("Please use initWithDevice:endpoindID:queue:"); +- (NSDictionary *)readAttributeAclWithParams:(MTRReadParams * _Nullable)params + MTR_NEWLY_DEPRECATED("Please use readAttributeACLWithParams on MTRClusterAccessControl"); +- (void)writeAttributeAclWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs + MTR_NEWLY_DEPRECATED("Please use writeAtributeACLWithValue on MTRClusterAccessControl"); +- (void)writeAttributeAclWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs + params:(MTRWriteParams * _Nullable)params + MTR_NEWLY_DEPRECATED("Please use writeAttributeACLWithValue on MTRClusterAccessControl"); @end @interface MTRClusterActions (Deprecated) @@ -6505,6 +6531,33 @@ MTR_NEWLY_DEPRECATED("Please use MTRClusterUnitTesting") endpoint:(uint16_t)endpoint queue:(dispatch_queue_t)queue MTR_NEWLY_DEPRECATED("Please use initWithDevice:endpoindID:queue:"); +- (NSDictionary *)readAttributePirOccupiedToUnoccupiedDelayWithParams:(MTRReadParams * _Nullable)params + MTR_NEWLY_DEPRECATED("Please use readAttributePIROccupiedToUnoccupiedDelayWithParams on MTRClusterOccupancySensing"); +- (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs + MTR_NEWLY_DEPRECATED("Please use writeAtributePIROccupiedToUnoccupiedDelayWithValue on MTRClusterOccupancySensing"); +- (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs + params:(MTRWriteParams * _Nullable)params + MTR_NEWLY_DEPRECATED("Please use writeAttributePIROccupiedToUnoccupiedDelayWithValue on MTRClusterOccupancySensing"); +- (NSDictionary *)readAttributePirUnoccupiedToOccupiedDelayWithParams:(MTRReadParams * _Nullable)params + MTR_NEWLY_DEPRECATED("Please use readAttributePIRUnoccupiedToOccupiedDelayWithParams on MTRClusterOccupancySensing"); +- (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs + MTR_NEWLY_DEPRECATED("Please use writeAtributePIRUnoccupiedToOccupiedDelayWithValue on MTRClusterOccupancySensing"); +- (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs + params:(MTRWriteParams * _Nullable)params + MTR_NEWLY_DEPRECATED("Please use writeAttributePIRUnoccupiedToOccupiedDelayWithValue on MTRClusterOccupancySensing"); +- (NSDictionary *)readAttributePirUnoccupiedToOccupiedThresholdWithParams:(MTRReadParams * _Nullable)params + MTR_NEWLY_DEPRECATED("Please use readAttributePIRUnoccupiedToOccupiedThresholdWithParams on MTRClusterOccupancySensing"); +- (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs + MTR_NEWLY_DEPRECATED("Please use writeAtributePIRUnoccupiedToOccupiedThresholdWithValue on MTRClusterOccupancySensing"); +- (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs + params:(MTRWriteParams * _Nullable)params + MTR_NEWLY_DEPRECATED("Please use writeAttributePIRUnoccupiedToOccupiedThresholdWithValue on MTRClusterOccupancySensing"); @end @interface MTRClusterWakeOnLan (Deprecated) diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRClusters.mm b/src/darwin/Framework/CHIP/zap-generated/MTRClusters.mm index 487c481949f9a0..795bea30c58be3 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRClusters.mm +++ b/src/darwin/Framework/CHIP/zap-generated/MTRClusters.mm @@ -26,6 +26,7 @@ #import "MTRCommandPayloadsObjc.h" #import "MTRDevice.h" #import "MTRDevice_Internal.h" +#import "MTRLogging_Internal.h" #import "MTRStructsObjc.h" #include @@ -38,6 +39,21 @@ using chip::Messaging::ExchangeManager; using chip::SessionHandle; +static void MTRClustersLogEnqueue(NSString * logPrefix, MTRAsyncCallbackWorkQueue * workQueue) +{ + MTR_LOG_INFO("%@ enqueueWorkItem %@", logPrefix, workQueue); +} + +static void MTRClustersLogDequeue(NSString * logPrefix, MTRAsyncCallbackWorkQueue * workQueue) +{ + MTR_LOG_INFO("%@ dequeueWorkItem %@", logPrefix, workQueue); +} + +static void MTRClustersLogCompletion(NSString * logPrefix, id value, NSError * error) +{ + MTR_LOG_INFO("%@ completion value %@ error %@ endWork", logPrefix, value, error); +} + // NOLINTBEGIN(clang-analyzer-cplusplus.NewDeleteLeaks): Linter is unable to locate the delete on these objects. @implementation MTRClusterIdentify @@ -59,20 +75,27 @@ - (void)identifyWithParams:(MTRIdentifyClusterIdentifyParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeIdentifyID, (unsigned int) MTRCommandIDTypeClusterIdentifyCommandIdentifyID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -91,6 +114,7 @@ - (void)identifyWithParams:(MTRIdentifyClusterIdentifyParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -108,20 +132,27 @@ - (void)triggerEffectWithParams:(MTRIdentifyClusterTriggerEffectParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeIdentifyID, (unsigned int) MTRCommandIDTypeClusterIdentifyCommandTriggerEffectID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -143,6 +174,7 @@ - (void)triggerEffectWithParams:(MTRIdentifyClusterTriggerEffectParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -281,20 +313,27 @@ - (void)addGroupWithParams:(MTRGroupsClusterAddGroupParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(void (^)(MTRGroupsClusterAddGroupResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeGroupsID, (unsigned int) MTRCommandIDTypeClusterGroupsCommandAddGroupID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRGroupsClusterAddGroupResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, GroupsClusterAddGroupResponseCallbackType successCb, @@ -314,6 +353,7 @@ - (void)addGroupWithParams:(MTRGroupsClusterAddGroupParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -332,20 +372,27 @@ - (void)viewGroupWithParams:(MTRGroupsClusterViewGroupParams *)params completion: (void (^)(MTRGroupsClusterViewGroupResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeGroupsID, (unsigned int) MTRCommandIDTypeClusterGroupsCommandViewGroupID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRGroupsClusterViewGroupResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -364,6 +411,7 @@ - (void)viewGroupWithParams:(MTRGroupsClusterViewGroupParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -382,20 +430,27 @@ - (void)getGroupMembershipWithParams:(MTRGroupsClusterGetGroupMembershipParams * completion:(void (^)(MTRGroupsClusterGetGroupMembershipResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeGroupsID, (unsigned int) MTRCommandIDTypeClusterGroupsCommandGetGroupMembershipID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRGroupsClusterGetGroupMembershipResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -436,6 +491,7 @@ - (void)getGroupMembershipWithParams:(MTRGroupsClusterGetGroupMembershipParams * std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -454,20 +510,27 @@ - (void)removeGroupWithParams:(MTRGroupsClusterRemoveGroupParams *)params completion: (void (^)(MTRGroupsClusterRemoveGroupResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeGroupsID, (unsigned int) MTRCommandIDTypeClusterGroupsCommandRemoveGroupID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRGroupsClusterRemoveGroupResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -487,6 +550,7 @@ - (void)removeGroupWithParams:(MTRGroupsClusterRemoveGroupParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -513,20 +577,27 @@ - (void)removeAllGroupsWithParams:(MTRGroupsClusterRemoveAllGroupsParams * _Null expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeGroupsID, (unsigned int) MTRCommandIDTypeClusterGroupsCommandRemoveAllGroupsID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -544,6 +615,7 @@ - (void)removeAllGroupsWithParams:(MTRGroupsClusterRemoveAllGroupsParams * _Null std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -561,20 +633,27 @@ - (void)addGroupIfIdentifyingWithParams:(MTRGroupsClusterAddGroupIfIdentifyingPa expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeGroupsID, + (unsigned int) MTRCommandIDTypeClusterGroupsCommandAddGroupIfIdentifyingID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -594,6 +673,7 @@ - (void)addGroupIfIdentifyingWithParams:(MTRGroupsClusterAddGroupIfIdentifyingPa std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -771,20 +851,27 @@ - (void)addSceneWithParams:(MTRScenesClusterAddSceneParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(void (^)(MTRScenesClusterAddSceneResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeScenesID, (unsigned int) MTRCommandIDTypeClusterScenesCommandAddSceneID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRScenesClusterAddSceneResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, ScenesClusterAddSceneResponseCallbackType successCb, @@ -880,6 +967,7 @@ - (void)addSceneWithParams:(MTRScenesClusterAddSceneParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -898,20 +986,27 @@ - (void)viewSceneWithParams:(MTRScenesClusterViewSceneParams *)params completion: (void (^)(MTRScenesClusterViewSceneResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeScenesID, (unsigned int) MTRCommandIDTypeClusterScenesCommandViewSceneID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRScenesClusterViewSceneResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -931,6 +1026,7 @@ - (void)viewSceneWithParams:(MTRScenesClusterViewSceneParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -949,20 +1045,27 @@ - (void)removeSceneWithParams:(MTRScenesClusterRemoveSceneParams *)params completion: (void (^)(MTRScenesClusterRemoveSceneResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeScenesID, (unsigned int) MTRCommandIDTypeClusterScenesCommandRemoveSceneID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRScenesClusterRemoveSceneResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -983,6 +1086,7 @@ - (void)removeSceneWithParams:(MTRScenesClusterRemoveSceneParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -1001,20 +1105,27 @@ - (void)removeAllScenesWithParams:(MTRScenesClusterRemoveAllScenesParams *)param completion:(void (^)(MTRScenesClusterRemoveAllScenesResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeScenesID, (unsigned int) MTRCommandIDTypeClusterScenesCommandRemoveAllScenesID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRScenesClusterRemoveAllScenesResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -1034,6 +1145,7 @@ - (void)removeAllScenesWithParams:(MTRScenesClusterRemoveAllScenesParams *)param std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -1052,20 +1164,27 @@ - (void)storeSceneWithParams:(MTRScenesClusterStoreSceneParams *)params completion: (void (^)(MTRScenesClusterStoreSceneResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeScenesID, (unsigned int) MTRCommandIDTypeClusterScenesCommandStoreSceneID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRScenesClusterStoreSceneResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -1085,6 +1204,7 @@ - (void)storeSceneWithParams:(MTRScenesClusterStoreSceneParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -1102,20 +1222,27 @@ - (void)recallSceneWithParams:(MTRScenesClusterRecallSceneParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeScenesID, (unsigned int) MTRCommandIDTypeClusterScenesCommandRecallSceneID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -1144,6 +1271,7 @@ - (void)recallSceneWithParams:(MTRScenesClusterRecallSceneParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -1162,20 +1290,27 @@ - (void)getSceneMembershipWithParams:(MTRScenesClusterGetSceneMembershipParams * completion:(void (^)(MTRScenesClusterGetSceneMembershipResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeScenesID, (unsigned int) MTRCommandIDTypeClusterScenesCommandGetSceneMembershipID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRScenesClusterGetSceneMembershipResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -1195,6 +1330,7 @@ - (void)getSceneMembershipWithParams:(MTRScenesClusterGetSceneMembershipParams * std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -1213,20 +1349,27 @@ - (void)enhancedAddSceneWithParams:(MTRScenesClusterEnhancedAddSceneParams *)par completion:(void (^)(MTRScenesClusterEnhancedAddSceneResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeScenesID, (unsigned int) MTRCommandIDTypeClusterScenesCommandEnhancedAddSceneID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRScenesClusterEnhancedAddSceneResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -1323,6 +1466,7 @@ - (void)enhancedAddSceneWithParams:(MTRScenesClusterEnhancedAddSceneParams *)par std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -1341,20 +1485,27 @@ - (void)enhancedViewSceneWithParams:(MTRScenesClusterEnhancedViewSceneParams *)p completion:(void (^)(MTRScenesClusterEnhancedViewSceneResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeScenesID, (unsigned int) MTRCommandIDTypeClusterScenesCommandEnhancedViewSceneID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRScenesClusterEnhancedViewSceneResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -1375,6 +1526,7 @@ - (void)enhancedViewSceneWithParams:(MTRScenesClusterEnhancedViewSceneParams *)p std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -1393,20 +1545,27 @@ - (void)copySceneWithParams:(MTRScenesClusterCopySceneParams *)params completion: (void (^)(MTRScenesClusterCopySceneResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeScenesID, (unsigned int) MTRCommandIDTypeClusterScenesCommandCopySceneID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRScenesClusterCopySceneResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -1429,6 +1588,7 @@ - (void)copySceneWithParams:(MTRScenesClusterCopySceneParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -1704,20 +1864,27 @@ - (void)offWithParams:(MTROnOffClusterOffParams * _Nullable)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeOnOffID, (unsigned int) MTRCommandIDTypeClusterOnOffCommandOffID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -1735,6 +1902,7 @@ - (void)offWithParams:(MTROnOffClusterOffParams * _Nullable)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -1758,20 +1926,27 @@ - (void)onWithParams:(MTROnOffClusterOnParams * _Nullable)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeOnOffID, (unsigned int) MTRCommandIDTypeClusterOnOffCommandOnID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -1789,6 +1964,7 @@ - (void)onWithParams:(MTROnOffClusterOnParams * _Nullable)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -1812,20 +1988,27 @@ - (void)toggleWithParams:(MTROnOffClusterToggleParams * _Nullable)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeOnOffID, (unsigned int) MTRCommandIDTypeClusterOnOffCommandToggleID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -1843,6 +2026,7 @@ - (void)toggleWithParams:(MTROnOffClusterToggleParams * _Nullable)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -1860,20 +2044,27 @@ - (void)offWithEffectWithParams:(MTROnOffClusterOffWithEffectParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeOnOffID, (unsigned int) MTRCommandIDTypeClusterOnOffCommandOffWithEffectID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -1895,6 +2086,7 @@ - (void)offWithEffectWithParams:(MTROnOffClusterOffWithEffectParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -1921,20 +2113,27 @@ - (void)onWithRecallGlobalSceneWithParams:(MTROnOffClusterOnWithRecallGlobalScen expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeOnOffID, + (unsigned int) MTRCommandIDTypeClusterOnOffCommandOnWithRecallGlobalSceneID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -1952,6 +2151,7 @@ - (void)onWithRecallGlobalSceneWithParams:(MTROnOffClusterOnWithRecallGlobalScen std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -1969,20 +2169,27 @@ - (void)onWithTimedOffWithParams:(MTROnOffClusterOnWithTimedOffParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeOnOffID, (unsigned int) MTRCommandIDTypeClusterOnOffCommandOnWithTimedOffID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -2004,6 +2211,7 @@ - (void)onWithTimedOffWithParams:(MTROnOffClusterOnWithTimedOffParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -2383,20 +2591,27 @@ - (void)moveToLevelWithParams:(MTRLevelControlClusterMoveToLevelParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeLevelControlID, + (unsigned int) MTRCommandIDTypeClusterLevelControlCommandMoveToLevelID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -2425,6 +2640,7 @@ - (void)moveToLevelWithParams:(MTRLevelControlClusterMoveToLevelParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -2442,20 +2658,27 @@ - (void)moveWithParams:(MTRLevelControlClusterMoveParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeLevelControlID, (unsigned int) MTRCommandIDTypeClusterLevelControlCommandMoveID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -2485,6 +2708,7 @@ - (void)moveWithParams:(MTRLevelControlClusterMoveParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -2502,20 +2726,27 @@ - (void)stepWithParams:(MTRLevelControlClusterStepParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeLevelControlID, (unsigned int) MTRCommandIDTypeClusterLevelControlCommandStepID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -2546,6 +2777,7 @@ - (void)stepWithParams:(MTRLevelControlClusterStepParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -2563,20 +2795,27 @@ - (void)stopWithParams:(MTRLevelControlClusterStopParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeLevelControlID, (unsigned int) MTRCommandIDTypeClusterLevelControlCommandStopID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -2598,6 +2837,7 @@ - (void)stopWithParams:(MTRLevelControlClusterStopParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -2615,20 +2855,27 @@ - (void)moveToLevelWithOnOffWithParams:(MTRLevelControlClusterMoveToLevelWithOnO expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeLevelControlID, + (unsigned int) MTRCommandIDTypeClusterLevelControlCommandMoveToLevelWithOnOffID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -2657,6 +2904,7 @@ - (void)moveToLevelWithOnOffWithParams:(MTRLevelControlClusterMoveToLevelWithOnO std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -2674,20 +2922,27 @@ - (void)moveWithOnOffWithParams:(MTRLevelControlClusterMoveWithOnOffParams *)par expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeLevelControlID, + (unsigned int) MTRCommandIDTypeClusterLevelControlCommandMoveWithOnOffID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -2717,6 +2972,7 @@ - (void)moveWithOnOffWithParams:(MTRLevelControlClusterMoveWithOnOffParams *)par std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -2734,20 +2990,27 @@ - (void)stepWithOnOffWithParams:(MTRLevelControlClusterStepWithOnOffParams *)par expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeLevelControlID, + (unsigned int) MTRCommandIDTypeClusterLevelControlCommandStepWithOnOffID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -2778,6 +3041,7 @@ - (void)stepWithOnOffWithParams:(MTRLevelControlClusterStepWithOnOffParams *)par std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -2795,20 +3059,27 @@ - (void)stopWithOnOffWithParams:(MTRLevelControlClusterStopWithOnOffParams *)par expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeLevelControlID, + (unsigned int) MTRCommandIDTypeClusterLevelControlCommandStopWithOnOffID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -2830,6 +3101,7 @@ - (void)stopWithOnOffWithParams:(MTRLevelControlClusterStopWithOnOffParams *)par std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -2847,20 +3119,27 @@ - (void)moveToClosestFrequencyWithParams:(MTRLevelControlClusterMoveToClosestFre expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeLevelControlID, + (unsigned int) MTRCommandIDTypeClusterLevelControlCommandMoveToClosestFrequencyID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -2879,6 +3158,7 @@ - (void)moveToClosestFrequencyWithParams:(MTRLevelControlClusterMoveToClosestFre std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -3544,7 +3824,7 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi return self; } -- (NSDictionary *)readAttributeDeviceListWithParams:(MTRReadParams * _Nullable)params +- (NSDictionary *)readAttributeDeviceTypeListWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) clusterID:@(MTRClusterIDTypeDescriptorID) @@ -3625,6 +3905,10 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q return [self initWithDevice:device endpointID:@(endpoint) queue:queue]; } +- (NSDictionary *)readAttributeDeviceListWithParams:(MTRReadParams * _Nullable)params +{ + return [self readAttributeDeviceTypeListWithParams:params]; +} @end @implementation MTRClusterBinding @@ -3735,20 +4019,20 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi return self; } -- (NSDictionary *)readAttributeAclWithParams:(MTRReadParams * _Nullable)params +- (NSDictionary *)readAttributeACLWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) clusterID:@(MTRClusterIDTypeAccessControlID) - attributeID:@(MTRAttributeIDTypeClusterAccessControlAttributeAclID) + attributeID:@(MTRAttributeIDTypeClusterAccessControlAttributeACLID) params:params]; } -- (void)writeAttributeAclWithValue:(NSDictionary *)dataValueDictionary +- (void)writeAttributeACLWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs { - [self writeAttributeAclWithValue:dataValueDictionary expectedValueInterval:expectedValueIntervalMs params:nil]; + [self writeAttributeACLWithValue:dataValueDictionary expectedValueInterval:expectedValueIntervalMs params:nil]; } -- (void)writeAttributeAclWithValue:(NSDictionary *)dataValueDictionary +- (void)writeAttributeACLWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs params:(MTRWriteParams * _Nullable)params { @@ -3756,7 +4040,7 @@ - (void)writeAttributeAclWithValue:(NSDictionary *)dataValueDict [self.device writeAttributeWithEndpointID:@(_endpoint) clusterID:@(MTRClusterIDTypeAccessControlID) - attributeID:@(MTRAttributeIDTypeClusterAccessControlAttributeAclID) + attributeID:@(MTRAttributeIDTypeClusterAccessControlAttributeACLID) value:dataValueDictionary expectedValueInterval:expectedValueIntervalMs timedWriteTimeout:timedWriteTimeout]; @@ -3864,6 +4148,21 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q return [self initWithDevice:device endpointID:@(endpoint) queue:queue]; } +- (NSDictionary *)readAttributeAclWithParams:(MTRReadParams * _Nullable)params +{ + return [self readAttributeACLWithParams:params]; +} +- (void)writeAttributeAclWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs +{ + [self writeAttributeACLWithValue:dataValueDictionary expectedValueInterval:expectedValueIntervalMs]; +} +- (void)writeAttributeAclWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs + params:(MTRWriteParams * _Nullable)params +{ + [self writeAttributeACLWithValue:dataValueDictionary expectedValueInterval:expectedValueIntervalMs params:params]; +} @end @implementation MTRClusterActions @@ -3886,20 +4185,27 @@ - (void)instantActionWithParams:(MTRActionsClusterInstantActionParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeActionsID, (unsigned int) MTRCommandIDTypeClusterActionsCommandInstantActionID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -3922,6 +4228,7 @@ - (void)instantActionWithParams:(MTRActionsClusterInstantActionParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -3939,20 +4246,27 @@ - (void)instantActionWithTransitionWithParams:(MTRActionsClusterInstantActionWit expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeActionsID, + (unsigned int) MTRCommandIDTypeClusterActionsCommandInstantActionWithTransitionID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -3976,6 +4290,7 @@ - (void)instantActionWithTransitionWithParams:(MTRActionsClusterInstantActionWit std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -3993,20 +4308,27 @@ - (void)startActionWithParams:(MTRActionsClusterStartActionParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeActionsID, (unsigned int) MTRCommandIDTypeClusterActionsCommandStartActionID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -4029,6 +4351,7 @@ - (void)startActionWithParams:(MTRActionsClusterStartActionParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -4046,20 +4369,27 @@ - (void)startActionWithDurationWithParams:(MTRActionsClusterStartActionWithDurat expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeActionsID, + (unsigned int) MTRCommandIDTypeClusterActionsCommandStartActionWithDurationID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -4083,6 +4413,7 @@ - (void)startActionWithDurationWithParams:(MTRActionsClusterStartActionWithDurat std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -4100,20 +4431,27 @@ - (void)stopActionWithParams:(MTRActionsClusterStopActionParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeActionsID, (unsigned int) MTRCommandIDTypeClusterActionsCommandStopActionID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -4136,6 +4474,7 @@ - (void)stopActionWithParams:(MTRActionsClusterStopActionParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -4153,20 +4492,27 @@ - (void)pauseActionWithParams:(MTRActionsClusterPauseActionParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeActionsID, (unsigned int) MTRCommandIDTypeClusterActionsCommandPauseActionID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -4189,6 +4535,7 @@ - (void)pauseActionWithParams:(MTRActionsClusterPauseActionParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -4206,20 +4553,27 @@ - (void)pauseActionWithDurationWithParams:(MTRActionsClusterPauseActionWithDurat expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeActionsID, + (unsigned int) MTRCommandIDTypeClusterActionsCommandPauseActionWithDurationID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -4243,6 +4597,7 @@ - (void)pauseActionWithDurationWithParams:(MTRActionsClusterPauseActionWithDurat std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -4260,20 +4615,27 @@ - (void)resumeActionWithParams:(MTRActionsClusterResumeActionParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeActionsID, (unsigned int) MTRCommandIDTypeClusterActionsCommandResumeActionID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -4296,6 +4658,7 @@ - (void)resumeActionWithParams:(MTRActionsClusterResumeActionParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -4313,20 +4676,27 @@ - (void)enableActionWithParams:(MTRActionsClusterEnableActionParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeActionsID, (unsigned int) MTRCommandIDTypeClusterActionsCommandEnableActionID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -4349,6 +4719,7 @@ - (void)enableActionWithParams:(MTRActionsClusterEnableActionParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -4366,20 +4737,27 @@ - (void)enableActionWithDurationWithParams:(MTRActionsClusterEnableActionWithDur expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeActionsID, + (unsigned int) MTRCommandIDTypeClusterActionsCommandEnableActionWithDurationID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -4403,6 +4781,7 @@ - (void)enableActionWithDurationWithParams:(MTRActionsClusterEnableActionWithDur std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -4420,20 +4799,27 @@ - (void)disableActionWithParams:(MTRActionsClusterDisableActionParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeActionsID, (unsigned int) MTRCommandIDTypeClusterActionsCommandDisableActionID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -4456,6 +4842,7 @@ - (void)disableActionWithParams:(MTRActionsClusterDisableActionParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -4473,20 +4860,27 @@ - (void)disableActionWithDurationWithParams:(MTRActionsClusterDisableActionWithD expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeActionsID, + (unsigned int) MTRCommandIDTypeClusterActionsCommandDisableActionWithDurationID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -4510,6 +4904,7 @@ - (void)disableActionWithDurationWithParams:(MTRActionsClusterDisableActionWithD std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -4746,20 +5141,27 @@ - (void)mfgSpecificPingWithParams:(MTRBasicClusterMfgSpecificPingParams * _Nulla expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeBasicID, (unsigned int) MTRCommandIDTypeClusterBasicCommandMfgSpecificPingID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -4777,6 +5179,7 @@ - (void)mfgSpecificPingWithParams:(MTRBasicClusterMfgSpecificPingParams * _Nulla std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -5076,7 +5479,7 @@ - (void)mfgSpecificPingWithExpectedValues:(NSArray } @end -@implementation MTRClusterOtaSoftwareUpdateProvider +@implementation MTRClusterOTASoftwareUpdateProvider - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue { @@ -5091,30 +5494,37 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi return self; } -- (void)queryImageWithParams:(MTROtaSoftwareUpdateProviderClusterQueryImageParams *)params +- (void)queryImageWithParams:(MTROTASoftwareUpdateProviderClusterQueryImageParams *)params expectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs - completion:(void (^)(MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, + completion:(void (^)(MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeOTASoftwareUpdateProviderID, + (unsigned int) MTRCommandIDTypeClusterOTASoftwareUpdateProviderCommandQueryImageID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; - auto * bridge = new MTROtaSoftwareUpdateProviderClusterQueryImageResponseCallbackBridge( - self.callbackQueue, + auto * bridge = new MTROTASoftwareUpdateProviderClusterQueryImageResponseCallbackBridge( + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, - OtaSoftwareUpdateProviderClusterQueryImageResponseCallbackType successCb, MTRErrorCallback failureCb, + OTASoftwareUpdateProviderClusterQueryImageResponseCallbackType successCb, MTRErrorCallback failureCb, MTRCallbackBridgeBase * bridge) { chip::Optional timedInvokeTimeoutMs; ListFreer listFreer; @@ -5172,6 +5582,7 @@ - (void)queryImageWithParams:(MTROtaSoftwareUpdateProviderClusterQueryImageParam std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -5184,30 +5595,37 @@ - (void)queryImageWithParams:(MTROtaSoftwareUpdateProviderClusterQueryImageParam } } -- (void)applyUpdateRequestWithParams:(MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams *)params +- (void)applyUpdateRequestWithParams:(MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams *)params expectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs - completion:(void (^)(MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, + completion:(void (^)(MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeOTASoftwareUpdateProviderID, + (unsigned int) MTRCommandIDTypeClusterOTASoftwareUpdateProviderCommandApplyUpdateRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; - auto * bridge = new MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseCallbackBridge( - self.callbackQueue, + auto * bridge = new MTROTASoftwareUpdateProviderClusterApplyUpdateResponseCallbackBridge( + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, - OtaSoftwareUpdateProviderClusterApplyUpdateResponseCallbackType successCb, MTRErrorCallback failureCb, + OTASoftwareUpdateProviderClusterApplyUpdateResponseCallbackType successCb, MTRErrorCallback failureCb, MTRCallbackBridgeBase * bridge) { chip::Optional timedInvokeTimeoutMs; ListFreer listFreer; @@ -5224,6 +5642,7 @@ - (void)applyUpdateRequestWithParams:(MTROtaSoftwareUpdateProviderClusterApplyUp std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -5236,25 +5655,32 @@ - (void)applyUpdateRequestWithParams:(MTROtaSoftwareUpdateProviderClusterApplyUp } } -- (void)notifyUpdateAppliedWithParams:(MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams *)params +- (void)notifyUpdateAppliedWithParams:(MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams *)params expectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeOTASoftwareUpdateProviderID, + (unsigned int) MTRCommandIDTypeClusterOTASoftwareUpdateProviderCommandNotifyUpdateAppliedID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -5274,6 +5700,7 @@ - (void)notifyUpdateAppliedWithParams:(MTROtaSoftwareUpdateProviderClusterNotify std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -5290,8 +5717,8 @@ - (void)notifyUpdateAppliedWithParams:(MTROtaSoftwareUpdateProviderClusterNotify { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeOtaSoftwareUpdateProviderID) - attributeID:@(MTRAttributeIDTypeClusterOtaSoftwareUpdateProviderAttributeGeneratedCommandListID) + clusterID:@(MTRClusterIDTypeOTASoftwareUpdateProviderID) + attributeID:@(MTRAttributeIDTypeClusterOTASoftwareUpdateProviderAttributeGeneratedCommandListID) params:params]; } @@ -5299,37 +5726,40 @@ - (void)notifyUpdateAppliedWithParams:(MTROtaSoftwareUpdateProviderClusterNotify { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeOtaSoftwareUpdateProviderID) - attributeID:@(MTRAttributeIDTypeClusterOtaSoftwareUpdateProviderAttributeAcceptedCommandListID) + clusterID:@(MTRClusterIDTypeOTASoftwareUpdateProviderID) + attributeID:@(MTRAttributeIDTypeClusterOTASoftwareUpdateProviderAttributeAcceptedCommandListID) params:params]; } - (NSDictionary *)readAttributeAttributeListWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeOtaSoftwareUpdateProviderID) - attributeID:@(MTRAttributeIDTypeClusterOtaSoftwareUpdateProviderAttributeAttributeListID) + clusterID:@(MTRClusterIDTypeOTASoftwareUpdateProviderID) + attributeID:@(MTRAttributeIDTypeClusterOTASoftwareUpdateProviderAttributeAttributeListID) params:params]; } - (NSDictionary *)readAttributeFeatureMapWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeOtaSoftwareUpdateProviderID) - attributeID:@(MTRAttributeIDTypeClusterOtaSoftwareUpdateProviderAttributeFeatureMapID) + clusterID:@(MTRClusterIDTypeOTASoftwareUpdateProviderID) + attributeID:@(MTRAttributeIDTypeClusterOTASoftwareUpdateProviderAttributeFeatureMapID) params:params]; } - (NSDictionary *)readAttributeClusterRevisionWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeOtaSoftwareUpdateProviderID) - attributeID:@(MTRAttributeIDTypeClusterOtaSoftwareUpdateProviderAttributeClusterRevisionID) + clusterID:@(MTRClusterIDTypeOTASoftwareUpdateProviderID) + attributeID:@(MTRAttributeIDTypeClusterOTASoftwareUpdateProviderAttributeClusterRevisionID) params:params]; } @end +@implementation MTRClusterOtaSoftwareUpdateProvider +@end + @implementation MTRClusterOtaSoftwareUpdateProvider (Deprecated) - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint queue:(dispatch_queue_t)queue @@ -5347,7 +5777,7 @@ - (void)queryImageWithParams:(MTROtaSoftwareUpdateProviderClusterQueryImageParam expectedValues:expectedDataValueDictionaries expectedValueInterval:expectedValueIntervalMs completion:^( - MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error) { + MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. completionHandler(static_cast(data), error); }]; @@ -5361,7 +5791,7 @@ - (void)applyUpdateRequestWithParams:(MTROtaSoftwareUpdateProviderClusterApplyUp [self applyUpdateRequestWithParams:params expectedValues:expectedDataValueDictionaries expectedValueInterval:expectedValueIntervalMs - completion:^(MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, + completion:^(MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, NSError * _Nullable error) { // Cast is safe because subclass does not add any selectors. completionHandler( @@ -5380,7 +5810,7 @@ - (void)notifyUpdateAppliedWithParams:(MTROtaSoftwareUpdateProviderClusterNotify } @end -@implementation MTRClusterOtaSoftwareUpdateRequestor +@implementation MTRClusterOTASoftwareUpdateRequestor - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue { @@ -5395,25 +5825,32 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi return self; } -- (void)announceOtaProviderWithParams:(MTROtaSoftwareUpdateRequestorClusterAnnounceOtaProviderParams *)params +- (void)announceOtaProviderWithParams:(MTROTASoftwareUpdateRequestorClusterAnnounceOtaProviderParams *)params expectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeOTASoftwareUpdateRequestorID, + (unsigned int) MTRCommandIDTypeClusterOTASoftwareUpdateRequestorCommandAnnounceOtaProviderID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -5441,6 +5878,7 @@ - (void)announceOtaProviderWithParams:(MTROtaSoftwareUpdateRequestorClusterAnnou std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -5457,8 +5895,8 @@ - (void)announceOtaProviderWithParams:(MTROtaSoftwareUpdateRequestorClusterAnnou { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeOtaSoftwareUpdateRequestorID) - attributeID:@(MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeDefaultOtaProvidersID) + clusterID:@(MTRClusterIDTypeOTASoftwareUpdateRequestorID) + attributeID:@(MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeDefaultOtaProvidersID) params:params]; } @@ -5474,8 +5912,8 @@ - (void)writeAttributeDefaultOtaProvidersWithValue:(NSDictionary NSNumber * timedWriteTimeout = params.timedWriteTimeout; [self.device writeAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeOtaSoftwareUpdateRequestorID) - attributeID:@(MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeDefaultOtaProvidersID) + clusterID:@(MTRClusterIDTypeOTASoftwareUpdateRequestorID) + attributeID:@(MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeDefaultOtaProvidersID) value:dataValueDictionary expectedValueInterval:expectedValueIntervalMs timedWriteTimeout:timedWriteTimeout]; @@ -5484,16 +5922,16 @@ - (void)writeAttributeDefaultOtaProvidersWithValue:(NSDictionary - (NSDictionary *)readAttributeUpdatePossibleWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeOtaSoftwareUpdateRequestorID) - attributeID:@(MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeUpdatePossibleID) + clusterID:@(MTRClusterIDTypeOTASoftwareUpdateRequestorID) + attributeID:@(MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeUpdatePossibleID) params:params]; } - (NSDictionary *)readAttributeUpdateStateWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeOtaSoftwareUpdateRequestorID) - attributeID:@(MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeUpdateStateID) + clusterID:@(MTRClusterIDTypeOTASoftwareUpdateRequestorID) + attributeID:@(MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeUpdateStateID) params:params]; } @@ -5501,8 +5939,8 @@ - (void)writeAttributeDefaultOtaProvidersWithValue:(NSDictionary { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeOtaSoftwareUpdateRequestorID) - attributeID:@(MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeUpdateStateProgressID) + clusterID:@(MTRClusterIDTypeOTASoftwareUpdateRequestorID) + attributeID:@(MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeUpdateStateProgressID) params:params]; } @@ -5510,8 +5948,8 @@ - (void)writeAttributeDefaultOtaProvidersWithValue:(NSDictionary { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeOtaSoftwareUpdateRequestorID) - attributeID:@(MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeGeneratedCommandListID) + clusterID:@(MTRClusterIDTypeOTASoftwareUpdateRequestorID) + attributeID:@(MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeGeneratedCommandListID) params:params]; } @@ -5519,37 +5957,40 @@ - (void)writeAttributeDefaultOtaProvidersWithValue:(NSDictionary { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeOtaSoftwareUpdateRequestorID) - attributeID:@(MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeAcceptedCommandListID) + clusterID:@(MTRClusterIDTypeOTASoftwareUpdateRequestorID) + attributeID:@(MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeAcceptedCommandListID) params:params]; } - (NSDictionary *)readAttributeAttributeListWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeOtaSoftwareUpdateRequestorID) - attributeID:@(MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeAttributeListID) + clusterID:@(MTRClusterIDTypeOTASoftwareUpdateRequestorID) + attributeID:@(MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeAttributeListID) params:params]; } - (NSDictionary *)readAttributeFeatureMapWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeOtaSoftwareUpdateRequestorID) - attributeID:@(MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeFeatureMapID) + clusterID:@(MTRClusterIDTypeOTASoftwareUpdateRequestorID) + attributeID:@(MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeFeatureMapID) params:params]; } - (NSDictionary *)readAttributeClusterRevisionWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeOtaSoftwareUpdateRequestorID) - attributeID:@(MTRAttributeIDTypeClusterOtaSoftwareUpdateRequestorAttributeClusterRevisionID) + clusterID:@(MTRClusterIDTypeOTASoftwareUpdateRequestorID) + attributeID:@(MTRAttributeIDTypeClusterOTASoftwareUpdateRequestorAttributeClusterRevisionID) params:params]; } @end +@implementation MTRClusterOtaSoftwareUpdateRequestor +@end + @implementation MTRClusterOtaSoftwareUpdateRequestor (Deprecated) - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint queue:(dispatch_queue_t)queue @@ -6306,20 +6747,27 @@ - (void)armFailSafeWithParams:(MTRGeneralCommissioningClusterArmFailSafeParams * completion:(void (^)(MTRGeneralCommissioningClusterArmFailSafeResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeGeneralCommissioningID, + (unsigned int) MTRCommandIDTypeClusterGeneralCommissioningCommandArmFailSafeID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRGeneralCommissioningClusterArmFailSafeResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -6340,6 +6788,7 @@ - (void)armFailSafeWithParams:(MTRGeneralCommissioningClusterArmFailSafeParams * std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -6358,20 +6807,27 @@ - (void)setRegulatoryConfigWithParams:(MTRGeneralCommissioningClusterSetRegulato completion:(void (^)(MTRGeneralCommissioningClusterSetRegulatoryConfigResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeGeneralCommissioningID, + (unsigned int) MTRCommandIDTypeClusterGeneralCommissioningCommandSetRegulatoryConfigID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRGeneralCommissioningClusterSetRegulatoryConfigResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -6394,6 +6850,7 @@ - (void)setRegulatoryConfigWithParams:(MTRGeneralCommissioningClusterSetRegulato std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -6425,20 +6882,27 @@ - (void)commissioningCompleteWithParams:(MTRGeneralCommissioningClusterCommissio (void (^)(MTRGeneralCommissioningClusterCommissioningCompleteResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeGeneralCommissioningID, + (unsigned int) MTRCommandIDTypeClusterGeneralCommissioningCommandCommissioningCompleteID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRGeneralCommissioningClusterCommissioningCompleteResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -6457,6 +6921,7 @@ - (void)commissioningCompleteWithParams:(MTRGeneralCommissioningClusterCommissio std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -6662,20 +7127,27 @@ - (void)scanNetworksWithParams:(MTRNetworkCommissioningClusterScanNetworksParams completion:(void (^)(MTRNetworkCommissioningClusterScanNetworksResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeNetworkCommissioningID, + (unsigned int) MTRCommandIDTypeClusterNetworkCommissioningCommandScanNetworksID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRNetworkCommissioningClusterScanNetworksResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -6709,6 +7181,7 @@ - (void)scanNetworksWithParams:(MTRNetworkCommissioningClusterScanNetworksParams std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -6727,20 +7200,27 @@ - (void)addOrUpdateWiFiNetworkWithParams:(MTRNetworkCommissioningClusterAddOrUpd completion:(void (^)(MTRNetworkCommissioningClusterNetworkConfigResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeNetworkCommissioningID, + (unsigned int) MTRCommandIDTypeClusterNetworkCommissioningCommandAddOrUpdateWiFiNetworkID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRNetworkCommissioningClusterNetworkConfigResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -6765,6 +7245,7 @@ - (void)addOrUpdateWiFiNetworkWithParams:(MTRNetworkCommissioningClusterAddOrUpd std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -6783,20 +7264,27 @@ - (void)addOrUpdateThreadNetworkWithParams:(MTRNetworkCommissioningClusterAddOrU completion:(void (^)(MTRNetworkCommissioningClusterNetworkConfigResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeNetworkCommissioningID, + (unsigned int) MTRCommandIDTypeClusterNetworkCommissioningCommandAddOrUpdateThreadNetworkID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRNetworkCommissioningClusterNetworkConfigResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -6820,6 +7308,7 @@ - (void)addOrUpdateThreadNetworkWithParams:(MTRNetworkCommissioningClusterAddOrU std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -6838,20 +7327,27 @@ - (void)removeNetworkWithParams:(MTRNetworkCommissioningClusterRemoveNetworkPara completion:(void (^)(MTRNetworkCommissioningClusterNetworkConfigResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeNetworkCommissioningID, + (unsigned int) MTRCommandIDTypeClusterNetworkCommissioningCommandRemoveNetworkID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRNetworkCommissioningClusterNetworkConfigResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -6875,6 +7371,7 @@ - (void)removeNetworkWithParams:(MTRNetworkCommissioningClusterRemoveNetworkPara std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -6893,20 +7390,27 @@ - (void)connectNetworkWithParams:(MTRNetworkCommissioningClusterConnectNetworkPa completion:(void (^)(MTRNetworkCommissioningClusterConnectNetworkResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeNetworkCommissioningID, + (unsigned int) MTRCommandIDTypeClusterNetworkCommissioningCommandConnectNetworkID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRNetworkCommissioningClusterConnectNetworkResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -6930,6 +7434,7 @@ - (void)connectNetworkWithParams:(MTRNetworkCommissioningClusterConnectNetworkPa std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -6948,20 +7453,27 @@ - (void)reorderNetworkWithParams:(MTRNetworkCommissioningClusterReorderNetworkPa completion:(void (^)(MTRNetworkCommissioningClusterNetworkConfigResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeNetworkCommissioningID, + (unsigned int) MTRCommandIDTypeClusterNetworkCommissioningCommandReorderNetworkID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRNetworkCommissioningClusterNetworkConfigResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -6986,6 +7498,7 @@ - (void)reorderNetworkWithParams:(MTRNetworkCommissioningClusterReorderNetworkPa std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -7247,20 +7760,27 @@ - (void)retrieveLogsRequestWithParams:(MTRDiagnosticLogsClusterRetrieveLogsReque completion:(void (^)(MTRDiagnosticLogsClusterRetrieveLogsResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeDiagnosticLogsID, + (unsigned int) MTRCommandIDTypeClusterDiagnosticLogsCommandRetrieveLogsRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRDiagnosticLogsClusterRetrieveLogsResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -7283,6 +7803,7 @@ - (void)retrieveLogsRequestWithParams:(MTRDiagnosticLogsClusterRetrieveLogsReque std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -7381,20 +7902,27 @@ - (void)testEventTriggerWithParams:(MTRGeneralDiagnosticsClusterTestEventTrigger expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeGeneralDiagnosticsID, + (unsigned int) MTRCommandIDTypeClusterGeneralDiagnosticsCommandTestEventTriggerID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -7414,6 +7942,7 @@ - (void)testEventTriggerWithParams:(MTRGeneralDiagnosticsClusterTestEventTrigger std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -7589,20 +8118,27 @@ - (void)resetWatermarksWithParams:(MTRSoftwareDiagnosticsClusterResetWatermarksP expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeSoftwareDiagnosticsID, + (unsigned int) MTRCommandIDTypeClusterSoftwareDiagnosticsCommandResetWatermarksID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -7620,6 +8156,7 @@ - (void)resetWatermarksWithParams:(MTRSoftwareDiagnosticsClusterResetWatermarksP std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -7764,20 +8301,27 @@ - (void)resetCountsWithParams:(MTRThreadNetworkDiagnosticsClusterResetCountsPara expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeThreadNetworkDiagnosticsID, + (unsigned int) MTRCommandIDTypeClusterThreadNetworkDiagnosticsCommandResetCountsID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -7795,6 +8339,7 @@ - (void)resetCountsWithParams:(MTRThreadNetworkDiagnosticsClusterResetCountsPara std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -8428,20 +8973,27 @@ - (void)resetCountsWithParams:(MTRWiFiNetworkDiagnosticsClusterResetCountsParams expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeWiFiNetworkDiagnosticsID, + (unsigned int) MTRCommandIDTypeClusterWiFiNetworkDiagnosticsCommandResetCountsID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -8459,6 +9011,7 @@ - (void)resetCountsWithParams:(MTRWiFiNetworkDiagnosticsClusterResetCountsParams std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -8679,20 +9232,27 @@ - (void)resetCountsWithParams:(MTREthernetNetworkDiagnosticsClusterResetCountsPa expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeEthernetNetworkDiagnosticsID, + (unsigned int) MTRCommandIDTypeClusterEthernetNetworkDiagnosticsCommandResetCountsID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -8710,6 +9270,7 @@ - (void)resetCountsWithParams:(MTREthernetNetworkDiagnosticsClusterResetCountsPa std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -9181,20 +9742,28 @@ - (void)openCommissioningWindowWithParams:(MTRAdministratorCommissioningClusterO expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeAdministratorCommissioningID, + (unsigned int) MTRCommandIDTypeClusterAdministratorCommissioningCommandOpenCommissioningWindowID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -9220,6 +9789,7 @@ - (void)openCommissioningWindowWithParams:(MTRAdministratorCommissioningClusterO std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -9237,20 +9807,28 @@ - (void)openBasicCommissioningWindowWithParams:(MTRAdministratorCommissioningClu expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeAdministratorCommissioningID, + (unsigned int) MTRCommandIDTypeClusterAdministratorCommissioningCommandOpenBasicCommissioningWindowID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -9272,6 +9850,7 @@ - (void)openBasicCommissioningWindowWithParams:(MTRAdministratorCommissioningClu std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -9298,20 +9877,27 @@ - (void)revokeCommissioningWithParams:(MTRAdministratorCommissioningClusterRevok expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeAdministratorCommissioningID, + (unsigned int) MTRCommandIDTypeClusterAdministratorCommissioningCommandRevokeCommissioningID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -9332,6 +9918,7 @@ - (void)revokeCommissioningWithParams:(MTRAdministratorCommissioningClusterRevok std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -9482,20 +10069,27 @@ - (void)attestationRequestWithParams:(MTROperationalCredentialsClusterAttestatio completion:(void (^)(MTROperationalCredentialsClusterAttestationResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeOperationalCredentialsID, + (unsigned int) MTRCommandIDTypeClusterOperationalCredentialsCommandAttestationRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTROperationalCredentialsClusterAttestationResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -9515,6 +10109,7 @@ - (void)attestationRequestWithParams:(MTROperationalCredentialsClusterAttestatio std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -9533,20 +10128,27 @@ - (void)certificateChainRequestWithParams:(MTROperationalCredentialsClusterCerti completion:(void (^)(MTROperationalCredentialsClusterCertificateChainResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeOperationalCredentialsID, + (unsigned int) MTRCommandIDTypeClusterOperationalCredentialsCommandCertificateChainRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTROperationalCredentialsClusterCertificateChainResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -9566,6 +10168,7 @@ - (void)certificateChainRequestWithParams:(MTROperationalCredentialsClusterCerti std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -9584,20 +10187,27 @@ - (void)CSRRequestWithParams:(MTROperationalCredentialsClusterCSRRequestParams * completion:(void (^)(MTROperationalCredentialsClusterCSRResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeOperationalCredentialsID, + (unsigned int) MTRCommandIDTypeClusterOperationalCredentialsCommandCSRRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTROperationalCredentialsClusterCSRResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -9621,6 +10231,7 @@ - (void)CSRRequestWithParams:(MTROperationalCredentialsClusterCSRRequestParams * std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -9639,20 +10250,27 @@ - (void)addNOCWithParams:(MTROperationalCredentialsClusterAddNOCParams *)params completion:(void (^)(MTROperationalCredentialsClusterNOCResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeOperationalCredentialsID, + (unsigned int) MTRCommandIDTypeClusterOperationalCredentialsCommandAddNOCID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTROperationalCredentialsClusterNOCResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -9680,6 +10298,7 @@ - (void)addNOCWithParams:(MTROperationalCredentialsClusterAddNOCParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -9698,20 +10317,27 @@ - (void)updateNOCWithParams:(MTROperationalCredentialsClusterUpdateNOCParams *)p completion:(void (^)(MTROperationalCredentialsClusterNOCResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeOperationalCredentialsID, + (unsigned int) MTRCommandIDTypeClusterOperationalCredentialsCommandUpdateNOCID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTROperationalCredentialsClusterNOCResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -9735,6 +10361,7 @@ - (void)updateNOCWithParams:(MTROperationalCredentialsClusterUpdateNOCParams *)p std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -9753,20 +10380,27 @@ - (void)updateFabricLabelWithParams:(MTROperationalCredentialsClusterUpdateFabri completion:(void (^)(MTROperationalCredentialsClusterNOCResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeOperationalCredentialsID, + (unsigned int) MTRCommandIDTypeClusterOperationalCredentialsCommandUpdateFabricLabelID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTROperationalCredentialsClusterNOCResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -9786,6 +10420,7 @@ - (void)updateFabricLabelWithParams:(MTROperationalCredentialsClusterUpdateFabri std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -9804,20 +10439,27 @@ - (void)removeFabricWithParams:(MTROperationalCredentialsClusterRemoveFabricPara completion:(void (^)(MTROperationalCredentialsClusterNOCResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeOperationalCredentialsID, + (unsigned int) MTRCommandIDTypeClusterOperationalCredentialsCommandRemoveFabricID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTROperationalCredentialsClusterNOCResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -9837,6 +10479,7 @@ - (void)removeFabricWithParams:(MTROperationalCredentialsClusterRemoveFabricPara std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -9854,20 +10497,28 @@ - (void)addTrustedRootCertificateWithParams:(MTROperationalCredentialsClusterAdd expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeOperationalCredentialsID, + (unsigned int) MTRCommandIDTypeClusterOperationalCredentialsCommandAddTrustedRootCertificateID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -9886,6 +10537,7 @@ - (void)addTrustedRootCertificateWithParams:(MTROperationalCredentialsClusterAdd std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -10133,20 +10785,27 @@ - (void)keySetWriteWithParams:(MTRGroupKeyManagementClusterKeySetWriteParams *)p expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeGroupKeyManagementID, + (unsigned int) MTRCommandIDTypeClusterGroupKeyManagementCommandKeySetWriteID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -10204,6 +10863,7 @@ - (void)keySetWriteWithParams:(MTRGroupKeyManagementClusterKeySetWriteParams *)p std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -10222,20 +10882,27 @@ - (void)keySetReadWithParams:(MTRGroupKeyManagementClusterKeySetReadParams *)par completion:(void (^)(MTRGroupKeyManagementClusterKeySetReadResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeGroupKeyManagementID, + (unsigned int) MTRCommandIDTypeClusterGroupKeyManagementCommandKeySetReadID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRGroupKeyManagementClusterKeySetReadResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -10255,6 +10922,7 @@ - (void)keySetReadWithParams:(MTRGroupKeyManagementClusterKeySetReadParams *)par std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -10272,20 +10940,27 @@ - (void)keySetRemoveWithParams:(MTRGroupKeyManagementClusterKeySetRemoveParams * expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeGroupKeyManagementID, + (unsigned int) MTRCommandIDTypeClusterGroupKeyManagementCommandKeySetRemoveID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -10304,6 +10979,7 @@ - (void)keySetRemoveWithParams:(MTRGroupKeyManagementClusterKeySetRemoveParams * std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -10322,20 +10998,27 @@ - (void)keySetReadAllIndicesWithParams:(MTRGroupKeyManagementClusterKeySetReadAl completion:(void (^)(MTRGroupKeyManagementClusterKeySetReadAllIndicesResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeGroupKeyManagementID, + (unsigned int) MTRCommandIDTypeClusterGroupKeyManagementCommandKeySetReadAllIndicesID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRGroupKeyManagementClusterKeySetReadAllIndicesResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -10376,6 +11059,7 @@ - (void)keySetReadAllIndicesWithParams:(MTRGroupKeyManagementClusterKeySetReadAl std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -10801,20 +11485,27 @@ - (void)changeToModeWithParams:(MTRModeSelectClusterChangeToModeParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeModeSelectID, + (unsigned int) MTRCommandIDTypeClusterModeSelectCommandChangeToModeID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -10833,6 +11524,7 @@ - (void)changeToModeWithParams:(MTRModeSelectClusterChangeToModeParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11012,20 +11704,27 @@ - (void)lockDoorWithParams:(MTRDoorLockClusterLockDoorParams * _Nullable)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeDoorLockID, (unsigned int) MTRCommandIDTypeClusterDoorLockCommandLockDoorID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -11052,6 +11751,7 @@ - (void)lockDoorWithParams:(MTRDoorLockClusterLockDoorParams * _Nullable)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11069,20 +11769,27 @@ - (void)unlockDoorWithParams:(MTRDoorLockClusterUnlockDoorParams * _Nullable)par expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeDoorLockID, (unsigned int) MTRCommandIDTypeClusterDoorLockCommandUnlockDoorID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -11109,6 +11816,7 @@ - (void)unlockDoorWithParams:(MTRDoorLockClusterUnlockDoorParams * _Nullable)par std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11126,20 +11834,27 @@ - (void)unlockWithTimeoutWithParams:(MTRDoorLockClusterUnlockWithTimeoutParams * expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeDoorLockID, + (unsigned int) MTRCommandIDTypeClusterDoorLockCommandUnlockWithTimeoutID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -11165,6 +11880,7 @@ - (void)unlockWithTimeoutWithParams:(MTRDoorLockClusterUnlockWithTimeoutParams * std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11182,20 +11898,27 @@ - (void)setWeekDayScheduleWithParams:(MTRDoorLockClusterSetWeekDayScheduleParams expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeDoorLockID, + (unsigned int) MTRCommandIDTypeClusterDoorLockCommandSetWeekDayScheduleID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -11221,6 +11944,7 @@ - (void)setWeekDayScheduleWithParams:(MTRDoorLockClusterSetWeekDayScheduleParams std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11239,20 +11963,27 @@ - (void)getWeekDayScheduleWithParams:(MTRDoorLockClusterGetWeekDayScheduleParams completion:(void (^)(MTRDoorLockClusterGetWeekDayScheduleResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeDoorLockID, + (unsigned int) MTRCommandIDTypeClusterDoorLockCommandGetWeekDayScheduleID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRDoorLockClusterGetWeekDayScheduleResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -11273,6 +12004,7 @@ - (void)getWeekDayScheduleWithParams:(MTRDoorLockClusterGetWeekDayScheduleParams std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11290,20 +12022,27 @@ - (void)clearWeekDayScheduleWithParams:(MTRDoorLockClusterClearWeekDaySchedulePa expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeDoorLockID, + (unsigned int) MTRCommandIDTypeClusterDoorLockCommandClearWeekDayScheduleID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -11323,6 +12062,7 @@ - (void)clearWeekDayScheduleWithParams:(MTRDoorLockClusterClearWeekDaySchedulePa std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11340,20 +12080,27 @@ - (void)setYearDayScheduleWithParams:(MTRDoorLockClusterSetYearDayScheduleParams expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeDoorLockID, + (unsigned int) MTRCommandIDTypeClusterDoorLockCommandSetYearDayScheduleID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -11375,6 +12122,7 @@ - (void)setYearDayScheduleWithParams:(MTRDoorLockClusterSetYearDayScheduleParams std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11393,20 +12141,27 @@ - (void)getYearDayScheduleWithParams:(MTRDoorLockClusterGetYearDayScheduleParams completion:(void (^)(MTRDoorLockClusterGetYearDayScheduleResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeDoorLockID, + (unsigned int) MTRCommandIDTypeClusterDoorLockCommandGetYearDayScheduleID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRDoorLockClusterGetYearDayScheduleResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -11427,6 +12182,7 @@ - (void)getYearDayScheduleWithParams:(MTRDoorLockClusterGetYearDayScheduleParams std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11444,20 +12200,27 @@ - (void)clearYearDayScheduleWithParams:(MTRDoorLockClusterClearYearDaySchedulePa expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeDoorLockID, + (unsigned int) MTRCommandIDTypeClusterDoorLockCommandClearYearDayScheduleID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -11477,6 +12240,7 @@ - (void)clearYearDayScheduleWithParams:(MTRDoorLockClusterClearYearDaySchedulePa std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11494,20 +12258,27 @@ - (void)setHolidayScheduleWithParams:(MTRDoorLockClusterSetHolidayScheduleParams expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeDoorLockID, + (unsigned int) MTRCommandIDTypeClusterDoorLockCommandSetHolidayScheduleID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -11530,6 +12301,7 @@ - (void)setHolidayScheduleWithParams:(MTRDoorLockClusterSetHolidayScheduleParams std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11548,20 +12320,27 @@ - (void)getHolidayScheduleWithParams:(MTRDoorLockClusterGetHolidayScheduleParams completion:(void (^)(MTRDoorLockClusterGetHolidayScheduleResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeDoorLockID, + (unsigned int) MTRCommandIDTypeClusterDoorLockCommandGetHolidayScheduleID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRDoorLockClusterGetHolidayScheduleResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -11581,6 +12360,7 @@ - (void)getHolidayScheduleWithParams:(MTRDoorLockClusterGetHolidayScheduleParams std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11598,20 +12378,27 @@ - (void)clearHolidayScheduleWithParams:(MTRDoorLockClusterClearHolidaySchedulePa expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeDoorLockID, + (unsigned int) MTRCommandIDTypeClusterDoorLockCommandClearHolidayScheduleID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -11630,6 +12417,7 @@ - (void)clearHolidayScheduleWithParams:(MTRDoorLockClusterClearHolidaySchedulePa std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11647,20 +12435,27 @@ - (void)setUserWithParams:(MTRDoorLockClusterSetUserParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeDoorLockID, (unsigned int) MTRCommandIDTypeClusterDoorLockCommandSetUserID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -11717,6 +12512,7 @@ - (void)setUserWithParams:(MTRDoorLockClusterSetUserParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11734,20 +12530,27 @@ - (void)getUserWithParams:(MTRDoorLockClusterGetUserParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(void (^)(MTRDoorLockClusterGetUserResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeDoorLockID, (unsigned int) MTRCommandIDTypeClusterDoorLockCommandGetUserID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRDoorLockClusterGetUserResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -11766,6 +12569,7 @@ - (void)getUserWithParams:(MTRDoorLockClusterGetUserParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11783,20 +12587,27 @@ - (void)clearUserWithParams:(MTRDoorLockClusterClearUserParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeDoorLockID, (unsigned int) MTRCommandIDTypeClusterDoorLockCommandClearUserID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -11818,6 +12629,7 @@ - (void)clearUserWithParams:(MTRDoorLockClusterClearUserParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11836,20 +12648,27 @@ - (void)setCredentialWithParams:(MTRDoorLockClusterSetCredentialParams *)params completion:(void (^)(MTRDoorLockClusterSetCredentialResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeDoorLockID, (unsigned int) MTRCommandIDTypeClusterDoorLockCommandSetCredentialID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRDoorLockClusterSetCredentialResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -11898,6 +12717,7 @@ - (void)setCredentialWithParams:(MTRDoorLockClusterSetCredentialParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11916,20 +12736,27 @@ - (void)getCredentialStatusWithParams:(MTRDoorLockClusterGetCredentialStatusPara completion:(void (^)(MTRDoorLockClusterGetCredentialStatusResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeDoorLockID, + (unsigned int) MTRCommandIDTypeClusterDoorLockCommandGetCredentialStatusID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRDoorLockClusterGetCredentialStatusResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -11952,6 +12779,7 @@ - (void)getCredentialStatusWithParams:(MTRDoorLockClusterGetCredentialStatusPara std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -11969,20 +12797,27 @@ - (void)clearCredentialWithParams:(MTRDoorLockClusterClearCredentialParams *)par expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeDoorLockID, + (unsigned int) MTRCommandIDTypeClusterDoorLockCommandClearCredentialID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -12011,6 +12846,7 @@ - (void)clearCredentialWithParams:(MTRDoorLockClusterClearCredentialParams *)par std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -12955,20 +13791,27 @@ - (void)upOrOpenWithParams:(MTRWindowCoveringClusterUpOrOpenParams * _Nullable)p expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeWindowCoveringID, + (unsigned int) MTRCommandIDTypeClusterWindowCoveringCommandUpOrOpenID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -12986,6 +13829,7 @@ - (void)upOrOpenWithParams:(MTRWindowCoveringClusterUpOrOpenParams * _Nullable)p std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -13012,20 +13856,27 @@ - (void)downOrCloseWithParams:(MTRWindowCoveringClusterDownOrCloseParams * _Null expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeWindowCoveringID, + (unsigned int) MTRCommandIDTypeClusterWindowCoveringCommandDownOrCloseID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -13043,6 +13894,7 @@ - (void)downOrCloseWithParams:(MTRWindowCoveringClusterDownOrCloseParams * _Null std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -13069,20 +13921,27 @@ - (void)stopMotionWithParams:(MTRWindowCoveringClusterStopMotionParams * _Nullab expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeWindowCoveringID, + (unsigned int) MTRCommandIDTypeClusterWindowCoveringCommandStopMotionID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -13100,6 +13959,7 @@ - (void)stopMotionWithParams:(MTRWindowCoveringClusterStopMotionParams * _Nullab std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -13117,20 +13977,27 @@ - (void)goToLiftValueWithParams:(MTRWindowCoveringClusterGoToLiftValueParams *)p expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeWindowCoveringID, + (unsigned int) MTRCommandIDTypeClusterWindowCoveringCommandGoToLiftValueID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -13149,6 +14016,7 @@ - (void)goToLiftValueWithParams:(MTRWindowCoveringClusterGoToLiftValueParams *)p std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -13166,20 +14034,27 @@ - (void)goToLiftPercentageWithParams:(MTRWindowCoveringClusterGoToLiftPercentage expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeWindowCoveringID, + (unsigned int) MTRCommandIDTypeClusterWindowCoveringCommandGoToLiftPercentageID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -13198,6 +14073,7 @@ - (void)goToLiftPercentageWithParams:(MTRWindowCoveringClusterGoToLiftPercentage std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -13215,20 +14091,27 @@ - (void)goToTiltValueWithParams:(MTRWindowCoveringClusterGoToTiltValueParams *)p expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeWindowCoveringID, + (unsigned int) MTRCommandIDTypeClusterWindowCoveringCommandGoToTiltValueID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -13247,6 +14130,7 @@ - (void)goToTiltValueWithParams:(MTRWindowCoveringClusterGoToTiltValueParams *)p std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -13264,20 +14148,27 @@ - (void)goToTiltPercentageWithParams:(MTRWindowCoveringClusterGoToTiltPercentage expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeWindowCoveringID, + (unsigned int) MTRCommandIDTypeClusterWindowCoveringCommandGoToTiltPercentageID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -13296,6 +14187,7 @@ - (void)goToTiltPercentageWithParams:(MTRWindowCoveringClusterGoToTiltPercentage std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -13677,20 +14569,27 @@ - (void)barrierControlGoToPercentWithParams:(MTRBarrierControlClusterBarrierCont expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeBarrierControlID, + (unsigned int) MTRCommandIDTypeClusterBarrierControlCommandBarrierControlGoToPercentID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -13709,6 +14608,7 @@ - (void)barrierControlGoToPercentWithParams:(MTRBarrierControlClusterBarrierCont std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -13735,20 +14635,27 @@ - (void)barrierControlStopWithParams:(MTRBarrierControlClusterBarrierControlStop expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeBarrierControlID, + (unsigned int) MTRCommandIDTypeClusterBarrierControlCommandBarrierControlStopID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -13766,6 +14673,7 @@ - (void)barrierControlStopWithParams:(MTRBarrierControlClusterBarrierControlStop std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -14416,20 +15324,27 @@ - (void)setpointRaiseLowerWithParams:(MTRThermostatClusterSetpointRaiseLowerPara expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeThermostatID, + (unsigned int) MTRCommandIDTypeClusterThermostatCommandSetpointRaiseLowerID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -14449,6 +15364,7 @@ - (void)setpointRaiseLowerWithParams:(MTRThermostatClusterSetpointRaiseLowerPara std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -14466,20 +15382,27 @@ - (void)setWeeklyScheduleWithParams:(MTRThermostatClusterSetWeeklyScheduleParams expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeThermostatID, + (unsigned int) MTRCommandIDTypeClusterThermostatCommandSetWeeklyScheduleID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -14536,6 +15459,7 @@ - (void)setWeeklyScheduleWithParams:(MTRThermostatClusterSetWeeklyScheduleParams std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -14554,20 +15478,27 @@ - (void)getWeeklyScheduleWithParams:(MTRThermostatClusterGetWeeklyScheduleParams completion:(void (^)(MTRThermostatClusterGetWeeklyScheduleResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeThermostatID, + (unsigned int) MTRCommandIDTypeClusterThermostatCommandGetWeeklyScheduleID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRThermostatClusterGetWeeklyScheduleResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -14590,6 +15521,7 @@ - (void)getWeeklyScheduleWithParams:(MTRThermostatClusterGetWeeklyScheduleParams std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -14616,20 +15548,27 @@ - (void)clearWeeklyScheduleWithParams:(MTRThermostatClusterClearWeeklySchedulePa expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeThermostatID, + (unsigned int) MTRCommandIDTypeClusterThermostatCommandClearWeeklyScheduleID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -14647,6 +15586,7 @@ - (void)clearWeeklyScheduleWithParams:(MTRThermostatClusterClearWeeklySchedulePa std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16144,20 +17084,27 @@ - (void)moveToHueWithParams:(MTRColorControlClusterMoveToHueParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandMoveToHueID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16181,6 +17128,7 @@ - (void)moveToHueWithParams:(MTRColorControlClusterMoveToHueParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16198,20 +17146,27 @@ - (void)moveHueWithParams:(MTRColorControlClusterMoveHueParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandMoveHueID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16234,6 +17189,7 @@ - (void)moveHueWithParams:(MTRColorControlClusterMoveHueParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16251,20 +17207,27 @@ - (void)stepHueWithParams:(MTRColorControlClusterStepHueParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandStepHueID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16288,6 +17251,7 @@ - (void)stepHueWithParams:(MTRColorControlClusterStepHueParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16305,20 +17269,27 @@ - (void)moveToSaturationWithParams:(MTRColorControlClusterMoveToSaturationParams expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandMoveToSaturationID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16340,6 +17311,7 @@ - (void)moveToSaturationWithParams:(MTRColorControlClusterMoveToSaturationParams std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16357,20 +17329,27 @@ - (void)moveSaturationWithParams:(MTRColorControlClusterMoveSaturationParams *)p expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandMoveSaturationID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16393,6 +17372,7 @@ - (void)moveSaturationWithParams:(MTRColorControlClusterMoveSaturationParams *)p std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16410,20 +17390,27 @@ - (void)stepSaturationWithParams:(MTRColorControlClusterStepSaturationParams *)p expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandStepSaturationID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16447,6 +17434,7 @@ - (void)stepSaturationWithParams:(MTRColorControlClusterStepSaturationParams *)p std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16464,20 +17452,27 @@ - (void)moveToHueAndSaturationWithParams:(MTRColorControlClusterMoveToHueAndSatu expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandMoveToHueAndSaturationID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16500,6 +17495,7 @@ - (void)moveToHueAndSaturationWithParams:(MTRColorControlClusterMoveToHueAndSatu std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16517,20 +17513,27 @@ - (void)moveToColorWithParams:(MTRColorControlClusterMoveToColorParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandMoveToColorID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16553,6 +17556,7 @@ - (void)moveToColorWithParams:(MTRColorControlClusterMoveToColorParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16570,20 +17574,27 @@ - (void)moveColorWithParams:(MTRColorControlClusterMoveColorParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandMoveColorID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16605,6 +17616,7 @@ - (void)moveColorWithParams:(MTRColorControlClusterMoveColorParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16622,20 +17634,27 @@ - (void)stepColorWithParams:(MTRColorControlClusterStepColorParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandStepColorID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16658,6 +17677,7 @@ - (void)stepColorWithParams:(MTRColorControlClusterStepColorParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16675,20 +17695,27 @@ - (void)moveToColorTemperatureWithParams:(MTRColorControlClusterMoveToColorTempe expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandMoveToColorTemperatureID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16710,6 +17737,7 @@ - (void)moveToColorTemperatureWithParams:(MTRColorControlClusterMoveToColorTempe std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16727,20 +17755,27 @@ - (void)enhancedMoveToHueWithParams:(MTRColorControlClusterEnhancedMoveToHuePara expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandEnhancedMoveToHueID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16764,6 +17799,7 @@ - (void)enhancedMoveToHueWithParams:(MTRColorControlClusterEnhancedMoveToHuePara std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16781,20 +17817,27 @@ - (void)enhancedMoveHueWithParams:(MTRColorControlClusterEnhancedMoveHueParams * expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandEnhancedMoveHueID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16817,6 +17860,7 @@ - (void)enhancedMoveHueWithParams:(MTRColorControlClusterEnhancedMoveHueParams * std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16834,20 +17878,27 @@ - (void)enhancedStepHueWithParams:(MTRColorControlClusterEnhancedStepHueParams * expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandEnhancedStepHueID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16871,6 +17922,7 @@ - (void)enhancedStepHueWithParams:(MTRColorControlClusterEnhancedStepHueParams * std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16888,20 +17940,27 @@ - (void)enhancedMoveToHueAndSaturationWithParams:(MTRColorControlClusterEnhanced expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandEnhancedMoveToHueAndSaturationID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16924,6 +17983,7 @@ - (void)enhancedMoveToHueAndSaturationWithParams:(MTRColorControlClusterEnhanced std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16941,20 +18001,27 @@ - (void)colorLoopSetWithParams:(MTRColorControlClusterColorLoopSetParams *)param expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandColorLoopSetID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -16981,6 +18048,7 @@ - (void)colorLoopSetWithParams:(MTRColorControlClusterColorLoopSetParams *)param std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -16998,20 +18066,27 @@ - (void)stopMoveStepWithParams:(MTRColorControlClusterStopMoveStepParams *)param expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandStopMoveStepID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -17031,6 +18106,7 @@ - (void)stopMoveStepWithParams:(MTRColorControlClusterStopMoveStepParams *)param std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -17048,20 +18124,27 @@ - (void)moveColorTemperatureWithParams:(MTRColorControlClusterMoveColorTemperatu expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandMoveColorTemperatureID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -17086,6 +18169,7 @@ - (void)moveColorTemperatureWithParams:(MTRColorControlClusterMoveColorTemperatu std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -17103,20 +18187,27 @@ - (void)stepColorTemperatureWithParams:(MTRColorControlClusterStepColorTemperatu expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeColorControlID, + (unsigned int) MTRCommandIDTypeClusterColorControlCommandStepColorTemperatureID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -17142,6 +18233,7 @@ - (void)stepColorTemperatureWithParams:(MTRColorControlClusterStepColorTemperatu std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -19022,23 +20114,23 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi params:params]; } -- (NSDictionary *)readAttributePirOccupiedToUnoccupiedDelayWithParams:(MTRReadParams * _Nullable)params +- (NSDictionary *)readAttributePIROccupiedToUnoccupiedDelayWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) clusterID:@(MTRClusterIDTypeOccupancySensingID) - attributeID:@(MTRAttributeIDTypeClusterOccupancySensingAttributePirOccupiedToUnoccupiedDelayID) + attributeID:@(MTRAttributeIDTypeClusterOccupancySensingAttributePIROccupiedToUnoccupiedDelayID) params:params]; } -- (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSDictionary *)dataValueDictionary +- (void)writeAttributePIROccupiedToUnoccupiedDelayWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs { - [self writeAttributePirOccupiedToUnoccupiedDelayWithValue:dataValueDictionary + [self writeAttributePIROccupiedToUnoccupiedDelayWithValue:dataValueDictionary expectedValueInterval:expectedValueIntervalMs params:nil]; } -- (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSDictionary *)dataValueDictionary +- (void)writeAttributePIROccupiedToUnoccupiedDelayWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs params:(MTRWriteParams * _Nullable)params { @@ -19046,29 +20138,29 @@ - (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSDictionary *)readAttributePirUnoccupiedToOccupiedDelayWithParams:(MTRReadParams * _Nullable)params +- (NSDictionary *)readAttributePIRUnoccupiedToOccupiedDelayWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) clusterID:@(MTRClusterIDTypeOccupancySensingID) - attributeID:@(MTRAttributeIDTypeClusterOccupancySensingAttributePirUnoccupiedToOccupiedDelayID) + attributeID:@(MTRAttributeIDTypeClusterOccupancySensingAttributePIRUnoccupiedToOccupiedDelayID) params:params]; } -- (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSDictionary *)dataValueDictionary +- (void)writeAttributePIRUnoccupiedToOccupiedDelayWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs { - [self writeAttributePirUnoccupiedToOccupiedDelayWithValue:dataValueDictionary + [self writeAttributePIRUnoccupiedToOccupiedDelayWithValue:dataValueDictionary expectedValueInterval:expectedValueIntervalMs params:nil]; } -- (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSDictionary *)dataValueDictionary +- (void)writeAttributePIRUnoccupiedToOccupiedDelayWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs params:(MTRWriteParams * _Nullable)params { @@ -19076,29 +20168,29 @@ - (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSDictionary *)readAttributePirUnoccupiedToOccupiedThresholdWithParams:(MTRReadParams * _Nullable)params +- (NSDictionary *)readAttributePIRUnoccupiedToOccupiedThresholdWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) clusterID:@(MTRClusterIDTypeOccupancySensingID) - attributeID:@(MTRAttributeIDTypeClusterOccupancySensingAttributePirUnoccupiedToOccupiedThresholdID) + attributeID:@(MTRAttributeIDTypeClusterOccupancySensingAttributePIRUnoccupiedToOccupiedThresholdID) params:params]; } -- (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSDictionary *)dataValueDictionary +- (void)writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs { - [self writeAttributePirUnoccupiedToOccupiedThresholdWithValue:dataValueDictionary + [self writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:dataValueDictionary expectedValueInterval:expectedValueIntervalMs params:nil]; } -- (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSDictionary *)dataValueDictionary +- (void)writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs params:(MTRWriteParams * _Nullable)params { @@ -19107,7 +20199,7 @@ - (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSDictionary *)readAttributePirOccupiedToUnoccupiedDelayWithParams:(MTRReadParams * _Nullable)params +{ + return [self readAttributePIROccupiedToUnoccupiedDelayWithParams:params]; +} +- (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs +{ + [self writeAttributePIROccupiedToUnoccupiedDelayWithValue:dataValueDictionary expectedValueInterval:expectedValueIntervalMs]; +} +- (void)writeAttributePirOccupiedToUnoccupiedDelayWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs + params:(MTRWriteParams * _Nullable)params +{ + [self writeAttributePIROccupiedToUnoccupiedDelayWithValue:dataValueDictionary + expectedValueInterval:expectedValueIntervalMs + params:params]; +} +- (NSDictionary *)readAttributePirUnoccupiedToOccupiedDelayWithParams:(MTRReadParams * _Nullable)params +{ + return [self readAttributePIRUnoccupiedToOccupiedDelayWithParams:params]; +} +- (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs +{ + [self writeAttributePIRUnoccupiedToOccupiedDelayWithValue:dataValueDictionary expectedValueInterval:expectedValueIntervalMs]; +} +- (void)writeAttributePirUnoccupiedToOccupiedDelayWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs + params:(MTRWriteParams * _Nullable)params +{ + [self writeAttributePIRUnoccupiedToOccupiedDelayWithValue:dataValueDictionary + expectedValueInterval:expectedValueIntervalMs + params:params]; +} +- (NSDictionary *)readAttributePirUnoccupiedToOccupiedThresholdWithParams:(MTRReadParams * _Nullable)params +{ + return [self readAttributePIRUnoccupiedToOccupiedThresholdWithParams:params]; +} +- (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs +{ + [self writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:dataValueDictionary + expectedValueInterval:expectedValueIntervalMs]; +} +- (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSDictionary *)dataValueDictionary + expectedValueInterval:(NSNumber *)expectedValueIntervalMs + params:(MTRWriteParams * _Nullable)params +{ + [self writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:dataValueDictionary + expectedValueInterval:expectedValueIntervalMs + params:params]; +} @end -@implementation MTRClusterWakeOnLan +@implementation MTRClusterWakeOnLAN - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue { @@ -19371,53 +20515,56 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi - (NSDictionary *)readAttributeMACAddressWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeWakeOnLanID) - attributeID:@(MTRAttributeIDTypeClusterWakeOnLanAttributeMACAddressID) + clusterID:@(MTRClusterIDTypeWakeOnLANID) + attributeID:@(MTRAttributeIDTypeClusterWakeOnLANAttributeMACAddressID) params:params]; } - (NSDictionary *)readAttributeGeneratedCommandListWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeWakeOnLanID) - attributeID:@(MTRAttributeIDTypeClusterWakeOnLanAttributeGeneratedCommandListID) + clusterID:@(MTRClusterIDTypeWakeOnLANID) + attributeID:@(MTRAttributeIDTypeClusterWakeOnLANAttributeGeneratedCommandListID) params:params]; } - (NSDictionary *)readAttributeAcceptedCommandListWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeWakeOnLanID) - attributeID:@(MTRAttributeIDTypeClusterWakeOnLanAttributeAcceptedCommandListID) + clusterID:@(MTRClusterIDTypeWakeOnLANID) + attributeID:@(MTRAttributeIDTypeClusterWakeOnLANAttributeAcceptedCommandListID) params:params]; } - (NSDictionary *)readAttributeAttributeListWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeWakeOnLanID) - attributeID:@(MTRAttributeIDTypeClusterWakeOnLanAttributeAttributeListID) + clusterID:@(MTRClusterIDTypeWakeOnLANID) + attributeID:@(MTRAttributeIDTypeClusterWakeOnLANAttributeAttributeListID) params:params]; } - (NSDictionary *)readAttributeFeatureMapWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeWakeOnLanID) - attributeID:@(MTRAttributeIDTypeClusterWakeOnLanAttributeFeatureMapID) + clusterID:@(MTRClusterIDTypeWakeOnLANID) + attributeID:@(MTRAttributeIDTypeClusterWakeOnLANAttributeFeatureMapID) params:params]; } - (NSDictionary *)readAttributeClusterRevisionWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(_endpoint) - clusterID:@(MTRClusterIDTypeWakeOnLanID) - attributeID:@(MTRAttributeIDTypeClusterWakeOnLanAttributeClusterRevisionID) + clusterID:@(MTRClusterIDTypeWakeOnLANID) + attributeID:@(MTRAttributeIDTypeClusterWakeOnLANAttributeClusterRevisionID) params:params]; } @end +@implementation MTRClusterWakeOnLan +@end + @implementation MTRClusterWakeOnLan (Deprecated) - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint queue:(dispatch_queue_t)queue @@ -19448,20 +20595,27 @@ - (void)changeChannelWithParams:(MTRChannelClusterChangeChannelParams *)params completion:(void (^)(MTRChannelClusterChangeChannelResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeChannelID, (unsigned int) MTRCommandIDTypeClusterChannelCommandChangeChannelID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRChannelClusterChangeChannelResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -19481,6 +20635,7 @@ - (void)changeChannelWithParams:(MTRChannelClusterChangeChannelParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -19498,20 +20653,27 @@ - (void)changeChannelByNumberWithParams:(MTRChannelClusterChangeChannelByNumberP expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeChannelID, + (unsigned int) MTRCommandIDTypeClusterChannelCommandChangeChannelByNumberID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -19531,6 +20693,7 @@ - (void)changeChannelByNumberWithParams:(MTRChannelClusterChangeChannelByNumberP std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -19548,20 +20711,27 @@ - (void)skipChannelWithParams:(MTRChannelClusterSkipChannelParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeChannelID, (unsigned int) MTRCommandIDTypeClusterChannelCommandSkipChannelID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -19580,6 +20750,7 @@ - (void)skipChannelWithParams:(MTRChannelClusterSkipChannelParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -19722,20 +20893,27 @@ - (void)navigateTargetWithParams:(MTRTargetNavigatorClusterNavigateTargetParams completion:(void (^)(MTRTargetNavigatorClusterNavigateTargetResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeTargetNavigatorID, + (unsigned int) MTRCommandIDTypeClusterTargetNavigatorCommandNavigateTargetID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRTargetNavigatorClusterNavigateTargetResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -19759,6 +20937,7 @@ - (void)navigateTargetWithParams:(MTRTargetNavigatorClusterNavigateTargetParams std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -19881,20 +21060,27 @@ - (void)playWithParams:(MTRMediaPlaybackClusterPlayParams * _Nullable)params completion: (void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeMediaPlaybackID, (unsigned int) MTRCommandIDTypeClusterMediaPlaybackCommandPlayID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRMediaPlaybackClusterPlaybackResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -19913,6 +21099,7 @@ - (void)playWithParams:(MTRMediaPlaybackClusterPlayParams * _Nullable)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -19938,20 +21125,27 @@ - (void)pauseWithParams:(MTRMediaPlaybackClusterPauseParams * _Nullable)params completion: (void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeMediaPlaybackID, + (unsigned int) MTRCommandIDTypeClusterMediaPlaybackCommandPauseID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRMediaPlaybackClusterPlaybackResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -19970,6 +21164,7 @@ - (void)pauseWithParams:(MTRMediaPlaybackClusterPauseParams * _Nullable)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -19998,20 +21193,27 @@ - (void)stopPlaybackWithParams:(MTRMediaPlaybackClusterStopPlaybackParams * _Nul completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeMediaPlaybackID, + (unsigned int) MTRCommandIDTypeClusterMediaPlaybackCommandStopPlaybackID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRMediaPlaybackClusterPlaybackResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -20030,6 +21232,7 @@ - (void)stopPlaybackWithParams:(MTRMediaPlaybackClusterStopPlaybackParams * _Nul std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -20058,20 +21261,27 @@ - (void)startOverWithParams:(MTRMediaPlaybackClusterStartOverParams * _Nullable) completion: (void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeMediaPlaybackID, + (unsigned int) MTRCommandIDTypeClusterMediaPlaybackCommandStartOverID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRMediaPlaybackClusterPlaybackResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -20090,6 +21300,7 @@ - (void)startOverWithParams:(MTRMediaPlaybackClusterStartOverParams * _Nullable) std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -20115,20 +21326,27 @@ - (void)previousWithParams:(MTRMediaPlaybackClusterPreviousParams * _Nullable)pa completion: (void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeMediaPlaybackID, + (unsigned int) MTRCommandIDTypeClusterMediaPlaybackCommandPreviousID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRMediaPlaybackClusterPlaybackResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -20147,6 +21365,7 @@ - (void)previousWithParams:(MTRMediaPlaybackClusterPreviousParams * _Nullable)pa std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -20172,20 +21391,27 @@ - (void)nextWithParams:(MTRMediaPlaybackClusterNextParams * _Nullable)params completion: (void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeMediaPlaybackID, (unsigned int) MTRCommandIDTypeClusterMediaPlaybackCommandNextID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRMediaPlaybackClusterPlaybackResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -20204,6 +21430,7 @@ - (void)nextWithParams:(MTRMediaPlaybackClusterNextParams * _Nullable)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -20229,20 +21456,27 @@ - (void)rewindWithParams:(MTRMediaPlaybackClusterRewindParams * _Nullable)params completion: (void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeMediaPlaybackID, + (unsigned int) MTRCommandIDTypeClusterMediaPlaybackCommandRewindID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRMediaPlaybackClusterPlaybackResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -20261,6 +21495,7 @@ - (void)rewindWithParams:(MTRMediaPlaybackClusterRewindParams * _Nullable)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -20289,20 +21524,27 @@ - (void)fastForwardWithParams:(MTRMediaPlaybackClusterFastForwardParams * _Nulla completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeMediaPlaybackID, + (unsigned int) MTRCommandIDTypeClusterMediaPlaybackCommandFastForwardID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRMediaPlaybackClusterPlaybackResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -20321,6 +21563,7 @@ - (void)fastForwardWithParams:(MTRMediaPlaybackClusterFastForwardParams * _Nulla std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -20339,20 +21582,27 @@ - (void)skipForwardWithParams:(MTRMediaPlaybackClusterSkipForwardParams *)params completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeMediaPlaybackID, + (unsigned int) MTRCommandIDTypeClusterMediaPlaybackCommandSkipForwardID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRMediaPlaybackClusterPlaybackResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -20372,6 +21622,7 @@ - (void)skipForwardWithParams:(MTRMediaPlaybackClusterSkipForwardParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -20390,20 +21641,27 @@ - (void)skipBackwardWithParams:(MTRMediaPlaybackClusterSkipBackwardParams *)para completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeMediaPlaybackID, + (unsigned int) MTRCommandIDTypeClusterMediaPlaybackCommandSkipBackwardID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRMediaPlaybackClusterPlaybackResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -20423,6 +21681,7 @@ - (void)skipBackwardWithParams:(MTRMediaPlaybackClusterSkipBackwardParams *)para std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -20441,20 +21700,27 @@ - (void)seekWithParams:(MTRMediaPlaybackClusterSeekParams *)params completion: (void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeMediaPlaybackID, (unsigned int) MTRCommandIDTypeClusterMediaPlaybackCommandSeekID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRMediaPlaybackClusterPlaybackResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -20474,6 +21740,7 @@ - (void)seekWithParams:(MTRMediaPlaybackClusterSeekParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -20847,20 +22114,27 @@ - (void)selectInputWithParams:(MTRMediaInputClusterSelectInputParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeMediaInputID, + (unsigned int) MTRCommandIDTypeClusterMediaInputCommandSelectInputID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -20879,6 +22153,7 @@ - (void)selectInputWithParams:(MTRMediaInputClusterSelectInputParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -20905,20 +22180,27 @@ - (void)showInputStatusWithParams:(MTRMediaInputClusterShowInputStatusParams * _ expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeMediaInputID, + (unsigned int) MTRCommandIDTypeClusterMediaInputCommandShowInputStatusID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -20936,6 +22218,7 @@ - (void)showInputStatusWithParams:(MTRMediaInputClusterShowInputStatusParams * _ std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -20962,20 +22245,27 @@ - (void)hideInputStatusWithParams:(MTRMediaInputClusterHideInputStatusParams * _ expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeMediaInputID, + (unsigned int) MTRCommandIDTypeClusterMediaInputCommandHideInputStatusID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -20993,6 +22283,7 @@ - (void)hideInputStatusWithParams:(MTRMediaInputClusterHideInputStatusParams * _ std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -21010,20 +22301,27 @@ - (void)renameInputWithParams:(MTRMediaInputClusterRenameInputParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeMediaInputID, + (unsigned int) MTRCommandIDTypeClusterMediaInputCommandRenameInputID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -21043,6 +22341,7 @@ - (void)renameInputWithParams:(MTRMediaInputClusterRenameInputParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -21206,20 +22505,27 @@ - (void)sleepWithParams:(MTRLowPowerClusterSleepParams * _Nullable)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeLowPowerID, (unsigned int) MTRCommandIDTypeClusterLowPowerCommandSleepID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -21237,6 +22543,7 @@ - (void)sleepWithParams:(MTRLowPowerClusterSleepParams * _Nullable)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -21340,20 +22647,27 @@ - (void)sendKeyWithParams:(MTRKeypadInputClusterSendKeyParams *)params completion: (void (^)(MTRKeypadInputClusterSendKeyResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeKeypadInputID, (unsigned int) MTRCommandIDTypeClusterKeypadInputCommandSendKeyID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRKeypadInputClusterSendKeyResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -21373,6 +22687,7 @@ - (void)sendKeyWithParams:(MTRKeypadInputClusterSendKeyParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -21471,20 +22786,27 @@ - (void)launchContentWithParams:(MTRContentLauncherClusterLaunchContentParams *) completion:(void (^)(MTRContentLauncherClusterLaunchResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeContentLauncherID, + (unsigned int) MTRCommandIDTypeClusterContentLauncherCommandLaunchContentID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRContentLauncherClusterLaunchResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -21561,6 +22883,7 @@ - (void)launchContentWithParams:(MTRContentLauncherClusterLaunchContentParams *) std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -21579,20 +22902,27 @@ - (void)launchURLWithParams:(MTRContentLauncherClusterLaunchURLParams *)params completion: (void (^)(MTRContentLauncherClusterLaunchResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeContentLauncherID, + (unsigned int) MTRCommandIDTypeClusterContentLauncherCommandLaunchURLID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRContentLauncherClusterLaunchResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -21710,6 +23040,7 @@ - (void)launchURLWithParams:(MTRContentLauncherClusterLaunchURLParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -21859,20 +23190,27 @@ - (void)selectOutputWithParams:(MTRAudioOutputClusterSelectOutputParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeAudioOutputID, + (unsigned int) MTRCommandIDTypeClusterAudioOutputCommandSelectOutputID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -21891,6 +23229,7 @@ - (void)selectOutputWithParams:(MTRAudioOutputClusterSelectOutputParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -21908,20 +23247,27 @@ - (void)renameOutputWithParams:(MTRAudioOutputClusterRenameOutputParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeAudioOutputID, + (unsigned int) MTRCommandIDTypeClusterAudioOutputCommandRenameOutputID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -21941,6 +23287,7 @@ - (void)renameOutputWithParams:(MTRAudioOutputClusterRenameOutputParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -22061,20 +23408,27 @@ - (void)launchAppWithParams:(MTRApplicationLauncherClusterLaunchAppParams *)para completion:(void (^)(MTRApplicationLauncherClusterLauncherResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeApplicationLauncherID, + (unsigned int) MTRCommandIDTypeClusterApplicationLauncherCommandLaunchAppID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRApplicationLauncherClusterLauncherResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -22099,6 +23453,7 @@ - (void)launchAppWithParams:(MTRApplicationLauncherClusterLaunchAppParams *)para std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -22117,20 +23472,27 @@ - (void)stopAppWithParams:(MTRApplicationLauncherClusterStopAppParams *)params completion:(void (^)(MTRApplicationLauncherClusterLauncherResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeApplicationLauncherID, + (unsigned int) MTRCommandIDTypeClusterApplicationLauncherCommandStopAppID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRApplicationLauncherClusterLauncherResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -22151,6 +23513,7 @@ - (void)stopAppWithParams:(MTRApplicationLauncherClusterStopAppParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -22169,20 +23532,27 @@ - (void)hideAppWithParams:(MTRApplicationLauncherClusterHideAppParams *)params completion:(void (^)(MTRApplicationLauncherClusterLauncherResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeApplicationLauncherID, + (unsigned int) MTRCommandIDTypeClusterApplicationLauncherCommandHideAppID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRApplicationLauncherClusterLauncherResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -22203,6 +23573,7 @@ - (void)hideAppWithParams:(MTRApplicationLauncherClusterHideAppParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -22494,20 +23865,27 @@ - (void)getSetupPINWithParams:(MTRAccountLoginClusterGetSetupPINParams *)params completion:(void (^)(MTRAccountLoginClusterGetSetupPINResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeAccountLoginID, + (unsigned int) MTRCommandIDTypeClusterAccountLoginCommandGetSetupPINID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRAccountLoginClusterGetSetupPINResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -22530,6 +23908,7 @@ - (void)getSetupPINWithParams:(MTRAccountLoginClusterGetSetupPINParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -22547,20 +23926,27 @@ - (void)loginWithParams:(MTRAccountLoginClusterLoginParams *)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeAccountLoginID, (unsigned int) MTRCommandIDTypeClusterAccountLoginCommandLoginID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -22583,6 +23969,7 @@ - (void)loginWithParams:(MTRAccountLoginClusterLoginParams *)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -22606,20 +23993,27 @@ - (void)logoutWithParams:(MTRAccountLoginClusterLogoutParams * _Nullable)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeAccountLoginID, (unsigned int) MTRCommandIDTypeClusterAccountLoginCommandLogoutID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -22640,6 +24034,7 @@ - (void)logoutWithParams:(MTRAccountLoginClusterLogoutParams * _Nullable)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -22775,20 +24170,27 @@ - (void)getProfileInfoCommandWithParams:(MTRElectricalMeasurementClusterGetProfi expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeElectricalMeasurementID, + (unsigned int) MTRCommandIDTypeClusterElectricalMeasurementCommandGetProfileInfoCommandID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -22806,6 +24208,7 @@ - (void)getProfileInfoCommandWithParams:(MTRElectricalMeasurementClusterGetProfi std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -22823,20 +24226,28 @@ - (void)getMeasurementProfileCommandWithParams:(MTRElectricalMeasurementClusterG expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeElectricalMeasurementID, + (unsigned int) MTRCommandIDTypeClusterElectricalMeasurementCommandGetMeasurementProfileCommandID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -22857,6 +24268,7 @@ - (void)getMeasurementProfileCommandWithParams:(MTRElectricalMeasurementClusterG std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -24212,20 +25624,27 @@ - (void)testWithParams:(MTRUnitTestingClusterTestParams * _Nullable)params expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeUnitTestingID, (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -24243,6 +25662,7 @@ - (void)testWithParams:(MTRUnitTestingClusterTestParams * _Nullable)params std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -24269,20 +25689,27 @@ - (void)testNotHandledWithParams:(MTRUnitTestingClusterTestNotHandledParams * _N expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestNotHandledID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -24300,6 +25727,7 @@ - (void)testNotHandledWithParams:(MTRUnitTestingClusterTestNotHandledParams * _N std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -24328,20 +25756,27 @@ - (void)testSpecificWithParams:(MTRUnitTestingClusterTestSpecificParams * _Nulla completion:(void (^)(MTRUnitTestingClusterTestSpecificResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestSpecificID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterTestSpecificResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -24360,6 +25795,7 @@ - (void)testSpecificWithParams:(MTRUnitTestingClusterTestSpecificParams * _Nulla std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -24386,20 +25822,27 @@ - (void)testUnknownCommandWithParams:(MTRUnitTestingClusterTestUnknownCommandPar expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestUnknownCommandID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -24417,6 +25860,7 @@ - (void)testUnknownCommandWithParams:(MTRUnitTestingClusterTestUnknownCommandPar std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -24435,20 +25879,27 @@ - (void)testAddArgumentsWithParams:(MTRUnitTestingClusterTestAddArgumentsParams completion:(void (^)(MTRUnitTestingClusterTestAddArgumentsResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestAddArgumentsID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterTestAddArgumentsResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -24469,6 +25920,7 @@ - (void)testAddArgumentsWithParams:(MTRUnitTestingClusterTestAddArgumentsParams std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -24487,20 +25939,27 @@ - (void)testSimpleArgumentRequestWithParams:(MTRUnitTestingClusterTestSimpleArgu completion:(void (^)(MTRUnitTestingClusterTestSimpleArgumentResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestSimpleArgumentRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterTestSimpleArgumentResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -24520,6 +25979,7 @@ - (void)testSimpleArgumentRequestWithParams:(MTRUnitTestingClusterTestSimpleArgu std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -24539,20 +25999,27 @@ - (void)testStructArrayArgumentRequestWithParams:(MTRUnitTestingClusterTestStruc (void (^)(MTRUnitTestingClusterTestStructArrayArgumentResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestStructArrayArgumentRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterTestStructArrayArgumentResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -24783,6 +26250,7 @@ - (void)testStructArrayArgumentRequestWithParams:(MTRUnitTestingClusterTestStruc std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -24801,20 +26269,27 @@ - (void)testStructArgumentRequestWithParams:(MTRUnitTestingClusterTestStructArgu completion:(void (^)(MTRUnitTestingClusterBooleanResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestStructArgumentRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterBooleanResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -24841,6 +26316,7 @@ - (void)testStructArgumentRequestWithParams:(MTRUnitTestingClusterTestStructArgu std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -24859,20 +26335,27 @@ - (void)testNestedStructArgumentRequestWithParams:(MTRUnitTestingClusterTestNest completion:(void (^)(MTRUnitTestingClusterBooleanResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestNestedStructArgumentRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterBooleanResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -24903,6 +26386,7 @@ - (void)testNestedStructArgumentRequestWithParams:(MTRUnitTestingClusterTestNest std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -24921,20 +26405,27 @@ - (void)testListStructArgumentRequestWithParams:(MTRUnitTestingClusterTestListSt completion:(void (^)(MTRUnitTestingClusterBooleanResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestListStructArgumentRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterBooleanResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -24984,6 +26475,7 @@ - (void)testListStructArgumentRequestWithParams:(MTRUnitTestingClusterTestListSt std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -25002,20 +26494,27 @@ - (void)testListInt8UArgumentRequestWithParams:(MTRUnitTestingClusterTestListInt completion:(void (^)(MTRUnitTestingClusterBooleanResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestListInt8UArgumentRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterBooleanResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -25056,6 +26555,7 @@ - (void)testListInt8UArgumentRequestWithParams:(MTRUnitTestingClusterTestListInt std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -25074,20 +26574,27 @@ - (void)testNestedStructListArgumentRequestWithParams:(MTRUnitTestingClusterTest completion:(void (^)(MTRUnitTestingClusterBooleanResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestNestedStructListArgumentRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterBooleanResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -25215,6 +26722,7 @@ - (void)testNestedStructListArgumentRequestWithParams:(MTRUnitTestingClusterTest std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -25234,20 +26742,28 @@ - (void)testListNestedStructListArgumentRequestWithParams: completion:(void (^)(MTRUnitTestingClusterBooleanResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestListNestedStructListArgumentRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterBooleanResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -25400,6 +26916,7 @@ - (void)testListNestedStructListArgumentRequestWithParams: std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -25418,20 +26935,27 @@ - (void)testListInt8UReverseRequestWithParams:(MTRUnitTestingClusterTestListInt8 completion:(void (^)(MTRUnitTestingClusterTestListInt8UReverseResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestListInt8UReverseRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterTestListInt8UReverseResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -25472,6 +26996,7 @@ - (void)testListInt8UReverseRequestWithParams:(MTRUnitTestingClusterTestListInt8 std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -25490,20 +27015,27 @@ - (void)testEnumsRequestWithParams:(MTRUnitTestingClusterTestEnumsRequestParams completion:(void (^)(MTRUnitTestingClusterTestEnumsResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestEnumsRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterTestEnumsResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -25524,6 +27056,7 @@ - (void)testEnumsRequestWithParams:(MTRUnitTestingClusterTestEnumsRequestParams std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -25542,20 +27075,27 @@ - (void)testNullableOptionalRequestWithParams:(MTRUnitTestingClusterTestNullable completion:(void (^)(MTRUnitTestingClusterTestNullableOptionalResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestNullableOptionalRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterTestNullableOptionalResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -25585,6 +27125,7 @@ - (void)testNullableOptionalRequestWithParams:(MTRUnitTestingClusterTestNullable std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -25605,20 +27146,27 @@ - (void)testComplexNullableOptionalRequestWithParams:(MTRUnitTestingClusterTestC MTRUnitTestingClusterTestComplexNullableOptionalResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestComplexNullableOptionalRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterTestComplexNullableOptionalResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -25807,6 +27355,7 @@ - (void)testComplexNullableOptionalRequestWithParams:(MTRUnitTestingClusterTestC std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -25825,20 +27374,27 @@ - (void)simpleStructEchoRequestWithParams:(MTRUnitTestingClusterSimpleStructEcho completion:(void (^)(MTRUnitTestingClusterSimpleStructResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandSimpleStructEchoRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterSimpleStructResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -25865,6 +27421,7 @@ - (void)simpleStructEchoRequestWithParams:(MTRUnitTestingClusterSimpleStructEcho std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -25891,20 +27448,27 @@ - (void)timedInvokeRequestWithParams:(MTRUnitTestingClusterTimedInvokeRequestPar expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTimedInvokeRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -25925,6 +27489,7 @@ - (void)timedInvokeRequestWithParams:(MTRUnitTestingClusterTimedInvokeRequestPar std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -25942,20 +27507,27 @@ - (void)testSimpleOptionalArgumentRequestWithParams:(MTRUnitTestingClusterTestSi expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestSimpleOptionalArgumentRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRCommandSuccessCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, CommandSuccessCallbackType successCb, @@ -25979,6 +27551,7 @@ - (void)testSimpleOptionalArgumentRequestWithParams:(MTRUnitTestingClusterTestSi std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -25997,20 +27570,27 @@ - (void)testEmitTestEventRequestWithParams:(MTRUnitTestingClusterTestEmitTestEve completion:(void (^)(MTRUnitTestingClusterTestEmitTestEventResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, + _endpoint, (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestEmitTestEventRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterTestEmitTestEventResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -26032,6 +27612,7 @@ - (void)testEmitTestEventRequestWithParams:(MTRUnitTestingClusterTestEmitTestEve std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { @@ -26053,20 +27634,28 @@ - (void)testEmitTestEventRequestWithParams:(MTRUnitTestingClusterTestEmitTestEve MTRUnitTestingClusterTestEmitTestFabricScopedEventResponseParams * _Nullable data, NSError * _Nullable error))completion { + NSString * logPrefix = + [NSString stringWithFormat:@"MTRDevice command %u %u %u %u", self.device.deviceController.fabricIndex, _endpoint, + (unsigned int) MTRClusterIDTypeUnitTestingID, + (unsigned int) MTRCommandIDTypeClusterUnitTestingCommandTestEmitTestFabricScopedEventRequestID]; // Make a copy of params before we go async. params = [params copy]; NSNumber * timedInvokeTimeoutMsParam = params.timedInvokeTimeoutMs; if (timedInvokeTimeoutMsParam) { timedInvokeTimeoutMsParam = MTRClampedNumber(timedInvokeTimeoutMsParam, @(1), @(UINT16_MAX)); } - MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.callbackQueue]; + MTRAsyncCallbackQueueWorkItem * workItem = [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:self.device.queue]; MTRAsyncCallbackReadyHandler readyHandler = ^(MTRDevice * device, NSUInteger retryCount) { + MTRClustersLogDequeue(logPrefix, self.device.asyncCallbackWorkQueue); MTRBaseDevice * baseDevice = [[MTRBaseDevice alloc] initWithNodeID:self.device.nodeID controller:self.device.deviceController]; auto * bridge = new MTRUnitTestingClusterTestEmitTestFabricScopedEventResponseCallbackBridge( - self.callbackQueue, + self.device.queue, ^(id _Nullable value, NSError * _Nullable error) { - completion(value, error); + MTRClustersLogCompletion(logPrefix, value, error); + dispatch_async(self.callbackQueue, ^{ + completion(value, error); + }); [workItem endWork]; }, ^(ExchangeManager & exchangeManager, const SessionHandle & session, @@ -26086,6 +27675,7 @@ - (void)testEmitTestEventRequestWithParams:(MTRUnitTestingClusterTestEmitTestEve std::move(*bridge).DispatchAction(baseDevice); }; workItem.readyHandler = readyHandler; + MTRClustersLogEnqueue(logPrefix, self.device.asyncCallbackWorkQueue); [self.device.asyncCallbackWorkQueue enqueueWorkItem:workItem]; if (!expectedValueIntervalMs || ([expectedValueIntervalMs compare:@(0)] == NSOrderedAscending)) { diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRClusters_internal.h b/src/darwin/Framework/CHIP/zap-generated/MTRClusters_internal.h index b5d6cff234544e..3bcc5e9a5af1b3 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRClusters_internal.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRClusters_internal.h @@ -83,12 +83,12 @@ @property (nonatomic, readonly) MTRDevice * device; @end -@interface MTRClusterOtaSoftwareUpdateProvider () +@interface MTRClusterOTASoftwareUpdateProvider () @property (nonatomic, readonly) uint16_t endpoint; @property (nonatomic, readonly) MTRDevice * device; @end -@interface MTRClusterOtaSoftwareUpdateRequestor () +@interface MTRClusterOTASoftwareUpdateRequestor () @property (nonatomic, readonly) uint16_t endpoint; @property (nonatomic, readonly) MTRDevice * device; @end @@ -278,7 +278,7 @@ @property (nonatomic, readonly) MTRDevice * device; @end -@interface MTRClusterWakeOnLan () +@interface MTRClusterWakeOnLAN () @property (nonatomic, readonly) uint16_t endpoint; @property (nonatomic, readonly) MTRDevice * device; @end diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.h b/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.h index 275e2e46bcd9db..0809cb2d5dc57f 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.h @@ -38,9 +38,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRIdentifyClusterTriggerEffectParams : NSObject @@ -62,9 +59,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupsClusterAddGroupParams : NSObject @@ -86,9 +80,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupsClusterAddGroupResponseParams : NSObject @@ -111,9 +102,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupsClusterViewGroupParams : NSObject @@ -133,9 +121,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupsClusterViewGroupResponseParams : NSObject @@ -160,9 +145,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupsClusterGetGroupMembershipParams : NSObject @@ -182,9 +164,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupsClusterGetGroupMembershipResponseParams : NSObject @@ -207,9 +186,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupsClusterRemoveGroupParams : NSObject @@ -229,9 +205,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupsClusterRemoveGroupResponseParams : NSObject @@ -254,9 +227,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupsClusterRemoveAllGroupsParams : NSObject /** @@ -274,9 +244,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupsClusterAddGroupIfIdentifyingParams : NSObject @@ -298,9 +265,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterAddSceneParams : NSObject @@ -328,9 +292,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterAddSceneResponseParams : NSObject @@ -355,9 +316,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterViewSceneParams : NSObject @@ -379,9 +337,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterViewSceneResponseParams : NSObject @@ -412,9 +367,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterRemoveSceneParams : NSObject @@ -436,9 +388,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterRemoveSceneResponseParams : NSObject @@ -463,9 +412,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterRemoveAllScenesParams : NSObject @@ -485,9 +431,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterRemoveAllScenesResponseParams : NSObject @@ -510,9 +453,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterStoreSceneParams : NSObject @@ -534,9 +474,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterStoreSceneResponseParams : NSObject @@ -561,9 +498,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterRecallSceneParams : NSObject @@ -587,9 +521,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterGetSceneMembershipParams : NSObject @@ -609,9 +540,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterGetSceneMembershipResponseParams : NSObject @@ -638,9 +566,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterEnhancedAddSceneParams : NSObject @@ -668,9 +593,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterEnhancedAddSceneResponseParams : NSObject @@ -695,9 +617,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterEnhancedViewSceneParams : NSObject @@ -719,9 +638,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterEnhancedViewSceneResponseParams : NSObject @@ -752,9 +668,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterCopySceneParams : NSObject @@ -782,9 +695,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterCopySceneResponseParams : NSObject @@ -809,9 +719,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROnOffClusterOffParams : NSObject /** @@ -829,9 +736,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROnOffClusterOnParams : NSObject /** @@ -849,9 +753,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROnOffClusterToggleParams : NSObject /** @@ -869,9 +770,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROnOffClusterOffWithEffectParams : NSObject @@ -893,9 +791,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROnOffClusterOnWithRecallGlobalSceneParams : NSObject /** @@ -913,9 +808,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROnOffClusterOnWithTimedOffParams : NSObject @@ -939,9 +831,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRLevelControlClusterMoveToLevelParams : NSObject @@ -967,9 +856,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRLevelControlClusterMoveParams : NSObject @@ -995,9 +881,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRLevelControlClusterStepParams : NSObject @@ -1025,9 +908,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRLevelControlClusterStopParams : NSObject @@ -1049,9 +929,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRLevelControlClusterMoveToLevelWithOnOffParams : NSObject @@ -1077,9 +954,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRLevelControlClusterMoveWithOnOffParams : NSObject @@ -1105,9 +979,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRLevelControlClusterStepWithOnOffParams : NSObject @@ -1135,9 +1006,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRLevelControlClusterStopWithOnOffParams : NSObject @@ -1159,9 +1027,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRLevelControlClusterMoveToClosestFrequencyParams : NSObject @@ -1181,9 +1046,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterInstantActionParams : NSObject @@ -1205,9 +1067,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterInstantActionWithTransitionParams : NSObject @@ -1231,9 +1090,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterStartActionParams : NSObject @@ -1255,9 +1111,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterStartActionWithDurationParams : NSObject @@ -1281,9 +1134,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterStopActionParams : NSObject @@ -1305,9 +1155,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterPauseActionParams : NSObject @@ -1329,9 +1176,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterPauseActionWithDurationParams : NSObject @@ -1355,9 +1199,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterResumeActionParams : NSObject @@ -1379,9 +1220,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterEnableActionParams : NSObject @@ -1403,9 +1241,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterEnableActionWithDurationParams : NSObject @@ -1429,9 +1264,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterDisableActionParams : NSObject @@ -1453,9 +1285,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterDisableActionWithDurationParams : NSObject @@ -1479,9 +1308,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRBasicClusterMfgSpecificPingParams : NSObject /** @@ -1499,11 +1325,9 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end -@interface MTROtaSoftwareUpdateProviderClusterQueryImageParams : NSObject +MTR_NEWLY_AVAILABLE +@interface MTROTASoftwareUpdateProviderClusterQueryImageParams : NSObject @property (nonatomic, copy) NSNumber * _Nonnull vendorId; @@ -1535,11 +1359,14 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; +@end -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; +MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateProviderClusterQueryImageParams") +@interface MTROtaSoftwareUpdateProviderClusterQueryImageParams : MTROTASoftwareUpdateProviderClusterQueryImageParams @end -@interface MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams : NSObject + +MTR_NEWLY_AVAILABLE +@interface MTROTASoftwareUpdateProviderClusterQueryImageResponseParams : NSObject @property (nonatomic, copy) NSNumber * _Nonnull status; @@ -1572,11 +1399,14 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); +@end -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; +MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateProviderClusterQueryImageResponseParams") +@interface MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams : MTROTASoftwareUpdateProviderClusterQueryImageResponseParams @end -@interface MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams : NSObject + +MTR_NEWLY_AVAILABLE +@interface MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams : NSObject @property (nonatomic, copy) NSData * _Nonnull updateToken; @@ -1596,11 +1426,14 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; +@end -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; +MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams") +@interface MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams : MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams @end -@interface MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams : NSObject + +MTR_NEWLY_AVAILABLE +@interface MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams : NSObject @property (nonatomic, copy) NSNumber * _Nonnull action; @@ -1621,11 +1454,15 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); +@end -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; +MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams") +@interface MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams + : MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams @end -@interface MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams : NSObject + +MTR_NEWLY_AVAILABLE +@interface MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams : NSObject @property (nonatomic, copy) NSData * _Nonnull updateToken; @@ -1645,11 +1482,15 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; +@end -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; +MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams") +@interface MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams + : MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams @end -@interface MTROtaSoftwareUpdateRequestorClusterAnnounceOtaProviderParams : NSObject + +MTR_NEWLY_AVAILABLE +@interface MTROTASoftwareUpdateRequestorClusterAnnounceOtaProviderParams : NSObject @property (nonatomic, copy) NSNumber * _Nonnull providerNodeId; @@ -1675,10 +1516,13 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; +@end -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; +MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateRequestorClusterAnnounceOtaProviderParams") +@interface MTROtaSoftwareUpdateRequestorClusterAnnounceOtaProviderParams + : MTROTASoftwareUpdateRequestorClusterAnnounceOtaProviderParams @end + @interface MTRGeneralCommissioningClusterArmFailSafeParams : NSObject @property (nonatomic, copy) NSNumber * _Nonnull expiryLengthSeconds; @@ -1699,9 +1543,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGeneralCommissioningClusterArmFailSafeResponseParams : NSObject @@ -1724,9 +1565,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGeneralCommissioningClusterSetRegulatoryConfigParams : NSObject @@ -1750,9 +1588,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGeneralCommissioningClusterSetRegulatoryConfigResponseParams : NSObject @@ -1775,9 +1610,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGeneralCommissioningClusterCommissioningCompleteParams : NSObject /** @@ -1795,9 +1627,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGeneralCommissioningClusterCommissioningCompleteResponseParams : NSObject @@ -1820,9 +1649,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRNetworkCommissioningClusterScanNetworksParams : NSObject @@ -1844,9 +1670,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRNetworkCommissioningClusterScanNetworksResponseParams : NSObject @@ -1873,9 +1696,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRNetworkCommissioningClusterAddOrUpdateWiFiNetworkParams : NSObject @@ -1899,9 +1719,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRNetworkCommissioningClusterAddOrUpdateThreadNetworkParams : NSObject @@ -1923,9 +1740,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRNetworkCommissioningClusterRemoveNetworkParams : NSObject @@ -1947,9 +1761,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRNetworkCommissioningClusterNetworkConfigResponseParams : NSObject @@ -1974,9 +1785,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRNetworkCommissioningClusterConnectNetworkParams : NSObject @@ -1998,9 +1806,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRNetworkCommissioningClusterConnectNetworkResponseParams : NSObject @@ -2025,9 +1830,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRNetworkCommissioningClusterReorderNetworkParams : NSObject @@ -2051,9 +1853,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDiagnosticLogsClusterRetrieveLogsRequestParams : NSObject @@ -2077,9 +1876,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDiagnosticLogsClusterRetrieveLogsResponseParams : NSObject @@ -2106,9 +1902,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGeneralDiagnosticsClusterTestEventTriggerParams : NSObject @@ -2130,9 +1923,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRSoftwareDiagnosticsClusterResetWatermarksParams : NSObject /** @@ -2150,9 +1940,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRThreadNetworkDiagnosticsClusterResetCountsParams : NSObject /** @@ -2170,9 +1957,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRWiFiNetworkDiagnosticsClusterResetCountsParams : NSObject /** @@ -2190,9 +1974,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTREthernetNetworkDiagnosticsClusterResetCountsParams : NSObject /** @@ -2210,9 +1991,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRTimeSynchronizationClusterSetUtcTimeParams : NSObject @@ -2236,9 +2014,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRAdministratorCommissioningClusterOpenCommissioningWindowParams : NSObject @@ -2266,9 +2041,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRAdministratorCommissioningClusterOpenBasicCommissioningWindowParams : NSObject @@ -2288,9 +2060,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRAdministratorCommissioningClusterRevokeCommissioningParams : NSObject /** @@ -2308,9 +2077,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROperationalCredentialsClusterAttestationRequestParams : NSObject @@ -2330,9 +2096,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROperationalCredentialsClusterAttestationResponseParams : NSObject @@ -2355,9 +2118,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROperationalCredentialsClusterCertificateChainRequestParams : NSObject @@ -2377,9 +2137,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROperationalCredentialsClusterCertificateChainResponseParams : NSObject @@ -2400,9 +2157,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROperationalCredentialsClusterCSRRequestParams : NSObject @@ -2424,9 +2178,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROperationalCredentialsClusterCSRResponseParams : NSObject @@ -2449,9 +2200,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROperationalCredentialsClusterAddNOCParams : NSObject @@ -2479,9 +2227,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROperationalCredentialsClusterUpdateNOCParams : NSObject @@ -2503,9 +2248,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROperationalCredentialsClusterNOCResponseParams : NSObject @@ -2530,9 +2272,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROperationalCredentialsClusterUpdateFabricLabelParams : NSObject @@ -2552,9 +2291,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROperationalCredentialsClusterRemoveFabricParams : NSObject @@ -2574,9 +2310,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROperationalCredentialsClusterAddTrustedRootCertificateParams : NSObject @@ -2596,9 +2329,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupKeyManagementClusterKeySetWriteParams : NSObject @@ -2618,9 +2348,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupKeyManagementClusterKeySetReadParams : NSObject @@ -2640,9 +2367,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupKeyManagementClusterKeySetReadResponseParams : NSObject @@ -2663,9 +2387,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupKeyManagementClusterKeySetRemoveParams : NSObject @@ -2685,9 +2406,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupKeyManagementClusterKeySetReadAllIndicesParams : NSObject @@ -2707,9 +2425,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupKeyManagementClusterKeySetReadAllIndicesResponseParams : NSObject @@ -2730,9 +2445,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRModeSelectClusterChangeToModeParams : NSObject @@ -2752,9 +2464,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterLockDoorParams : NSObject @@ -2774,9 +2483,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterUnlockDoorParams : NSObject @@ -2796,9 +2502,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterUnlockWithTimeoutParams : NSObject @@ -2820,9 +2523,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterSetWeekDayScheduleParams : NSObject @@ -2854,9 +2554,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterGetWeekDayScheduleParams : NSObject @@ -2878,9 +2575,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterGetWeekDayScheduleResponseParams : NSObject @@ -2915,9 +2609,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterClearWeekDayScheduleParams : NSObject @@ -2939,9 +2630,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterSetYearDayScheduleParams : NSObject @@ -2967,9 +2655,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterGetYearDayScheduleParams : NSObject @@ -2991,9 +2676,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterGetYearDayScheduleResponseParams : NSObject @@ -3022,9 +2704,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterClearYearDayScheduleParams : NSObject @@ -3046,9 +2725,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterSetHolidayScheduleParams : NSObject @@ -3074,9 +2750,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterGetHolidayScheduleParams : NSObject @@ -3096,9 +2769,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterGetHolidayScheduleResponseParams : NSObject @@ -3127,9 +2797,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterClearHolidayScheduleParams : NSObject @@ -3149,9 +2816,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterSetUserParams : NSObject @@ -3183,9 +2847,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterGetUserParams : NSObject @@ -3205,9 +2866,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterGetUserResponseParams : NSObject @@ -3246,9 +2904,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterClearUserParams : NSObject @@ -3268,9 +2923,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterSetCredentialParams : NSObject @@ -3300,9 +2952,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterSetCredentialResponseParams : NSObject @@ -3327,9 +2976,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterGetCredentialStatusParams : NSObject @@ -3349,9 +2995,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterGetCredentialStatusResponseParams : NSObject @@ -3380,9 +3023,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterClearCredentialParams : NSObject @@ -3402,9 +3042,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRWindowCoveringClusterUpOrOpenParams : NSObject /** @@ -3422,9 +3059,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRWindowCoveringClusterDownOrCloseParams : NSObject /** @@ -3442,9 +3076,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRWindowCoveringClusterStopMotionParams : NSObject /** @@ -3462,9 +3093,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRWindowCoveringClusterGoToLiftValueParams : NSObject @@ -3484,9 +3112,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRWindowCoveringClusterGoToLiftPercentageParams : NSObject @@ -3506,9 +3131,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRWindowCoveringClusterGoToTiltValueParams : NSObject @@ -3528,9 +3150,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRWindowCoveringClusterGoToTiltPercentageParams : NSObject @@ -3550,9 +3169,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRBarrierControlClusterBarrierControlGoToPercentParams : NSObject @@ -3572,9 +3188,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRBarrierControlClusterBarrierControlStopParams : NSObject /** @@ -3592,9 +3205,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRThermostatClusterSetpointRaiseLowerParams : NSObject @@ -3616,9 +3226,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRThermostatClusterGetWeeklyScheduleResponseParams : NSObject @@ -3645,9 +3252,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRThermostatClusterSetWeeklyScheduleParams : NSObject @@ -3673,9 +3277,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRThermostatClusterGetWeeklyScheduleParams : NSObject @@ -3697,9 +3298,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRThermostatClusterClearWeeklyScheduleParams : NSObject /** @@ -3717,9 +3315,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterMoveToHueParams : NSObject @@ -3747,9 +3342,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterMoveHueParams : NSObject @@ -3775,9 +3367,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterStepHueParams : NSObject @@ -3805,9 +3394,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterMoveToSaturationParams : NSObject @@ -3833,9 +3419,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterMoveSaturationParams : NSObject @@ -3861,9 +3444,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterStepSaturationParams : NSObject @@ -3891,9 +3471,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterMoveToHueAndSaturationParams : NSObject @@ -3921,9 +3498,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterMoveToColorParams : NSObject @@ -3951,9 +3525,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterMoveColorParams : NSObject @@ -3979,9 +3550,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterStepColorParams : NSObject @@ -4009,9 +3577,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterMoveToColorTemperatureParams : NSObject @@ -4037,9 +3602,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterEnhancedMoveToHueParams : NSObject @@ -4067,9 +3629,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterEnhancedMoveHueParams : NSObject @@ -4095,9 +3654,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterEnhancedStepHueParams : NSObject @@ -4125,9 +3681,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterEnhancedMoveToHueAndSaturationParams : NSObject @@ -4155,9 +3708,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterColorLoopSetParams : NSObject @@ -4189,9 +3739,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterStopMoveStepParams : NSObject @@ -4213,9 +3760,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterMoveColorTemperatureParams : NSObject @@ -4245,9 +3789,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRColorControlClusterStepColorTemperatureParams : NSObject @@ -4279,9 +3820,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRChannelClusterChangeChannelParams : NSObject @@ -4301,9 +3839,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRChannelClusterChangeChannelResponseParams : NSObject @@ -4326,9 +3861,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRChannelClusterChangeChannelByNumberParams : NSObject @@ -4350,9 +3882,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRChannelClusterSkipChannelParams : NSObject @@ -4372,9 +3901,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRTargetNavigatorClusterNavigateTargetParams : NSObject @@ -4396,9 +3922,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRTargetNavigatorClusterNavigateTargetResponseParams : NSObject @@ -4421,9 +3944,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaPlaybackClusterPlayParams : NSObject /** @@ -4441,9 +3961,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaPlaybackClusterPauseParams : NSObject /** @@ -4461,9 +3978,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaPlaybackClusterStopPlaybackParams : NSObject /** @@ -4481,9 +3995,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaPlaybackClusterStartOverParams : NSObject /** @@ -4501,9 +4012,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaPlaybackClusterPreviousParams : NSObject /** @@ -4521,9 +4029,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaPlaybackClusterNextParams : NSObject /** @@ -4541,9 +4046,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaPlaybackClusterRewindParams : NSObject /** @@ -4561,9 +4063,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaPlaybackClusterFastForwardParams : NSObject /** @@ -4581,9 +4080,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaPlaybackClusterSkipForwardParams : NSObject @@ -4603,9 +4099,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaPlaybackClusterSkipBackwardParams : NSObject @@ -4625,9 +4118,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaPlaybackClusterPlaybackResponseParams : NSObject @@ -4650,9 +4140,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaPlaybackClusterSeekParams : NSObject @@ -4672,9 +4159,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaInputClusterSelectInputParams : NSObject @@ -4694,9 +4178,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaInputClusterShowInputStatusParams : NSObject /** @@ -4714,9 +4195,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaInputClusterHideInputStatusParams : NSObject /** @@ -4734,9 +4212,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaInputClusterRenameInputParams : NSObject @@ -4758,9 +4233,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRLowPowerClusterSleepParams : NSObject /** @@ -4778,9 +4250,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRKeypadInputClusterSendKeyParams : NSObject @@ -4800,9 +4269,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRKeypadInputClusterSendKeyResponseParams : NSObject @@ -4823,9 +4289,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRContentLauncherClusterLaunchContentParams : NSObject @@ -4849,9 +4312,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRContentLauncherClusterLaunchURLParams : NSObject @@ -4875,9 +4335,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRContentLauncherClusterLaunchResponseParams : NSObject @@ -4900,9 +4357,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRAudioOutputClusterSelectOutputParams : NSObject @@ -4922,9 +4376,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRAudioOutputClusterRenameOutputParams : NSObject @@ -4946,9 +4397,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRApplicationLauncherClusterLaunchAppParams : NSObject @@ -4970,9 +4418,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRApplicationLauncherClusterStopAppParams : NSObject @@ -4992,9 +4437,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRApplicationLauncherClusterHideAppParams : NSObject @@ -5014,9 +4456,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRApplicationLauncherClusterLauncherResponseParams : NSObject @@ -5039,9 +4478,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRAccountLoginClusterGetSetupPINParams : NSObject @@ -5061,9 +4497,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRAccountLoginClusterGetSetupPINResponseParams : NSObject @@ -5084,9 +4517,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRAccountLoginClusterLoginParams : NSObject @@ -5108,9 +4538,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRAccountLoginClusterLogoutParams : NSObject /** @@ -5128,9 +4555,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRElectricalMeasurementClusterGetProfileInfoResponseCommandParams : NSObject @@ -5157,9 +4581,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRElectricalMeasurementClusterGetProfileInfoCommandParams : NSObject /** @@ -5177,9 +4598,6 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRElectricalMeasurementClusterGetMeasurementProfileResponseCommandParams : NSObject @@ -5210,9 +4628,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRElectricalMeasurementClusterGetMeasurementProfileCommandParams : NSObject @@ -5236,9 +4651,44 @@ NS_ASSUME_NONNULL_BEGIN * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; +@end +@interface MTRClientMonitoringClusterRegisterClientMonitoringParams : NSObject + +@property (nonatomic, copy) NSNumber * _Nonnull clientNodeId; -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; +@property (nonatomic, copy) NSNumber * _Nonnull iCid; +/** + * Controls whether the command is a timed command (using Timed Invoke). + * + * If nil (the default value), a regular invoke is done for commands that do + * not require a timed invoke and a timed invoke with some default timed request + * timeout is done for commands that require a timed invoke. + * + * If not nil, a timed invoke is done, with the provided value used as the timed + * request timeout. The value should be chosen small enough to provide the + * desired security properties but large enough that it will allow a round-trip + * from the sever to the client (for the status response and actual invoke + * request) within the timeout window. + * + */ +@property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; +@end +@interface MTRClientMonitoringClusterStayAwakeRequestParams : NSObject +/** + * Controls whether the command is a timed command (using Timed Invoke). + * + * If nil (the default value), a regular invoke is done for commands that do + * not require a timed invoke and a timed invoke with some default timed request + * timeout is done for commands that require a timed invoke. + * + * If not nil, a timed invoke is done, with the provided value used as the timed + * request timeout. The value should be chosen small enough to provide the + * desired security properties but large enough that it will allow a round-trip + * from the sever to the client (for the status response and actual invoke + * request) within the timeout window. + * + */ +@property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; @end MTR_NEWLY_AVAILABLE @interface MTRUnitTestingClusterTestParams : NSObject @@ -5257,9 +4707,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestParams") @@ -5286,9 +4733,6 @@ MTR_NEWLY_AVAILABLE */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestSpecificResponseParams") @@ -5312,9 +4756,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestNotHandledParams") @@ -5341,9 +4782,6 @@ MTR_NEWLY_AVAILABLE */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestAddArgumentsResponseParams") @@ -5367,9 +4805,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestSpecificParams") @@ -5396,9 +4831,6 @@ MTR_NEWLY_AVAILABLE */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestSimpleArgumentResponseParams") @@ -5422,9 +4854,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestUnknownCommandParams") @@ -5461,9 +4890,6 @@ MTR_NEWLY_AVAILABLE */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestStructArrayArgumentResponseParams") @@ -5491,9 +4917,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestAddArgumentsParams") @@ -5520,9 +4943,6 @@ MTR_NEWLY_AVAILABLE */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestListInt8UReverseResponseParams") @@ -5548,9 +4968,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestSimpleArgumentRequestParams") @@ -5579,9 +4996,6 @@ MTR_NEWLY_AVAILABLE */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestEnumsResponseParams") @@ -5617,9 +5031,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestStructArrayArgumentRequestParams") @@ -5652,9 +5063,6 @@ MTR_NEWLY_AVAILABLE */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestNullableOptionalResponseParams") @@ -5680,9 +5088,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestStructArgumentRequestParams") @@ -5763,9 +5168,6 @@ MTR_NEWLY_AVAILABLE */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestComplexNullableOptionalResponseParams") @@ -5792,9 +5194,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestNestedStructArgumentRequestParams") @@ -5821,9 +5220,6 @@ MTR_NEWLY_AVAILABLE */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterBooleanResponseParams") @@ -5849,9 +5245,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestListStructArgumentRequestParams") @@ -5878,9 +5271,6 @@ MTR_NEWLY_AVAILABLE */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterSimpleStructResponseParams") @@ -5906,9 +5296,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestListInt8UArgumentRequestParams") @@ -5935,9 +5322,6 @@ MTR_NEWLY_AVAILABLE */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestEmitTestEventResponseParams") @@ -5963,9 +5347,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestNestedStructListArgumentRequestParams") @@ -5993,9 +5374,6 @@ MTR_NEWLY_AVAILABLE */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs MTR_NEWLY_DEPRECATED("Timed invoke does not make sense for server to client commands"); - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestEmitTestFabricScopedEventResponseParams") @@ -6022,9 +5400,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestListNestedStructListArgumentRequestParams") @@ -6051,9 +5426,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestListInt8UReverseRequestParams") @@ -6081,9 +5453,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestEnumsRequestParams") @@ -6109,9 +5478,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestNullableOptionalRequestParams") @@ -6159,9 +5525,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestComplexNullableOptionalRequestParams") @@ -6188,9 +5551,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterSimpleStructEchoRequestParams") @@ -6214,9 +5574,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTimedInvokeRequestParams") @@ -6242,9 +5599,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestSimpleOptionalArgumentRequestParams") @@ -6275,9 +5629,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestEmitTestEventRequestParams") @@ -6303,9 +5654,6 @@ MTR_NEWLY_AVAILABLE * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestEmitTestFabricScopedEventRequestParams") @@ -6339,9 +5687,6 @@ MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestEmitTestFabricScopedEv * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRFaultInjectionClusterFailRandomlyAtFaultParams : NSObject @@ -6365,9 +5710,6 @@ MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestEmitTestFabricScopedEv * */ @property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end NS_ASSUME_NONNULL_END diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.mm b/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.mm index 1206aaf5efbbda..0f925b15110406 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.mm +++ b/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.mm @@ -1985,7 +1985,7 @@ - (NSString *)description } @end -@implementation MTROtaSoftwareUpdateProviderClusterQueryImageParams +@implementation MTROTASoftwareUpdateProviderClusterQueryImageParams - (instancetype)init { if (self = [super init]) { @@ -2012,7 +2012,7 @@ - (instancetype)init - (id)copyWithZone:(NSZone * _Nullable)zone; { - auto other = [[MTROtaSoftwareUpdateProviderClusterQueryImageParams alloc] init]; + auto other = [[MTROTASoftwareUpdateProviderClusterQueryImageParams alloc] init]; other.vendorId = self.vendorId; other.productId = self.productId; @@ -2038,7 +2038,10 @@ - (NSString *)description } @end -@implementation MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams + +@implementation MTROtaSoftwareUpdateProviderClusterQueryImageParams +@end +@implementation MTROTASoftwareUpdateProviderClusterQueryImageResponseParams - (instancetype)init { if (self = [super init]) { @@ -2065,7 +2068,7 @@ - (instancetype)init - (id)copyWithZone:(NSZone * _Nullable)zone; { - auto other = [[MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams alloc] init]; + auto other = [[MTROTASoftwareUpdateProviderClusterQueryImageResponseParams alloc] init]; other.status = self.status; other.delayedActionTime = self.delayedActionTime; @@ -2092,7 +2095,10 @@ - (NSString *)description } @end -@implementation MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams + +@implementation MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams +@end +@implementation MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams - (instancetype)init { if (self = [super init]) { @@ -2107,7 +2113,7 @@ - (instancetype)init - (id)copyWithZone:(NSZone * _Nullable)zone; { - auto other = [[MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams alloc] init]; + auto other = [[MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams alloc] init]; other.updateToken = self.updateToken; other.newVersion = self.newVersion; @@ -2125,7 +2131,10 @@ - (NSString *)description } @end -@implementation MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams + +@implementation MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams +@end +@implementation MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams - (instancetype)init { if (self = [super init]) { @@ -2140,7 +2149,7 @@ - (instancetype)init - (id)copyWithZone:(NSZone * _Nullable)zone; { - auto other = [[MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams alloc] init]; + auto other = [[MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams alloc] init]; other.action = self.action; other.delayedActionTime = self.delayedActionTime; @@ -2157,7 +2166,10 @@ - (NSString *)description } @end -@implementation MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams + +@implementation MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams +@end +@implementation MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams - (instancetype)init { if (self = [super init]) { @@ -2172,7 +2184,7 @@ - (instancetype)init - (id)copyWithZone:(NSZone * _Nullable)zone; { - auto other = [[MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams alloc] init]; + auto other = [[MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams alloc] init]; other.updateToken = self.updateToken; other.softwareVersion = self.softwareVersion; @@ -2190,7 +2202,10 @@ - (NSString *)description } @end -@implementation MTROtaSoftwareUpdateRequestorClusterAnnounceOtaProviderParams + +@implementation MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams +@end +@implementation MTROTASoftwareUpdateRequestorClusterAnnounceOtaProviderParams - (instancetype)init { if (self = [super init]) { @@ -2211,7 +2226,7 @@ - (instancetype)init - (id)copyWithZone:(NSZone * _Nullable)zone; { - auto other = [[MTROtaSoftwareUpdateRequestorClusterAnnounceOtaProviderParams alloc] init]; + auto other = [[MTROTASoftwareUpdateRequestorClusterAnnounceOtaProviderParams alloc] init]; other.providerNodeId = self.providerNodeId; other.vendorId = self.vendorId; @@ -2232,6 +2247,9 @@ - (NSString *)description return descriptionString; } +@end + +@implementation MTROtaSoftwareUpdateRequestorClusterAnnounceOtaProviderParams @end @implementation MTRGeneralCommissioningClusterArmFailSafeParams - (instancetype)init @@ -6977,6 +6995,63 @@ - (NSString *)description return descriptionString; } +@end +@implementation MTRClientMonitoringClusterRegisterClientMonitoringParams +- (instancetype)init +{ + if (self = [super init]) { + + _clientNodeId = @(0); + + _iCid = @(0); + _timedInvokeTimeoutMs = nil; + } + return self; +} + +- (id)copyWithZone:(NSZone * _Nullable)zone; +{ + auto other = [[MTRClientMonitoringClusterRegisterClientMonitoringParams alloc] init]; + + other.clientNodeId = self.clientNodeId; + other.iCid = self.iCid; + other.timedInvokeTimeoutMs = self.timedInvokeTimeoutMs; + + return other; +} + +- (NSString *)description +{ + NSString * descriptionString = + [NSString stringWithFormat:@"<%@: clientNodeId:%@; iCid:%@; >", NSStringFromClass([self class]), _clientNodeId, _iCid]; + return descriptionString; +} + +@end +@implementation MTRClientMonitoringClusterStayAwakeRequestParams +- (instancetype)init +{ + if (self = [super init]) { + _timedInvokeTimeoutMs = nil; + } + return self; +} + +- (id)copyWithZone:(NSZone * _Nullable)zone; +{ + auto other = [[MTRClientMonitoringClusterStayAwakeRequestParams alloc] init]; + + other.timedInvokeTimeoutMs = self.timedInvokeTimeoutMs; + + return other; +} + +- (NSString *)description +{ + NSString * descriptionString = [NSString stringWithFormat:@"<%@: >", NSStringFromClass([self class])]; + return descriptionString; +} + @end @implementation MTRUnitTestingClusterTestParams - (instancetype)init diff --git a/src/darwin/Framework/CHIP/zap-generated/MTREventTLVValueDecoder.mm b/src/darwin/Framework/CHIP/zap-generated/MTREventTLVValueDecoder.mm index 52fe36a5c035c6..165f07adbea315 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTREventTLVValueDecoder.mm +++ b/src/darwin/Framework/CHIP/zap-generated/MTREventTLVValueDecoder.mm @@ -136,8 +136,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRAccessControlClusterAccessControlEntryChangedEvent * value = - [MTRAccessControlClusterAccessControlEntryChangedEvent new]; + __auto_type * value = [MTRAccessControlClusterAccessControlEntryChangedEvent new]; do { NSNumber * _Nullable memberValue; @@ -247,8 +246,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRAccessControlClusterAccessControlExtensionChangedEvent * value = - [MTRAccessControlClusterAccessControlExtensionChangedEvent new]; + __auto_type * value = [MTRAccessControlClusterAccessControlExtensionChangedEvent new]; do { NSNumber * _Nullable memberValue; @@ -311,7 +309,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRActionsClusterStateChangedEvent * value = [MTRActionsClusterStateChangedEvent new]; + __auto_type * value = [MTRActionsClusterStateChangedEvent new]; do { NSNumber * _Nonnull memberValue; @@ -339,7 +337,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRActionsClusterActionFailedEvent * value = [MTRActionsClusterActionFailedEvent new]; + __auto_type * value = [MTRActionsClusterActionFailedEvent new]; do { NSNumber * _Nonnull memberValue; @@ -382,7 +380,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRBasicClusterStartUpEvent * value = [MTRBasicClusterStartUpEvent new]; + __auto_type * value = [MTRBasicClusterStartUpEvent new]; do { NSNumber * _Nonnull memberValue; @@ -400,7 +398,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRBasicClusterShutDownEvent * value = [MTRBasicClusterShutDownEvent new]; + __auto_type * value = [MTRBasicClusterShutDownEvent new]; return value; } @@ -412,7 +410,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRBasicClusterLeaveEvent * value = [MTRBasicClusterLeaveEvent new]; + __auto_type * value = [MTRBasicClusterLeaveEvent new]; do { NSNumber * _Nonnull memberValue; @@ -430,7 +428,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRBasicClusterReachableChangedEvent * value = [MTRBasicClusterReachableChangedEvent new]; + __auto_type * value = [MTRBasicClusterReachableChangedEvent new]; do { NSNumber * _Nonnull memberValue; @@ -468,8 +466,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTROtaSoftwareUpdateRequestorClusterStateTransitionEvent * value = - [MTROtaSoftwareUpdateRequestorClusterStateTransitionEvent new]; + __auto_type * value = [MTROTASoftwareUpdateRequestorClusterStateTransitionEvent new]; do { NSNumber * _Nonnull memberValue; @@ -506,8 +503,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTROtaSoftwareUpdateRequestorClusterVersionAppliedEvent * value = - [MTROtaSoftwareUpdateRequestorClusterVersionAppliedEvent new]; + __auto_type * value = [MTROTASoftwareUpdateRequestorClusterVersionAppliedEvent new]; do { NSNumber * _Nonnull memberValue; @@ -530,8 +526,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTROtaSoftwareUpdateRequestorClusterDownloadErrorEvent * value = - [MTROtaSoftwareUpdateRequestorClusterDownloadErrorEvent new]; + __auto_type * value = [MTROTASoftwareUpdateRequestorClusterDownloadErrorEvent new]; do { NSNumber * _Nonnull memberValue; @@ -662,8 +657,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRGeneralDiagnosticsClusterHardwareFaultChangeEvent * value = - [MTRGeneralDiagnosticsClusterHardwareFaultChangeEvent new]; + __auto_type * value = [MTRGeneralDiagnosticsClusterHardwareFaultChangeEvent new]; do { NSArray * _Nonnull memberValue; @@ -716,7 +710,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRGeneralDiagnosticsClusterRadioFaultChangeEvent * value = [MTRGeneralDiagnosticsClusterRadioFaultChangeEvent new]; + __auto_type * value = [MTRGeneralDiagnosticsClusterRadioFaultChangeEvent new]; do { NSArray * _Nonnull memberValue; @@ -769,7 +763,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRGeneralDiagnosticsClusterNetworkFaultChangeEvent * value = [MTRGeneralDiagnosticsClusterNetworkFaultChangeEvent new]; + __auto_type * value = [MTRGeneralDiagnosticsClusterNetworkFaultChangeEvent new]; do { NSArray * _Nonnull memberValue; @@ -822,7 +816,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRGeneralDiagnosticsClusterBootReasonEvent * value = [MTRGeneralDiagnosticsClusterBootReasonEvent new]; + __auto_type * value = [MTRGeneralDiagnosticsClusterBootReasonEvent new]; do { NSNumber * _Nonnull memberValue; @@ -850,7 +844,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRSoftwareDiagnosticsClusterSoftwareFaultEvent * value = [MTRSoftwareDiagnosticsClusterSoftwareFaultEvent new]; + __auto_type * value = [MTRSoftwareDiagnosticsClusterSoftwareFaultEvent new]; do { NSNumber * _Nonnull memberValue; @@ -899,8 +893,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRThreadNetworkDiagnosticsClusterConnectionStatusEvent * value = - [MTRThreadNetworkDiagnosticsClusterConnectionStatusEvent new]; + __auto_type * value = [MTRThreadNetworkDiagnosticsClusterConnectionStatusEvent new]; do { NSNumber * _Nonnull memberValue; @@ -918,8 +911,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRThreadNetworkDiagnosticsClusterNetworkFaultChangeEvent * value = - [MTRThreadNetworkDiagnosticsClusterNetworkFaultChangeEvent new]; + __auto_type * value = [MTRThreadNetworkDiagnosticsClusterNetworkFaultChangeEvent new]; do { NSArray * _Nonnull memberValue; @@ -982,7 +974,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRWiFiNetworkDiagnosticsClusterDisconnectionEvent * value = [MTRWiFiNetworkDiagnosticsClusterDisconnectionEvent new]; + __auto_type * value = [MTRWiFiNetworkDiagnosticsClusterDisconnectionEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1000,8 +992,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRWiFiNetworkDiagnosticsClusterAssociationFailureEvent * value = - [MTRWiFiNetworkDiagnosticsClusterAssociationFailureEvent new]; + __auto_type * value = [MTRWiFiNetworkDiagnosticsClusterAssociationFailureEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1024,8 +1015,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRWiFiNetworkDiagnosticsClusterConnectionStatusEvent * value = - [MTRWiFiNetworkDiagnosticsClusterConnectionStatusEvent new]; + __auto_type * value = [MTRWiFiNetworkDiagnosticsClusterConnectionStatusEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1063,7 +1053,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRBridgedDeviceBasicClusterStartUpEvent * value = [MTRBridgedDeviceBasicClusterStartUpEvent new]; + __auto_type * value = [MTRBridgedDeviceBasicClusterStartUpEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1081,7 +1071,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRBridgedDeviceBasicClusterShutDownEvent * value = [MTRBridgedDeviceBasicClusterShutDownEvent new]; + __auto_type * value = [MTRBridgedDeviceBasicClusterShutDownEvent new]; return value; } @@ -1093,7 +1083,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRBridgedDeviceBasicClusterLeaveEvent * value = [MTRBridgedDeviceBasicClusterLeaveEvent new]; + __auto_type * value = [MTRBridgedDeviceBasicClusterLeaveEvent new]; return value; } @@ -1105,7 +1095,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRBridgedDeviceBasicClusterReachableChangedEvent * value = [MTRBridgedDeviceBasicClusterReachableChangedEvent new]; + __auto_type * value = [MTRBridgedDeviceBasicClusterReachableChangedEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1133,7 +1123,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRSwitchClusterSwitchLatchedEvent * value = [MTRSwitchClusterSwitchLatchedEvent new]; + __auto_type * value = [MTRSwitchClusterSwitchLatchedEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1151,7 +1141,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRSwitchClusterInitialPressEvent * value = [MTRSwitchClusterInitialPressEvent new]; + __auto_type * value = [MTRSwitchClusterInitialPressEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1169,7 +1159,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRSwitchClusterLongPressEvent * value = [MTRSwitchClusterLongPressEvent new]; + __auto_type * value = [MTRSwitchClusterLongPressEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1187,7 +1177,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRSwitchClusterShortReleaseEvent * value = [MTRSwitchClusterShortReleaseEvent new]; + __auto_type * value = [MTRSwitchClusterShortReleaseEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1205,7 +1195,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRSwitchClusterLongReleaseEvent * value = [MTRSwitchClusterLongReleaseEvent new]; + __auto_type * value = [MTRSwitchClusterLongReleaseEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1223,7 +1213,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRSwitchClusterMultiPressOngoingEvent * value = [MTRSwitchClusterMultiPressOngoingEvent new]; + __auto_type * value = [MTRSwitchClusterMultiPressOngoingEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1246,12 +1236,12 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRSwitchClusterMultiPressCompleteEvent * value = [MTRSwitchClusterMultiPressCompleteEvent new]; + __auto_type * value = [MTRSwitchClusterMultiPressCompleteEvent new]; do { NSNumber * _Nonnull memberValue; - memberValue = [NSNumber numberWithUnsignedChar:cppValue.newPosition]; - value.newPosition = memberValue; + memberValue = [NSNumber numberWithUnsignedChar:cppValue.previousPosition]; + value.previousPosition = memberValue; } while (0); do { NSNumber * _Nonnull memberValue; @@ -1329,7 +1319,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRBooleanStateClusterStateChangeEvent * value = [MTRBooleanStateClusterStateChangeEvent new]; + __auto_type * value = [MTRBooleanStateClusterStateChangeEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1367,7 +1357,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRDoorLockClusterDoorLockAlarmEvent * value = [MTRDoorLockClusterDoorLockAlarmEvent new]; + __auto_type * value = [MTRDoorLockClusterDoorLockAlarmEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1385,7 +1375,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRDoorLockClusterDoorStateChangeEvent * value = [MTRDoorLockClusterDoorStateChangeEvent new]; + __auto_type * value = [MTRDoorLockClusterDoorStateChangeEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1403,7 +1393,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRDoorLockClusterLockOperationEvent * value = [MTRDoorLockClusterLockOperationEvent new]; + __auto_type * value = [MTRDoorLockClusterLockOperationEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1484,7 +1474,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRDoorLockClusterLockOperationErrorEvent * value = [MTRDoorLockClusterLockOperationErrorEvent new]; + __auto_type * value = [MTRDoorLockClusterLockOperationErrorEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1570,7 +1560,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRDoorLockClusterLockUserChangeEvent * value = [MTRDoorLockClusterLockUserChangeEvent new]; + __auto_type * value = [MTRDoorLockClusterLockUserChangeEvent new]; do { NSNumber * _Nonnull memberValue; @@ -1664,8 +1654,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterSupplyVoltageLowEvent * value = - [MTRPumpConfigurationAndControlClusterSupplyVoltageLowEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterSupplyVoltageLowEvent new]; return value; } @@ -1677,8 +1666,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterSupplyVoltageHighEvent * value = - [MTRPumpConfigurationAndControlClusterSupplyVoltageHighEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterSupplyVoltageHighEvent new]; return value; } @@ -1690,8 +1678,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterPowerMissingPhaseEvent * value = - [MTRPumpConfigurationAndControlClusterPowerMissingPhaseEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterPowerMissingPhaseEvent new]; return value; } @@ -1703,8 +1690,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterSystemPressureLowEvent * value = - [MTRPumpConfigurationAndControlClusterSystemPressureLowEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterSystemPressureLowEvent new]; return value; } @@ -1716,8 +1702,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterSystemPressureHighEvent * value = - [MTRPumpConfigurationAndControlClusterSystemPressureHighEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterSystemPressureHighEvent new]; return value; } @@ -1729,8 +1714,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterDryRunningEvent * value = - [MTRPumpConfigurationAndControlClusterDryRunningEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterDryRunningEvent new]; return value; } @@ -1742,8 +1726,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterMotorTemperatureHighEvent * value = - [MTRPumpConfigurationAndControlClusterMotorTemperatureHighEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterMotorTemperatureHighEvent new]; return value; } @@ -1755,8 +1738,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterPumpMotorFatalFailureEvent * value = - [MTRPumpConfigurationAndControlClusterPumpMotorFatalFailureEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterPumpMotorFatalFailureEvent new]; return value; } @@ -1768,8 +1750,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterElectronicTemperatureHighEvent * value = - [MTRPumpConfigurationAndControlClusterElectronicTemperatureHighEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterElectronicTemperatureHighEvent new]; return value; } @@ -1781,8 +1762,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterPumpBlockedEvent * value = - [MTRPumpConfigurationAndControlClusterPumpBlockedEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterPumpBlockedEvent new]; return value; } @@ -1794,8 +1774,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterSensorFailureEvent * value = - [MTRPumpConfigurationAndControlClusterSensorFailureEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterSensorFailureEvent new]; return value; } @@ -1807,8 +1786,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterElectronicNonFatalFailureEvent * value = - [MTRPumpConfigurationAndControlClusterElectronicNonFatalFailureEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterElectronicNonFatalFailureEvent new]; return value; } @@ -1820,8 +1798,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterElectronicFatalFailureEvent * value = - [MTRPumpConfigurationAndControlClusterElectronicFatalFailureEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterElectronicFatalFailureEvent new]; return value; } @@ -1833,8 +1810,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterGeneralFaultEvent * value = - [MTRPumpConfigurationAndControlClusterGeneralFaultEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterGeneralFaultEvent new]; return value; } @@ -1846,7 +1822,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterLeakageEvent * value = [MTRPumpConfigurationAndControlClusterLeakageEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterLeakageEvent new]; return value; } @@ -1858,8 +1834,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterAirDetectionEvent * value = - [MTRPumpConfigurationAndControlClusterAirDetectionEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterAirDetectionEvent new]; return value; } @@ -1871,8 +1846,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRPumpConfigurationAndControlClusterTurbineOperationEvent * value = - [MTRPumpConfigurationAndControlClusterTurbineOperationEvent new]; + __auto_type * value = [MTRPumpConfigurationAndControlClusterTurbineOperationEvent new]; return value; } @@ -2134,7 +2108,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRUnitTestingClusterTestEventEvent * value = [MTRUnitTestingClusterTestEventEvent new]; + __auto_type * value = [MTRUnitTestingClusterTestEventEvent new]; do { NSNumber * _Nonnull memberValue; @@ -2227,7 +2201,7 @@ id MTRDecodeEventPayload(const ConcreteEventPath & aPath, TLV::TLVReader & aRead return nil; } - MTRUnitTestingClusterTestFabricScopedEventEvent * value = [MTRUnitTestingClusterTestFabricScopedEventEvent new]; + __auto_type * value = [MTRUnitTestingClusterTestFabricScopedEventEvent new]; do { NSNumber * _Nonnull memberValue; diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRStructsObjc.h b/src/darwin/Framework/CHIP/zap-generated/MTRStructsObjc.h index 9d1a2aab2e3d41..397f744a2b7852 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRStructsObjc.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRStructsObjc.h @@ -22,34 +22,22 @@ NS_ASSUME_NONNULL_BEGIN @interface MTRScenesClusterAttributeValuePair : NSObject @property (nonatomic, copy) NSNumber * _Nullable attributeId; @property (nonatomic, copy) NSArray * _Nonnull attributeValue; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRScenesClusterExtensionFieldSet : NSObject @property (nonatomic, copy) NSNumber * _Nonnull clusterId; @property (nonatomic, copy) NSArray * _Nonnull attributeValueList; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @interface MTRDescriptorClusterDeviceTypeStruct : NSObject @property (nonatomic, copy) NSNumber * _Nonnull type; @property (nonatomic, copy) NSNumber * _Nonnull revision; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDescriptorClusterDeviceType : NSObject @property (nonatomic, copy) NSNumber * _Nonnull type; @property (nonatomic, copy) NSNumber * _Nonnull revision; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRBindingClusterTargetStruct : NSObject @@ -58,18 +46,12 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nullable endpoint; @property (nonatomic, copy) NSNumber * _Nullable cluster; @property (nonatomic, copy) NSNumber * _Nonnull fabricIndex; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRAccessControlClusterTarget : NSObject @property (nonatomic, copy) NSNumber * _Nullable cluster; @property (nonatomic, copy) NSNumber * _Nullable endpoint; @property (nonatomic, copy) NSNumber * _Nullable deviceType; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRAccessControlClusterAccessControlEntry : NSObject @@ -78,17 +60,11 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSArray * _Nullable subjects; @property (nonatomic, copy) NSArray * _Nullable targets; @property (nonatomic, copy) NSNumber * _Nonnull fabricIndex; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRAccessControlClusterExtensionEntry : NSObject @property (nonatomic, copy) NSData * _Nonnull data; @property (nonatomic, copy) NSNumber * _Nonnull fabricIndex; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRAccessControlClusterAccessControlEntryChangedEvent : NSObject @@ -97,9 +73,6 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nonnull changeType; @property (nonatomic, copy) MTRAccessControlClusterAccessControlEntry * _Nullable latestValue; @property (nonatomic, copy) NSNumber * _Nonnull fabricIndex; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRAccessControlClusterAccessControlExtensionChangedEvent : NSObject @@ -108,9 +81,6 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nonnull changeType; @property (nonatomic, copy) MTRAccessControlClusterExtensionEntry * _Nullable latestValue; @property (nonatomic, copy) NSNumber * _Nonnull fabricIndex; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterActionStruct : NSObject @@ -120,9 +90,6 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nonnull endpointListID; @property (nonatomic, copy) NSNumber * _Nonnull supportedCommands; @property (nonatomic, copy) NSNumber * _Nonnull state; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterEndpointListStruct : NSObject @@ -130,18 +97,12 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSString * _Nonnull name; @property (nonatomic, copy) NSNumber * _Nonnull type; @property (nonatomic, copy) NSArray * _Nonnull endpoints; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterStateChangedEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull actionID; @property (nonatomic, copy) NSNumber * _Nonnull invokeID; @property (nonatomic, copy, getter=getNewState) NSNumber * _Nonnull newState; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRActionsClusterActionFailedEvent : NSObject @@ -149,121 +110,96 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nonnull invokeID; @property (nonatomic, copy, getter=getNewState) NSNumber * _Nonnull newState; @property (nonatomic, copy) NSNumber * _Nonnull error; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRBasicClusterCapabilityMinimaStruct : NSObject @property (nonatomic, copy) NSNumber * _Nonnull caseSessionsPerFabric; @property (nonatomic, copy) NSNumber * _Nonnull subscriptionsPerFabric; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRBasicClusterStartUpEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull softwareVersion; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRBasicClusterShutDownEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRBasicClusterLeaveEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull fabricIndex; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRBasicClusterReachableChangedEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull reachableNewValue; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end -@interface MTROtaSoftwareUpdateRequestorClusterProviderLocation : NSObject +MTR_NEWLY_AVAILABLE +@interface MTROTASoftwareUpdateRequestorClusterProviderLocation : NSObject @property (nonatomic, copy) NSNumber * _Nonnull providerNodeID; @property (nonatomic, copy) NSNumber * _Nonnull endpoint; @property (nonatomic, copy) NSNumber * _Nonnull fabricIndex; +@end -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; +MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateRequestorClusterProviderLocation") +@interface MTROtaSoftwareUpdateRequestorClusterProviderLocation : MTROTASoftwareUpdateRequestorClusterProviderLocation @end -@interface MTROtaSoftwareUpdateRequestorClusterStateTransitionEvent : NSObject +MTR_NEWLY_AVAILABLE +@interface MTROTASoftwareUpdateRequestorClusterStateTransitionEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull previousState; @property (nonatomic, copy, getter=getNewState) NSNumber * _Nonnull newState; @property (nonatomic, copy) NSNumber * _Nonnull reason; @property (nonatomic, copy) NSNumber * _Nullable targetSoftwareVersion; +@end -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; +MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateRequestorClusterStateTransitionEvent") +@interface MTROtaSoftwareUpdateRequestorClusterStateTransitionEvent : MTROTASoftwareUpdateRequestorClusterStateTransitionEvent @end -@interface MTROtaSoftwareUpdateRequestorClusterVersionAppliedEvent : NSObject +MTR_NEWLY_AVAILABLE +@interface MTROTASoftwareUpdateRequestorClusterVersionAppliedEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull softwareVersion; @property (nonatomic, copy) NSNumber * _Nonnull productID; +@end -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; +MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateRequestorClusterVersionAppliedEvent") +@interface MTROtaSoftwareUpdateRequestorClusterVersionAppliedEvent : MTROTASoftwareUpdateRequestorClusterVersionAppliedEvent @end -@interface MTROtaSoftwareUpdateRequestorClusterDownloadErrorEvent : NSObject +MTR_NEWLY_AVAILABLE +@interface MTROTASoftwareUpdateRequestorClusterDownloadErrorEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull softwareVersion; @property (nonatomic, copy) NSNumber * _Nonnull bytesDownloaded; @property (nonatomic, copy) NSNumber * _Nullable progressPercent; @property (nonatomic, copy) NSNumber * _Nullable platformCode; +@end -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; +MTR_NEWLY_DEPRECATED("Please use MTROTASoftwareUpdateRequestorClusterDownloadErrorEvent") +@interface MTROtaSoftwareUpdateRequestorClusterDownloadErrorEvent : MTROTASoftwareUpdateRequestorClusterDownloadErrorEvent @end @interface MTRPowerSourceClusterBatChargeFaultChangeType : NSObject @property (nonatomic, copy) NSArray * _Nonnull current; @property (nonatomic, copy) NSArray * _Nonnull previous; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPowerSourceClusterBatFaultChangeType : NSObject @property (nonatomic, copy) NSArray * _Nonnull current; @property (nonatomic, copy) NSArray * _Nonnull previous; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPowerSourceClusterWiredFaultChangeType : NSObject @property (nonatomic, copy) NSArray * _Nonnull current; @property (nonatomic, copy) NSArray * _Nonnull previous; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGeneralCommissioningClusterBasicCommissioningInfo : NSObject @property (nonatomic, copy) NSNumber * _Nonnull failSafeExpiryLengthSeconds; @property (nonatomic, copy) NSNumber * _Nonnull maxCumulativeFailsafeSeconds; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRNetworkCommissioningClusterNetworkInfo : NSObject @property (nonatomic, copy) NSData * _Nonnull networkID; @property (nonatomic, copy) NSNumber * _Nonnull connected; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRNetworkCommissioningClusterThreadInterfaceScanResult : NSObject @@ -275,9 +211,6 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSData * _Nonnull extendedAddress; @property (nonatomic, copy) NSNumber * _Nonnull rssi; @property (nonatomic, copy) NSNumber * _Nonnull lqi; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRNetworkCommissioningClusterWiFiInterfaceScanResult : NSObject @@ -287,9 +220,6 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nonnull channel; @property (nonatomic, copy) NSNumber * _Nonnull wiFiBand; @property (nonatomic, copy) NSNumber * _Nonnull rssi; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGeneralDiagnosticsClusterNetworkInterfaceType : NSObject @@ -301,40 +231,25 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSArray * _Nonnull iPv4Addresses; @property (nonatomic, copy) NSArray * _Nonnull iPv6Addresses; @property (nonatomic, copy) NSNumber * _Nonnull type; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGeneralDiagnosticsClusterHardwareFaultChangeEvent : NSObject @property (nonatomic, copy) NSArray * _Nonnull current; @property (nonatomic, copy) NSArray * _Nonnull previous; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGeneralDiagnosticsClusterRadioFaultChangeEvent : NSObject @property (nonatomic, copy) NSArray * _Nonnull current; @property (nonatomic, copy) NSArray * _Nonnull previous; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGeneralDiagnosticsClusterNetworkFaultChangeEvent : NSObject @property (nonatomic, copy) NSArray * _Nonnull current; @property (nonatomic, copy) NSArray * _Nonnull previous; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGeneralDiagnosticsClusterBootReasonEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull bootReason; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRSoftwareDiagnosticsClusterThreadMetrics : NSObject @@ -343,18 +258,12 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nullable stackFreeCurrent; @property (nonatomic, copy) NSNumber * _Nullable stackFreeMinimum; @property (nonatomic, copy) NSNumber * _Nullable stackSize; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRSoftwareDiagnosticsClusterSoftwareFaultEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull id; @property (nonatomic, copy) NSString * _Nullable name; @property (nonatomic, copy) NSData * _Nullable faultRecording; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRThreadNetworkDiagnosticsClusterNeighborTable : NSObject @@ -372,9 +281,6 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nonnull fullThreadDevice; @property (nonatomic, copy) NSNumber * _Nonnull fullNetworkData; @property (nonatomic, copy) NSNumber * _Nonnull isChild; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRThreadNetworkDiagnosticsClusterOperationalDatasetComponents : NSObject @@ -390,9 +296,6 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nonnull pskcPresent; @property (nonatomic, copy) NSNumber * _Nonnull securityPolicyPresent; @property (nonatomic, copy) NSNumber * _Nonnull channelMaskPresent; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRThreadNetworkDiagnosticsClusterRouteTable : NSObject @@ -406,149 +309,90 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nonnull age; @property (nonatomic, copy) NSNumber * _Nonnull allocated; @property (nonatomic, copy) NSNumber * _Nonnull linkEstablished; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRThreadNetworkDiagnosticsClusterSecurityPolicy : NSObject @property (nonatomic, copy) NSNumber * _Nonnull rotationTime; @property (nonatomic, copy) NSNumber * _Nonnull flags; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRThreadNetworkDiagnosticsClusterConnectionStatusEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull connectionStatus; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRThreadNetworkDiagnosticsClusterNetworkFaultChangeEvent : NSObject @property (nonatomic, copy) NSArray * _Nonnull current; @property (nonatomic, copy) NSArray * _Nonnull previous; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRWiFiNetworkDiagnosticsClusterDisconnectionEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull reasonCode; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRWiFiNetworkDiagnosticsClusterAssociationFailureEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull associationFailure; @property (nonatomic, copy) NSNumber * _Nonnull status; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRWiFiNetworkDiagnosticsClusterConnectionStatusEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull connectionStatus; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRTimeSynchronizationClusterDstOffsetType : NSObject @property (nonatomic, copy) NSNumber * _Nonnull offset; @property (nonatomic, copy) NSNumber * _Nonnull validStarting; @property (nonatomic, copy) NSNumber * _Nonnull validUntil; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRTimeSynchronizationClusterTimeZoneType : NSObject @property (nonatomic, copy) NSNumber * _Nonnull offset; @property (nonatomic, copy) NSNumber * _Nonnull validAt; @property (nonatomic, copy) NSString * _Nullable name; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRBridgedDeviceBasicClusterStartUpEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull softwareVersion; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRBridgedDeviceBasicClusterShutDownEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRBridgedDeviceBasicClusterLeaveEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRBridgedDeviceBasicClusterReachableChangedEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull reachableNewValue; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRSwitchClusterSwitchLatchedEvent : NSObject @property (nonatomic, copy, getter=getNewPosition) NSNumber * _Nonnull newPosition; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRSwitchClusterInitialPressEvent : NSObject @property (nonatomic, copy, getter=getNewPosition) NSNumber * _Nonnull newPosition; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRSwitchClusterLongPressEvent : NSObject @property (nonatomic, copy, getter=getNewPosition) NSNumber * _Nonnull newPosition; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRSwitchClusterShortReleaseEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull previousPosition; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRSwitchClusterLongReleaseEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull previousPosition; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRSwitchClusterMultiPressOngoingEvent : NSObject @property (nonatomic, copy, getter=getNewPosition) NSNumber * _Nonnull newPosition; @property (nonatomic, copy) NSNumber * _Nonnull currentNumberOfPressesCounted; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRSwitchClusterMultiPressCompleteEvent : NSObject -@property (nonatomic, copy, getter=getNewPosition) NSNumber * _Nonnull newPosition; +@property (nonatomic, copy) NSNumber * _Nonnull previousPosition MTR_NEWLY_AVAILABLE; +@property (nonatomic, copy) NSNumber * _Nonnull newPosition MTR_NEWLY_DEPRECATED("Please use previousPosition"); @property (nonatomic, copy) NSNumber * _Nonnull totalNumberOfPressesCounted; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROperationalCredentialsClusterFabricDescriptor : NSObject @@ -558,18 +402,12 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nonnull nodeId; @property (nonatomic, copy) NSString * _Nonnull label; @property (nonatomic, copy) NSNumber * _Nonnull fabricIndex; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTROperationalCredentialsClusterNOCStruct : NSObject @property (nonatomic, copy) NSData * _Nonnull noc; @property (nonatomic, copy) NSData * _Nullable icac; @property (nonatomic, copy) NSNumber * _Nonnull fabricIndex; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupKeyManagementClusterGroupInfoMapStruct : NSObject @@ -577,18 +415,12 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSArray * _Nonnull endpoints; @property (nonatomic, copy) NSString * _Nullable groupName; @property (nonatomic, copy) NSNumber * _Nonnull fabricIndex; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupKeyManagementClusterGroupKeyMapStruct : NSObject @property (nonatomic, copy) NSNumber * _Nonnull groupId; @property (nonatomic, copy) NSNumber * _Nonnull groupKeySetID; @property (nonatomic, copy) NSNumber * _Nonnull fabricIndex; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRGroupKeyManagementClusterGroupKeySetStruct : NSObject @@ -600,71 +432,44 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nullable epochStartTime1; @property (nonatomic, copy) NSData * _Nullable epochKey2; @property (nonatomic, copy) NSNumber * _Nullable epochStartTime2; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRFixedLabelClusterLabelStruct : NSObject @property (nonatomic, copy) NSString * _Nonnull label; @property (nonatomic, copy) NSString * _Nonnull value; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRUserLabelClusterLabelStruct : NSObject @property (nonatomic, copy) NSString * _Nonnull label; @property (nonatomic, copy) NSString * _Nonnull value; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRBooleanStateClusterStateChangeEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull stateValue; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRModeSelectClusterSemanticTag : NSObject @property (nonatomic, copy) NSNumber * _Nonnull mfgCode; @property (nonatomic, copy) NSNumber * _Nonnull value; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRModeSelectClusterModeOptionStruct : NSObject @property (nonatomic, copy) NSString * _Nonnull label; @property (nonatomic, copy) NSNumber * _Nonnull mode; @property (nonatomic, copy) NSArray * _Nonnull semanticTags; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterDlCredential : NSObject @property (nonatomic, copy) NSNumber * _Nonnull credentialType; @property (nonatomic, copy) NSNumber * _Nonnull credentialIndex; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterDoorLockAlarmEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull alarmCode; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterDoorStateChangeEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull doorState; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterLockOperationEvent : NSObject @@ -674,9 +479,6 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nullable fabricIndex; @property (nonatomic, copy) NSNumber * _Nullable sourceNode; @property (nonatomic, copy) NSArray * _Nullable credentials; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterLockOperationErrorEvent : NSObject @@ -687,9 +489,6 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nullable fabricIndex; @property (nonatomic, copy) NSNumber * _Nullable sourceNode; @property (nonatomic, copy) NSArray * _Nullable credentials; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRDoorLockClusterLockUserChangeEvent : NSObject @@ -700,120 +499,63 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nullable fabricIndex; @property (nonatomic, copy) NSNumber * _Nullable sourceNode; @property (nonatomic, copy) NSNumber * _Nullable dataIndex; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterSupplyVoltageLowEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterSupplyVoltageHighEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterPowerMissingPhaseEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterSystemPressureLowEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterSystemPressureHighEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterDryRunningEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterMotorTemperatureHighEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterPumpMotorFatalFailureEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterElectronicTemperatureHighEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterPumpBlockedEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterSensorFailureEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterElectronicNonFatalFailureEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterElectronicFatalFailureEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterGeneralFaultEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterLeakageEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterAirDetectionEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRPumpConfigurationAndControlClusterTurbineOperationEvent : NSObject - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRThermostatClusterThermostatScheduleTransition : NSObject @property (nonatomic, copy) NSNumber * _Nonnull transitionTime; @property (nonatomic, copy) NSNumber * _Nullable heatSetpoint; @property (nonatomic, copy) NSNumber * _Nullable coolSetpoint; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRChannelClusterChannelInfo : NSObject @@ -822,9 +564,6 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSString * _Nullable name; @property (nonatomic, copy) NSString * _Nullable callSign; @property (nonatomic, copy) NSString * _Nullable affiliateCallSign; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRChannelClusterLineupInfo : NSObject @@ -832,25 +571,16 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSString * _Nullable lineupName; @property (nonatomic, copy) NSString * _Nullable postalCode; @property (nonatomic, copy) NSNumber * _Nonnull lineupInfoType; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRTargetNavigatorClusterTargetInfo : NSObject @property (nonatomic, copy) NSNumber * _Nonnull identifier; @property (nonatomic, copy) NSString * _Nonnull name; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaPlaybackClusterPlaybackPosition : NSObject @property (nonatomic, copy) NSNumber * _Nonnull updatedAt; @property (nonatomic, copy) NSNumber * _Nullable position; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRMediaInputClusterInputInfo : NSObject @@ -858,51 +588,33 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) NSNumber * _Nonnull inputType; @property (nonatomic, copy) NSString * _Nonnull name; @property (nonatomic, copy) NSString * _Nonnull descriptionString; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRContentLauncherClusterDimension : NSObject @property (nonatomic, copy) NSNumber * _Nonnull width; @property (nonatomic, copy) NSNumber * _Nonnull height; @property (nonatomic, copy) NSNumber * _Nonnull metric; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRContentLauncherClusterAdditionalInfo : NSObject @property (nonatomic, copy) NSString * _Nonnull name; @property (nonatomic, copy) NSString * _Nonnull value; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRContentLauncherClusterParameter : NSObject @property (nonatomic, copy) NSNumber * _Nonnull type; @property (nonatomic, copy) NSString * _Nonnull value; @property (nonatomic, copy) NSArray * _Nullable externalIDList; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRContentLauncherClusterContentSearch : NSObject @property (nonatomic, copy) NSArray * _Nonnull parameterList; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRContentLauncherClusterStyleInformation : NSObject @property (nonatomic, copy) NSString * _Nullable imageUrl; @property (nonatomic, copy) NSString * _Nullable color; @property (nonatomic, copy) MTRContentLauncherClusterDimension * _Nullable size; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRContentLauncherClusterBrandingInformation : NSObject @@ -912,42 +624,33 @@ API_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) @property (nonatomic, copy) MTRContentLauncherClusterStyleInformation * _Nullable progressBar; @property (nonatomic, copy) MTRContentLauncherClusterStyleInformation * _Nullable splash; @property (nonatomic, copy) MTRContentLauncherClusterStyleInformation * _Nullable waterMark; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRAudioOutputClusterOutputInfo : NSObject @property (nonatomic, copy) NSNumber * _Nonnull index; @property (nonatomic, copy) NSNumber * _Nonnull outputType; @property (nonatomic, copy) NSString * _Nonnull name; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRApplicationLauncherClusterApplication : NSObject @property (nonatomic, copy) NSNumber * _Nonnull catalogVendorId; @property (nonatomic, copy) NSString * _Nonnull applicationId; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRApplicationLauncherClusterApplicationEP : NSObject @property (nonatomic, copy) MTRApplicationLauncherClusterApplication * _Nonnull application; @property (nonatomic, copy) NSNumber * _Nullable endpoint; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end @interface MTRApplicationBasicClusterApplicationBasicApplication : NSObject @property (nonatomic, copy) NSNumber * _Nonnull catalogVendorId; @property (nonatomic, copy) NSString * _Nonnull applicationId; +@end -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; +@interface MTRClientMonitoringClusterMonitoringRegistration : NSObject +@property (nonatomic, copy) NSNumber * _Nonnull clientNodeId; +@property (nonatomic, copy) NSNumber * _Nonnull iCid; +@property (nonatomic, copy) NSNumber * _Nonnull fabricIndex; @end MTR_NEWLY_AVAILABLE @@ -960,9 +663,6 @@ MTR_NEWLY_AVAILABLE @property (nonatomic, copy) NSNumber * _Nonnull f; @property (nonatomic, copy) NSNumber * _Nonnull g; @property (nonatomic, copy) NSNumber * _Nonnull h; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterSimpleStruct") @@ -978,9 +678,6 @@ MTR_NEWLY_AVAILABLE @property (nonatomic, copy) MTRUnitTestingClusterSimpleStruct * _Nonnull fabricSensitiveStruct; @property (nonatomic, copy) NSArray * _Nonnull fabricSensitiveInt8uList; @property (nonatomic, copy) NSNumber * _Nonnull fabricIndex; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestFabricScoped") @@ -1000,9 +697,6 @@ MTR_NEWLY_AVAILABLE @property (nonatomic, copy) NSArray * _Nullable nullableList; @property (nonatomic, copy) NSArray * _Nullable optionalList; @property (nonatomic, copy) NSArray * _Nullable nullableOptionalList; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterNullablesAndOptionalsStruct") @@ -1013,9 +707,6 @@ MTR_NEWLY_AVAILABLE @property (nonatomic, copy) NSNumber * _Nonnull a; @property (nonatomic, copy) NSNumber * _Nonnull b; @property (nonatomic, copy) MTRUnitTestingClusterSimpleStruct * _Nonnull c; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterNestedStruct") @@ -1030,9 +721,6 @@ MTR_NEWLY_AVAILABLE @property (nonatomic, copy) NSArray * _Nonnull e; @property (nonatomic, copy) NSArray * _Nonnull f; @property (nonatomic, copy) NSArray * _Nonnull g; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterNestedStructList") @@ -1041,9 +729,6 @@ MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterNestedStructList") MTR_NEWLY_AVAILABLE @interface MTRUnitTestingClusterDoubleNestedStructList : NSObject @property (nonatomic, copy) NSArray * _Nonnull a; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterDoubleNestedStructList") @@ -1053,9 +738,6 @@ MTR_NEWLY_AVAILABLE @interface MTRUnitTestingClusterTestListStructOctet : NSObject @property (nonatomic, copy) NSNumber * _Nonnull member1; @property (nonatomic, copy) NSData * _Nonnull member2; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestListStructOctet") @@ -1070,9 +752,6 @@ MTR_NEWLY_AVAILABLE @property (nonatomic, copy) MTRUnitTestingClusterSimpleStruct * _Nonnull arg4; @property (nonatomic, copy) NSArray * _Nonnull arg5; @property (nonatomic, copy) NSArray * _Nonnull arg6; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestEventEvent") @@ -1082,9 +761,6 @@ MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestEventEvent") MTR_NEWLY_AVAILABLE @interface MTRUnitTestingClusterTestFabricScopedEventEvent : NSObject @property (nonatomic, copy) NSNumber * _Nonnull fabricIndex; - -- (instancetype)init; -- (id)copyWithZone:(NSZone * _Nullable)zone; @end MTR_NEWLY_DEPRECATED("Please use MTRUnitTestingClusterTestFabricScopedEventEvent") diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRStructsObjc.mm b/src/darwin/Framework/CHIP/zap-generated/MTRStructsObjc.mm index 38f32e60ca16d4..9b69f0d7850cc5 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRStructsObjc.mm +++ b/src/darwin/Framework/CHIP/zap-generated/MTRStructsObjc.mm @@ -661,7 +661,7 @@ - (NSString *)description @end -@implementation MTROtaSoftwareUpdateRequestorClusterProviderLocation +@implementation MTROTASoftwareUpdateRequestorClusterProviderLocation - (instancetype)init { if (self = [super init]) { @@ -677,7 +677,7 @@ - (instancetype)init - (id)copyWithZone:(NSZone * _Nullable)zone { - auto other = [[MTROtaSoftwareUpdateRequestorClusterProviderLocation alloc] init]; + auto other = [[MTROTASoftwareUpdateRequestorClusterProviderLocation alloc] init]; other.providerNodeID = self.providerNodeID; other.endpoint = self.endpoint; @@ -695,7 +695,10 @@ - (NSString *)description @end -@implementation MTROtaSoftwareUpdateRequestorClusterStateTransitionEvent +@implementation MTROtaSoftwareUpdateRequestorClusterProviderLocation : MTROTASoftwareUpdateRequestorClusterProviderLocation +@end + +@implementation MTROTASoftwareUpdateRequestorClusterStateTransitionEvent - (instancetype)init { if (self = [super init]) { @@ -713,7 +716,7 @@ - (instancetype)init - (id)copyWithZone:(NSZone * _Nullable)zone { - auto other = [[MTROtaSoftwareUpdateRequestorClusterStateTransitionEvent alloc] init]; + auto other = [[MTROTASoftwareUpdateRequestorClusterStateTransitionEvent alloc] init]; other.previousState = self.previousState; other.newState = self.newState; @@ -733,7 +736,10 @@ - (NSString *)description @end -@implementation MTROtaSoftwareUpdateRequestorClusterVersionAppliedEvent +@implementation MTROtaSoftwareUpdateRequestorClusterStateTransitionEvent : MTROTASoftwareUpdateRequestorClusterStateTransitionEvent +@end + +@implementation MTROTASoftwareUpdateRequestorClusterVersionAppliedEvent - (instancetype)init { if (self = [super init]) { @@ -747,7 +753,7 @@ - (instancetype)init - (id)copyWithZone:(NSZone * _Nullable)zone { - auto other = [[MTROtaSoftwareUpdateRequestorClusterVersionAppliedEvent alloc] init]; + auto other = [[MTROTASoftwareUpdateRequestorClusterVersionAppliedEvent alloc] init]; other.softwareVersion = self.softwareVersion; other.productID = self.productID; @@ -764,7 +770,10 @@ - (NSString *)description @end -@implementation MTROtaSoftwareUpdateRequestorClusterDownloadErrorEvent +@implementation MTROtaSoftwareUpdateRequestorClusterVersionAppliedEvent : MTROTASoftwareUpdateRequestorClusterVersionAppliedEvent +@end + +@implementation MTROTASoftwareUpdateRequestorClusterDownloadErrorEvent - (instancetype)init { if (self = [super init]) { @@ -782,7 +791,7 @@ - (instancetype)init - (id)copyWithZone:(NSZone * _Nullable)zone { - auto other = [[MTROtaSoftwareUpdateRequestorClusterDownloadErrorEvent alloc] init]; + auto other = [[MTROTASoftwareUpdateRequestorClusterDownloadErrorEvent alloc] init]; other.softwareVersion = self.softwareVersion; other.bytesDownloaded = self.bytesDownloaded; @@ -802,6 +811,9 @@ - (NSString *)description @end +@implementation MTROtaSoftwareUpdateRequestorClusterDownloadErrorEvent : MTROTASoftwareUpdateRequestorClusterDownloadErrorEvent +@end + @implementation MTRPowerSourceClusterBatChargeFaultChangeType - (instancetype)init { @@ -2023,7 +2035,7 @@ - (instancetype)init { if (self = [super init]) { - _newPosition = @(0); + _previousPosition = @(0); _totalNumberOfPressesCounted = @(0); } @@ -2034,7 +2046,7 @@ - (id)copyWithZone:(NSZone * _Nullable)zone { auto other = [[MTRSwitchClusterMultiPressCompleteEvent alloc] init]; - other.newPosition = self.newPosition; + other.previousPosition = self.previousPosition; other.totalNumberOfPressesCounted = self.totalNumberOfPressesCounted; return other; @@ -2042,11 +2054,21 @@ - (id)copyWithZone:(NSZone * _Nullable)zone - (NSString *)description { - NSString * descriptionString = [NSString stringWithFormat:@"<%@: newPosition:%@; totalNumberOfPressesCounted:%@; >", - NSStringFromClass([self class]), _newPosition, _totalNumberOfPressesCounted]; + NSString * descriptionString = [NSString stringWithFormat:@"<%@: previousPosition:%@; totalNumberOfPressesCounted:%@; >", + NSStringFromClass([self class]), _previousPosition, _totalNumberOfPressesCounted]; return descriptionString; } +- (void)setNewPosition:(NSNumber * _Nonnull)newPosition +{ + self.previousPosition = newPosition; +} + +- (NSNumber * _Nonnull)newPosition +{ + return self.previousPosition; +} + @end @implementation MTROperationalCredentialsClusterFabricDescriptor @@ -3569,6 +3591,40 @@ - (NSString *)description @end +@implementation MTRClientMonitoringClusterMonitoringRegistration +- (instancetype)init +{ + if (self = [super init]) { + + _clientNodeId = @(0); + + _iCid = @(0); + + _fabricIndex = @(0); + } + return self; +} + +- (id)copyWithZone:(NSZone * _Nullable)zone +{ + auto other = [[MTRClientMonitoringClusterMonitoringRegistration alloc] init]; + + other.clientNodeId = self.clientNodeId; + other.iCid = self.iCid; + other.fabricIndex = self.fabricIndex; + + return other; +} + +- (NSString *)description +{ + NSString * descriptionString = [NSString stringWithFormat:@"<%@: clientNodeId:%@; iCid:%@; fabricIndex:%@; >", + NSStringFromClass([self class]), _clientNodeId, _iCid, _fabricIndex]; + return descriptionString; +} + +@end + @implementation MTRUnitTestingClusterSimpleStruct - (instancetype)init { diff --git a/src/darwin/Framework/CHIPTests/MTRAsyncCallbackQueueTests.m b/src/darwin/Framework/CHIPTests/MTRAsyncCallbackQueueTests.m index 716727bc1205ab..7676d2051b9f5a 100644 --- a/src/darwin/Framework/CHIPTests/MTRAsyncCallbackQueueTests.m +++ b/src/darwin/Framework/CHIPTests/MTRAsyncCallbackQueueTests.m @@ -136,4 +136,38 @@ - (void)testRunItemsRetry XCTAssertEqual(counter, 2); } +- (void)testRunItemsAfterDrain +{ + XCTestExpectation * expectation1 = [self expectationWithDescription:@"First work item caled"]; + XCTestExpectation * expectation2 = [self expectationWithDescription:@"Second work item called after drain"]; + + MTRAsyncCallbackWorkQueue * workQueue = [[MTRAsyncCallbackWorkQueue alloc] initWithContext:nil queue:dispatch_get_main_queue()]; + + MTRAsyncCallbackQueueWorkItem * workItem1 = + [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:dispatch_get_global_queue(QOS_CLASS_DEFAULT, 0)]; + MTRAsyncCallbackReadyHandler readyHandler1 = ^(MTRDevice * _Nonnull device, NSUInteger retryCount) { + [workItem1 endWork]; + [expectation1 fulfill]; + }; + workItem1.readyHandler = readyHandler1; + workItem1.cancelHandler = ^{ + }; + [workQueue enqueueWorkItem:workItem1]; + + [self waitForExpectations:@[ expectation1 ] timeout:5]; + + MTRAsyncCallbackQueueWorkItem * workItem2 = + [[MTRAsyncCallbackQueueWorkItem alloc] initWithQueue:dispatch_get_global_queue(QOS_CLASS_DEFAULT, 0)]; + MTRAsyncCallbackReadyHandler readyHandler2 = ^(MTRDevice * _Nonnull device, NSUInteger retryCount) { + [expectation2 fulfill]; + [workItem2 endWork]; + }; + workItem2.readyHandler = readyHandler2; + workItem2.cancelHandler = ^{ + }; + [workQueue enqueueWorkItem:workItem2]; + + [self waitForExpectationsWithTimeout:5 handler:nil]; +} + @end diff --git a/src/darwin/Framework/CHIPTests/MTRDeviceTests.m b/src/darwin/Framework/CHIPTests/MTRDeviceTests.m index 1b5e64dd7728dd..f7ab5557af14db 100644 --- a/src/darwin/Framework/CHIPTests/MTRDeviceTests.m +++ b/src/darwin/Framework/CHIPTests/MTRDeviceTests.m @@ -116,8 +116,13 @@ - (void)controller:(MTRDeviceController *)controller commissioningComplete:(NSEr @end +typedef void (^MTRDeviceTestDelegateDataHandler)(NSArray *> *); + @interface MTRDeviceTestDelegate : NSObject @property (nonatomic) dispatch_block_t onSubscriptionEstablished; +@property (nonatomic, nullable) MTRDeviceTestDelegateDataHandler onAttributeDataReceived; +@property (nonatomic, nullable) MTRDeviceTestDelegateDataHandler onEventDataReceived; +@property (nonatomic, nullable) dispatch_block_t onSubscriptionDropped; @end @implementation MTRDeviceTestDelegate @@ -125,15 +130,23 @@ - (void)device:(MTRDevice *)device stateChanged:(MTRDeviceState)state { if (state == MTRDeviceStateReachable) { self.onSubscriptionEstablished(); + } else if (state == MTRDeviceStateUnknown && self.onSubscriptionDropped != nil) { + self.onSubscriptionDropped(); } } - (void)device:(MTRDevice *)device receivedAttributeReport:(NSArray *> *)attributeReport { + if (self.onAttributeDataReceived != nil) { + self.onAttributeDataReceived(attributeReport); + } } - (void)device:(MTRDevice *)device receivedEventReport:(NSArray *> *)eventReport { + if (self.onEventDataReceived != nil) { + self.onEventDataReceived(eventReport); + } } @end @@ -1369,9 +1382,68 @@ - (void)test017_TestMTRDeviceBasics [subscriptionExpectation fulfill]; }; + __block unsigned attributeReportsReceived = 0; + delegate.onAttributeDataReceived = ^(NSArray *> * data) { + attributeReportsReceived += data.count; + }; + + __block unsigned eventReportsReceived = 0; + delegate.onEventDataReceived = ^(NSArray *> * data) { + eventReportsReceived += data.count; + }; + [device setDelegate:delegate queue:queue]; [self waitForExpectations:@[ subscriptionExpectation ] timeout:60]; + + XCTAssertNotEqual(attributeReportsReceived, 0); + + attributeReportsReceived = 0; + eventReportsReceived = 0; + + XCTestExpectation * resubscriptionExpectation = [self expectationWithDescription:@"Resubscription has happened"]; + delegate.onSubscriptionEstablished = ^() { + [resubscriptionExpectation fulfill]; + }; + + XCTestExpectation * subscriptionDroppedExpectation = [self expectationWithDescription:@"Subscription has dropped"]; + delegate.onSubscriptionDropped = ^() { + [subscriptionDroppedExpectation fulfill]; + }; + + // Now trigger another subscription which will cause ours to drop; we should re-subscribe after that. + MTRBaseDevice * baseDevice = GetConnectedDevice(); + __auto_type params = [[MTRSubscribeParams alloc] initWithMinInterval:@(1) maxInterval:@(10)]; + params.resubscribeIfLost = NO; + params.replaceExistingSubscriptions = YES; + // Create second subscription which will cancel the first subscription. We + // can use a non-existent path here to cut down on the work that gets done. + [baseDevice subscribeAttributeWithEndpointId:@10000 + clusterId:@6 + attributeId:@0 + minInterval:@(1) + maxInterval:@(2) + params:params + clientQueue:queue + reportHandler:^(id _Nullable values, NSError * _Nullable error) { + } + subscriptionEstablished:^() { + }]; + + [self waitForExpectations:@[ subscriptionDroppedExpectation, resubscriptionExpectation ] timeout:60 enforceOrder:YES]; + + // Now make sure we ignore later tests. Ideally we would just unsubscribe + // or remove the delegate, but there's no good way to do that. + delegate.onSubscriptionEstablished = ^() { + }; + delegate.onSubscriptionDropped = nil; + delegate.onAttributeDataReceived = nil; + delegate.onEventDataReceived = nil; + + // Make sure we got no updated reports (because we had a cluster state cache + // with data versions) during the resubscribe. + XCTAssertEqual(attributeReportsReceived, 0); + XCTAssertEqual(eventReportsReceived, 0); } - (void)test018_SubscriptionErrorWhenNotResubscribing diff --git a/src/darwin/Framework/CHIPTests/MTRTestOTAProvider.m b/src/darwin/Framework/CHIPTests/MTRTestOTAProvider.m index 28aeb68f7bbbc2..444e2fdd900cd4 100644 --- a/src/darwin/Framework/CHIPTests/MTRTestOTAProvider.m +++ b/src/darwin/Framework/CHIPTests/MTRTestOTAProvider.m @@ -22,21 +22,21 @@ @interface MTRTestOTAProvider () @implementation MTRTestOTAProvider - (void)handleQueryImageForNodeID:(NSNumber *)nodeID controller:(MTRDeviceController *)controller - params:(MTROtaSoftwareUpdateProviderClusterQueryImageParams *)params + params:(MTROTASoftwareUpdateProviderClusterQueryImageParams *)params completion:(MTRQueryImageCompletionHandler)completion { } - (void)handleApplyUpdateRequestForNodeID:(NSNumber *)nodeID controller:(MTRDeviceController *)controller - params:(MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams *)params + params:(MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams *)params completion:(MTRApplyUpdateRequestCompletionHandler)completion { } - (void)handleNotifyUpdateAppliedForNodeID:(NSNumber *)nodeID controller:(MTRDeviceController *)controller - params:(MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams *)params + params:(MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams *)params completion:(MTRStatusCompletion)completion { } diff --git a/src/darwin/Framework/Matter.xcodeproj/project.pbxproj b/src/darwin/Framework/Matter.xcodeproj/project.pbxproj index a8394387ea941f..af1f6c339433e5 100644 --- a/src/darwin/Framework/Matter.xcodeproj/project.pbxproj +++ b/src/darwin/Framework/Matter.xcodeproj/project.pbxproj @@ -33,10 +33,15 @@ 2CB7163F252F731E0026E2BB /* MTRDeviceControllerDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = 2CB7163E252F731E0026E2BB /* MTRDeviceControllerDelegate.h */; settings = {ATTRIBUTES = (Public, ); }; }; 2FD775552695557E00FF4B12 /* error-mapping.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2FD775542695557E00FF4B12 /* error-mapping.cpp */; }; 3CF134A7289D8ADA0017A19E /* MTRCSRInfo.h in Headers */ = {isa = PBXBuildFile; fileRef = 3CF134A6289D8AD90017A19E /* MTRCSRInfo.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 3CF134A9289D8D800017A19E /* MTRCSRInfo.m in Sources */ = {isa = PBXBuildFile; fileRef = 3CF134A8289D8D800017A19E /* MTRCSRInfo.m */; }; + 3CF134A9289D8D800017A19E /* MTRCSRInfo.mm in Sources */ = {isa = PBXBuildFile; fileRef = 3CF134A8289D8D800017A19E /* MTRCSRInfo.mm */; }; 3CF134AB289D8DF70017A19E /* MTRAttestationInfo.h in Headers */ = {isa = PBXBuildFile; fileRef = 3CF134AA289D8DF70017A19E /* MTRAttestationInfo.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 3CF134AD289D8E570017A19E /* MTRAttestationInfo.m in Sources */ = {isa = PBXBuildFile; fileRef = 3CF134AC289D8E570017A19E /* MTRAttestationInfo.m */; }; + 3CF134AD289D8E570017A19E /* MTRAttestationInfo.mm in Sources */ = {isa = PBXBuildFile; fileRef = 3CF134AC289D8E570017A19E /* MTRAttestationInfo.mm */; }; 3CF134AF289D90FF0017A19E /* MTRNOCChainIssuer.h in Headers */ = {isa = PBXBuildFile; fileRef = 3CF134AE289D90FF0017A19E /* MTRNOCChainIssuer.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 3D69868529383096007314E7 /* com.csa.matter.plist in Copy Logging Preferences */ = {isa = PBXBuildFile; fileRef = 3D69868029382EF4007314E7 /* com.csa.matter.plist */; }; + 3DECCB6E29347D2D00585AEC /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DECCB6D29347D2C00585AEC /* Security.framework */; }; + 3DECCB702934AECD00585AEC /* MTRLogging.h in Headers */ = {isa = PBXBuildFile; fileRef = 3DECCB6F2934AC1C00585AEC /* MTRLogging.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 3DECCB722934AFE200585AEC /* MTRLogging.mm in Sources */ = {isa = PBXBuildFile; fileRef = 3DECCB712934AFE200585AEC /* MTRLogging.mm */; }; + 3DECCB742934C21B00585AEC /* MTRDefines.h in Headers */ = {isa = PBXBuildFile; fileRef = 3DECCB732934C21B00585AEC /* MTRDefines.h */; settings = {ATTRIBUTES = (Public, ); }; }; 5112F606287CD2C100B827E7 /* privilege-storage.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 5112F605287CD2C100B827E7 /* privilege-storage.cpp */; }; 511913FB28C100EF009235E9 /* MTRBaseSubscriptionCallback.mm in Sources */ = {isa = PBXBuildFile; fileRef = 511913F928C100EF009235E9 /* MTRBaseSubscriptionCallback.mm */; }; 511913FC28C100EF009235E9 /* MTRBaseSubscriptionCallback.h in Headers */ = {isa = PBXBuildFile; fileRef = 511913FA28C100EF009235E9 /* MTRBaseSubscriptionCallback.h */; }; @@ -50,8 +55,8 @@ 514304202914CED9004DC7FE /* generic-callback-stubs.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 5143041F2914CED9004DC7FE /* generic-callback-stubs.cpp */; }; 51431AF927D2973E008A7943 /* MTRIMDispatch.mm in Sources */ = {isa = PBXBuildFile; fileRef = 51431AF827D2973E008A7943 /* MTRIMDispatch.mm */; }; 51431AFB27D29CA4008A7943 /* ota-provider.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 51431AFA27D29CA4008A7943 /* ota-provider.cpp */; }; - 515C1C6F284F9FFB00A48F0C /* MTRMemory.mm in Sources */ = {isa = PBXBuildFile; fileRef = 515C1C6D284F9FFB00A48F0C /* MTRMemory.mm */; }; - 515C1C70284F9FFB00A48F0C /* MTRMemory.h in Headers */ = {isa = PBXBuildFile; fileRef = 515C1C6E284F9FFB00A48F0C /* MTRMemory.h */; }; + 515C1C6F284F9FFB00A48F0C /* MTRFramework.mm in Sources */ = {isa = PBXBuildFile; fileRef = 515C1C6D284F9FFB00A48F0C /* MTRFramework.mm */; }; + 515C1C70284F9FFB00A48F0C /* MTRFramework.h in Headers */ = {isa = PBXBuildFile; fileRef = 515C1C6E284F9FFB00A48F0C /* MTRFramework.h */; }; 51669AF02913204400F4AA36 /* MTRBackwardsCompatTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 51669AEF2913204400F4AA36 /* MTRBackwardsCompatTests.m */; }; 517BF3F0282B62B800A8B7DB /* MTRCertificates.h in Headers */ = {isa = PBXBuildFile; fileRef = 517BF3EE282B62B800A8B7DB /* MTRCertificates.h */; settings = {ATTRIBUTES = (Public, ); }; }; 517BF3F1282B62B800A8B7DB /* MTRCertificates.mm in Sources */ = {isa = PBXBuildFile; fileRef = 517BF3EF282B62B800A8B7DB /* MTRCertificates.mm */; }; @@ -70,15 +75,15 @@ 51E51FC0282AD37A00FC978D /* MTRDeviceControllerStartupParams_Internal.h in Headers */ = {isa = PBXBuildFile; fileRef = 51E51FBD282AD37A00FC978D /* MTRDeviceControllerStartupParams_Internal.h */; }; 51E51FC1282AD37A00FC978D /* MTRDeviceControllerStartupParams.mm in Sources */ = {isa = PBXBuildFile; fileRef = 51E51FBE282AD37A00FC978D /* MTRDeviceControllerStartupParams.mm */; }; 5A60370827EA1FF60020DB79 /* MTRClusterStateCacheContainer+XPC.h in Headers */ = {isa = PBXBuildFile; fileRef = 5A60370727EA1FF60020DB79 /* MTRClusterStateCacheContainer+XPC.h */; }; - 5A6FEC9027B563D900F25F42 /* MTRDeviceControllerOverXPC.m in Sources */ = {isa = PBXBuildFile; fileRef = 5A6FEC8F27B563D900F25F42 /* MTRDeviceControllerOverXPC.m */; }; + 5A6FEC9027B563D900F25F42 /* MTRDeviceControllerOverXPC.mm in Sources */ = {isa = PBXBuildFile; fileRef = 5A6FEC8F27B563D900F25F42 /* MTRDeviceControllerOverXPC.mm */; }; 5A6FEC9227B5669C00F25F42 /* MTRDeviceControllerOverXPC.h in Headers */ = {isa = PBXBuildFile; fileRef = 5A6FEC8D27B5624E00F25F42 /* MTRDeviceControllerOverXPC.h */; }; - 5A6FEC9627B5983000F25F42 /* MTRDeviceControllerXPCConnection.m in Sources */ = {isa = PBXBuildFile; fileRef = 5A6FEC9527B5983000F25F42 /* MTRDeviceControllerXPCConnection.m */; }; - 5A6FEC9827B5C6AF00F25F42 /* MTRDeviceOverXPC.m in Sources */ = {isa = PBXBuildFile; fileRef = 5A6FEC9727B5C6AF00F25F42 /* MTRDeviceOverXPC.m */; }; + 5A6FEC9627B5983000F25F42 /* MTRDeviceControllerXPCConnection.mm in Sources */ = {isa = PBXBuildFile; fileRef = 5A6FEC9527B5983000F25F42 /* MTRDeviceControllerXPCConnection.mm */; }; + 5A6FEC9827B5C6AF00F25F42 /* MTRDeviceOverXPC.mm in Sources */ = {isa = PBXBuildFile; fileRef = 5A6FEC9727B5C6AF00F25F42 /* MTRDeviceOverXPC.mm */; }; 5A6FEC9927B5C88900F25F42 /* MTRDeviceOverXPC.h in Headers */ = {isa = PBXBuildFile; fileRef = 5A6FEC8B27B5609C00F25F42 /* MTRDeviceOverXPC.h */; }; 5A6FEC9A27B5C89300F25F42 /* MTRDeviceControllerXPCConnection.h in Headers */ = {isa = PBXBuildFile; fileRef = 5A6FEC9427B5976200F25F42 /* MTRDeviceControllerXPCConnection.h */; }; 5A6FEC9D27B5E48900F25F42 /* MTRXPCProtocolTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 5A6FEC9C27B5E48800F25F42 /* MTRXPCProtocolTests.m */; }; 5A7947DE27BEC3F500434CF2 /* MTRXPCListenerSampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 5A7947DD27BEC3F500434CF2 /* MTRXPCListenerSampleTests.m */; }; - 5A7947E427C0129600434CF2 /* MTRDeviceController+XPC.m in Sources */ = {isa = PBXBuildFile; fileRef = 5A7947E327C0129500434CF2 /* MTRDeviceController+XPC.m */; }; + 5A7947E427C0129600434CF2 /* MTRDeviceController+XPC.mm in Sources */ = {isa = PBXBuildFile; fileRef = 5A7947E327C0129500434CF2 /* MTRDeviceController+XPC.mm */; }; 5A7947E527C0129F00434CF2 /* MTRDeviceController+XPC.h in Headers */ = {isa = PBXBuildFile; fileRef = 5A7947E227C0101200434CF2 /* MTRDeviceController+XPC.h */; settings = {ATTRIBUTES = (Public, ); }; }; 5A830D6C27CFCF590053B85D /* MTRDeviceControllerOverXPC_Internal.h in Headers */ = {isa = PBXBuildFile; fileRef = 5A830D6B27CFCF590053B85D /* MTRDeviceControllerOverXPC_Internal.h */; }; 5ACDDD7A27CD129700EFD68A /* MTRClusterStateCacheContainer.h in Headers */ = {isa = PBXBuildFile; fileRef = 5ACDDD7927CD129700EFD68A /* MTRClusterStateCacheContainer.h */; settings = {ATTRIBUTES = (Public, ); }; }; @@ -105,7 +110,7 @@ 88EBF8D027FABDD500686BC1 /* MTRDeviceAttestationDelegateBridge.h in Headers */ = {isa = PBXBuildFile; fileRef = 88EBF8CD27FABDD500686BC1 /* MTRDeviceAttestationDelegateBridge.h */; }; 991DC0842475F45400C13860 /* MTRDeviceController.h in Headers */ = {isa = PBXBuildFile; fileRef = 991DC0822475F45400C13860 /* MTRDeviceController.h */; settings = {ATTRIBUTES = (Public, ); }; }; 991DC0892475F47D00C13860 /* MTRDeviceController.mm in Sources */ = {isa = PBXBuildFile; fileRef = 991DC0872475F47D00C13860 /* MTRDeviceController.mm */; }; - 991DC08B247704DC00C13860 /* MTRLogging.h in Headers */ = {isa = PBXBuildFile; fileRef = 991DC08A247704DC00C13860 /* MTRLogging.h */; }; + 991DC08B247704DC00C13860 /* MTRLogging_Internal.h in Headers */ = {isa = PBXBuildFile; fileRef = 991DC08A247704DC00C13860 /* MTRLogging_Internal.h */; }; 9956064426420367000C28DE /* MTRSetupPayload_Internal.h in Headers */ = {isa = PBXBuildFile; fileRef = 9956064326420367000C28DE /* MTRSetupPayload_Internal.h */; }; 997DED162695343400975E97 /* MTRThreadOperationalDataset.mm in Sources */ = {isa = PBXBuildFile; fileRef = 997DED152695343400975E97 /* MTRThreadOperationalDataset.mm */; }; 997DED182695344800975E97 /* MTRThreadOperationalDataset.h in Headers */ = {isa = PBXBuildFile; fileRef = 997DED172695344800975E97 /* MTRThreadOperationalDataset.h */; settings = {ATTRIBUTES = (Public, ); }; }; @@ -113,7 +118,7 @@ 998F286D26D55E10001846C6 /* MTRKeypair.h in Headers */ = {isa = PBXBuildFile; fileRef = 998F286C26D55E10001846C6 /* MTRKeypair.h */; settings = {ATTRIBUTES = (Public, ); }; }; 998F286F26D55EC5001846C6 /* MTRP256KeypairBridge.h in Headers */ = {isa = PBXBuildFile; fileRef = 998F286E26D55EC5001846C6 /* MTRP256KeypairBridge.h */; }; 998F287126D56940001846C6 /* MTRP256KeypairBridge.mm in Sources */ = {isa = PBXBuildFile; fileRef = 998F287026D56940001846C6 /* MTRP256KeypairBridge.mm */; }; - 99AECC802798A57F00B6355B /* MTRCommissioningParameters.m in Sources */ = {isa = PBXBuildFile; fileRef = 99AECC7F2798A57E00B6355B /* MTRCommissioningParameters.m */; }; + 99AECC802798A57F00B6355B /* MTRCommissioningParameters.mm in Sources */ = {isa = PBXBuildFile; fileRef = 99AECC7F2798A57E00B6355B /* MTRCommissioningParameters.mm */; }; 99C65E10267282F1003402F6 /* MTRControllerTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 99C65E0F267282F1003402F6 /* MTRControllerTests.m */; }; 99D466E12798936D0089A18F /* MTRCommissioningParameters.h in Headers */ = {isa = PBXBuildFile; fileRef = 99D466E02798936D0089A18F /* MTRCommissioningParameters.h */; settings = {ATTRIBUTES = (Public, ); }; }; AF1CB86E2874B03B00865A96 /* MTROTAProviderDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = AF1CB86D2874B03B00865A96 /* MTROTAProviderDelegate.h */; settings = {ATTRIBUTES = (Public, ); }; }; @@ -121,7 +126,7 @@ AF5F90FF2878D351005503FA /* MTROTAProviderDelegateBridge.mm in Sources */ = {isa = PBXBuildFile; fileRef = AF5F90FE2878D351005503FA /* MTROTAProviderDelegateBridge.mm */; }; B20252972459E34F00F97062 /* Matter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B202528D2459E34F00F97062 /* Matter.framework */; }; B289D4212639C0D300D4E314 /* MTROnboardingPayloadParser.h in Headers */ = {isa = PBXBuildFile; fileRef = B289D41F2639C0D300D4E314 /* MTROnboardingPayloadParser.h */; settings = {ATTRIBUTES = (Public, ); }; }; - B289D4222639C0D300D4E314 /* MTROnboardingPayloadParser.m in Sources */ = {isa = PBXBuildFile; fileRef = B289D4202639C0D300D4E314 /* MTROnboardingPayloadParser.m */; }; + B289D4222639C0D300D4E314 /* MTROnboardingPayloadParser.mm in Sources */ = {isa = PBXBuildFile; fileRef = B289D4202639C0D300D4E314 /* MTROnboardingPayloadParser.mm */; }; B2E0D7B1245B0B5C003C5B48 /* Matter.h in Headers */ = {isa = PBXBuildFile; fileRef = B2E0D7A8245B0B5C003C5B48 /* Matter.h */; settings = {ATTRIBUTES = (Public, ); }; }; B2E0D7B2245B0B5C003C5B48 /* MTRManualSetupPayloadParser.h in Headers */ = {isa = PBXBuildFile; fileRef = B2E0D7A9245B0B5C003C5B48 /* MTRManualSetupPayloadParser.h */; settings = {ATTRIBUTES = (Public, ); }; }; B2E0D7B3245B0B5C003C5B48 /* MTRError.mm in Sources */ = {isa = PBXBuildFile; fileRef = B2E0D7AA245B0B5C003C5B48 /* MTRError.mm */; }; @@ -146,6 +151,20 @@ }; /* End PBXContainerItemProxy section */ +/* Begin PBXCopyFilesBuildPhase section */ + 3D69868429383083007314E7 /* Copy Logging Preferences */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 8; + dstPath = "$(SYSTEM_LIBRARY_DIR)/Preferences/Logging/Subsystems"; + dstSubfolderSpec = 0; + files = ( + 3D69868529383096007314E7 /* com.csa.matter.plist in Copy Logging Preferences */, + ); + name = "Copy Logging Preferences"; + runOnlyForDeploymentPostprocessing = 1; + }; +/* End PBXCopyFilesBuildPhase section */ + /* Begin PBXFileReference section */ 1E748B3828941A44008A1BE8 /* MTRTestOTAProvider.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MTRTestOTAProvider.m; sourceTree = ""; }; 1E748B3928941A45008A1BE8 /* MTRTestOTAProvider.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MTRTestOTAProvider.h; sourceTree = ""; }; @@ -174,10 +193,15 @@ 2CB7163E252F731E0026E2BB /* MTRDeviceControllerDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MTRDeviceControllerDelegate.h; sourceTree = ""; }; 2FD775542695557E00FF4B12 /* error-mapping.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = "error-mapping.cpp"; path = "../../../app/util/error-mapping.cpp"; sourceTree = ""; }; 3CF134A6289D8AD90017A19E /* MTRCSRInfo.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRCSRInfo.h; sourceTree = ""; }; - 3CF134A8289D8D800017A19E /* MTRCSRInfo.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MTRCSRInfo.m; sourceTree = ""; }; + 3CF134A8289D8D800017A19E /* MTRCSRInfo.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRCSRInfo.mm; sourceTree = ""; }; 3CF134AA289D8DF70017A19E /* MTRAttestationInfo.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRAttestationInfo.h; sourceTree = ""; }; - 3CF134AC289D8E570017A19E /* MTRAttestationInfo.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MTRAttestationInfo.m; sourceTree = ""; }; + 3CF134AC289D8E570017A19E /* MTRAttestationInfo.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRAttestationInfo.mm; sourceTree = ""; }; 3CF134AE289D90FF0017A19E /* MTRNOCChainIssuer.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRNOCChainIssuer.h; sourceTree = ""; }; + 3D69868029382EF4007314E7 /* com.csa.matter.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = com.csa.matter.plist; sourceTree = ""; }; + 3DECCB6D29347D2C00585AEC /* Security.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Security.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.1.sdk/System/Library/Frameworks/Security.framework; sourceTree = DEVELOPER_DIR; }; + 3DECCB6F2934AC1C00585AEC /* MTRLogging.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRLogging.h; sourceTree = ""; }; + 3DECCB712934AFE200585AEC /* MTRLogging.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRLogging.mm; sourceTree = ""; }; + 3DECCB732934C21B00585AEC /* MTRDefines.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRDefines.h; sourceTree = ""; }; 5112F605287CD2C100B827E7 /* privilege-storage.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = "privilege-storage.cpp"; path = "../../../app/util/privilege-storage.cpp"; sourceTree = ""; }; 511913F928C100EF009235E9 /* MTRBaseSubscriptionCallback.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRBaseSubscriptionCallback.mm; sourceTree = ""; }; 511913FA28C100EF009235E9 /* MTRBaseSubscriptionCallback.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MTRBaseSubscriptionCallback.h; sourceTree = ""; }; @@ -191,8 +215,8 @@ 5143041F2914CED9004DC7FE /* generic-callback-stubs.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = "generic-callback-stubs.cpp"; path = "../../../app/util/generic-callback-stubs.cpp"; sourceTree = ""; }; 51431AF827D2973E008A7943 /* MTRIMDispatch.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRIMDispatch.mm; sourceTree = ""; }; 51431AFA27D29CA4008A7943 /* ota-provider.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = "ota-provider.cpp"; path = "../../../app/clusters/ota-provider/ota-provider.cpp"; sourceTree = ""; }; - 515C1C6D284F9FFB00A48F0C /* MTRMemory.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRMemory.mm; sourceTree = ""; }; - 515C1C6E284F9FFB00A48F0C /* MTRMemory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MTRMemory.h; sourceTree = ""; }; + 515C1C6D284F9FFB00A48F0C /* MTRFramework.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRFramework.mm; sourceTree = ""; }; + 515C1C6E284F9FFB00A48F0C /* MTRFramework.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MTRFramework.h; sourceTree = ""; }; 51669AEF2913204400F4AA36 /* MTRBackwardsCompatTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MTRBackwardsCompatTests.m; sourceTree = ""; }; 517BF3EE282B62B800A8B7DB /* MTRCertificates.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MTRCertificates.h; sourceTree = ""; }; 517BF3EF282B62B800A8B7DB /* MTRCertificates.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRCertificates.mm; sourceTree = ""; }; @@ -213,14 +237,14 @@ 5A60370727EA1FF60020DB79 /* MTRClusterStateCacheContainer+XPC.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "MTRClusterStateCacheContainer+XPC.h"; sourceTree = ""; }; 5A6FEC8B27B5609C00F25F42 /* MTRDeviceOverXPC.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRDeviceOverXPC.h; sourceTree = ""; }; 5A6FEC8D27B5624E00F25F42 /* MTRDeviceControllerOverXPC.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRDeviceControllerOverXPC.h; sourceTree = ""; }; - 5A6FEC8F27B563D900F25F42 /* MTRDeviceControllerOverXPC.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MTRDeviceControllerOverXPC.m; sourceTree = ""; }; + 5A6FEC8F27B563D900F25F42 /* MTRDeviceControllerOverXPC.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRDeviceControllerOverXPC.mm; sourceTree = ""; }; 5A6FEC9427B5976200F25F42 /* MTRDeviceControllerXPCConnection.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRDeviceControllerXPCConnection.h; sourceTree = ""; }; - 5A6FEC9527B5983000F25F42 /* MTRDeviceControllerXPCConnection.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MTRDeviceControllerXPCConnection.m; sourceTree = ""; }; - 5A6FEC9727B5C6AF00F25F42 /* MTRDeviceOverXPC.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MTRDeviceOverXPC.m; sourceTree = ""; }; + 5A6FEC9527B5983000F25F42 /* MTRDeviceControllerXPCConnection.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRDeviceControllerXPCConnection.mm; sourceTree = ""; }; + 5A6FEC9727B5C6AF00F25F42 /* MTRDeviceOverXPC.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRDeviceOverXPC.mm; sourceTree = ""; }; 5A6FEC9C27B5E48800F25F42 /* MTRXPCProtocolTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MTRXPCProtocolTests.m; sourceTree = ""; }; 5A7947DD27BEC3F500434CF2 /* MTRXPCListenerSampleTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MTRXPCListenerSampleTests.m; sourceTree = ""; }; 5A7947E227C0101200434CF2 /* MTRDeviceController+XPC.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "MTRDeviceController+XPC.h"; sourceTree = ""; }; - 5A7947E327C0129500434CF2 /* MTRDeviceController+XPC.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = "MTRDeviceController+XPC.m"; sourceTree = ""; }; + 5A7947E327C0129500434CF2 /* MTRDeviceController+XPC.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = "MTRDeviceController+XPC.mm"; sourceTree = ""; }; 5A830D6B27CFCF590053B85D /* MTRDeviceControllerOverXPC_Internal.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRDeviceControllerOverXPC_Internal.h; sourceTree = ""; }; 5ACDDD7927CD129700EFD68A /* MTRClusterStateCacheContainer.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRClusterStateCacheContainer.h; sourceTree = ""; }; 5ACDDD7B27CD14AF00EFD68A /* MTRClusterStateCacheContainer_Internal.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRClusterStateCacheContainer_Internal.h; sourceTree = ""; }; @@ -246,7 +270,7 @@ 88EBF8CD27FABDD500686BC1 /* MTRDeviceAttestationDelegateBridge.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MTRDeviceAttestationDelegateBridge.h; sourceTree = ""; }; 991DC0822475F45400C13860 /* MTRDeviceController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRDeviceController.h; sourceTree = ""; }; 991DC0872475F47D00C13860 /* MTRDeviceController.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRDeviceController.mm; sourceTree = ""; }; - 991DC08A247704DC00C13860 /* MTRLogging.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRLogging.h; sourceTree = ""; }; + 991DC08A247704DC00C13860 /* MTRLogging_Internal.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRLogging_Internal.h; sourceTree = ""; }; 9956064326420367000C28DE /* MTRSetupPayload_Internal.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRSetupPayload_Internal.h; sourceTree = ""; }; 997DED152695343400975E97 /* MTRThreadOperationalDataset.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRThreadOperationalDataset.mm; sourceTree = ""; }; 997DED172695344800975E97 /* MTRThreadOperationalDataset.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRThreadOperationalDataset.h; sourceTree = ""; }; @@ -254,7 +278,7 @@ 998F286C26D55E10001846C6 /* MTRKeypair.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRKeypair.h; sourceTree = ""; }; 998F286E26D55EC5001846C6 /* MTRP256KeypairBridge.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRP256KeypairBridge.h; sourceTree = ""; }; 998F287026D56940001846C6 /* MTRP256KeypairBridge.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRP256KeypairBridge.mm; sourceTree = ""; }; - 99AECC7F2798A57E00B6355B /* MTRCommissioningParameters.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MTRCommissioningParameters.m; sourceTree = ""; }; + 99AECC7F2798A57E00B6355B /* MTRCommissioningParameters.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRCommissioningParameters.mm; sourceTree = ""; }; 99C65E0F267282F1003402F6 /* MTRControllerTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MTRControllerTests.m; sourceTree = ""; }; 99D466E02798936D0089A18F /* MTRCommissioningParameters.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTRCommissioningParameters.h; sourceTree = ""; }; AF1CB86D2874B03B00865A96 /* MTROTAProviderDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTROTAProviderDelegate.h; sourceTree = ""; }; @@ -265,7 +289,7 @@ B20252962459E34F00F97062 /* MatterTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = MatterTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; B202529D2459E34F00F97062 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; B289D41F2639C0D300D4E314 /* MTROnboardingPayloadParser.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MTROnboardingPayloadParser.h; sourceTree = ""; }; - B289D4202639C0D300D4E314 /* MTROnboardingPayloadParser.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MTROnboardingPayloadParser.m; sourceTree = ""; }; + B289D4202639C0D300D4E314 /* MTROnboardingPayloadParser.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = MTROnboardingPayloadParser.mm; sourceTree = ""; }; B2E0D7A8245B0B5C003C5B48 /* Matter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Matter.h; sourceTree = ""; }; B2E0D7A9245B0B5C003C5B48 /* MTRManualSetupPayloadParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MTRManualSetupPayloadParser.h; sourceTree = ""; }; B2E0D7AA245B0B5C003C5B48 /* MTRError.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = MTRError.mm; sourceTree = ""; }; @@ -289,6 +313,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( + 3DECCB6E29347D2D00585AEC /* Security.framework in Frameworks */, BA09EB43247477BA00605257 /* libCHIP.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; @@ -336,6 +361,22 @@ name = CHIPGeneratedFiles; sourceTree = ""; }; + 3D69867E29382E58007314E7 /* Resources */ = { + isa = PBXGroup; + children = ( + 3D69867F29382EAD007314E7 /* Logging */, + ); + path = Resources; + sourceTree = ""; + }; + 3D69867F29382EAD007314E7 /* Logging */ = { + isa = PBXGroup; + children = ( + 3D69868029382EF4007314E7 /* com.csa.matter.plist */, + ); + path = Logging; + sourceTree = ""; + }; B20252832459E34F00F97062 = { isa = PBXGroup; children = ( @@ -359,6 +400,7 @@ B202528F2459E34F00F97062 /* CHIP */ = { isa = PBXGroup; children = ( + 3D69867E29382E58007314E7 /* Resources */, 1EDCE543289049A100E41EC9 /* MTROTAHeader.h */, 1EDCE544289049A100E41EC9 /* MTROTAHeader.mm */, 27A53C1527FBC6920053F131 /* MTRAttestationTrustStoreBridge.h */, @@ -385,6 +427,7 @@ 2C222ADE255C811800E446B9 /* MTRBaseDevice_Internal.h */, 2C222ACE255C620600E446B9 /* MTRBaseDevice.h */, 2C222ACF255C620600E446B9 /* MTRBaseDevice.mm */, + 3DECCB732934C21B00585AEC /* MTRDefines.h */, 7596A84A287636C1004DAE0E /* MTRDevice_Internal.h */, 7596A84228762729004DAE0E /* MTRDevice.h */, 7596A84328762729004DAE0E /* MTRDevice.mm */, @@ -401,7 +444,7 @@ 2C8C8FBD253E0C2100797F05 /* MTRPersistentStorageDelegateBridge.h */, 2C8C8FBF253E0C2100797F05 /* MTRPersistentStorageDelegateBridge.mm */, 99D466E02798936D0089A18F /* MTRCommissioningParameters.h */, - 99AECC7F2798A57E00B6355B /* MTRCommissioningParameters.m */, + 99AECC7F2798A57E00B6355B /* MTRCommissioningParameters.mm */, 2CB7163E252F731E0026E2BB /* MTRDeviceControllerDelegate.h */, 2CB71638252E8A7B0026E2BB /* MTRDeviceControllerDelegateBridge.h */, 2CB71639252E8A7B0026E2BB /* MTRDeviceControllerDelegateBridge.mm */, @@ -412,9 +455,11 @@ B2E0D7AB245B0B5C003C5B48 /* MTRError_Internal.h */, 5129BCFC26A9EE3300122DDF /* MTRError.h */, B2E0D7AA245B0B5C003C5B48 /* MTRError.mm */, - 991DC08A247704DC00C13860 /* MTRLogging.h */, + 3DECCB6F2934AC1C00585AEC /* MTRLogging.h */, + 991DC08A247704DC00C13860 /* MTRLogging_Internal.h */, + 3DECCB712934AFE200585AEC /* MTRLogging.mm */, B289D41F2639C0D300D4E314 /* MTROnboardingPayloadParser.h */, - B289D4202639C0D300D4E314 /* MTROnboardingPayloadParser.m */, + B289D4202639C0D300D4E314 /* MTROnboardingPayloadParser.mm */, B2E0D7A9245B0B5C003C5B48 /* MTRManualSetupPayloadParser.h */, B2E0D7AD245B0B5C003C5B48 /* MTRManualSetupPayloadParser.mm */, B2E0D7AC245B0B5C003C5B48 /* MTRQRCodeSetupPayloadParser.h */, @@ -434,24 +479,24 @@ 5A7947E227C0101200434CF2 /* MTRDeviceController+XPC.h */, 517BF3EE282B62B800A8B7DB /* MTRCertificates.h */, 517BF3EF282B62B800A8B7DB /* MTRCertificates.mm */, - 515C1C6E284F9FFB00A48F0C /* MTRMemory.h */, - 515C1C6D284F9FFB00A48F0C /* MTRMemory.mm */, - 5A7947E327C0129500434CF2 /* MTRDeviceController+XPC.m */, + 515C1C6E284F9FFB00A48F0C /* MTRFramework.h */, + 515C1C6D284F9FFB00A48F0C /* MTRFramework.mm */, + 5A7947E327C0129500434CF2 /* MTRDeviceController+XPC.mm */, B20252912459E34F00F97062 /* Info.plist */, 998F286C26D55E10001846C6 /* MTRKeypair.h */, 998F286E26D55EC5001846C6 /* MTRP256KeypairBridge.h */, 998F287026D56940001846C6 /* MTRP256KeypairBridge.mm */, 5A6FEC8B27B5609C00F25F42 /* MTRDeviceOverXPC.h */, - 5A6FEC9727B5C6AF00F25F42 /* MTRDeviceOverXPC.m */, + 5A6FEC9727B5C6AF00F25F42 /* MTRDeviceOverXPC.mm */, 5A6FEC8D27B5624E00F25F42 /* MTRDeviceControllerOverXPC.h */, 5A830D6B27CFCF590053B85D /* MTRDeviceControllerOverXPC_Internal.h */, - 5A6FEC8F27B563D900F25F42 /* MTRDeviceControllerOverXPC.m */, + 5A6FEC8F27B563D900F25F42 /* MTRDeviceControllerOverXPC.mm */, 5A6FEC9427B5976200F25F42 /* MTRDeviceControllerXPCConnection.h */, - 5A6FEC9527B5983000F25F42 /* MTRDeviceControllerXPCConnection.m */, + 5A6FEC9527B5983000F25F42 /* MTRDeviceControllerXPCConnection.mm */, 3CF134A6289D8AD90017A19E /* MTRCSRInfo.h */, - 3CF134A8289D8D800017A19E /* MTRCSRInfo.m */, + 3CF134A8289D8D800017A19E /* MTRCSRInfo.mm */, 3CF134AA289D8DF70017A19E /* MTRAttestationInfo.h */, - 3CF134AC289D8E570017A19E /* MTRAttestationInfo.m */, + 3CF134AC289D8E570017A19E /* MTRAttestationInfo.mm */, 3CF134AE289D90FF0017A19E /* MTRNOCChainIssuer.h */, 511913FA28C100EF009235E9 /* MTRBaseSubscriptionCallback.h */, 511913F928C100EF009235E9 /* MTRBaseSubscriptionCallback.mm */, @@ -488,6 +533,7 @@ BA09EB3E2474762900605257 /* Frameworks */ = { isa = PBXGroup; children = ( + 3DECCB6D29347D2C00585AEC /* Security.framework */, BA09EB3F2474762900605257 /* libCHIP.a */, ); name = Frameworks; @@ -514,7 +560,7 @@ 7596A85728788557004DAE0E /* MTRClusters.h in Headers */, 99D466E12798936D0089A18F /* MTRCommissioningParameters.h in Headers */, 5136661528067D550025EDAE /* MTRDeviceControllerFactory_Internal.h in Headers */, - 515C1C70284F9FFB00A48F0C /* MTRMemory.h in Headers */, + 515C1C70284F9FFB00A48F0C /* MTRFramework.h in Headers */, 7534F12928BFF20300390851 /* MTRDeviceAttestationDelegate_Internal.h in Headers */, D4772A46285AE98400383630 /* MTRClusterConstants.h in Headers */, B289D4212639C0D300D4E314 /* MTROnboardingPayloadParser.h in Headers */, @@ -551,15 +597,17 @@ AF1CB8702874B04C00865A96 /* MTROTAProviderDelegateBridge.h in Headers */, B2E0D7B5245B0B5C003C5B48 /* MTRQRCodeSetupPayloadParser.h in Headers */, 1EC4CE6425CC276600D7304F /* MTRBaseClusters.h in Headers */, + 3DECCB742934C21B00585AEC /* MTRDefines.h in Headers */, 2C5EEEF6268A85C400CAE3D3 /* MTRDeviceConnectionBridge.h in Headers */, 2C8C8FC0253E0C2100797F05 /* MTRPersistentStorageDelegateBridge.h in Headers */, 51E4D121291D0EB400C8C535 /* MTRBaseClustersCpp_Internal.h in Headers */, 51E51FC0282AD37A00FC978D /* MTRDeviceControllerStartupParams_Internal.h in Headers */, + 3DECCB702934AECD00585AEC /* MTRLogging.h in Headers */, 998F286F26D55EC5001846C6 /* MTRP256KeypairBridge.h in Headers */, 2C222ADF255C811800E446B9 /* MTRBaseDevice_Internal.h in Headers */, 511913FC28C100EF009235E9 /* MTRBaseSubscriptionCallback.h in Headers */, 51E0310027EA20D20083DC9C /* MTRControllerAccessControl.h in Headers */, - 991DC08B247704DC00C13860 /* MTRLogging.h in Headers */, + 991DC08B247704DC00C13860 /* MTRLogging_Internal.h in Headers */, 7596A84828762783004DAE0E /* MTRAsyncCallbackWorkQueue.h in Headers */, 5A7947E527C0129F00434CF2 /* MTRDeviceController+XPC.h in Headers */, B2E0D7B4245B0B5C003C5B48 /* MTRError_Internal.h in Headers */, @@ -579,6 +627,7 @@ B20252892459E34F00F97062 /* Sources */, B202528A2459E34F00F97062 /* Frameworks */, B202528B2459E34F00F97062 /* Resources */, + 3D69868429383083007314E7 /* Copy Logging Preferences */, ); buildRules = ( ); @@ -689,10 +738,10 @@ buildActionMask = 2147483647; files = ( 2C8C8FC2253E0C2100797F05 /* MTRPersistentStorageDelegateBridge.mm in Sources */, - 99AECC802798A57F00B6355B /* MTRCommissioningParameters.m in Sources */, + 99AECC802798A57F00B6355B /* MTRCommissioningParameters.mm in Sources */, 2CB7163C252E8A7C0026E2BB /* MTRDeviceControllerDelegateBridge.mm in Sources */, 997DED162695343400975E97 /* MTRThreadOperationalDataset.mm in Sources */, - 515C1C6F284F9FFB00A48F0C /* MTRMemory.mm in Sources */, + 515C1C6F284F9FFB00A48F0C /* MTRFramework.mm in Sources */, 27A53C1827FBC6920053F131 /* MTRAttestationTrustStoreBridge.mm in Sources */, 998F287126D56940001846C6 /* MTRP256KeypairBridge.mm in Sources */, 5136661428067D550025EDAE /* MTRDeviceControllerFactory.mm in Sources */, @@ -703,7 +752,7 @@ 51B22C262740CB32008D5055 /* MTRStructsObjc.mm in Sources */, 2C222AD1255C620600E446B9 /* MTRBaseDevice.mm in Sources */, 1EC3238D271999E2002A8BF0 /* cluster-objects.cpp in Sources */, - 3CF134A9289D8D800017A19E /* MTRCSRInfo.m in Sources */, + 3CF134A9289D8D800017A19E /* MTRCSRInfo.mm in Sources */, 991DC0892475F47D00C13860 /* MTRDeviceController.mm in Sources */, B2E0D7B7245B0B5C003C5B48 /* MTRQRCodeSetupPayloadParser.mm in Sources */, 514304202914CED9004DC7FE /* generic-callback-stubs.cpp in Sources */, @@ -715,16 +764,16 @@ 51E51FC1282AD37A00FC978D /* MTRDeviceControllerStartupParams.mm in Sources */, 1ED276E026C57CF000547A89 /* MTRCallbackBridge.mm in Sources */, 517BF3F1282B62B800A8B7DB /* MTRCertificates.mm in Sources */, - 5A6FEC9627B5983000F25F42 /* MTRDeviceControllerXPCConnection.m in Sources */, + 5A6FEC9627B5983000F25F42 /* MTRDeviceControllerXPCConnection.mm in Sources */, 511913FB28C100EF009235E9 /* MTRBaseSubscriptionCallback.mm in Sources */, 5ACDDD7D27CD16D200EFD68A /* MTRClusterStateCacheContainer.mm in Sources */, 513DDB8A2761F6F900DAA01A /* MTRAttributeTLVValueDecoder.mm in Sources */, 2FD775552695557E00FF4B12 /* error-mapping.cpp in Sources */, - 5A7947E427C0129600434CF2 /* MTRDeviceController+XPC.m in Sources */, - 5A6FEC9027B563D900F25F42 /* MTRDeviceControllerOverXPC.m in Sources */, - B289D4222639C0D300D4E314 /* MTROnboardingPayloadParser.m in Sources */, + 5A7947E427C0129600434CF2 /* MTRDeviceController+XPC.mm in Sources */, + 5A6FEC9027B563D900F25F42 /* MTRDeviceControllerOverXPC.mm in Sources */, + B289D4222639C0D300D4E314 /* MTROnboardingPayloadParser.mm in Sources */, 5112F606287CD2C100B827E7 /* privilege-storage.cpp in Sources */, - 3CF134AD289D8E570017A19E /* MTRAttestationInfo.m in Sources */, + 3CF134AD289D8E570017A19E /* MTRAttestationInfo.mm in Sources */, 2C1B027A2641DB4E00780EF1 /* MTROperationalCredentialsDelegate.mm in Sources */, 7560FD1C27FBBD3F005E85B3 /* MTREventTLVValueDecoder.mm in Sources */, 7596A84928762783004DAE0E /* MTRAsyncCallbackWorkQueue.mm in Sources */, @@ -732,9 +781,10 @@ B2E0D7B6245B0B5C003C5B48 /* MTRManualSetupPayloadParser.mm in Sources */, 7596A85528788557004DAE0E /* MTRClusters.mm in Sources */, 88EBF8CF27FABDD500686BC1 /* MTRDeviceAttestationDelegateBridge.mm in Sources */, - 5A6FEC9827B5C6AF00F25F42 /* MTRDeviceOverXPC.m in Sources */, + 5A6FEC9827B5C6AF00F25F42 /* MTRDeviceOverXPC.mm in Sources */, 51431AF927D2973E008A7943 /* MTRIMDispatch.mm in Sources */, 51431AFB27D29CA4008A7943 /* ota-provider.cpp in Sources */, + 3DECCB722934AFE200585AEC /* MTRLogging.mm in Sources */, 7596A84528762729004DAE0E /* MTRDevice.mm in Sources */, ); runOnlyForDeploymentPostprocessing = 0; @@ -826,6 +876,12 @@ MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; MTL_FAST_MATH = YES; ONLY_ACTIVE_ARCH = YES; + OTHER_CFLAGS = ( + "-Wformat", + "-Wformat-nonliteral", + "-Wformat-security", + "-Wconversion", + ); OTHER_LDFLAGS = "-Wl,-unexported_symbol,\"__Z*\""; SDKROOT = iphoneos; SUPPORTED_PLATFORMS = "macosx iphonesimulator iphoneos appletvos appletvsimulator watchos watchsimulator"; @@ -872,11 +928,6 @@ INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 13.4; LIBRARY_SEARCH_PATHS = "$(TEMP_DIR)/out/lib"; - OTHER_CFLAGS = ( - "-Wformat", - "-Wformat-nonliteral", - "-Wformat-security", - ); OTHER_LDFLAGS = ""; "OTHER_LDFLAGS[sdk=*]" = ( "-framework", @@ -975,6 +1026,12 @@ MTL_ENABLE_DEBUG_INFO = NO; MTL_FAST_MATH = YES; ONLY_ACTIVE_ARCH = YES; + OTHER_CFLAGS = ( + "-Wformat", + "-Wformat-nonliteral", + "-Wformat-security", + "-Wconversion", + ); OTHER_LDFLAGS = "-Wl,-unexported_symbol,\"__Z*\""; SDKROOT = iphoneos; SUPPORTED_PLATFORMS = "macosx iphonesimulator iphoneos appletvos appletvsimulator watchos watchsimulator"; @@ -1022,11 +1079,6 @@ INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 13.4; LIBRARY_SEARCH_PATHS = "$(TEMP_DIR)/out/lib"; - OTHER_CFLAGS = ( - "-Wformat", - "-Wformat-nonliteral", - "-Wformat-security", - ); OTHER_LDFLAGS = ""; "OTHER_LDFLAGS[sdk=*]" = ( "-framework", diff --git a/src/darwin/Framework/chip_xcode_build_connector.sh b/src/darwin/Framework/chip_xcode_build_connector.sh index 0357064c6c626c..ab94517c93f2f8 100755 --- a/src/darwin/Framework/chip_xcode_build_connector.sh +++ b/src/darwin/Framework/chip_xcode_build_connector.sh @@ -113,6 +113,12 @@ declare -a args=( ) } +[[ $CHIP_INET_CONFIG_ENABLE_IPV4 == NO ]] && { + args+=( + 'chip_inet_config_enable_ipv4=false' + ) +} + # search current (or $2) and its parent directories until # a name match is found, which is output on stdout find_in_ancestors() { diff --git a/src/include/platform/CHIPDeviceConfig.h b/src/include/platform/CHIPDeviceConfig.h index 5dfc6fcf9ba258..05065105d207f4 100644 --- a/src/include/platform/CHIPDeviceConfig.h +++ b/src/include/platform/CHIPDeviceConfig.h @@ -200,7 +200,7 @@ * A string identifying the software version running on the device. */ #ifndef CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING -#define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING "prerelease" +#define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING "1.0" #endif /** diff --git a/src/include/platform/ThreadStackManager.h b/src/include/platform/ThreadStackManager.h index fb2f18b94866ac..df6adfd73b9a62 100644 --- a/src/include/platform/ThreadStackManager.h +++ b/src/include/platform/ThreadStackManager.h @@ -26,6 +26,7 @@ #include #include #include +#include #include #include diff --git a/src/inet/BUILD.gn b/src/inet/BUILD.gn index cb86a45780df9c..f8f81f94e3c44a 100644 --- a/src/inet/BUILD.gn +++ b/src/inet/BUILD.gn @@ -122,6 +122,8 @@ static_library("inet") { if (chip_inet_config_enable_udp_endpoint) { sources += [ + "BasicPacketFilters.h", + "EndpointQueueFilter.h", "UDPEndPoint.cpp", "UDPEndPoint.h", "UDPEndPointImpl${chip_system_config_inet}.cpp", diff --git a/src/inet/BasicPacketFilters.h b/src/inet/BasicPacketFilters.h new file mode 100644 index 00000000000000..364c0c7c11f17d --- /dev/null +++ b/src/inet/BasicPacketFilters.h @@ -0,0 +1,185 @@ +/* + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +#include +#include +#include +#include +#include + +namespace chip { +namespace Inet { + +/** + * @brief Basic filter that counts how many pending (not yet dequeued) packets + * are accumulated that match a predicate function, and drops those that + * would cause crossing of the threshold. + */ +class DropIfTooManyQueuedPacketsFilter : public chip::Inet::EndpointQueueFilter +{ +public: + typedef bool (*PacketMatchPredicateFunc)(void * context, const void * endpoint, const chip::Inet::IPPacketInfo & pktInfo, + const chip::System::PacketBufferHandle & pktPayload); + + /** + * @brief Initialize the packet filter with a starting limit + * + * @param maxAllowedQueuedPackets - max number of pending-in-queue not yet processed predicate-matching packets + */ + DropIfTooManyQueuedPacketsFilter(size_t maxAllowedQueuedPackets) : mMaxAllowedQueuedPackets(maxAllowedQueuedPackets) {} + + /** + * @brief Set the predicate to use for filtering + * + * @warning DO NOT modify at runtime while the filter is being called. If you do so, the queue accounting could + * get out of sync, and cause the filtering to fail to properly work. + * + * @param predicateFunc - Predicate function to apply. If nullptr, no filtering will take place + * @param context - Pointer to predicate-specific context that will be provided to predicate at every call. May be nullptr. + */ + void SetPredicate(PacketMatchPredicateFunc predicateFunc, void * context) + { + mPredicate = predicateFunc; + mContext = context; + } + + /** + * @brief Set the ceiling for max allowed packets queued up that matched the predicate. + * + * @note Changing this at runtime while packets are coming only affects future dropping, and + * does not remove packets from the queue if the limit is lowered below the currently-in-queue + * count. + * + * @param maxAllowedQueuedPackets - number of packets currently pending allowed. + */ + void SetMaxQueuedPacketsLimit(int maxAllowedQueuedPackets) { mMaxAllowedQueuedPackets.store(maxAllowedQueuedPackets); } + + /** + * @return the total number of packets dropped so far by the filter + */ + size_t GetNumDroppedPackets() const { return mNumDroppedPackets.load(); } + + /** + * @brief Reset the counter of dropped packets. + */ + void ClearNumDroppedPackets() { mNumDroppedPackets.store(0); } + + /** + * @brief Method called when a packet is dropped due to high watermark getting reached, based on predicate. + * + * Subclasses may use this to implement additional behavior or diagnostics. + * + * This is called once for every dropped packet. If there is no filter predicate, this is not called. + * + * @param endpoint - pointer to endpoint instance (platform-dependent, which is why it's void) + * @param pktInfo - info about source/dest of packet + * @param pktPayload - payload content of packet + */ + virtual void OnDropped(const void * endpoint, const chip::Inet::IPPacketInfo & pktInfo, + const chip::System::PacketBufferHandle & pktPayload) + {} + + /** + * @brief Method called whenever queue of accumulated packets is now empty, based on predicate. + * + * Subclasses may use this to implement additional behavior or diagnostics. + * + * This is possibly called repeatedly in a row, if the queue actually never gets above one. + * + * This is only called for packets that had matched the filtering rule, where they had + * been explicitly allowed in the past. If there is no filter predicate, this is not called. + * + * @param endpoint - pointer to endpoint instance (platform-dependent, which is why it's void) + * @param pktInfo - info about source/dest of packet + * @param pktPayload - payload content of packet + */ + virtual void OnLastMatchDequeued(const void * endpoint, const chip::Inet::IPPacketInfo & pktInfo, + const chip::System::PacketBufferHandle & pktPayload) + {} + + /** + * @brief Implementation of filtering before queueing that applies the predicate. + * + * See base class for arguments + */ + FilterOutcome FilterBeforeEnqueue(const void * endpoint, const chip::Inet::IPPacketInfo & pktInfo, + const chip::System::PacketBufferHandle & pktPayload) override + { + // WARNING: This is likely called in a different context than `FilterAfterDequeue`. We use an atomic for the counter. + + // Non-matching is never accounted, always allowed. Lack of predicate is equivalent to non-matching. + if ((mPredicate == nullptr) || !mPredicate(mContext, endpoint, pktInfo, pktPayload)) + { + return FilterOutcome::kAllowPacket; + } + + if (mNumQueuedPackets.load() >= mMaxAllowedQueuedPackets) + { + ++mNumDroppedPackets; + OnDropped(endpoint, pktInfo, pktPayload); + return FilterOutcome::kDropPacket; + } + + ++mNumQueuedPackets; + + return FilterOutcome::kAllowPacket; + } + + /** + * @brief Implementation of filtering after dequeueing that applies the predicate. + * + * See base class for arguments + */ + FilterOutcome FilterAfterDequeue(const void * endpoint, const chip::Inet::IPPacketInfo & pktInfo, + const chip::System::PacketBufferHandle & pktPayload) override + { + // WARNING: This is likely called in a different context than `FilterBeforeEnqueue`. We use an atomic for the counter. + // NOTE: This is always called from Matter platform event loop + + // Non-matching is never accounted, always allowed. Lack of predicate is equivalent to non-matching. + if ((mPredicate == nullptr) || !mPredicate(mContext, endpoint, pktInfo, pktPayload)) + { + return FilterOutcome::kAllowPacket; + } + + --mNumQueuedPackets; + int numQueuedPackets = mNumQueuedPackets.load(); + if (numQueuedPackets == 0) + { + OnLastMatchDequeued(endpoint, pktInfo, pktPayload); + } + + // If we ever go negative, we have mismatch ingress/egress filter via predicate and + // device may eventually starve. + VerifyOrDie(numQueuedPackets >= 0); + + // We always allow the packet and just do accounting, since all dropping is prior to queue entry. + return FilterOutcome::kAllowPacket; + } + +protected: + PacketMatchPredicateFunc mPredicate = nullptr; + void * mContext = nullptr; + std::atomic_int mNumQueuedPackets{ 0 }; + std::atomic_int mMaxAllowedQueuedPackets{ 0 }; + std::atomic_size_t mNumDroppedPackets{ 0u }; +}; + +} // namespace Inet +} // namespace chip diff --git a/src/inet/EndpointQueueFilter.h b/src/inet/EndpointQueueFilter.h new file mode 100644 index 00000000000000..3239b973ac3f64 --- /dev/null +++ b/src/inet/EndpointQueueFilter.h @@ -0,0 +1,88 @@ +/* + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +#include +#include + +namespace chip { +namespace Inet { + +/** + * @brief Filter for UDP Packets going into and out of UDPEndPoint queue. + * + * NOTE: This is only used by some low-level implementations of UDPEndPoint + */ +class EndpointQueueFilter +{ +public: + enum FilterOutcome + { + kAllowPacket = 0, + kDropPacket = 1, + }; + + virtual ~EndpointQueueFilter() {} + + /** + * @brief Run filter prior to inserting in queue. + * + * If filter returns `kAllowPacket`, packet will be enqueued, and `FilterAfterDequeue` will + * be called when it gets dequeued. If filter returns `kDropPacket`, packet will be dropped + * rather than enqueued and `FilterAfterDequeue` method will not be called. + * + * WARNING: This is likely called from non-Matter-eventloop context, from network layer code. + * Be extremely careful about accessing any system data which may belong to Matter + * stack from this method. + * + * @param endpoint - pointer to endpoint instance (platform-dependent, which is why it's void) + * @param pktInfo - info about source/dest of packet + * @param pktPayload - payload content of packet + * + * @return kAllowPacket to allow packet to enqueue or kDropPacket to drop the packet + */ + virtual FilterOutcome FilterBeforeEnqueue(const void * endpoint, const IPPacketInfo & pktInfo, + const chip::System::PacketBufferHandle & pktPayload) + { + return FilterOutcome::kAllowPacket; + } + + /** + * @brief Run filter after dequeuing, prior to processing. + * + * If filter returns `kAllowPacket`, packet will be processed after dequeuing. If filter returns + * `kDropPacket`, packet will be dropped and not processed, even though it was dequeued. + * + * WARNING: This is called from Matter thread context. Be extremely careful about accessing any + * data which may belong to different threads from this method. + * + * @param endpoint - pointer to endpoint instance (platform-dependent, which is why it's void) + * @param pktInfo - info about source/dest of packet + * @param pktPayload - payload content of packet + * + * @return kAllowPacket to allow packet to be processed or kDropPacket to drop the packet + */ + virtual FilterOutcome FilterAfterDequeue(const void * endpoint, const IPPacketInfo & pktInfo, + const chip::System::PacketBufferHandle & pktPayload) + { + return FilterOutcome::kAllowPacket; + } +}; + +} // namespace Inet +} // namespace chip diff --git a/src/inet/UDPEndPointImplLwIP.cpp b/src/inet/UDPEndPointImplLwIP.cpp index 07ce94c7d653e9..78355628420b8b 100644 --- a/src/inet/UDPEndPointImplLwIP.cpp +++ b/src/inet/UDPEndPointImplLwIP.cpp @@ -78,6 +78,8 @@ struct Deleter namespace chip { namespace Inet { +EndpointQueueFilter * UDPEndPointImplLwIP::sQueueFilter = nullptr; + CHIP_ERROR UDPEndPointImplLwIP::BindImpl(IPAddressType addressType, const IPAddress & address, uint16_t port, InterfaceId interfaceId) { @@ -287,7 +289,16 @@ void UDPEndPointImplLwIP::Free() void UDPEndPointImplLwIP::HandleDataReceived(System::PacketBufferHandle && msg, IPPacketInfo * pktInfo) { - if ((mState == State::kListening) && (OnMessageReceived != nullptr)) + // Process packet filter if needed. May cause packet to get dropped before processing. + bool dropPacket = false; + if ((pktInfo != nullptr) && (sQueueFilter != nullptr)) + { + auto outcome = sQueueFilter->FilterAfterDequeue(this, *pktInfo, msg); + dropPacket = (outcome == EndpointQueueFilter::FilterOutcome::kDropPacket); + } + + // Process actual packet if allowed + if ((mState == State::kListening) && (OnMessageReceived != nullptr) && !dropPacket) { if (pktInfo != nullptr) { @@ -424,6 +435,18 @@ void UDPEndPointImplLwIP::LwIPReceiveUDPMessage(void * arg, struct udp_pcb * pcb pktInfo->SrcPort = port; pktInfo->DestPort = pcb->local_port; + auto filterOutcome = EndpointQueueFilter::FilterOutcome::kAllowPacket; + if (sQueueFilter != nullptr) + { + filterOutcome = sQueueFilter->FilterBeforeEnqueue(ep, *(pktInfo.get()), buf); + } + + if (filterOutcome != EndpointQueueFilter::FilterOutcome::kAllowPacket) + { + // Logging, if any, should be at the choice of the filter impl at time of filtering. + return; + } + // Increase mDelayReleaseCount to delay release of this UDP EndPoint while the HandleDataReceived call is // pending on it. ep->mDelayReleaseCount++; @@ -431,7 +454,9 @@ void UDPEndPointImplLwIP::LwIPReceiveUDPMessage(void * arg, struct udp_pcb * pcb CHIP_ERROR err = ep->GetSystemLayer().ScheduleLambda( [ep, p = System::LwIPPacketBufferView::UnsafeGetLwIPpbuf(buf), pktInfo = pktInfo.get()] { ep->mDelayReleaseCount--; - ep->HandleDataReceived(System::PacketBufferHandle::Adopt(p), pktInfo); + + auto handle = System::PacketBufferHandle::Adopt(p); + ep->HandleDataReceived(std::move(handle), pktInfo); }); if (err == CHIP_NO_ERROR) @@ -443,6 +468,14 @@ void UDPEndPointImplLwIP::LwIPReceiveUDPMessage(void * arg, struct udp_pcb * pcb } else { + // On failure to enqueue the processing, we have to tell the filter that + // the packet is basically dequeued, if it tries to keep track of the lifecycle. + if (sQueueFilter != nullptr) + { + (void) sQueueFilter->FilterAfterDequeue(ep, *(pktInfo.get()), buf); + ChipLogError(Inet, "Dequeue ERROR err = %" CHIP_ERROR_FORMAT, err.Format()); + } + ep->mDelayReleaseCount--; } } diff --git a/src/inet/UDPEndPointImplLwIP.h b/src/inet/UDPEndPointImplLwIP.h index 3d8aebe1021f52..230c872743641c 100644 --- a/src/inet/UDPEndPointImplLwIP.h +++ b/src/inet/UDPEndPointImplLwIP.h @@ -24,6 +24,7 @@ #pragma once #include +#include #include namespace chip { @@ -40,6 +41,20 @@ class UDPEndPointImplLwIP : public UDPEndPoint, public EndPointStateLwIP uint16_t GetBoundPort() const override; void Free() override; + /** + * @brief Set the queue filter for all UDP endpoints + * + * Responsibility is on the caller to avoid changing the filter while packets are being + * processed. Setting the queue filter to `nullptr` disables the filtering. + * + * NOTE: There is only one EndpointQueueFilter instance settable. However it's possible + * to create an instance of EndpointQueueFilter that combines several other + * EndpointQueueFilter by composition to achieve the effect of multiple filters. + * + * @param queueFilter - queue filter instance to set, owned by caller + */ + static void SetQueueFilter(EndpointQueueFilter * queueFilter) { sQueueFilter = queueFilter; } + private: // UDPEndPoint overrides. #if INET_CONFIG_ENABLE_IPV4 @@ -62,6 +77,8 @@ class UDPEndPointImplLwIP : public UDPEndPoint, public EndPointStateLwIP udp_pcb * mUDP; // LwIP User datagram protocol (UDP) control block. std::atomic_int mDelayReleaseCount{ 0 }; + + static EndpointQueueFilter * sQueueFilter; }; using UDPEndPointImpl = UDPEndPointImplLwIP; diff --git a/src/inet/tests/BUILD.gn b/src/inet/tests/BUILD.gn index 1788410bb6c6d3..ce7fd4664096ba 100644 --- a/src/inet/tests/BUILD.gn +++ b/src/inet/tests/BUILD.gn @@ -74,6 +74,7 @@ chip_test_suite("tests") { ] test_sources = [ + "TestBasicPacketFilters.cpp", "TestInetAddress.cpp", "TestInetErrorStr.cpp", ] diff --git a/src/inet/tests/TestBasicPacketFilters.cpp b/src/inet/tests/TestBasicPacketFilters.cpp new file mode 100644 index 00000000000000..ef07cab057eb89 --- /dev/null +++ b/src/inet/tests/TestBasicPacketFilters.cpp @@ -0,0 +1,385 @@ +/* + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +namespace { + +using namespace chip; +using namespace chip::Inet; + +class DropIfTooManyQueuedPacketsHarness : public DropIfTooManyQueuedPacketsFilter +{ +public: + DropIfTooManyQueuedPacketsHarness(size_t maxAllowedQueuedPackets) : DropIfTooManyQueuedPacketsFilter(maxAllowedQueuedPackets) {} + + void OnDropped(const void * endpoint, const IPPacketInfo & pktInfo, + const chip::System::PacketBufferHandle & pktPayload) override + { + ++mNumOnDroppedCalled; + + // Log a hysteretic event + if (!mHitCeilingWantFloor) + { + mHitCeilingWantFloor = true; + ChipLogError(Inet, "Hit waterwark, will log as resolved once we get back to empty"); + } + } + + void OnLastMatchDequeued(const void * endpoint, const IPPacketInfo & pktInfo, + const chip::System::PacketBufferHandle & pktPayload) override + { + ++mNumOnLastMatchDequeuedCalled; + + // Log a hysteretic event + if (mHitCeilingWantFloor) + { + mHitCeilingWantFloor = false; + ChipLogError(Inet, "Resolved burst, got back to fully empty."); + } + } + + // Public bits to make testing easier + nlTestSuite * mTestSuite = nullptr; + int mNumOnDroppedCalled = 0; + int mNumOnLastMatchDequeuedCalled = 0; + bool mHitCeilingWantFloor; +}; + +class FilterDriver +{ +public: + FilterDriver(EndpointQueueFilter * filter, const void * endpoint) : mFilter(filter), mEndpoint(endpoint) {} + + EndpointQueueFilter::FilterOutcome ProcessEnqueue(const IPAddress & srcAddr, uint16_t srcPort, const IPAddress & dstAddr, + uint16_t dstPort, ByteSpan payload) + { + VerifyOrDie(mFilter != nullptr); + + chip::Inet::IPPacketInfo pktInfo; + pktInfo.SrcAddress = srcAddr; + pktInfo.DestAddress = dstAddr; + pktInfo.SrcPort = srcPort; + pktInfo.DestPort = dstPort; + + auto pktPayload = chip::System::PacketBufferHandle::NewWithData(payload.data(), payload.size()); + + return mFilter->FilterBeforeEnqueue(mEndpoint, pktInfo, pktPayload); + } + + EndpointQueueFilter::FilterOutcome ProcessDequeue(const IPAddress & srcAddr, uint16_t srcPort, const IPAddress & dstAddr, + uint16_t dstPort, ByteSpan payload) + { + VerifyOrDie(mFilter != nullptr); + + chip::Inet::IPPacketInfo pktInfo; + pktInfo.SrcAddress = srcAddr; + pktInfo.DestAddress = dstAddr; + pktInfo.SrcPort = srcPort; + pktInfo.DestPort = dstPort; + + auto pktPayload = chip::System::PacketBufferHandle::NewWithData(payload.data(), payload.size()); + + return mFilter->FilterAfterDequeue(mEndpoint, pktInfo, pktPayload); + } + +protected: + EndpointQueueFilter * mFilter = nullptr; + const void * mEndpoint = nullptr; +}; + +DropIfTooManyQueuedPacketsHarness gFilter(0); +int gFakeEndpointForPointer = 0; + +void TestBasicPacketFilter(nlTestSuite * inSuite, void * inContext) +{ + constexpr uint16_t kMdnsPort = 5353u; + + gFilter.mTestSuite = inSuite; + + // Predicate for test is filter that destination port is 5353 (mDNS). + // NOTE: A non-capturing lambda is used, but a plain function could have been used as well... + auto predicate = [](void * context, const void * endpoint, const chip::Inet::IPPacketInfo & pktInfo, + const chip::System::PacketBufferHandle & pktPayload) -> bool { + auto filter = reinterpret_cast(context); + auto testSuite = filter->mTestSuite; + auto expectedEndpoint = &gFakeEndpointForPointer; + + // Ensure we get called with context and expected endpoint pointer + NL_TEST_ASSERT(testSuite, context == &gFilter); + NL_TEST_ASSERT(testSuite, endpoint == expectedEndpoint); + + // Predicate filters destination port being 5353 + return (pktInfo.DestPort == kMdnsPort); + }; + gFilter.SetPredicate(predicate, &gFilter); + + FilterDriver fakeUdpEndpoint(&gFilter, &gFakeEndpointForPointer); + + IPAddress fakeSrc; + IPAddress fakeDest; + IPAddress fakeMdnsDest; + constexpr uint16_t kOtherPort = 43210u; + const uint8_t kFakePayloadData[] = { 1, 2, 3 }; + const ByteSpan kFakePayload{ kFakePayloadData }; + + NL_TEST_ASSERT(inSuite, IPAddress::FromString("fe80::aaaa:bbbb:cccc:dddd", fakeSrc)); + NL_TEST_ASSERT(inSuite, IPAddress::FromString("fe80::0000:1111:2222:3333", fakeDest)); + NL_TEST_ASSERT(inSuite, IPAddress::FromString("ff02::fb", fakeMdnsDest)); + + // Shorthands for simplifying asserts + constexpr EndpointQueueFilter::FilterOutcome kAllowPacket = EndpointQueueFilter::FilterOutcome::kAllowPacket; + constexpr EndpointQueueFilter::FilterOutcome kDropPacket = EndpointQueueFilter::FilterOutcome::kDropPacket; + + constexpr int kMaxQueuedPacketsLimit = 3; + gFilter.SetMaxQueuedPacketsLimit(kMaxQueuedPacketsLimit); + + { + // Enqueue some packets that don't match filter, all allowed, never hit the drop + for (int numPkt = 0; numPkt < (kMaxQueuedPacketsLimit + 1); ++numPkt) + { + NL_TEST_ASSERT(inSuite, + kAllowPacket == fakeUdpEndpoint.ProcessEnqueue(fakeSrc, kOtherPort, fakeDest, kOtherPort, kFakePayload)); + } + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 0); + + // Dequeue all packets + for (int numPkt = 0; numPkt < (kMaxQueuedPacketsLimit + 1); ++numPkt) + { + NL_TEST_ASSERT(inSuite, + kAllowPacket == fakeUdpEndpoint.ProcessDequeue(fakeSrc, kOtherPort, fakeDest, kOtherPort, kFakePayload)); + } + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 0); + + // OnDroped/OnLastMatchDequeued only ever called for matching packets, never for non-matching + NL_TEST_ASSERT(inSuite, gFilter.mNumOnDroppedCalled == 0); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnLastMatchDequeuedCalled == 0); + } + + { + // Enqueue packets that match filter, up to watermark. None dropped + for (int numPkt = 0; numPkt < kMaxQueuedPacketsLimit; ++numPkt) + { + NL_TEST_ASSERT(inSuite, + kAllowPacket == + fakeUdpEndpoint.ProcessEnqueue(fakeSrc, kOtherPort, fakeMdnsDest, kMdnsPort, kFakePayload)); + } + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 0); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnDroppedCalled == 0); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnLastMatchDequeuedCalled == 0); + + // Enqueue packets that match filter, beyond watermark: all dropped. + for (int numPkt = 0; numPkt < 2; ++numPkt) + { + NL_TEST_ASSERT( + inSuite, kDropPacket == fakeUdpEndpoint.ProcessEnqueue(fakeSrc, kOtherPort, fakeMdnsDest, kMdnsPort, kFakePayload)); + } + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 2); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnDroppedCalled == 2); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnLastMatchDequeuedCalled == 0); + + // Dequeue 2 packets that were enqueued, matching filter + for (int numPkt = 0; numPkt < 2; ++numPkt) + { + NL_TEST_ASSERT(inSuite, + kAllowPacket == + fakeUdpEndpoint.ProcessDequeue(fakeSrc, kOtherPort, fakeMdnsDest, kMdnsPort, kFakePayload)); + } + // Number of dropped packets didn't change + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 2); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnDroppedCalled == 2); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnLastMatchDequeuedCalled == 0); + + // Enqueue packets that match filter, up to watermark again. None dropped. + for (int numPkt = 0; numPkt < 2; ++numPkt) + { + NL_TEST_ASSERT(inSuite, + kAllowPacket == + fakeUdpEndpoint.ProcessEnqueue(fakeSrc, kOtherPort, fakeMdnsDest, kMdnsPort, kFakePayload)); + } + + // No change from prior state + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 2); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnDroppedCalled == 2); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnLastMatchDequeuedCalled == 0); + + // Enqueue two more packets, expect drop + for (int numPkt = 0; numPkt < 2; ++numPkt) + { + NL_TEST_ASSERT( + inSuite, kDropPacket == fakeUdpEndpoint.ProcessEnqueue(fakeSrc, kOtherPort, fakeMdnsDest, kMdnsPort, kFakePayload)); + } + + // Expect two more dropped total + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 4); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnDroppedCalled == 4); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnLastMatchDequeuedCalled == 0); + + // Enqueue non-matching packet, expect allowed. + for (int numPkt = 0; numPkt < kMaxQueuedPacketsLimit; ++numPkt) + { + NL_TEST_ASSERT(inSuite, + kAllowPacket == fakeUdpEndpoint.ProcessEnqueue(fakeSrc, kOtherPort, fakeDest, kOtherPort, kFakePayload)); + } + + // Expect no more dropepd + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 4); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnDroppedCalled == 4); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnLastMatchDequeuedCalled == 0); + + // Dequeue non-matching packet, expect allowed. + for (int numPkt = 0; numPkt < kMaxQueuedPacketsLimit; ++numPkt) + { + NL_TEST_ASSERT(inSuite, + kAllowPacket == fakeUdpEndpoint.ProcessDequeue(fakeSrc, kOtherPort, fakeDest, kOtherPort, kFakePayload)); + } + + // Expect no change + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 4); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnDroppedCalled == 4); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnLastMatchDequeuedCalled == 0); + + // Dequeue all matching packets, expect allowed and one OnLastMatchDequeued on last one. + for (int numPkt = 0; numPkt < (kMaxQueuedPacketsLimit - 1); ++numPkt) + { + NL_TEST_ASSERT(inSuite, + kAllowPacket == + fakeUdpEndpoint.ProcessDequeue(fakeSrc, kOtherPort, fakeMdnsDest, kMdnsPort, kFakePayload)); + } + + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 4); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnDroppedCalled == 4); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnLastMatchDequeuedCalled == 0); + + NL_TEST_ASSERT(inSuite, + kAllowPacket == fakeUdpEndpoint.ProcessDequeue(fakeSrc, kOtherPort, fakeMdnsDest, kMdnsPort, kFakePayload)); + + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 4); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnDroppedCalled == 4); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnLastMatchDequeuedCalled == 1); + } + + // Validate that clearing drop count works + { + gFilter.ClearNumDroppedPackets(); + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 0); + + gFilter.mNumOnDroppedCalled = 0; + gFilter.mNumOnLastMatchDequeuedCalled = 0; + } + + // Validate that all packets pass when no predicate set + { + gFilter.SetPredicate(nullptr, nullptr); + + // Enqueue packets up to twice the watermark. None dropped. + for (int numPkt = 0; numPkt < (2 * kMaxQueuedPacketsLimit); ++numPkt) + { + NL_TEST_ASSERT(inSuite, + kAllowPacket == + fakeUdpEndpoint.ProcessEnqueue(fakeSrc, kOtherPort, fakeMdnsDest, kMdnsPort, kFakePayload)); + } + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 0); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnDroppedCalled == 0); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnLastMatchDequeuedCalled == 0); + + // Works even if max number of packets allowed is zero + gFilter.SetMaxQueuedPacketsLimit(0); + + // Enqueue packets up to twice the watermark. None dropped. + for (int numPkt = 0; numPkt < (2 * kMaxQueuedPacketsLimit); ++numPkt) + { + NL_TEST_ASSERT(inSuite, + kAllowPacket == + fakeUdpEndpoint.ProcessEnqueue(fakeSrc, kOtherPort, fakeMdnsDest, kMdnsPort, kFakePayload)); + } + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 0); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnDroppedCalled == 0); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnLastMatchDequeuedCalled == 0); + } + + // Validate that setting max packets to zero, with a matching predicate, drops all matching packets, none of the non-matching. + { + gFilter.SetPredicate(predicate, &gFilter); + gFilter.SetMaxQueuedPacketsLimit(0); + + // Enqueue packets that match filter, up to watermark. All dropped + for (int numPkt = 0; numPkt < kMaxQueuedPacketsLimit; ++numPkt) + { + NL_TEST_ASSERT( + inSuite, kDropPacket == fakeUdpEndpoint.ProcessEnqueue(fakeSrc, kOtherPort, fakeMdnsDest, kMdnsPort, kFakePayload)); + } + + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 3); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnDroppedCalled == 3); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnLastMatchDequeuedCalled == 0); + + // Enqueue non-filter-matching, none dropped + for (int numPkt = 0; numPkt < kMaxQueuedPacketsLimit; ++numPkt) + { + NL_TEST_ASSERT(inSuite, + kAllowPacket == fakeUdpEndpoint.ProcessDequeue(fakeSrc, kOtherPort, fakeDest, kOtherPort, kFakePayload)); + } + + NL_TEST_ASSERT(inSuite, gFilter.GetNumDroppedPackets() == 3); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnDroppedCalled == 3); + NL_TEST_ASSERT(inSuite, gFilter.mNumOnLastMatchDequeuedCalled == 0); + } +} + +const nlTest sTests[] = { + NL_TEST_DEF("TestBasicPacketFilter", TestBasicPacketFilter), // + NL_TEST_SENTINEL() // +}; + +int TestSuiteSetup(void * inContext) +{ + CHIP_ERROR error = chip::Platform::MemoryInit(); + if (error != CHIP_NO_ERROR) + return FAILURE; + return SUCCESS; +} + +int TestSuiteTeardown(void * inContext) +{ + chip::Platform::MemoryShutdown(); + return SUCCESS; +} + +} // namespace + +int TestBasicPacketFilters() +{ + nlTestSuite theSuite = { "TestBasicPacketFilters", sTests, &TestSuiteSetup, &TestSuiteTeardown }; + nlTestRunner(&theSuite, nullptr); + return nlTestRunnerStats(&theSuite); +} + +CHIP_REGISTER_TEST_SUITE(TestBasicPacketFilters) diff --git a/src/inet/tests/TestInetAddress.cpp b/src/inet/tests/TestInetAddress.cpp index 22e5dfc2534aed..b696a89e44da44 100644 --- a/src/inet/tests/TestInetAddress.cpp +++ b/src/inet/tests/TestInetAddress.cpp @@ -1880,7 +1880,7 @@ int TestTeardown(void * inContext) } // namespace -int TestInetAddress(void) +int TestInetAddress() { // clang-format off nlTestSuite theSuite = { diff --git a/src/inet/tests/TestInetCommonPosix.cpp b/src/inet/tests/TestInetCommonPosix.cpp index e7e658e0252a2c..d7820303a9a995 100644 --- a/src/inet/tests/TestInetCommonPosix.cpp +++ b/src/inet/tests/TestInetCommonPosix.cpp @@ -287,7 +287,9 @@ void InitNetwork() } } #endif // CHIP_TARGET_STYLE_UNIX +#if !defined(CHIP_DEVICE_LAYER_TARGET_OPEN_IOT_SDK) tcpip_init(OnLwIPInitComplete, NULL); +#endif // !defined(CHIP_DEVICE_LAYER_TARGET_OPEN_IOT_SDK) // Lock LwIP stack LOCK_TCPIP_CORE(); @@ -457,6 +459,13 @@ void ServiceEvents(uint32_t aSleepTimeMilliseconds) if (sRemainingSystemLayerEventDelay == 0) { +#if defined(CHIP_DEVICE_LAYER_TARGET_OPEN_IOT_SDK) + // We need to terminate event loop after performance single step. + // Event loop processing work items until StopEventLoopTask is called. + // Scheduling StopEventLoop task guarantees correct operation of the loop. + chip::DeviceLayer::PlatformMgr().ScheduleWork( + [](intptr_t) -> void { chip::DeviceLayer::PlatformMgr().StopEventLoopTask(); }, (intptr_t) nullptr); +#endif // CHIP_DEVICE_LAYER_TARGET_OPEN_IOT_SDK chip::DeviceLayer::PlatformMgr().RunEventLoop(); sRemainingSystemLayerEventDelay = gNetworkOptions.EventDelay; } diff --git a/src/inet/tests/TestInetErrorStr.cpp b/src/inet/tests/TestInetErrorStr.cpp index 2a00894578c962..89ea47bb1daa12 100644 --- a/src/inet/tests/TestInetErrorStr.cpp +++ b/src/inet/tests/TestInetErrorStr.cpp @@ -105,7 +105,7 @@ static const nlTest sTests[] = }; // clang-format on -int TestInetErrorStr(void) +int TestInetErrorStr() { // clang-format off nlTestSuite theSuite = diff --git a/src/lib/asn1/ASN1Reader.cpp b/src/lib/asn1/ASN1Reader.cpp index 14e583b6007a5f..6039e1ae084561 100644 --- a/src/lib/asn1/ASN1Reader.cpp +++ b/src/lib/asn1/ASN1Reader.cpp @@ -208,11 +208,11 @@ CHIP_ERROR ASN1Reader::GetGeneralizedTime(ASN1UniversalTime & outTime) static uint8_t ReverseBits(uint8_t v) { // swap adjacent bits - v = static_cast((v >> 1) & 0x55) | static_cast((v & 0x55) << 1); + v = static_cast(static_cast((v >> 1) & 0x55) | static_cast((v & 0x55) << 1)); // swap adjacent bit pairs - v = static_cast((v >> 2) & 0x33) | static_cast((v & 0x33) << 2); + v = static_cast(static_cast((v >> 2) & 0x33) | static_cast((v & 0x33) << 2)); // swap nibbles - v = static_cast(v >> 4) | static_cast(v << 4); + v = static_cast(static_cast(v >> 4) | static_cast(v << 4)); return v; } diff --git a/src/lib/asn1/ASN1Writer.cpp b/src/lib/asn1/ASN1Writer.cpp index 396f3e9356f763..aea03a559bb914 100644 --- a/src/lib/asn1/ASN1Writer.cpp +++ b/src/lib/asn1/ASN1Writer.cpp @@ -60,7 +60,7 @@ void ASN1Writer::Init(uint8_t * buf, size_t maxLen) mDeferredLengthCount = 0; } -void ASN1Writer::InitNullWriter(void) +void ASN1Writer::InitNullWriter() { mBuf = nullptr; mWritePoint = nullptr; @@ -133,11 +133,11 @@ CHIP_ERROR ASN1Writer::PutOctetString(uint8_t cls, uint8_t tag, chip::TLV::TLVRe static uint8_t ReverseBits(uint8_t v) { // swap adjacent bits - v = static_cast((v >> 1) & 0x55) | static_cast((v & 0x55) << 1); + v = static_cast(static_cast((v >> 1) & 0x55) | static_cast((v & 0x55) << 1)); // swap adjacent bit pairs - v = static_cast((v >> 2) & 0x33) | static_cast((v & 0x33) << 2); + v = static_cast(static_cast((v >> 2) & 0x33) | static_cast((v & 0x33) << 2)); // swap nibbles - v = static_cast(v >> 4) | static_cast(v << 4); + v = static_cast(static_cast(v >> 4) | static_cast(v << 4)); return v; } diff --git a/src/lib/asn1/tests/TestASN1.cpp b/src/lib/asn1/tests/TestASN1.cpp index 048ddeb91a38e7..29e56a11e6ab47 100644 --- a/src/lib/asn1/tests/TestASN1.cpp +++ b/src/lib/asn1/tests/TestASN1.cpp @@ -571,7 +571,7 @@ static const nlTest sTests[] = }; // clang-format on -int TestASN1(void) +int TestASN1() { nlTestSuite theSuite = { "Support-ASN1", &sTests[0], nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/core/CHIPConfig.h b/src/lib/core/CHIPConfig.h index b84fa02e091904..aaa28d079441ab 100644 --- a/src/lib/core/CHIPConfig.h +++ b/src/lib/core/CHIPConfig.h @@ -374,6 +374,16 @@ #define CHIP_AUTOMATION_LOGGING 1 #endif // CHIP_AUTOMATION_LOGGING +/** + * @def CHIP_LOG_FILTERING + * + * @brief + * If asserted (1), enable runtime log level configuration. + */ +#ifndef CHIP_LOG_FILTERING +#define CHIP_LOG_FILTERING 1 +#endif + /** * CHIP_CONFIG_LOG_MESSAGE_MAX_SIZE * diff --git a/src/lib/core/CHIPKeyIds.h b/src/lib/core/CHIPKeyIds.h index 9cfb4f899498be..3abbe90d674005 100644 --- a/src/lib/core/CHIPKeyIds.h +++ b/src/lib/core/CHIPKeyIds.h @@ -269,7 +269,10 @@ class ChipKeyId * @return root key number. * */ - static uint8_t GetRootKeyNumber(uint32_t keyId) { return (keyId & kMask_RootKeyNumber) >> kShift_RootKeyNumber; } + static uint8_t GetRootKeyNumber(uint32_t keyId) + { + return static_cast((keyId & kMask_RootKeyNumber) >> kShift_RootKeyNumber); + } /** * Get application group epoch key number that was used to derive specified application key. @@ -278,7 +281,10 @@ class ChipKeyId * @return epoch key number. * */ - static uint8_t GetEpochKeyNumber(uint32_t keyId) { return (keyId & kMask_EpochKeyNumber) >> kShift_EpochKeyNumber; } + static uint8_t GetEpochKeyNumber(uint32_t keyId) + { + return static_cast((keyId & kMask_EpochKeyNumber) >> kShift_EpochKeyNumber); + } /** * Get application group local number that was used to derive specified application key. @@ -287,7 +293,10 @@ class ChipKeyId * @return application group local number. * */ - static uint8_t GetAppGroupLocalNumber(uint32_t keyId) { return (keyId & kMask_GroupLocalNumber) >> kShift_GroupLocalNumber; } + static uint8_t GetAppGroupLocalNumber(uint32_t keyId) + { + return static_cast((keyId & kMask_GroupLocalNumber) >> kShift_GroupLocalNumber); + } /** * Construct application group root key ID given root key number. diff --git a/src/lib/core/CHIPTLVTypes.h b/src/lib/core/CHIPTLVTypes.h index 8cf7fc27a23756..e6fb238660ac31 100644 --- a/src/lib/core/CHIPTLVTypes.h +++ b/src/lib/core/CHIPTLVTypes.h @@ -204,7 +204,7 @@ inline uint8_t TLVFieldSizeToBytes(TLVFieldSize fieldSize) { // We would like to assert fieldSize < 7, but that gives us fatal // -Wtautological-constant-out-of-range-compare warnings... - return (fieldSize != kTLVFieldSize_0Byte) ? static_cast(1 << fieldSize) : 0; + return static_cast((fieldSize != kTLVFieldSize_0Byte) ? (1 << fieldSize) : 0); } } // namespace TLV diff --git a/src/lib/core/core.gni b/src/lib/core/core.gni index da4cf547e7c80a..ddd32fdd958b4d 100644 --- a/src/lib/core/core.gni +++ b/src/lib/core/core.gni @@ -87,7 +87,7 @@ declare_args() { if (chip_target_style == "") { if (current_os != "freertos" && current_os != "zephyr" && - current_os != "mbed") { + current_os != "mbed" && current_os != "cmsis-rtos") { chip_target_style = "unix" } else { chip_target_style = "embedded" diff --git a/src/lib/core/tests/TestCATValues.cpp b/src/lib/core/tests/TestCATValues.cpp index 838d4cac10e97e..86551d03130c58 100644 --- a/src/lib/core/tests/TestCATValues.cpp +++ b/src/lib/core/tests/TestCATValues.cpp @@ -226,7 +226,7 @@ int TestCATValues_Teardown(void * inContext) return SUCCESS; } -int TestCATValues(void) +int TestCATValues() { // clang-format off nlTestSuite theSuite = diff --git a/src/lib/core/tests/TestCHIPCallback.cpp b/src/lib/core/tests/TestCHIPCallback.cpp index a12a285ed5e597..fe12cfd57303b7 100644 --- a/src/lib/core/tests/TestCHIPCallback.cpp +++ b/src/lib/core/tests/TestCHIPCallback.cpp @@ -252,7 +252,7 @@ static const nlTest sTests[] = }; // clang-format on -int TestCHIPCallback(void) +int TestCHIPCallback() { // clang-format off nlTestSuite theSuite = diff --git a/src/lib/core/tests/TestCHIPErrorStr.cpp b/src/lib/core/tests/TestCHIPErrorStr.cpp index ebf5cd0f32a72f..1ea3c8834897e5 100644 --- a/src/lib/core/tests/TestCHIPErrorStr.cpp +++ b/src/lib/core/tests/TestCHIPErrorStr.cpp @@ -306,7 +306,7 @@ static const nlTest sTests[] = }; // clang-format on -int TestCHIPErrorStr(void) +int TestCHIPErrorStr() { // clang-format off nlTestSuite theSuite = diff --git a/src/lib/core/tests/TestCHIPTLV.cpp b/src/lib/core/tests/TestCHIPTLV.cpp index 747aaff7d99a12..60d87f93bedf0e 100644 --- a/src/lib/core/tests/TestCHIPTLV.cpp +++ b/src/lib/core/tests/TestCHIPTLV.cpp @@ -4497,7 +4497,7 @@ int TestCHIPTLV_Teardown(void * inContext) return SUCCESS; } -int TestCHIPTLV(void) +int TestCHIPTLV() { // clang-format off nlTestSuite theSuite = diff --git a/src/lib/core/tests/TestOTAImageHeader.cpp b/src/lib/core/tests/TestOTAImageHeader.cpp index 03b829ac743c29..928dc2618100b9 100644 --- a/src/lib/core/tests/TestOTAImageHeader.cpp +++ b/src/lib/core/tests/TestOTAImageHeader.cpp @@ -207,7 +207,7 @@ int TearDownSuite(void * inContext) } // namespace -int TestOTAImageHeader(void) +int TestOTAImageHeader() { nlTestSuite theSuite = { "OTA Image header test", &sTests[0], SetupSuite, TearDownSuite }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/core/tests/TestOptional.cpp b/src/lib/core/tests/TestOptional.cpp index 38e5af915b2784..9eff4dce870e45 100644 --- a/src/lib/core/tests/TestOptional.cpp +++ b/src/lib/core/tests/TestOptional.cpp @@ -191,7 +191,7 @@ int TestOptional_Teardown(void * inContext) return SUCCESS; } -int TestOptional(void) +int TestOptional() { // clang-format off nlTestSuite theSuite = diff --git a/src/lib/core/tests/TestReferenceCounted.cpp b/src/lib/core/tests/TestReferenceCounted.cpp index f504d54a0d74fd..9c292c4a057fe1 100644 --- a/src/lib/core/tests/TestReferenceCounted.cpp +++ b/src/lib/core/tests/TestReferenceCounted.cpp @@ -112,7 +112,7 @@ int TestReferenceCounted_Teardown(void * inContext) return SUCCESS; } -int TestReferenceCounted(void) +int TestReferenceCounted() { // clang-format off nlTestSuite theSuite = diff --git a/src/lib/dnssd/Advertiser_ImplMinimalMdns.cpp b/src/lib/dnssd/Advertiser_ImplMinimalMdns.cpp index 52a8be78bc6ffa..6153ee8245f37a 100644 --- a/src/lib/dnssd/Advertiser_ImplMinimalMdns.cpp +++ b/src/lib/dnssd/Advertiser_ImplMinimalMdns.cpp @@ -488,18 +488,19 @@ CHIP_ERROR AdvertiserMinMdns::Advertise(const OperationalAdvertisingParameters & return CHIP_ERROR_NO_MEMORY; } - if (!operationalAllocator->AddResponder(SrvResourceRecord(instanceName, hostName, params.GetPort())) - .SetReportAdditional(hostName) - .IsValid()) + // We are the sole owner of our instanceName, so records keyed on the + // instanceName should have the cache-flush bit set. + SrvResourceRecord srvRecord(instanceName, hostName, params.GetPort()); + srvRecord.SetCacheFlush(true); + if (!operationalAllocator->AddResponder(srvRecord).SetReportAdditional(hostName).IsValid()) { ChipLogError(Discovery, "Failed to add SRV record mDNS responder"); return CHIP_ERROR_NO_MEMORY; } - if (!operationalAllocator - ->AddResponder(TxtResourceRecord(instanceName, GetOperationalTxtEntries(operationalAllocator, params))) - .SetReportAdditional(hostName) - .IsValid()) + TxtResourceRecord txtRecord(instanceName, GetOperationalTxtEntries(operationalAllocator, params)); + txtRecord.SetCacheFlush(true); + if (!operationalAllocator->AddResponder(txtRecord).SetReportAdditional(hostName).IsValid()) { ChipLogError(Discovery, "Failed to add TXT record mDNS responder"); return CHIP_ERROR_NO_MEMORY; diff --git a/src/lib/dnssd/minimal_mdns/core/tests/TestFlatAllocatedQName.cpp b/src/lib/dnssd/minimal_mdns/core/tests/TestFlatAllocatedQName.cpp index d24f4e66b5dc4f..04cffc6bbc9c9a 100644 --- a/src/lib/dnssd/minimal_mdns/core/tests/TestFlatAllocatedQName.cpp +++ b/src/lib/dnssd/minimal_mdns/core/tests/TestFlatAllocatedQName.cpp @@ -133,7 +133,7 @@ const nlTest sTests[] = { } // namespace -int TestFlatAllocatedQName(void) +int TestFlatAllocatedQName() { nlTestSuite theSuite = { "FlatAllocatedQName", sTests, nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/minimal_mdns/core/tests/TestHeapQName.cpp b/src/lib/dnssd/minimal_mdns/core/tests/TestHeapQName.cpp index f77eb2441c948e..51e31ca0112205 100644 --- a/src/lib/dnssd/minimal_mdns/core/tests/TestHeapQName.cpp +++ b/src/lib/dnssd/minimal_mdns/core/tests/TestHeapQName.cpp @@ -93,7 +93,7 @@ int Teardown(void * inContext) } // namespace -int TestHeapQName(void) +int TestHeapQName() { nlTestSuite theSuite = { "HeapQName", diff --git a/src/lib/dnssd/minimal_mdns/core/tests/TestQName.cpp b/src/lib/dnssd/minimal_mdns/core/tests/TestQName.cpp index e1df1cb4fceade..da2f91013b3217 100644 --- a/src/lib/dnssd/minimal_mdns/core/tests/TestQName.cpp +++ b/src/lib/dnssd/minimal_mdns/core/tests/TestQName.cpp @@ -318,7 +318,7 @@ static const nlTest sTests[] = }; // clang-format on -int TestQName(void) +int TestQName() { // clang-format off nlTestSuite theSuite = diff --git a/src/lib/dnssd/minimal_mdns/core/tests/TestRecordWriter.cpp b/src/lib/dnssd/minimal_mdns/core/tests/TestRecordWriter.cpp index 6323417a1c7992..e6e2e9611f38c6 100644 --- a/src/lib/dnssd/minimal_mdns/core/tests/TestRecordWriter.cpp +++ b/src/lib/dnssd/minimal_mdns/core/tests/TestRecordWriter.cpp @@ -177,7 +177,7 @@ static const nlTest sTests[] = }; // clang-format on -int TestRecordWriter(void) +int TestRecordWriter() { // clang-format off nlTestSuite theSuite = diff --git a/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecord.cpp b/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecord.cpp index 4269d73854ea4c..517256ee19d464 100644 --- a/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecord.cpp +++ b/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecord.cpp @@ -281,7 +281,7 @@ const nlTest sTests[] = { } // namespace -int TestResourceRecord(void) +int TestResourceRecord() { nlTestSuite theSuite = { "ResourceRecord", sTests, nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordIP.cpp b/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordIP.cpp index ce66500b47e742..659b0609db11be 100644 --- a/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordIP.cpp +++ b/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordIP.cpp @@ -185,7 +185,7 @@ const nlTest sTests[] = { } // namespace -int TestIPResourceRecord(void) +int TestIPResourceRecord() { nlTestSuite theSuite = { "IPResourceRecord", sTests, nullptr, nullptr }; diff --git a/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordPtr.cpp b/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordPtr.cpp index 02f9d651752e0c..3822fdf372f5ac 100644 --- a/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordPtr.cpp +++ b/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordPtr.cpp @@ -74,7 +74,7 @@ const nlTest sTests[] = { } // namespace -int TestPtrResourceRecord(void) +int TestPtrResourceRecord() { nlTestSuite theSuite = { "PtrResourceRecord", sTests, nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordSrv.cpp b/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordSrv.cpp index 11fc163566074c..6293f2eb8b130e 100644 --- a/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordSrv.cpp +++ b/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordSrv.cpp @@ -79,7 +79,7 @@ const nlTest sTests[] = { } // namespace -int TestSrv(void) +int TestSrv() { nlTestSuite theSuite = { "Srv", sTests, nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordTxt.cpp b/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordTxt.cpp index 4ed533aaacdec7..0930d68a875feb 100644 --- a/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordTxt.cpp +++ b/src/lib/dnssd/minimal_mdns/records/tests/TestResourceRecordTxt.cpp @@ -75,7 +75,7 @@ const nlTest sTests[] = { } // namespace -int TestTxt(void) +int TestTxt() { nlTestSuite theSuite = { "Txt", sTests, nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/minimal_mdns/responders/IP.cpp b/src/lib/dnssd/minimal_mdns/responders/IP.cpp index c509d818adf573..8290db94e0aa40 100644 --- a/src/lib/dnssd/minimal_mdns/responders/IP.cpp +++ b/src/lib/dnssd/minimal_mdns/responders/IP.cpp @@ -40,6 +40,9 @@ void IPv4Responder::AddAllResponses(const chip::Inet::IPPacketInfo * source, Res assert(addr.IsIPv4()); IPResourceRecord record(GetQName(), addr); + // We're the only thing around with our hostname, so we should set the + // cache-flush bit. + record.SetCacheFlush(true); configuration.Adjust(record); delegate->AddResponse(record); } @@ -59,6 +62,9 @@ void IPv6Responder::AddAllResponses(const chip::Inet::IPPacketInfo * source, Res assert(addr.IsIPv6()); IPResourceRecord record(GetQName(), addr); + // We're the only thing around with our hostname, so we should set the + // cache-flush bit. + record.SetCacheFlush(true); configuration.Adjust(record); delegate->AddResponse(record); } diff --git a/src/lib/dnssd/minimal_mdns/responders/tests/TestIPResponder.cpp b/src/lib/dnssd/minimal_mdns/responders/tests/TestIPResponder.cpp index 6a35323c5b51db..ca66dd184cc9e6 100644 --- a/src/lib/dnssd/minimal_mdns/responders/tests/TestIPResponder.cpp +++ b/src/lib/dnssd/minimal_mdns/responders/tests/TestIPResponder.cpp @@ -42,7 +42,7 @@ class IPResponseAccumulator : public ResponderDelegate { NL_TEST_ASSERT(mSuite, (record.GetType() == QType::A) || (record.GetType() == QType::AAAA)); - NL_TEST_ASSERT(mSuite, record.GetClass() == QClass::IN); + NL_TEST_ASSERT(mSuite, record.GetClass() == QClass::IN_FLUSH); NL_TEST_ASSERT(mSuite, record.GetName() == kNames); } @@ -135,7 +135,7 @@ const nlTest sTests[] = { } // namespace -int TestIP(void) +int TestIP() { nlTestSuite theSuite = { "IP", sTests, &Setup, &Teardown }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/minimal_mdns/responders/tests/TestPtrResponder.cpp b/src/lib/dnssd/minimal_mdns/responders/tests/TestPtrResponder.cpp index 473103255e7c47..135a1a1d6e7f7c 100644 --- a/src/lib/dnssd/minimal_mdns/responders/tests/TestPtrResponder.cpp +++ b/src/lib/dnssd/minimal_mdns/responders/tests/TestPtrResponder.cpp @@ -138,7 +138,7 @@ const nlTest sTests[] = { } // namespace -int TestPtr(void) +int TestPtr() { nlTestSuite theSuite = { "IP", sTests, nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/minimal_mdns/responders/tests/TestQueryResponder.cpp b/src/lib/dnssd/minimal_mdns/responders/tests/TestQueryResponder.cpp index aed19ef04cc8e7..09494a40745f86 100644 --- a/src/lib/dnssd/minimal_mdns/responders/tests/TestQueryResponder.cpp +++ b/src/lib/dnssd/minimal_mdns/responders/tests/TestQueryResponder.cpp @@ -179,7 +179,7 @@ const nlTest sTests[] = { } // namespace -int TestQueryResponder(void) +int TestQueryResponder() { nlTestSuite theSuite = { "QueryResponder", sTests, nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/minimal_mdns/tests/TestAdvertiser.cpp b/src/lib/dnssd/minimal_mdns/tests/TestAdvertiser.cpp index 1bd59cc62727f2..35127bf86a1543 100644 --- a/src/lib/dnssd/minimal_mdns/tests/TestAdvertiser.cpp +++ b/src/lib/dnssd/minimal_mdns/tests/TestAdvertiser.cpp @@ -546,7 +546,7 @@ const nlTest sTests[] = { } // namespace -int TestAdvertiser(void) +int TestAdvertiser() { chip::Platform::MemoryInit(); chip::Test::IOContext context; diff --git a/src/lib/dnssd/minimal_mdns/tests/TestMinimalMdnsAllocator.cpp b/src/lib/dnssd/minimal_mdns/tests/TestMinimalMdnsAllocator.cpp index 2753f66a973a63..c712b1bd647f47 100644 --- a/src/lib/dnssd/minimal_mdns/tests/TestMinimalMdnsAllocator.cpp +++ b/src/lib/dnssd/minimal_mdns/tests/TestMinimalMdnsAllocator.cpp @@ -319,7 +319,7 @@ int TestTeardown(void * inContext) } // namespace -int TestMinimalMdnsAllocator(void) +int TestMinimalMdnsAllocator() { nlTestSuite theSuite = { "MinimalMdnsAllocator", &sTests[0], &TestSetup, &TestTeardown }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/minimal_mdns/tests/TestQueryReplyFilter.cpp b/src/lib/dnssd/minimal_mdns/tests/TestQueryReplyFilter.cpp index 662060616eb2f1..690c28b6193929 100644 --- a/src/lib/dnssd/minimal_mdns/tests/TestQueryReplyFilter.cpp +++ b/src/lib/dnssd/minimal_mdns/tests/TestQueryReplyFilter.cpp @@ -112,7 +112,7 @@ const nlTest sTests[] = { } // namespace -int TestQueryReplyFilter(void) +int TestQueryReplyFilter() { nlTestSuite theSuite = { "QueryReplyFilter", sTests, nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/minimal_mdns/tests/TestRecordData.cpp b/src/lib/dnssd/minimal_mdns/tests/TestRecordData.cpp index 8cc1d242b1f997..181b9d3b6f93fa 100644 --- a/src/lib/dnssd/minimal_mdns/tests/TestRecordData.cpp +++ b/src/lib/dnssd/minimal_mdns/tests/TestRecordData.cpp @@ -255,7 +255,7 @@ const nlTest sTests[] = { } // namespace -int TestRecordData(void) +int TestRecordData() { nlTestSuite theSuite = { "RecordData", sTests, nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/minimal_mdns/tests/TestResponseSender.cpp b/src/lib/dnssd/minimal_mdns/tests/TestResponseSender.cpp index 0089566ad249ad..70522395428e9b 100644 --- a/src/lib/dnssd/minimal_mdns/tests/TestResponseSender.cpp +++ b/src/lib/dnssd/minimal_mdns/tests/TestResponseSender.cpp @@ -372,7 +372,7 @@ int TestTeardown(void * inContext) } // namespace -int TestResponseSender(void) +int TestResponseSender() { nlTestSuite theSuite = { "RecordData", sTests, &TestSetup, &TestTeardown }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/platform/tests/TestPlatform.cpp b/src/lib/dnssd/platform/tests/TestPlatform.cpp index 47e70296f92632..b0285963ddd70c 100644 --- a/src/lib/dnssd/platform/tests/TestPlatform.cpp +++ b/src/lib/dnssd/platform/tests/TestPlatform.cpp @@ -241,7 +241,7 @@ const nlTest sTests[] = { } // namespace -int TestDnssdPlatform(void) +int TestDnssdPlatform() { nlTestSuite theSuite = { "DnssdPlatform", &sTests[0], &TestSetup, &TestTeardown }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/tests/TestActiveResolveAttempts.cpp b/src/lib/dnssd/tests/TestActiveResolveAttempts.cpp index 09c43a4a722bce..097aa11fec1d05 100644 --- a/src/lib/dnssd/tests/TestActiveResolveAttempts.cpp +++ b/src/lib/dnssd/tests/TestActiveResolveAttempts.cpp @@ -395,7 +395,7 @@ const nlTest sTests[] = { } // namespace -int TestActiveResolveAttempts(void) +int TestActiveResolveAttempts() { nlTestSuite theSuite = { "ActiveResolveAttempts", sTests, nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/tests/TestIncrementalResolve.cpp b/src/lib/dnssd/tests/TestIncrementalResolve.cpp index 005779b4f892ab..2791631a32e8a0 100644 --- a/src/lib/dnssd/tests/TestIncrementalResolve.cpp +++ b/src/lib/dnssd/tests/TestIncrementalResolve.cpp @@ -437,7 +437,7 @@ const nlTest sTests[] = { } // namespace -int TestChipDnsSdIncrementalResolve(void) +int TestChipDnsSdIncrementalResolve() { nlTestSuite theSuite = { "IncrementalResolve", &sTests[0], nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/tests/TestServiceNaming.cpp b/src/lib/dnssd/tests/TestServiceNaming.cpp index bbf1989fa418de..646a51e39f4806 100644 --- a/src/lib/dnssd/tests/TestServiceNaming.cpp +++ b/src/lib/dnssd/tests/TestServiceNaming.cpp @@ -279,7 +279,7 @@ const nlTest sTests[] = { } // namespace -int TestCHIPServiceNaming(void) +int TestCHIPServiceNaming() { nlTestSuite theSuite = { "ServiceNaming", &sTests[0], nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/dnssd/tests/TestTxtFields.cpp b/src/lib/dnssd/tests/TestTxtFields.cpp index f35ebf3183ae49..d83954692c0a8c 100644 --- a/src/lib/dnssd/tests/TestTxtFields.cpp +++ b/src/lib/dnssd/tests/TestTxtFields.cpp @@ -642,7 +642,7 @@ const nlTest sTests[] = { NL_TEST_DEF("TxtFieldKey", TestGetTxtFieldKey), } // namespace -int TestCHIPTxtFields(void) +int TestCHIPTxtFields() { nlTestSuite theSuite = { "TxtFields", &sTests[0], nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/shell/BUILD.gn b/src/lib/shell/BUILD.gn index 34a4cfc91122b8..d3fc4a4ee01127 100644 --- a/src/lib/shell/BUILD.gn +++ b/src/lib/shell/BUILD.gn @@ -104,6 +104,11 @@ static_library("shell") { "MainLoopDefault.cpp", "streamer_ameba.cpp", ] + } else if (chip_device_platform == "openiotsdk") { + sources += [ + "MainLoopDefault.cpp", + "streamer_openiotsdk.cpp", + ] } else { sources += [ "MainLoopDefault.cpp" ] } diff --git a/src/lib/shell/MainLoopZephyr.cpp b/src/lib/shell/MainLoopZephyr.cpp index e70a29c52c9dce..17b5d8438499a5 100644 --- a/src/lib/shell/MainLoopZephyr.cpp +++ b/src/lib/shell/MainLoopZephyr.cpp @@ -14,8 +14,8 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -#include -#include +#include +#include #include #include diff --git a/src/lib/shell/streamer_openiotsdk.cpp b/src/lib/shell/streamer_openiotsdk.cpp new file mode 100644 index 00000000000000..ae0e9d824aebb9 --- /dev/null +++ b/src/lib/shell/streamer_openiotsdk.cpp @@ -0,0 +1,62 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Source implementation of an input / output stream for Open IoT SDK platform. + */ + +#include +#include +#include + +#include + +namespace chip { +namespace Shell { + +int streamer_openiotsdk_init(streamer_t * streamer) +{ + (void) streamer; + return 0; +} + +ssize_t streamer_openiotsdk_read(streamer_t * streamer, char * buf, size_t len) +{ + (void) streamer; + return read(STDIN_FILENO, buf, len); +} + +ssize_t streamer_openiotsdk_write(streamer_t * streamer, const char * buf, size_t len) +{ + (void) streamer; + return write(STDOUT_FILENO, buf, len); +} + +static streamer_t streamer_openiotsdk = { + .init_cb = streamer_openiotsdk_init, + .read_cb = streamer_openiotsdk_read, + .write_cb = streamer_openiotsdk_write, +}; + +streamer_t * streamer_get() +{ + return &streamer_openiotsdk; +} + +} // namespace Shell +} // namespace chip diff --git a/src/lib/shell/streamer_zephyr.cpp b/src/lib/shell/streamer_zephyr.cpp index 40a16d56fbbd94..aad69438ab24b0 100644 --- a/src/lib/shell/streamer_zephyr.cpp +++ b/src/lib/shell/streamer_zephyr.cpp @@ -24,8 +24,8 @@ #include -#include -#include +#include +#include namespace chip { namespace Shell { diff --git a/src/lib/shell/tests/TestShellStreamerStdio.cpp b/src/lib/shell/tests/TestShellStreamerStdio.cpp index f0db26bdca3452..147719a5264296 100644 --- a/src/lib/shell/tests/TestShellStreamerStdio.cpp +++ b/src/lib/shell/tests/TestShellStreamerStdio.cpp @@ -80,7 +80,7 @@ static const nlTest sTests[] = { NL_TEST_SENTINEL() }; -int TestStreamerStdio(void) +int TestStreamerStdio() { nlTestSuite theSuite = { "Test Shell: Streamer", &sTests[0], nullptr, nullptr }; diff --git a/src/lib/shell/tests/TestShellTokenizeLine.cpp b/src/lib/shell/tests/TestShellTokenizeLine.cpp index e88f9fe901aeb7..baf49ad54b1619 100644 --- a/src/lib/shell/tests/TestShellTokenizeLine.cpp +++ b/src/lib/shell/tests/TestShellTokenizeLine.cpp @@ -136,7 +136,7 @@ static const nlTest sTests[] = { NL_TEST_SENTINEL() }; -int TestShellTokenizeLine(void) +int TestShellTokenizeLine() { nlTestSuite theSuite = { "Test Shell: MainLoop", &sTests[0], nullptr, nullptr }; diff --git a/src/lib/support/BUILD.gn b/src/lib/support/BUILD.gn index 2f86189862e683..d006b42bf1b38e 100644 --- a/src/lib/support/BUILD.gn +++ b/src/lib/support/BUILD.gn @@ -66,8 +66,11 @@ source_set("logging_constants") { sources = [ "logging/Constants.h" ] } -source_set("enforce_format") { - sources = [ "EnforceFormat.h" ] +source_set("attributes") { + sources = [ + "DLLUtil.h", + "EnforceFormat.h", + ] } source_set("chip_version_header") { @@ -165,8 +168,8 @@ static_library("support") { cflags = [ "-Wconversion" ] public_deps = [ + ":attributes", ":chip_version_header", - ":enforce_format", ":logging_constants", "${chip_root}/src/lib/core:chip_config_header", "${chip_root}/src/platform:platform_buildconfig", @@ -188,6 +191,10 @@ static_library("support") { public_deps += [ "${chip_root}/src/platform/logging:android" ] } + if (current_os == "mac" || current_os == "ios") { + public_deps += [ "${chip_root}/src/platform/Darwin:logging" ] + } + public_configs = [ "${chip_root}/src:includes", "${chip_root}/src/system:system_config", diff --git a/src/lib/support/Base64.cpp b/src/lib/support/Base64.cpp index b1877860f598a9..8c6bfe2e7c237d 100644 --- a/src/lib/support/Base64.cpp +++ b/src/lib/support/Base64.cpp @@ -123,19 +123,19 @@ uint16_t Base64Encode(const uint8_t * in, uint16_t inLen, char * out, Base64ValT uint8_t val1, val2, val3, val4; val1 = static_cast(*in >> 2); - val2 = (*in << 4) & 0x3F; + val2 = static_cast((*in << 4) & 0x3F); in++; inLen--; if (inLen > 0) { val2 = static_cast(val2 | *in >> 4); - val3 = (*in << 2) & 0x3F; + val3 = static_cast((*in << 2) & 0x3F); in++; inLen--; if (inLen > 0) { val3 = static_cast(val3 | *in >> 6); - val4 = *in & 0x3F; + val4 = static_cast(*in & 0x3F); in++; inLen--; } diff --git a/src/lib/support/BufferWriter.cpp b/src/lib/support/BufferWriter.cpp index a8db80c2a91a65..1d7da851ea0ba1 100644 --- a/src/lib/support/BufferWriter.cpp +++ b/src/lib/support/BufferWriter.cpp @@ -57,8 +57,7 @@ LittleEndian::BufferWriter & LittleEndian::BufferWriter::EndianPut(uint64_t x, s { while (size > 0) { - uint8_t c = x & 0xff; - Put(c); + Put(static_cast(x & 0xff)); x >>= 8; size--; } @@ -69,8 +68,7 @@ BigEndian::BufferWriter & BigEndian::BufferWriter::EndianPut(uint64_t x, size_t { while (size-- > 0) { - uint8_t c = (x >> (size * 8)) & 0xff; - Put(c); + Put(static_cast((x >> (size * 8)) & 0xff)); } return *this; } diff --git a/src/lib/support/CodeUtils.h b/src/lib/support/CodeUtils.h index ae61f5211aae4b..3b754e0b9e5e12 100644 --- a/src/lib/support/CodeUtils.h +++ b/src/lib/support/CodeUtils.h @@ -254,11 +254,12 @@ constexpr inline const _T & max(const _T & a, const _T & b) * * Example usage: * - * @code + * @code * VerifyOrReturn(param != nullptr, LogError("param is nullptr")); * @endcode * * @param[in] expr A Boolean expression to be evaluated. + * @param[in] ... Statements to execute before returning. Optional. */ #define VerifyOrReturn(expr, ...) \ do \ @@ -271,7 +272,7 @@ constexpr inline const _T & max(const _T & a, const _T & b) } while (false) /** - * @def VerifyOrReturnError(expr, code) + * @def VerifyOrReturnError(expr, code, ...) * * @brief * Returns a specified error code if expression evaluates to false @@ -284,11 +285,12 @@ constexpr inline const _T & max(const _T & a, const _T & b) * * @param[in] expr A Boolean expression to be evaluated. * @param[in] code A value to return if @a expr is false. + * @param[in] ... Statements to execute before returning. Optional. */ -#define VerifyOrReturnError(expr, code) VerifyOrReturnValue(expr, code) +#define VerifyOrReturnError(expr, code, ...) VerifyOrReturnValue(expr, code, ##__VA_ARGS__) /** - * @def VerifyOrReturnValue(expr, value) + * @def VerifyOrReturnValue(expr, value, ...) * * @brief * Returns a specified value if expression evaluates to false @@ -301,12 +303,14 @@ constexpr inline const _T & max(const _T & a, const _T & b) * * @param[in] expr A Boolean expression to be evaluated. * @param[in] value A value to return if @a expr is false. + * @param[in] ... Statements to execute before returning. Optional. */ -#define VerifyOrReturnValue(expr, value) \ +#define VerifyOrReturnValue(expr, value, ...) \ do \ { \ if (!(expr)) \ { \ + __VA_ARGS__; \ return (value); \ } \ } while (false) @@ -468,9 +472,7 @@ constexpr inline const _T & max(const _T & a, const _T & b) * } * @endcode * - * @param[in] ... An optional expression or block to execute - * when the assertion fails. - * + * @param[in] ... Statements to execute. Optional. */ // clang-format off #define ExitNow(...) \ @@ -622,6 +624,7 @@ inline void chipDie(void) * @endcode * * @param[in] expr A Boolean expression to be evaluated. + * @param[in] ... Statements to execute. */ #define VerifyOrDo(expr, ...) \ do \ diff --git a/src/lib/support/SerializableIntegerSet.cpp b/src/lib/support/SerializableIntegerSet.cpp index 19b305467cff4a..7a16aea943a5ec 100644 --- a/src/lib/support/SerializableIntegerSet.cpp +++ b/src/lib/support/SerializableIntegerSet.cpp @@ -27,7 +27,7 @@ CHIP_ERROR SerializableU64SetBase::Deserialize(ByteSpan serialized) { VerifyOrReturnError(serialized.size() <= MaxSerializedSize(), CHIP_ERROR_INVALID_ARGUMENT); memcpy(mData, serialized.data(), serialized.size()); - mNextAvailable = static_cast(serialized.size()) / static_cast(sizeof(uint64_t)); + mNextAvailable = static_cast(serialized.size() / sizeof(uint64_t)); // Our serialized data is always little-endian; swap to native. SwapByteOrderIfNeeded(); diff --git a/src/lib/support/ThreadOperationalDataset.cpp b/src/lib/support/ThreadOperationalDataset.cpp index cbce0de667ac2a..70db620f8b24bc 100644 --- a/src/lib/support/ThreadOperationalDataset.cpp +++ b/src/lib/support/ThreadOperationalDataset.cpp @@ -52,13 +52,13 @@ class ThreadTLV final kActiveTimestamp = 14, }; - uint8_t GetSize(void) const { return static_cast(sizeof(*this) + GetLength()); } + uint8_t GetSize() const { return static_cast(sizeof(*this) + GetLength()); } - uint8_t GetType(void) const { return mType; } + uint8_t GetType() const { return mType; } void SetType(uint8_t aType) { mType = aType; } - uint8_t GetLength(void) const + uint8_t GetLength() const { assert(mLength != kLengthEscape); return mLength; @@ -70,7 +70,7 @@ class ThreadTLV final mLength = aLength; } - const void * GetValue(void) const + const void * GetValue() const { assert(mLength != kLengthEscape); @@ -79,7 +79,7 @@ class ThreadTLV final return reinterpret_cast(this) + sizeof(*this); } - void * GetValue(void) { return const_cast(const_cast(this)->GetValue()); } + void * GetValue() { return const_cast(const_cast(this)->GetValue()); } void Get64(uint64_t & aValue) const { @@ -156,13 +156,13 @@ class ThreadTLV final memcpy(GetValue(), aValue, aLength); } - const ThreadTLV * GetNext(void) const + const ThreadTLV * GetNext() const { static_assert(alignof(ThreadTLV) == 1, "Wrong alignment for ThreadTLV header"); return reinterpret_cast(static_cast(GetValue()) + GetLength()); } - ThreadTLV * GetNext(void) { return reinterpret_cast(static_cast(GetValue()) + GetLength()); } + ThreadTLV * GetNext() { return reinterpret_cast(static_cast(GetValue()) + GetLength()); } static bool IsValid(ByteSpan aData) { @@ -480,17 +480,17 @@ CHIP_ERROR OperationalDataset::SetPSKc(const uint8_t (&aPSKc)[kSizePSKc]) return CHIP_NO_ERROR; } -void OperationalDataset::UnsetMasterKey(void) +void OperationalDataset::UnsetMasterKey() { Remove(ThreadTLV::kMasterKey); } -void OperationalDataset::UnsetPSKc(void) +void OperationalDataset::UnsetPSKc() { Remove(ThreadTLV::kPSKc); } -bool OperationalDataset::IsCommissioned(void) const +bool OperationalDataset::IsCommissioned() const { return Has(ThreadTLV::kPanId) && Has(ThreadTLV::kMasterKey) && Has(ThreadTLV::kExtendedPanId) && Has(ThreadTLV::kChannel); } diff --git a/src/lib/support/jsontlv/BUILD.gn b/src/lib/support/jsontlv/BUILD.gn index 4bcea650508b75..eda4d7fa19bcf2 100644 --- a/src/lib/support/jsontlv/BUILD.gn +++ b/src/lib/support/jsontlv/BUILD.gn @@ -16,7 +16,6 @@ import("//build_overrides/chip.gni") import("//build_overrides/jsoncpp.gni") config("jsontlv_config") { - cflags = [ "-Wno-implicit-fallthrough" ] } static_library("jsontlv") { diff --git a/src/lib/support/jsontlv/TlvJson.cpp b/src/lib/support/jsontlv/TlvJson.cpp index e7044da118f0b0..35bf8686d43bfc 100644 --- a/src/lib/support/jsontlv/TlvJson.cpp +++ b/src/lib/support/jsontlv/TlvJson.cpp @@ -67,6 +67,9 @@ struct KeyContext // static constexpr uint16_t kMaxStringLen = 1280; +constexpr const char kBase64Header[] = "base64:"; +constexpr size_t kBase64HeaderLen = ArraySize(kBase64Header) - 1; + namespace chip { /* @@ -113,8 +116,6 @@ std::string JsonToString(Json::Value & json) CHIP_ERROR TlvToJson(TLV::TLVReader & reader, KeyContext context, Json::Value & parent) { - bool isStruct = false; - switch (reader.GetType()) { case TLV::kTLVType_UnsignedInteger: { @@ -152,10 +153,15 @@ CHIP_ERROR TlvToJson(TLV::TLVReader & reader, KeyContext context, Json::Value & VerifyOrReturnError(span.size() < kMaxStringLen, CHIP_ERROR_INVALID_TLV_ELEMENT); Platform::ScopedMemoryBuffer byteString; - byteString.Alloc(BASE64_ENCODED_LEN(span.size()) + 1); + byteString.Alloc(kBase64HeaderLen + BASE64_ENCODED_LEN(span.size()) + 1); VerifyOrReturnError(byteString.Get() != nullptr, CHIP_ERROR_NO_MEMORY); - auto encodedLen = Base64Encode(span.data(), span.size(), byteString.Get()); + auto encodedLen = Base64Encode(span.data(), span.size(), byteString.Get() + kBase64HeaderLen); + if (encodedLen) + { + memcpy(byteString.Get(), kBase64Header, kBase64HeaderLen); + encodedLen += kBase64HeaderLen; + } byteString.Get()[encodedLen] = '\0'; InsertKeyValue(parent, context, byteString.Get()); @@ -178,46 +184,46 @@ CHIP_ERROR TlvToJson(TLV::TLVReader & reader, KeyContext context, Json::Value & break; } - case TLV::kTLVType_Structure: - isStruct = true; + case TLV::kTLVType_Structure: { + TLV::TLVType containerType; + ReturnErrorOnFailure(reader.EnterContainer(containerType)); + + CHIP_ERROR err; + Json::Value value; + + while ((err = reader.Next()) == CHIP_NO_ERROR) + { + VerifyOrReturnError(TLV::IsContextTag(reader.GetTag()), CHIP_ERROR_INVALID_TLV_TAG); + KeyContext context2(static_cast(TLV::TagNumFromTag(reader.GetTag()))); + + // + // Recursively convert to JSON the encompassing item within the struct. + // + ReturnErrorOnFailure(TlvToJson(reader, context2, value)); + } - // - // Fall-through to the case below since - // arrays and structs are handled similarly with - // just a small difference in terms of handling of field IDs vs. - // list indices of the elements in the respective collections. - // + VerifyOrReturnError(err == CHIP_END_OF_TLV, err); + ReturnErrorOnFailure(reader.ExitContainer(containerType)); + InsertKeyValue(parent, context, value); + break; + } case TLV::kTLVType_Array: { TLV::TLVType containerType; - ReturnErrorOnFailure(reader.EnterContainer(containerType)); CHIP_ERROR err; - Json::Value value; - size_t listIndex = 0; + Json::Value value = Json::Value(Json::arrayValue); + size_t listIndex = 0; while ((err = reader.Next()) == CHIP_NO_ERROR) { - if (isStruct) - { - VerifyOrReturnError(TLV::IsContextTag(reader.GetTag()), CHIP_ERROR_INVALID_TLV_TAG); - KeyContext context2(static_cast(TLV::TagNumFromTag(reader.GetTag()))); - - // - // Recursively convert to JSON the encompassing item within the struct. - // - ReturnErrorOnFailure(TlvToJson(reader, context2, value)); - } - else - { - KeyContext context2(static_cast(listIndex++)); - - // - // Recursively convert to JSON the encompassing item within the array. - // - ReturnErrorOnFailure(TlvToJson(reader, context2, value)); - } + KeyContext context2(static_cast(listIndex++)); + + // + // Recursively convert to JSON the encompassing item within the array. + // + ReturnErrorOnFailure(TlvToJson(reader, context2, value)); } VerifyOrReturnError(err == CHIP_END_OF_TLV, err); diff --git a/src/lib/support/logging/CHIPLogging.cpp b/src/lib/support/logging/CHIPLogging.cpp index a374893d9197ed..ca04f60388d6b8 100644 --- a/src/lib/support/logging/CHIPLogging.cpp +++ b/src/lib/support/logging/CHIPLogging.cpp @@ -28,9 +28,10 @@ #include #include #include -#include #include +#include + #include #include #include @@ -69,70 +70,56 @@ namespace { std::atomic sLogRedirectCallback{ nullptr }; /* - * Array of strings containing the names for each of the chip log - * modules. - * - * NOTE: The names must be in the order defined in the LogModule - * enumeration. Each name must be a fixed number of characters - * long (chip::Logging::kMaxModuleNameLen) padded with nulls as - * necessary. + * Array of strings containing the names for each of the chip log modules. * + * NOTE: The names must be in the order defined in the LogModule enumeration. */ -const char ModuleNames[] = "-\0\0" // None - "IN\0" // Inet - "BLE" // BLE - "ML\0" // MessageLayer - "SM\0" // SecurityManager - "EM\0" // ExchangeManager - "TLV" // TLV - "ASN" // ASN1 - "CR\0" // Crypto - "CTL" // Controller - "AL\0" // Alarm - "SC\0" // SecureChannel - "BDX" // BulkDataTransfer - "DMG" // DataManagement - "DC\0" // DeviceControl - "DD\0" // DeviceDescription - "ECH" // Echo - "FP\0" // FabricProvisioning - "NP\0" // NetworkProvisioning - "SD\0" // ServiceDirectory - "SP\0" // ServiceProvisioning - "SWU" // SoftwareUpdate - "FS\0" // FailSafe - "TS\0" // TimeService - "HB\0" // Heartbeat - "CSL" // chipSystemLayer - "EVL" // Event Logging - "SPT" // Support - "TOO" // chipTool - "ZCL" // Zcl - "SH\0" // Shell - "DL\0" // DeviceLayer - "SPL" // SetupPayload - "SVR" // AppServer - "DIS" // Discovery - "IM\0" // InteractionModel - "TST" // Test - "OSS" // OperationalSessionSetup - "ATM" // Automation - "CSM" // CASESessionManager - ; - -#define ModuleNamesCount ((sizeof(ModuleNames) - 1) / chip::Logging::kMaxModuleNameLen) - -void GetModuleName(char (&buf)[chip::Logging::kMaxModuleNameLen + 1], uint8_t module) +static const char ModuleNames[kLogModule_Max][kMaxModuleNameLen + 1] = { + "-", // None + "IN", // Inet + "BLE", // BLE + "ML", // MessageLayer + "SM", // SecurityManager + "EM", // ExchangeManager + "TLV", // TLV + "ASN", // ASN1 + "CR", // Crypto + "CTL", // Controller + "AL", // Alarm + "SC", // SecureChannel + "BDX", // BulkDataTransfer + "DMG", // DataManagement + "DC", // DeviceControl + "DD", // DeviceDescription + "ECH", // Echo + "FP", // FabricProvisioning + "NP", // NetworkProvisioning + "SD", // ServiceDirectory + "SP", // ServiceProvisioning + "SWU", // SoftwareUpdate + "FS", // FailSafe + "TS", // TimeService + "HB", // Heartbeat + "CSL", // chipSystemLayer + "EVL", // Event Logging + "SPT", // Support + "TOO", // chipTool + "ZCL", // Zcl + "SH", // Shell + "DL", // DeviceLayer + "SPL", // SetupPayload + "SVR", // AppServer + "DIS", // Discovery + "IM", // InteractionModel + "TST", // Test + "OSS", // OperationalSessionSetup + "ATM", // Automation + "CSM", // CASESessionManager +}; + +static char const * GetModuleName(LogModule module) { - - const char * module_name = ModuleNames; - if (module < ModuleNamesCount) - { - module_name += module * chip::Logging::kMaxModuleNameLen; - } - - memcpy(buf, module_name, chip::Logging::kMaxModuleNameLen); - buf[chip::Logging::kMaxModuleNameLen] = 0; // ensure null termination + return ModuleNames[(module < kLogModule_Max) ? module : kLogModule_NotSpecified]; } } // namespace @@ -164,7 +151,7 @@ void SetLogRedirectCallback(LogRedirectCallback_t callback) * correspond to the format specifiers in @a msg. * */ -DLL_EXPORT void Log(uint8_t module, uint8_t category, const char * msg, ...) +void Log(uint8_t module, uint8_t category, const char * msg, ...) { va_list v; @@ -173,7 +160,7 @@ DLL_EXPORT void Log(uint8_t module, uint8_t category, const char * msg, ...) va_end(v); } -DLL_EXPORT void LogByteSpan(uint8_t module, uint8_t category, const chip::ByteSpan & span) +void LogByteSpan(uint8_t module, uint8_t category, const chip::ByteSpan & span) { // Maximum number of characters needed to print 8 byte buffer including formatting (0x) // 8 bytes * (2 nibbles per byte + 4 character for ", 0x") + null termination. @@ -206,16 +193,8 @@ DLL_EXPORT void LogByteSpan(uint8_t module, uint8_t category, const chip::ByteSp void LogV(uint8_t module, uint8_t category, const char * msg, va_list args) { - if (!IsCategoryEnabled(category)) - { - return; - } - - char moduleName[chip::Logging::kMaxModuleNameLen + 1]; - GetModuleName(moduleName, module); - + const char * moduleName = GetModuleName(static_cast(module)); LogRedirectCallback_t redirect = sLogRedirectCallback.load(); - if (redirect != nullptr) { redirect(moduleName, category, msg, args); @@ -228,41 +207,38 @@ void LogV(uint8_t module, uint8_t category, const char * msg, va_list args) #if CHIP_LOG_FILTERING uint8_t gLogFilter = kLogCategory_Max; -DLL_EXPORT bool IsCategoryEnabled(uint8_t category) -{ - return (category <= gLogFilter); -} -DLL_EXPORT uint8_t GetLogFilter() +uint8_t GetLogFilter() { return gLogFilter; } -DLL_EXPORT void SetLogFilter(uint8_t category) +void SetLogFilter(uint8_t category) { gLogFilter = category; } #else // CHIP_LOG_FILTERING -DLL_EXPORT bool IsCategoryEnabled(uint8_t category) +uint8_t GetLogFilter() { - (void) category; - return true; + return kLogCategory_Max; } -DLL_EXPORT uint8_t GetLogFilter() +void SetLogFilter(uint8_t category) { - return kLogCategory_Max; + IgnoreUnusedVariable(category); } +#endif // CHIP_LOG_FILTERING -DLL_EXPORT void SetLogFilter(uint8_t category) +#if CHIP_LOG_FILTERING +bool IsCategoryEnabled(uint8_t category) { - (void) category; + return (category <= gLogFilter); } #endif // CHIP_LOG_FILTERING -#endif /* _CHIP_USE_LOGGING */ +#endif // _CHIP_USE_LOGGING } // namespace Logging } // namespace chip diff --git a/src/lib/support/logging/CHIPLogging.h b/src/lib/support/logging/CHIPLogging.h index 9e6dc5c15d0744..28bdeb59c34a9b 100644 --- a/src/lib/support/logging/CHIPLogging.h +++ b/src/lib/support/logging/CHIPLogging.h @@ -37,8 +37,7 @@ #include -#include - +#include #include #include @@ -46,6 +45,10 @@ #include #include +#if CHIP_SYSTEM_CONFIG_PLATFORM_LOG && defined(CHIP_SYSTEM_CONFIG_PLATFORM_LOG_INCLUDE) +#include CHIP_SYSTEM_CONFIG_PLATFORM_LOG_INCLUDE +#endif + #if CHIP_PW_TOKENIZER_LOGGING #include "pw_tokenizer/tokenize_to_global_handler_with_payload.h" #endif @@ -68,7 +71,7 @@ * - #CHIP_ERROR_LOGGING * - #CHIP_PROGRESS_LOGGING * - #CHIP_DETAIL_LOGGING - * - #CHIP_AUTOMATION_LOGGING + * - #CHIP_AUTOMATION_LOGGING * */ @@ -80,25 +83,13 @@ using ByteSpan = Span; namespace Logging { +// Log redirection using LogRedirectCallback_t = void (*)(const char * module, uint8_t category, const char * msg, va_list args); +DLL_EXPORT void SetLogRedirectCallback(LogRedirectCallback_t callback); -void SetLogRedirectCallback(LogRedirectCallback_t callback); - -void LogV(uint8_t module, uint8_t category, const char * msg, va_list args) ENFORCE_FORMAT(3, 0); -void Log(uint8_t module, uint8_t category, const char * msg, ...) ENFORCE_FORMAT(3, 4); - -void LogByteSpan(uint8_t module, uint8_t category, const ByteSpan & span); - -uint8_t GetLogFilter(); -void SetLogFilter(uint8_t category); - -#ifndef CHIP_ERROR_LOGGING -#define CHIP_ERROR_LOGGING 1 -#endif - -#ifndef CHIP_LOG_FILTERING -#define CHIP_LOG_FILTERING 1 -#endif +// Log filtering (no-op unless CHIP_LOG_FILTERING is enabled) +DLL_EXPORT uint8_t GetLogFilter(); +DLL_EXPORT void SetLogFilter(uint8_t category); #if CHIP_ERROR_LOGGING /** @@ -109,23 +100,10 @@ void SetLogFilter(uint8_t category); * category. * */ -#ifndef ChipLogError -#if CHIP_PW_TOKENIZER_LOGGING -#define ChipLogError(MOD, MSG, ...) \ - PW_TOKENIZE_TO_GLOBAL_HANDLER_WITH_PAYLOAD( \ - (pw_tokenizer_Payload)((chip::Logging::kLogCategory_Error << 8) | chip::Logging::kLogModule_##MOD), MSG, __VA_ARGS__) -#else -#define ChipLogError(MOD, MSG, ...) \ - chip::Logging::Log(chip::Logging::kLogModule_##MOD, chip::Logging::kLogCategory_Error, MSG, ##__VA_ARGS__) -#endif -#endif -#else +#define ChipLogError(MOD, MSG, ...) ChipInternalLog(MOD, Error, MSG, ##__VA_ARGS__) +#else // CHIP_ERROR_LOGGING #define ChipLogError(MOD, MSG, ...) ((void) 0) -#endif - -#ifndef CHIP_PROGRESS_LOGGING -#define CHIP_PROGRESS_LOGGING 1 -#endif +#endif // CHIP_ERROR_LOGGING #if CHIP_PROGRESS_LOGGING /** @@ -136,23 +114,10 @@ void SetLogFilter(uint8_t category); * category. * */ -#ifndef ChipLogProgress -#if CHIP_PW_TOKENIZER_LOGGING -#define ChipLogProgress(MOD, MSG, ...) \ - PW_TOKENIZE_TO_GLOBAL_HANDLER_WITH_PAYLOAD( \ - (pw_tokenizer_Payload)((chip::Logging::kLogCategory_Progress << 8) | chip::Logging::kLogModule_##MOD), MSG, __VA_ARGS__) -#else -#define ChipLogProgress(MOD, MSG, ...) \ - chip::Logging::Log(chip::Logging::kLogModule_##MOD, chip::Logging::kLogCategory_Progress, MSG, ##__VA_ARGS__) -#endif -#endif -#else +#define ChipLogProgress(MOD, MSG, ...) ChipInternalLog(MOD, Progress, MSG, ##__VA_ARGS__) +#else // CHIP_PROGRESS_LOGGING #define ChipLogProgress(MOD, MSG, ...) ((void) 0) -#endif - -#ifndef CHIP_DETAIL_LOGGING -#define CHIP_DETAIL_LOGGING 1 -#endif +#endif // CHIP_PROGRESS_LOGGING #if CHIP_DETAIL_LOGGING /** @@ -163,32 +128,20 @@ void SetLogFilter(uint8_t category); * category. * */ -#ifndef ChipLogDetail -#if CHIP_PW_TOKENIZER_LOGGING -#define ChipLogDetail(MOD, MSG, ...) \ - PW_TOKENIZE_TO_GLOBAL_HANDLER_WITH_PAYLOAD( \ - (pw_tokenizer_Payload)((chip::Logging::kLogCategory_Detail << 8) | chip::Logging::kLogModule_##MOD), MSG, __VA_ARGS__) -#else -#define ChipLogDetail(MOD, MSG, ...) \ - chip::Logging::Log(chip::Logging::kLogModule_##MOD, chip::Logging::kLogCategory_Detail, MSG, ##__VA_ARGS__) -#endif -#endif -#else -#define ChipLogDetail(MOD, MSG, ...) ((void) 0) -#endif +#define ChipLogDetail(MOD, MSG, ...) ChipInternalLog(MOD, Detail, MSG, ##__VA_ARGS__) -#if CHIP_DETAIL_LOGGING -#ifndef ChipLogByteSpan -#define ChipLogByteSpan(MOD, DATA) \ - chip::Logging::LogByteSpan(chip::Logging::kLogModule_##MOD, chip::Logging::kLogCategory_Detail, DATA) -#endif -#else +/** + * @def ChipLogByteSpan(MOD, DATA) + * + * @brief + * Log a byte span for the specified module in the 'Detail' category. + * + */ +#define ChipLogByteSpan(MOD, DATA) ChipInternalLogByteSpan(MOD, Detail, DATA) +#else // CHP_DETAIL_LOGGING +#define ChipLogDetail(MOD, MSG, ...) ((void) 0) #define ChipLogByteSpan(MOD, DATA) ((void) 0) -#endif - -#ifndef CHIP_AUTOMATION_LOGGING -#define CHIP_AUTOMATION_LOGGING 1 -#endif +#endif // CHIP_DETAIL_LOGGING #if CHIP_AUTOMATION_LOGGING /** @@ -199,51 +152,10 @@ void SetLogFilter(uint8_t category); * category. * */ -#ifndef ChipLogAutomation -#if CHIP_PW_TOKENIZER_LOGGING -#define ChipLogAutomation(MSG, ...) \ - PW_TOKENIZE_TO_GLOBAL_HANDLER_WITH_PAYLOAD( \ - (pw_tokenizer_Payload)((chip::Logging::kLogModule_Automation << 8) | chip::Logging::kLogModule_Automation), MSG, \ - __VA_ARGS__) -#else -#define ChipLogAutomation(MSG, ...) \ - chip::Logging::Log(chip::Logging::kLogModule_Automation, chip::Logging::kLogCategory_Automation, MSG, ##__VA_ARGS__) -#endif -#endif -#else +#define ChipLogAutomation(MSG, ...) ChipInternalLog(Automation, Automation, MSG, ##__VA_ARGS__) +#else // CHIP_AUTOMATION_LOGGING #define ChipLogAutomation(MOD, MSG, ...) ((void) 0) -#endif - -#if CHIP_ERROR_LOGGING || CHIP_PROGRESS_LOGGING || CHIP_DETAIL_LOGGING || CHIP_AUTOMATION_LOGGING -#define _CHIP_USE_LOGGING 1 -#else -#define _CHIP_USE_LOGGING 0 -#endif /* CHIP_ERROR_LOGGING || CHIP_PROGRESS_LOGGING || CHIP_DETAIL_LOGGING || CHIP_AUTOMATION_LOGGING */ - -#if _CHIP_USE_LOGGING - -/** - * CHIP logging length constants - */ -static constexpr uint16_t kMaxModuleNameLen = 3; -static constexpr uint16_t kMaxPrefixLen = 3; -static constexpr uint16_t kMaxSeparatorLen = 2; -static constexpr uint16_t kMaxTrailerLen = 2; -static constexpr uint16_t kMaxMessagePadding = (chip::Logging::kMaxPrefixLen + chip::Logging::kMaxModuleNameLen + - chip::Logging::kMaxSeparatorLen + chip::Logging::kMaxTrailerLen); - -void GetMessageWithPrefix(char * buf, uint8_t bufSize, uint8_t module, const char * msg); - -#else - -static inline void GetMessageWithPrefix(char * buf, uint8_t bufSize, uint8_t module, const char * msg) -{ - return; -} - -#endif // _CHIP_USE_LOGGING - -bool IsCategoryEnabled(uint8_t category); +#endif // CHIP_AUTOMATION_LOGGING /** * @def ChipLogIfFalse(aCondition) @@ -411,5 +323,79 @@ bool IsCategoryEnabled(uint8_t category); #define ChipLogFormatScopedNodeId "<" ChipLogFormatX64 ", %d>" #define ChipLogValueScopedNodeId(id) ChipLogValueX64((id).GetNodeId()), (id).GetFabricIndex() +/** + * CHIP Logging Implementation internals. + */ + +#if CHIP_ERROR_LOGGING || CHIP_PROGRESS_LOGGING || CHIP_DETAIL_LOGGING || CHIP_AUTOMATION_LOGGING +#define _CHIP_USE_LOGGING 1 +#else +#define _CHIP_USE_LOGGING 0 +#endif // CHIP_ERROR_LOGGING || CHIP_PROGRESS_LOGGING || CHIP_DETAIL_LOGGING || CHIP_AUTOMATION_LOGGING + +#if _CHIP_USE_LOGGING + +static constexpr uint16_t kMaxModuleNameLen = 3; + +#if CHIP_LOG_FILTERING +DLL_LOCAL bool IsCategoryEnabled(uint8_t category); +#else // CHIP_LOG_FILTERING +DLL_LOCAL inline bool IsCategoryEnabled(uint8_t category) +{ + return true; +} +#endif // CHIP_LOG_FILTERING + +DLL_LOCAL void Log(uint8_t module, uint8_t category, const char * msg, ...) ENFORCE_FORMAT(3, 4); +DLL_LOCAL void LogByteSpan(uint8_t module, uint8_t category, const ByteSpan & span); +DLL_LOCAL void LogV(uint8_t module, uint8_t category, const char * msg, va_list args) ENFORCE_FORMAT(3, 0); + +#if CHIP_SYSTEM_CONFIG_PLATFORM_LOG +#ifndef ChipPlatformLog +#error "CHIP_SYSTEM_CONFIG_PLATFORM_LOG is enabled but ChipPlatformLog() is not defined" +#endif +#ifndef ChipPlatformLogByteSpan +#error "CHIP_SYSTEM_CONFIG_PLATFORM_LOG is enabled but ChipPlatformLogByteSpan() is not defined" +#endif +#define ChipInternalLog(...) ChipPlatformLog(__VA_ARGS__) +#define ChipInternalLogByteSpan(...) ChipPlatformLogByteSpan(__VA_ARGS__) +#else // CHIP_SYSTEM_CONFIG_PLATFORM_LOG +#define ChipInternalLog(MOD, CAT, MSG, ...) ChipInternalLogImpl(MOD, CAT, MSG, ##__VA_ARGS__) +#define ChipInternalLogByteSpan(MOD, CAT, DATA) ChipInternalLogByteSpanImpl(MOD, CAT, DATA) +#endif // CHIP_SYSTEM_CONFIG_PLATFORM_LOG + +#if CHIP_PW_TOKENIZER_LOGGING +#define ChipInternalLogImpl(MOD, CAT, MSG, ...) \ + do \ + { \ + if (chip::Logging::IsCategoryEnabled(chip::Logging::kLogCategory_##CAT)) \ + { \ + PW_TOKENIZE_TO_GLOBAL_HANDLER_WITH_PAYLOAD( \ + (pw_tokenizer_Payload)((chip::Logging::kLogCategory_##CAT << 8) | chip::Logging::kLogModule_##MOD), MSG, \ + __VA_ARGS__); \ + } \ + } while (0) +#else // CHIP_PW_TOKENIZER_LOGGING +#define ChipInternalLogImpl(MOD, CAT, MSG, ...) \ + do \ + { \ + if (chip::Logging::IsCategoryEnabled(chip::Logging::kLogCategory_##CAT)) \ + { \ + chip::Logging::Log(chip::Logging::kLogModule_##MOD, chip::Logging::kLogCategory_##CAT, MSG, ##__VA_ARGS__); \ + } \ + } while (0) +#endif // CHIP_PW_TOKENIZER_LOGGING + +#define ChipInternalLogByteSpanImpl(MOD, CAT, DATA) \ + do \ + { \ + if (chip::Logging::IsCategoryEnabled(chip::Logging::kLogCategory_##CAT)) \ + { \ + chip::Logging::LogByteSpan(chip::Logging::kLogModule_##MOD, chip::Logging::kLogCategory_##CAT, DATA); \ + } \ + } while (0) + +#endif // _CHIP_USE_LOGGING + } // namespace Logging } // namespace chip diff --git a/src/lib/support/tests/BUILD.gn b/src/lib/support/tests/BUILD.gn index 866fd6391feabd..0c1aee8ed3efd9 100644 --- a/src/lib/support/tests/BUILD.gn +++ b/src/lib/support/tests/BUILD.gn @@ -64,7 +64,7 @@ chip_test_suite("tests") { "-Wconversion", # TODO(#21255): work-around for SimpleStateMachine constructor issue. - "-Wno-error=uninitialized", + "-Wno-uninitialized", ] public_deps = [ diff --git a/src/lib/support/tests/TestBufferReader.cpp b/src/lib/support/tests/TestBufferReader.cpp index bcf2cc5503f7b1..ea501ee19ae47a 100644 --- a/src/lib/support/tests/TestBufferReader.cpp +++ b/src/lib/support/tests/TestBufferReader.cpp @@ -141,7 +141,7 @@ static const nlTest sTests[] = { NL_TEST_DEF_FN(TestBufferReader_Basic), NL_TEST NL_TEST_DEF_FN(TestBufferReader_Saturation), NL_TEST_DEF_FN(TestBufferReader_Skip), NL_TEST_SENTINEL() }; -int TestBufferReader(void) +int TestBufferReader() { nlTestSuite theSuite = { "CHIP BufferReader tests", &sTests[0], nullptr, nullptr }; diff --git a/src/lib/support/tests/TestBufferWriter.cpp b/src/lib/support/tests/TestBufferWriter.cpp index 11e2b1fda5c6cf..53a5012172f675 100644 --- a/src/lib/support/tests/TestBufferWriter.cpp +++ b/src/lib/support/tests/TestBufferWriter.cpp @@ -236,7 +236,7 @@ const nlTest sTests[] = { } // namespace -int TestBufferWriter(void) +int TestBufferWriter() { nlTestSuite theSuite = { "BufferWriter", sTests, nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/support/tests/TestBytesToHex.cpp b/src/lib/support/tests/TestBytesToHex.cpp index 21a6963ffd6faa..f5ac6eff27feb1 100644 --- a/src/lib/support/tests/TestBytesToHex.cpp +++ b/src/lib/support/tests/TestBytesToHex.cpp @@ -445,7 +445,7 @@ const nlTest sTests[] = { } // namespace -int TestBytesToHex(void) +int TestBytesToHex() { nlTestSuite theSuite = { "BytesToHex", sTests, nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/support/tests/TestCHIPArgParser.cpp b/src/lib/support/tests/TestCHIPArgParser.cpp index b5674d3e8a5bfa..76d079c7bab33b 100644 --- a/src/lib/support/tests/TestCHIPArgParser.cpp +++ b/src/lib/support/tests/TestCHIPArgParser.cpp @@ -759,7 +759,7 @@ static void ENFORCE_FORMAT(1, 2) HandleArgError(const char * msg, ...) sCallbackRecordCount++; } -int TestCHIPArgParser(void) +int TestCHIPArgParser() { if (chip::Platform::MemoryInit() != CHIP_NO_ERROR) { diff --git a/src/lib/support/tests/TestCHIPCounter.cpp b/src/lib/support/tests/TestCHIPCounter.cpp index e4b64a36db773a..9eff75fba22f24 100644 --- a/src/lib/support/tests/TestCHIPCounter.cpp +++ b/src/lib/support/tests/TestCHIPCounter.cpp @@ -77,7 +77,7 @@ static int TestTeardown(void * inContext) return (SUCCESS); } -int TestCHIPCounter(void) +int TestCHIPCounter() { // clang-format off nlTestSuite theSuite = { diff --git a/src/lib/support/tests/TestDefer.cpp b/src/lib/support/tests/TestDefer.cpp index 248d9bd1d159f5..0ef40f4fda2481 100644 --- a/src/lib/support/tests/TestDefer.cpp +++ b/src/lib/support/tests/TestDefer.cpp @@ -52,7 +52,7 @@ static void TestDeferUsage(nlTestSuite * inSuite, void * inContext) */ static const nlTest sTests[] = { NL_TEST_DEF_FN(TestDeferUsage), NL_TEST_SENTINEL() }; -int TestDefer(void) +int TestDefer() { nlTestSuite theSuite = { "CHIP Defer tests", &sTests[0], nullptr, nullptr }; diff --git a/src/lib/support/tests/TestErrorStr.cpp b/src/lib/support/tests/TestErrorStr.cpp index 2837b3e024fe8b..c39d355ae2efc4 100644 --- a/src/lib/support/tests/TestErrorStr.cpp +++ b/src/lib/support/tests/TestErrorStr.cpp @@ -178,7 +178,7 @@ static const nlTest sTests[] = }; // clang-format on -int TestErrorStr(void) +int TestErrorStr() { // clang-format off nlTestSuite theSuite = diff --git a/src/lib/support/tests/TestIniEscaping.cpp b/src/lib/support/tests/TestIniEscaping.cpp index 3c8890bb4d60be..44f8b37058b3cb 100644 --- a/src/lib/support/tests/TestIniEscaping.cpp +++ b/src/lib/support/tests/TestIniEscaping.cpp @@ -100,7 +100,7 @@ const nlTest sTests[] = { NL_TEST_DEF("Test escaping API", TestEscaping), NL_TES } // namespace -int TestIniEscaping(void) +int TestIniEscaping() { nlTestSuite theSuite = { "IniEscaping tests", &sTests[0], nullptr, nullptr }; diff --git a/src/lib/support/tests/TestOwnerOf.cpp b/src/lib/support/tests/TestOwnerOf.cpp index 709e1d46e59b72..2d957e1c022aad 100644 --- a/src/lib/support/tests/TestOwnerOf.cpp +++ b/src/lib/support/tests/TestOwnerOf.cpp @@ -49,7 +49,7 @@ static void TestMemberOwner(nlTestSuite * inSuite, void * inContext) */ static const nlTest sTests[] = { NL_TEST_DEF_FN(TestMemberOwner), NL_TEST_SENTINEL() }; -int TestOwnerOf(void) +int TestOwnerOf() { nlTestSuite theSuite = { "CHIP OwnerOf tests", &sTests[0], nullptr, nullptr }; diff --git a/src/lib/support/tests/TestPrivateHeap.cpp b/src/lib/support/tests/TestPrivateHeap.cpp index 09f2ae7f7d56d3..dae83951a2faa8 100644 --- a/src/lib/support/tests/TestPrivateHeap.cpp +++ b/src/lib/support/tests/TestPrivateHeap.cpp @@ -353,7 +353,7 @@ const nlTest sTests[] = { } // namespace -int TestPrivateHeap(void) +int TestPrivateHeap() { nlTestSuite theSuite = { "PrivateHeap", sTests, nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/support/tests/TestSafeInt.cpp b/src/lib/support/tests/TestSafeInt.cpp index 34de2a97d9a738..6b9121896cce89 100644 --- a/src/lib/support/tests/TestSafeInt.cpp +++ b/src/lib/support/tests/TestSafeInt.cpp @@ -355,7 +355,7 @@ static const nlTest sTests[] = { NL_TEST_DEF_FN(TestCanCastTo_Int8), NL_TEST_DE NL_TEST_DEF_FN(TestCanCastTo_Int32), NL_TEST_DEF_FN(TestCanCastTo_Int64), NL_TEST_DEF_FN(TestCastToSigned), NL_TEST_SENTINEL() }; -int TestSafeInt(void) +int TestSafeInt() { nlTestSuite theSuite = { "CHIP SafeInt tests", &sTests[0], nullptr, nullptr }; diff --git a/src/lib/support/tests/TestSafeString.cpp b/src/lib/support/tests/TestSafeString.cpp index 474fe2baa96f4b..acc4800f889cfb 100644 --- a/src/lib/support/tests/TestSafeString.cpp +++ b/src/lib/support/tests/TestSafeString.cpp @@ -54,7 +54,7 @@ static void TestTotalStringLength(nlTestSuite * inSuite, void * inContext) */ static const nlTest sTests[] = { NL_TEST_DEF_FN(TestMaxStringLength), NL_TEST_DEF_FN(TestTotalStringLength), NL_TEST_SENTINEL() }; -int TestSafeString(void) +int TestSafeString() { nlTestSuite theSuite = { "CHIP SafeString tests", &sTests[0], nullptr, nullptr }; diff --git a/src/lib/support/tests/TestScopedBuffer.cpp b/src/lib/support/tests/TestScopedBuffer.cpp index 646daed5021d4f..5f851b1531a55f 100644 --- a/src/lib/support/tests/TestScopedBuffer.cpp +++ b/src/lib/support/tests/TestScopedBuffer.cpp @@ -141,7 +141,7 @@ static const nlTest sTests[] = { NL_TEST_SENTINEL() // }; -int TestScopedBuffer(void) +int TestScopedBuffer() { nlTestSuite theSuite = { "CHIP ScopedBuffer tests", &sTests[0], Setup, Teardown }; diff --git a/src/lib/support/tests/TestSerializableIntegerSet.cpp b/src/lib/support/tests/TestSerializableIntegerSet.cpp index cbf58d31560981..a630a5cb4cf722 100644 --- a/src/lib/support/tests/TestSerializableIntegerSet.cpp +++ b/src/lib/support/tests/TestSerializableIntegerSet.cpp @@ -172,7 +172,7 @@ static const nlTest sTests[] = { NL_TEST_SENTINEL() // }; -int TestSerializableIntegerSet(void) +int TestSerializableIntegerSet() { nlTestSuite theSuite = { "CHIP SerializableIntegerSet tests", &sTests[0], Setup, Teardown }; diff --git a/src/lib/support/tests/TestSpan.cpp b/src/lib/support/tests/TestSpan.cpp index 742fbc9c12d0f9..06a9a57070bc02 100644 --- a/src/lib/support/tests/TestSpan.cpp +++ b/src/lib/support/tests/TestSpan.cpp @@ -301,7 +301,7 @@ static const nlTest sTests[] = { NL_TEST_DEF_FN(TestByteSpan), NL_TEST_DEF NL_TEST_DEF_FN(TestSubSpan), NL_TEST_DEF_FN(TestFromZclString), NL_TEST_DEF_FN(TestFromCharString), NL_TEST_SENTINEL() }; -int TestSpan(void) +int TestSpan() { nlTestSuite theSuite = { "CHIP Span tests", &sTests[0], nullptr, nullptr }; diff --git a/src/lib/support/tests/TestStringBuilder.cpp b/src/lib/support/tests/TestStringBuilder.cpp index 5d59e3bb4aa949..2886d6fe4b307d 100644 --- a/src/lib/support/tests/TestStringBuilder.cpp +++ b/src/lib/support/tests/TestStringBuilder.cpp @@ -87,7 +87,7 @@ const nlTest sTests[] = { } // namespace -int TestStringBuilder(void) +int TestStringBuilder() { nlTestSuite theSuite = { "StringBuilder", sTests, nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/support/tests/TestTestPersistentStorageDelegate.cpp b/src/lib/support/tests/TestTestPersistentStorageDelegate.cpp index 100fed7a7a1eb5..622520b320a5eb 100644 --- a/src/lib/support/tests/TestTestPersistentStorageDelegate.cpp +++ b/src/lib/support/tests/TestTestPersistentStorageDelegate.cpp @@ -347,7 +347,7 @@ const nlTest sTests[] = { NL_TEST_DEF("Test basic API", TestBasicApi), } // namespace -int TestTestPersistentStorageDelegate(void) +int TestTestPersistentStorageDelegate() { nlTestSuite theSuite = { "TestPersistentStorageDelegate tests", &sTests[0], nullptr, nullptr }; diff --git a/src/lib/support/tests/TestThreadOperationalDataset.cpp b/src/lib/support/tests/TestThreadOperationalDataset.cpp index 86bf61e17dc192..24586f39234b64 100644 --- a/src/lib/support/tests/TestThreadOperationalDataset.cpp +++ b/src/lib/support/tests/TestThreadOperationalDataset.cpp @@ -288,7 +288,7 @@ const nlTest sTests[] = { } // namespace -int TestThreadOperationalDatasetBuilder(void) +int TestThreadOperationalDatasetBuilder() { nlTestSuite theSuite = { "ThreadOperationalDataset", sTests, nullptr, nullptr }; diff --git a/src/lib/support/tests/TestTimeUtils.cpp b/src/lib/support/tests/TestTimeUtils.cpp index 8372eafb840348..35d0e934e38358 100644 --- a/src/lib/support/tests/TestTimeUtils.cpp +++ b/src/lib/support/tests/TestTimeUtils.cpp @@ -1021,7 +1021,7 @@ void TestChipEpochTimeConversion() } } -int TestTimeUtils(void) +int TestTimeUtils() { TestOrdinalDateConversion(); TestDaysSinceEpochConversion(); diff --git a/src/lib/support/tests/TestTlvToJson.cpp b/src/lib/support/tests/TestTlvToJson.cpp index 881045f17cddf8..95a8967820317e 100644 --- a/src/lib/support/tests/TestTlvToJson.cpp +++ b/src/lib/support/tests/TestTlvToJson.cpp @@ -147,7 +147,7 @@ void TestConverter(nlTestSuite * inSuite, void * inContext) ByteSpan byteSpan(byteBuf); EncodeAndValidate(byteSpan, "{\n" - " \"value\" : \"AQIDBP/+mYjdzQ==\"\n" + " \"value\" : \"base64:AQIDBP/+mYjdzQ==\"\n" "}\n"); DataModel::Nullable nullValue; @@ -170,7 +170,7 @@ void TestConverter(nlTestSuite * inSuite, void * inContext) " \"0\" : 20,\n" " \"1\" : true,\n" " \"2\" : 0,\n" - " \"3\" : \"AQIDBP/+mYjdzQ==\",\n" + " \"3\" : \"base64:AQIDBP/+mYjdzQ==\",\n" " \"4\" : \"hello\",\n" " \"5\" : 0,\n" " \"6\" : 1.0,\n" @@ -188,6 +188,18 @@ void TestConverter(nlTestSuite * inSuite, void * inContext) " \"value\" : [ 1, 2, 3, 4 ]\n" "}\n"); + int8uList = {}; + EncodeAndValidate(int8uList, + "{\n" + " \"value\" : []\n" + "}\n"); + + DataModel::Nullable> nullValueList; + EncodeAndValidate(nullValueList, + "{\n" + " \"value\" : null\n" + "}\n"); + Clusters::UnitTesting::Structs::SimpleStruct::Type structListData[2] = { structVal, structVal }; DataModel::List structList; @@ -200,7 +212,7 @@ void TestConverter(nlTestSuite * inSuite, void * inContext) " \"0\" : 20,\n" " \"1\" : true,\n" " \"2\" : 0,\n" - " \"3\" : \"AQIDBP/+mYjdzQ==\",\n" + " \"3\" : \"base64:AQIDBP/+mYjdzQ==\",\n" " \"4\" : \"hello\",\n" " \"5\" : 0,\n" " \"6\" : 1.0,\n" @@ -210,7 +222,7 @@ void TestConverter(nlTestSuite * inSuite, void * inContext) " \"0\" : 20,\n" " \"1\" : true,\n" " \"2\" : 0,\n" - " \"3\" : \"AQIDBP/+mYjdzQ==\",\n" + " \"3\" : \"base64:AQIDBP/+mYjdzQ==\",\n" " \"4\" : \"hello\",\n" " \"5\" : 0,\n" " \"6\" : 1.0,\n" @@ -237,7 +249,7 @@ const nlTest sTests[] = { NL_TEST_DEF("TestConverter", TestConverter), NL_TEST_S } // namespace -int TestTlvJson(void) +int TestTlvJson() { nlTestSuite theSuite = { "TlvJson", sTests, Initialize, Finalize }; nlTestRunner(&theSuite, nullptr); diff --git a/src/lib/support/tests/TestZclString.cpp b/src/lib/support/tests/TestZclString.cpp index 06a7cb43c4b5fa..c3b97984353377 100644 --- a/src/lib/support/tests/TestZclString.cpp +++ b/src/lib/support/tests/TestZclString.cpp @@ -167,7 +167,7 @@ static const nlTest sTests[] = { NL_TEST_DEF_FN(TestZclStringWhenBufferIsZero), NL_TEST_DEF_FN(TestZclStringBiggerThanMaximumSize_Length_257), NL_TEST_SENTINEL() }; -int TestZclString(void) +int TestZclString() { nlTestSuite theSuite = { "CHIP Memory Allocation tests", &sTests[0], TestZclString_Setup, TestZclString_Teardown }; diff --git a/src/messaging/tests/echo/common.cpp b/src/messaging/tests/echo/common.cpp index 84e8b09cb9b531..22a21ca391c95c 100644 --- a/src/messaging/tests/echo/common.cpp +++ b/src/messaging/tests/echo/common.cpp @@ -36,7 +36,7 @@ chip::Messaging::ExchangeManager gExchangeManager; chip::secure_channel::MessageCounterManager gMessageCounterManager; chip::TestPersistentStorageDelegate gStorage; -void InitializeChip(void) +void InitializeChip() { CHIP_ERROR err = CHIP_NO_ERROR; @@ -62,7 +62,7 @@ void InitializeChip(void) } } -void ShutdownChip(void) +void ShutdownChip() { gMessageCounterManager.Shutdown(); gExchangeManager.Shutdown(); diff --git a/src/platform/BUILD.gn b/src/platform/BUILD.gn index c02b331b49af33..b9f75555e02cd8 100644 --- a/src/platform/BUILD.gn +++ b/src/platform/BUILD.gn @@ -164,6 +164,11 @@ if (chip_device_platform != "none" && chip_device_platform != "external") { "CHIP_DEVICE_LAYER_TARGET_EFR32=1", "CHIP_DEVICE_LAYER_TARGET=silabs", ] + } else if (chip_device_platform == "SiWx917") { + defines += [ + "CHIP_DEVICE_LAYER_TARGET_EFR32=1", + "CHIP_DEVICE_LAYER_TARGET=silabs", + ] } else if (chip_device_platform == "esp32") { defines += [ "CHIP_DEVICE_LAYER_TARGET_ESP32=1", @@ -278,6 +283,11 @@ if (chip_device_platform != "none" && chip_device_platform != "external") { "CHIP_DEVICE_LAYER_TARGET=mt793x", "CHIP_DEVICE_CONFIG_ENABLE_WIFI=${chip_enable_wifi}", ] + } else if (chip_device_platform == "openiotsdk") { + defines += [ + "CHIP_DEVICE_LAYER_TARGET_OPEN_IOT_SDK=1", + "CHIP_DEVICE_LAYER_TARGET=openiotsdk", + ] } if (chip_device_config_device_software_version_string != "") { @@ -410,6 +420,8 @@ if (chip_device_platform != "none") { _platform_target = "Darwin" } else if (chip_device_platform == "efr32") { _platform_target = "silabs/EFR32" + } else if (chip_device_platform == "SiWx917") { + _platform_target = "silabs/SiWx917" } else if (chip_device_platform == "esp32") { _platform_target = "ESP32" } else if (chip_device_platform == "k32w0") { @@ -452,6 +464,8 @@ if (chip_device_platform != "none") { _platform_target = "Beken" } else if (chip_device_platform == "mt793x") { _platform_target = "mt793x" + } else if (chip_device_platform == "openiotsdk") { + _platform_target = "openiotsdk" } else { assert(false, "Unknown chip_device_platform: ${chip_device_platform}") } diff --git a/src/platform/Darwin/BLEManagerImpl.cpp b/src/platform/Darwin/BLEManagerImpl.cpp index 11365ee3e585b4..97853f783fd2d4 100644 --- a/src/platform/Darwin/BLEManagerImpl.cpp +++ b/src/platform/Darwin/BLEManagerImpl.cpp @@ -88,7 +88,7 @@ void BLEManagerImpl::_Shutdown() } } -bool BLEManagerImpl::_IsAdvertisingEnabled(void) +bool BLEManagerImpl::_IsAdvertisingEnabled() { ChipLogDetail(DeviceLayer, "%s", __FUNCTION__); return false; @@ -106,7 +106,7 @@ CHIP_ERROR BLEManagerImpl::_SetAdvertisingMode(BLEAdvertisingMode mode) return CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE; } -bool BLEManagerImpl::_IsAdvertising(void) +bool BLEManagerImpl::_IsAdvertising() { ChipLogDetail(DeviceLayer, "%s", __FUNCTION__); return false; @@ -129,7 +129,7 @@ BleLayer * BLEManagerImpl::_GetBleLayer() return this; } -uint16_t BLEManagerImpl::_NumConnections(void) +uint16_t BLEManagerImpl::_NumConnections() { ChipLogDetail(DeviceLayer, "%s", __FUNCTION__); return 0; diff --git a/src/platform/Darwin/BUILD.gn b/src/platform/Darwin/BUILD.gn index da17b8af7042a6..1a23fc1d1ea991 100644 --- a/src/platform/Darwin/BUILD.gn +++ b/src/platform/Darwin/BUILD.gn @@ -13,6 +13,7 @@ # limitations under the License. import("//build_overrides/chip.gni") +import("//build_overrides/nlassert.gni") import("${chip_root}/src/platform/device.gni") @@ -60,7 +61,7 @@ static_library("Darwin") { "DnssdImpl.cpp", "DnssdImpl.h", "InetPlatformConfig.h", - "Logging.cpp", + "LoggingImpl.cpp", "MdnsError.cpp", "MdnsError.h", "NetworkCommissioningDriver.h", @@ -81,7 +82,7 @@ static_library("Darwin") { ] } - if (chip_disable_platform_kvs == false) { + if (!chip_disable_platform_kvs) { sources += [ "DeviceInstanceInfoProviderImpl.cpp", "DeviceInstanceInfoProviderImpl.h", @@ -91,6 +92,7 @@ static_library("Darwin") { } deps = [ + ":logging", "${chip_root}/src/lib/dnssd:platform_header", "${chip_root}/src/setup_payload", ] @@ -123,3 +125,21 @@ static_library("Darwin") { ] } } + +static_library("logging") { + sources = [ + "Logging.h", + "Logging.mm", + ] + + deps = [ + "${chip_root}/src/lib/core:chip_config_header", # for lib/support/Span.h + "${chip_root}/src/lib/support:attributes", + "${chip_root}/src/lib/support:logging_constants", + "${nlassert_root}:nlassert", # for lib/support/Span.h + ] + + configs += [ "${chip_root}/src:includes" ] + cflags = [ "-fobjc-arc" ] + frameworks = [ "Foundation.framework" ] +} diff --git a/src/platform/Darwin/ConfigurationManagerImpl.cpp b/src/platform/Darwin/ConfigurationManagerImpl.cpp index d624821c9e8e5e..a24e9b84e07c27 100644 --- a/src/platform/Darwin/ConfigurationManagerImpl.cpp +++ b/src/platform/Darwin/ConfigurationManagerImpl.cpp @@ -487,7 +487,7 @@ CHIP_ERROR ConfigurationManagerImpl::WriteConfigValueBin(Key key, const uint8_t #endif // CHIP_DISABLE_PLATFORM_KVS } -void ConfigurationManagerImpl::RunConfigUnitTest(void) +void ConfigurationManagerImpl::RunConfigUnitTest() { #if CHIP_DISABLE_PLATFORM_KVS return; diff --git a/src/platform/Darwin/DnssdImpl.cpp b/src/platform/Darwin/DnssdImpl.cpp index c29a9c33b87ba3..2718cf4abaf25e 100644 --- a/src/platform/Darwin/DnssdImpl.cpp +++ b/src/platform/Darwin/DnssdImpl.cpp @@ -198,7 +198,7 @@ CHIP_ERROR Register(void * context, DnssdPublishCallback callback, uint32_t inte sdCtx->mHostNameRegistrar.Init(hostname, addressType, interfaceId); DNSServiceRef sdRef; - auto err = DNSServiceRegister(&sdRef, kRegisterFlags, interfaceId, name, type, kLocalDot, hostname, ntohs(port), record.size(), + auto err = DNSServiceRegister(&sdRef, kRegisterFlags, interfaceId, name, type, kLocalDot, hostname, htons(port), record.size(), record.data(), OnRegister, sdCtx); VerifyOrReturnError(kDNSServiceErr_NoError == err, sdCtx->Finalize(err)); diff --git a/src/platform/Darwin/Logging.cpp b/src/platform/Darwin/Logging.cpp deleted file mode 100644 index 5124ed427a69e5..00000000000000 --- a/src/platform/Darwin/Logging.cpp +++ /dev/null @@ -1,78 +0,0 @@ -/* See Project chip LICENSE file for licensing information. */ - -#include -#include -#include - -#include - -#include - -#include -#include -#include -#include -#include -#include - -namespace chip { -namespace Logging { -namespace Platform { - -void ENFORCE_FORMAT(3, 0) LogV(const char * module, uint8_t category, const char * msg, va_list v) -{ - timeval time; - gettimeofday(&time, nullptr); - long ms = (time.tv_sec * 1000) + (time.tv_usec / 1000); - - uint64_t ktid; - pthread_threadid_np(nullptr, &ktid); - - char formattedMsg[CHIP_CONFIG_LOG_MESSAGE_MAX_SIZE]; - int32_t prefixLen = snprintf(formattedMsg, sizeof(formattedMsg), "[%ld] [%lld:%lld] CHIP: [%s] ", ms, (long long) getpid(), - (long long) ktid, module); - static os_log_t log = os_log_create("com.csa.matter", "all"); - if (prefixLen < 0) - { - // This should not happen - return; - } - - if (static_cast(prefixLen) >= sizeof(formattedMsg)) - { - prefixLen = sizeof(formattedMsg) - 1; - } - - vsnprintf(formattedMsg + prefixLen, sizeof(formattedMsg) - static_cast(prefixLen), msg, v); - - switch (category) - { - case kLogCategory_Error: - os_log_with_type(log, OS_LOG_TYPE_ERROR, "🔴 %{public}s", formattedMsg); -#if TARGET_OS_MAC && TARGET_OS_IPHONE == 0 - fprintf(stdout, "\033[1;31m"); -#endif - break; - - case kLogCategory_Progress: - os_log_with_type(log, OS_LOG_TYPE_DEFAULT, "🔵 %{public}s", formattedMsg); -#if TARGET_OS_MAC && TARGET_OS_IPHONE == 0 - fprintf(stdout, "\033[0;32m"); -#endif - break; - - case kLogCategory_Detail: - os_log_with_type(log, OS_LOG_TYPE_DEFAULT, "🟢 %{public}s", formattedMsg); -#if TARGET_OS_MAC && TARGET_OS_IPHONE == 0 - fprintf(stdout, "\033[0;34m"); -#endif - break; - } -#if TARGET_OS_MAC && TARGET_OS_IPHONE == 0 - fprintf(stdout, "%s\033[0m\n", formattedMsg); -#endif -} - -} // namespace Platform -} // namespace Logging -} // namespace chip diff --git a/src/platform/Darwin/Logging.h b/src/platform/Darwin/Logging.h new file mode 100644 index 00000000000000..7fcb82a99f663a --- /dev/null +++ b/src/platform/Darwin/Logging.h @@ -0,0 +1,85 @@ +/* + * + * Copyright (c) 2021 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +#include +#include + +#include + +#ifdef __OBJC__ +@class NSString; +#endif // __OBJC__ + +#define ChipPlatformLog(MOD, CAT, MSG, ...) \ + do \ + { \ + ChipPlatformValidateLogFormat(MSG, ##__VA_ARGS__); /* validate once and ignore warnings from os_log() / Log() */ \ + _Pragma("clang diagnostic push"); \ + _Pragma("clang diagnostic ignored \"-Wformat\""); \ + os_log_with_type(chip::Logging::Platform::LoggerForModule(chip::Logging::kLogModule_##MOD, #MOD), \ + static_cast(chip::Logging::Platform::kOSLogCategory_##CAT), MSG, ##__VA_ARGS__); \ + ChipInternalLogImpl(MOD, CAT, MSG, ##__VA_ARGS__); \ + _Pragma("clang diagnostic pop"); \ + } while (0) + +#define ChipPlatformLogByteSpan(MOD, CAT, DATA) \ + do \ + { \ + chip::Logging::Platform::LogByteSpan(chip::Logging::kLogModule_##MOD, #MOD, \ + static_cast(chip::Logging::Platform::kOSLogCategory_##CAT), DATA); \ + ChipInternalLogByteSpanImpl(MOD, CAT, DATA); \ + } while (0) + +namespace chip { + +// Avoid includes cycle: Span.h indirectly includes CHIPLogging.h +template +class Span; +using ByteSpan = Span; + +namespace Logging { +namespace Platform { + +// Names align with chip::Logging::LogCategory +enum OSLogCategory +{ + kOSLogCategory_Error = OS_LOG_TYPE_ERROR, + kOSLogCategory_Progress = OS_LOG_TYPE_DEFAULT, + kOSLogCategory_Detail = OS_LOG_TYPE_INFO, + kOSLogCategory_Automation = OS_LOG_TYPE_DEFAULT, +}; + +DLL_LOCAL os_log_t LoggerForModule(chip::Logging::LogModule moduleId, char const * moduleName); +DLL_LOCAL void LogByteSpan(chip::Logging::LogModule moduleId, char const * moduleName, os_log_type_t type, + const chip::ByteSpan & span); + +// Helper constructs for compile-time validation of format strings for C++ / ObjC++ contexts. +// Note that ObjC++ contexts are restricted to NSString style specifiers. Supporting os_log() +// specifiers would require these to be emulated or stripped when log redirection is used. +#ifdef __OBJC__ +DLL_LOCAL bool ValidateLogFormat(NSString * format, ...) __attribute__((format(__NSString__, 1, 0))); // not implemented +#define ChipPlatformValidateLogFormat(F, ...) ((void) sizeof(chip::Logging::Platform::ValidateLogFormat(@F, ##__VA_ARGS__))) +#else // __OBJC__ +DLL_LOCAL bool ValidateLogFormat(char const * format, ...) __attribute__((format(printf, 1, 0))); // not implemented +#define ChipPlatformValidateLogFormat(F, ...) ((void) sizeof(chip::Logging::Platform::ValidateLogFormat(F, ##__VA_ARGS__))) +#endif // __OBJC__ + +} // namespace Platform +} // namespace Logging +} // namespace chip diff --git a/src/platform/Darwin/Logging.mm b/src/platform/Darwin/Logging.mm new file mode 100644 index 00000000000000..5bb751597c8281 --- /dev/null +++ b/src/platform/Darwin/Logging.mm @@ -0,0 +1,68 @@ +/* + * + * Copyright (c) 2021 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#if !__has_feature(objc_arc) +#error This file must be compiled with ARC. Use -fobjc-arc flag (or convert project to ARC). +#endif + +#include "Logging.h" + +#include + +#import +#import + +namespace chip { +namespace Logging { + namespace Platform { + + os_log_t LoggerForModule(chip::Logging::LogModule moduleID, char const * moduleName) + { + if (moduleID <= kLogModule_NotSpecified || kLogModule_Max <= moduleID) { + moduleID = kLogModule_NotSpecified; + moduleName = "Default"; + } + + static struct { + dispatch_once_t onceToken; + os_log_t logger; + } cache[kLogModule_Max]; + auto & entry = cache[moduleID]; + dispatch_once(&entry.onceToken, ^{ + entry.logger = os_log_create("com.csa.matter", moduleName); + }); + return entry.logger; + } + + void LogByteSpan( + chip::Logging::LogModule moduleId, char const * moduleName, os_log_type_t type, const chip::ByteSpan & span) + { + os_log_t logger = LoggerForModule(moduleId, moduleName); + if (os_log_type_enabled(logger, type)) { + auto size = span.size(); + auto data = span.data(); + NSMutableString * string = [[NSMutableString alloc] initWithCapacity:(size * 6)]; // 6 characters per byte + for (size_t i = 0; i < size; i++) { + [string appendFormat:((i % 8 != 7) ? @"0x%02x, " : @"0x%02x,\n"), data[i]]; + } + os_log_with_type(logger, type, "%@", string); + } + } + + } // namespace Platform +} // namespace Logging +} // namespace chip diff --git a/src/platform/Darwin/LoggingImpl.cpp b/src/platform/Darwin/LoggingImpl.cpp new file mode 100644 index 00000000000000..2d6c1b3b744294 --- /dev/null +++ b/src/platform/Darwin/LoggingImpl.cpp @@ -0,0 +1,34 @@ +/* + * + * Copyright (c) 2021 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +namespace chip { +namespace Logging { +namespace Platform { + +void LogV(const char * module, uint8_t category, const char * msg, va_list v) +{ + // ChipPlatformLog expands to an os_log call directly (see Logging.h), so + // we don't need to do anything further here. However his function and the + // call to it still exist because of scenarios where a different logging + // backend (usually stdio) is swapped in at link time, e.g. for unit tests. +} + +} // namespace Platform +} // namespace Logging +} // namespace chip diff --git a/src/platform/Darwin/PosixConfig.cpp b/src/platform/Darwin/PosixConfig.cpp index 7740d6637344a1..d54713edf532de 100644 --- a/src/platform/Darwin/PosixConfig.cpp +++ b/src/platform/Darwin/PosixConfig.cpp @@ -184,7 +184,7 @@ CHIP_ERROR PosixConfig::ClearNamespace(const char * ns) return err; } -CHIP_ERROR PosixConfig::FactoryResetConfig(void) +CHIP_ERROR PosixConfig::FactoryResetConfig() { CHIP_ERROR err = CHIP_ERROR_PERSISTED_STORAGE_FAILED; SuccessOrExit(err); diff --git a/src/platform/Darwin/SystemPlatformConfig.h b/src/platform/Darwin/SystemPlatformConfig.h index 48613ba75db9b2..19df50055af2ac 100644 --- a/src/platform/Darwin/SystemPlatformConfig.h +++ b/src/platform/Darwin/SystemPlatformConfig.h @@ -40,5 +40,7 @@ struct ChipDeviceEvent; #define CHIP_SYSTEM_CONFIG_PLATFORM_PROVIDES_TIME 1 #define CHIP_SYSTEM_CONFIG_USE_POSIX_TIME_FUNCTS 1 #define CHIP_SYSTEM_CONFIG_POOL_USE_HEAP 1 +#define CHIP_SYSTEM_CONFIG_PLATFORM_LOG 1 +#define CHIP_SYSTEM_CONFIG_PLATFORM_LOG_INCLUDE // ========== Platform-specific Configuration Overrides ========= diff --git a/src/platform/ESP32/ESP32Config.cpp b/src/platform/ESP32/ESP32Config.cpp index c700b35bb87012..6d91c0d2566ed0 100644 --- a/src/platform/ESP32/ESP32Config.cpp +++ b/src/platform/ESP32/ESP32Config.cpp @@ -105,7 +105,7 @@ const char * ESP32Config::GetPartitionLabelByNamespace(const char * ns) { return CHIP_DEVICE_CONFIG_CHIP_CONFIG_NAMESPACE_PARTITION; } - else if (strcmp(ns, kConfigNamespace_ChipCounters)) + else if (strcmp(ns, kConfigNamespace_ChipCounters) == 0) { return CHIP_DEVICE_CONFIG_CHIP_COUNTERS_NAMESPACE_PARTITION; } diff --git a/src/platform/Linux/ConfigurationManagerImpl.cpp b/src/platform/Linux/ConfigurationManagerImpl.cpp index afcd6c68bd309f..e3710959e5a6f1 100644 --- a/src/platform/Linux/ConfigurationManagerImpl.cpp +++ b/src/platform/Linux/ConfigurationManagerImpl.cpp @@ -129,31 +129,46 @@ CHIP_ERROR ConfigurationManagerImpl::Init() CHIP_ERROR ConfigurationManagerImpl::GetPrimaryWiFiMACAddress(uint8_t * buf) { struct ifaddrs * addresses = nullptr; + struct sockaddr_ll * mac = nullptr; CHIP_ERROR error = CHIP_NO_ERROR; - bool found = false; // TODO: ideally the buffer size should have been passed as a span, however // for now use the size that is validated in GenericConfigurationManagerImpl.ipp constexpr size_t kExpectedBufMinSize = ConfigurationManager::kPrimaryMACAddressLength; memset(buf, 0, kExpectedBufMinSize); + // Prioritize address for interface matching the WiFi interface name + // specified in the config headers. Otherwise, use the address for the + // first non-loopback interface. VerifyOrExit(getifaddrs(&addresses) == 0, error = CHIP_ERROR_INTERNAL); for (auto addr = addresses; addr != nullptr; addr = addr->ifa_next) { - if ((addr->ifa_addr) && (addr->ifa_addr->sa_family == AF_PACKET) && strncmp(addr->ifa_name, "lo", IFNAMSIZ) != 0) + if ((addr->ifa_addr) && (addr->ifa_addr->sa_family == AF_PACKET)) { - struct sockaddr_ll * mac = (struct sockaddr_ll *) addr->ifa_addr; - memcpy(buf, mac->sll_addr, std::min(mac->sll_halen, kExpectedBufMinSize)); - found = true; - break; + if (strncmp(addr->ifa_name, CHIP_DEVICE_CONFIG_WIFI_STATION_IF_NAME, IFNAMSIZ) == 0) + { + mac = (struct sockaddr_ll *) addr->ifa_addr; + break; + } + + if (strncmp(addr->ifa_name, "lo", IFNAMSIZ) != 0 && !mac) + { + mac = (struct sockaddr_ll *) addr->ifa_addr; + } } } - freeifaddrs(addresses); - if (!found) + + if (mac) + { + memcpy(buf, mac->sll_addr, std::min(mac->sll_halen, kExpectedBufMinSize)); + } + else { error = CHIP_ERROR_NO_ENDPOINT; } + freeifaddrs(addresses); + exit: return error; } @@ -292,7 +307,7 @@ CHIP_ERROR ConfigurationManagerImpl::WriteConfigValueBin(Key key, const uint8_t return PosixConfig::WriteConfigValueBin(key, data, dataLen); } -void ConfigurationManagerImpl::RunConfigUnitTest(void) +void ConfigurationManagerImpl::RunConfigUnitTest() { PosixConfig::RunConfigUnitTest(); } diff --git a/src/platform/Linux/PlatformManagerImpl.cpp b/src/platform/Linux/PlatformManagerImpl.cpp index e29f04bd1d0383..ff753e40fab6ba 100644 --- a/src/platform/Linux/PlatformManagerImpl.cpp +++ b/src/platform/Linux/PlatformManagerImpl.cpp @@ -285,8 +285,8 @@ CHIP_ERROR PlatformManagerImpl::RunOnGLibMainLoopThread(GSourceFunc callback, vo { GMainContext * context = g_main_loop_get_context(mGLibMainLoop); - VerifyOrReturnError(context != nullptr, - (ChipLogDetail(DeviceLayer, "Failed to get GLib main loop context"), CHIP_ERROR_INTERNAL)); + VerifyOrReturnError(context != nullptr, CHIP_ERROR_INTERNAL, + ChipLogDetail(DeviceLayer, "Failed to get GLib main loop context")); // If we've been called from the GLib main loop thread itself, there is no reason to wait // for the callback, as it will be executed immediately by the g_main_context_invoke() call diff --git a/src/platform/Linux/bluez/Helper.cpp b/src/platform/Linux/bluez/Helper.cpp index b00ca750aadac9..ff0c73d1214c8c 100644 --- a/src/platform/Linux/bluez/Helper.cpp +++ b/src/platform/Linux/bluez/Helper.cpp @@ -1438,7 +1438,7 @@ static ConnectionDataBundle * MakeConnectionDataBundle(BLE_CONNECTION_OBJECT apC CHIP_ERROR SendBluezIndication(BLE_CONNECTION_OBJECT apConn, chip::System::PacketBufferHandle apBuf) { - VerifyOrReturnError(!apBuf.IsNull(), (ChipLogError(DeviceLayer, "apBuf is NULL in %s", __func__), CHIP_ERROR_INVALID_ARGUMENT)); + VerifyOrReturnError(!apBuf.IsNull(), CHIP_ERROR_INVALID_ARGUMENT, ChipLogError(DeviceLayer, "apBuf is NULL in %s", __func__)); return PlatformMgrImpl().ScheduleOnGLibMainLoopThread(BluezC2Indicate, MakeConnectionDataBundle(apConn, apBuf)); } @@ -1476,33 +1476,32 @@ CHIP_ERROR CloseBluezConnection(BLE_CONNECTION_OBJECT apConn) CHIP_ERROR StartBluezAdv(BluezEndpoint * apEndpoint) { CHIP_ERROR err = PlatformMgrImpl().ScheduleOnGLibMainLoopThread(BluezAdvStart, apEndpoint); - VerifyOrReturnError(err == CHIP_NO_ERROR, - (ChipLogError(Ble, "Failed to schedule BluezAdvStart() on CHIPoBluez thread"), CHIP_ERROR_INCORRECT_STATE)); + VerifyOrReturnError(err == CHIP_NO_ERROR, CHIP_ERROR_INCORRECT_STATE, + ChipLogError(Ble, "Failed to schedule BluezAdvStart() on CHIPoBluez thread")); return err; } CHIP_ERROR StopBluezAdv(BluezEndpoint * apEndpoint) { CHIP_ERROR err = PlatformMgrImpl().ScheduleOnGLibMainLoopThread(BluezAdvStop, apEndpoint); - VerifyOrReturnError(err == CHIP_NO_ERROR, - (ChipLogError(Ble, "Failed to schedule BluezAdvStop() on CHIPoBluez thread"), CHIP_ERROR_INCORRECT_STATE)); + VerifyOrReturnError(err == CHIP_NO_ERROR, CHIP_ERROR_INCORRECT_STATE, + ChipLogError(Ble, "Failed to schedule BluezAdvStop() on CHIPoBluez thread")); return err; } CHIP_ERROR BluezAdvertisementSetup(BluezEndpoint * apEndpoint) { CHIP_ERROR err = PlatformMgrImpl().ScheduleOnGLibMainLoopThread(BluezAdvSetup, apEndpoint); - VerifyOrReturnError(err == CHIP_NO_ERROR, - (ChipLogError(Ble, "Failed to schedule BluezAdvSetup() on CHIPoBluez thread"), CHIP_ERROR_INCORRECT_STATE)); + VerifyOrReturnError(err == CHIP_NO_ERROR, CHIP_ERROR_INCORRECT_STATE, + ChipLogError(Ble, "Failed to schedule BluezAdvSetup() on CHIPoBluez thread")); return err; } CHIP_ERROR BluezGattsAppRegister(BluezEndpoint * apEndpoint) { CHIP_ERROR err = PlatformMgrImpl().ScheduleOnGLibMainLoopThread(BluezPeripheralRegisterApp, apEndpoint); - VerifyOrReturnError( - err == CHIP_NO_ERROR, - (ChipLogError(Ble, "Failed to schedule BluezPeripheralRegisterApp() on CHIPoBluez thread"), CHIP_ERROR_INCORRECT_STATE)); + VerifyOrReturnError(err == CHIP_NO_ERROR, CHIP_ERROR_INCORRECT_STATE, + ChipLogError(Ble, "Failed to schedule BluezPeripheralRegisterApp() on CHIPoBluez thread")); return err; } @@ -1631,7 +1630,7 @@ static gboolean SendWriteRequestImpl(ConnectionDataBundle * data) CHIP_ERROR BluezSendWriteRequest(BLE_CONNECTION_OBJECT apConn, chip::System::PacketBufferHandle apBuf) { - VerifyOrReturnError(!apBuf.IsNull(), (ChipLogError(DeviceLayer, "apBuf is NULL in %s", __func__), CHIP_ERROR_INVALID_ARGUMENT)); + VerifyOrReturnError(!apBuf.IsNull(), CHIP_ERROR_INVALID_ARGUMENT, ChipLogError(DeviceLayer, "apBuf is NULL in %s", __func__)); return PlatformMgrImpl().ScheduleOnGLibMainLoopThread(SendWriteRequestImpl, MakeConnectionDataBundle(apConn, apBuf)); } diff --git a/src/platform/OpenThread/GenericThreadStackManagerImpl_OpenThread.cpp b/src/platform/OpenThread/GenericThreadStackManagerImpl_OpenThread.cpp index 4979e7249873b5..6e59b2e8d0df60 100644 --- a/src/platform/OpenThread/GenericThreadStackManagerImpl_OpenThread.cpp +++ b/src/platform/OpenThread/GenericThreadStackManagerImpl_OpenThread.cpp @@ -1152,8 +1152,24 @@ CHIP_ERROR GenericThreadStackManagerImpl_OpenThread::_WriteThreadNetw app::DataModel::Nullable averageRssi; app::DataModel::Nullable lastRssi; - averageRssi.SetNonNull(neighInfo.mAverageRssi); - lastRssi.SetNonNull(neighInfo.mLastRssi); + if (neighInfo.mAverageRssi == OT_RADIO_RSSI_INVALID) + { + averageRssi.SetNull(); + } + else + { + // Thread average calculation already restrict mAverageRssi to be between -128 and 0 + averageRssi.SetNonNull(neighInfo.mAverageRssi); + } + + if (neighInfo.mAverageRssi == OT_RADIO_RSSI_INVALID) + { + lastRssi.SetNull(); + } + else + { + lastRssi.SetNonNull(((neighInfo.mLastRssi > 0) ? 0 : neighInfo.mLastRssi)); + } neighborTable.averageRssi = averageRssi; neighborTable.lastRssi = lastRssi; @@ -1833,23 +1849,30 @@ GenericThreadStackManagerImpl_OpenThread::SetSEDIntervalMode(Connecti #else uint32_t curIntervalMS = otLinkGetPollPeriod(mOTInst); #endif - + otError otErr = OT_ERROR_NONE; if (interval.count() != curIntervalMS) { #if CHIP_DEVICE_CONFIG_THREAD_SSED // Set CSL period in units of 10 symbols, convert it to microseconds and divide by 1000 to get milliseconds. - otError otErr = otLinkCslSetPeriod(mOTInst, interval.count() * 1000 / OT_US_PER_TEN_SYMBOLS); + otErr = otLinkCslSetPeriod(mOTInst, interval.count() * 1000 / OT_US_PER_TEN_SYMBOLS); + curIntervalMS = otLinkCslGetPeriod(mOTInst) * OT_US_PER_TEN_SYMBOLS / 1000; #else - otError otErr = otLinkSetPollPeriod(mOTInst, interval.count()); + otErr = otLinkSetPollPeriod(mOTInst, interval.count()); + curIntervalMS = otLinkGetPollPeriod(mOTInst); #endif err = MapOpenThreadError(otErr); } Impl()->UnlockThreadStack(); - if (interval.count() != curIntervalMS) + if (otErr != OT_ERROR_NONE) + { + ChipLogError(DeviceLayer, "Failed to set SED interval to %" PRId32 "ms. Defaulting to %" PRId32 "ms", interval.count(), + curIntervalMS); + } + else { - ChipLogProgress(DeviceLayer, "OpenThread SED interval set to %" PRId32 "ms", interval.count()); + ChipLogProgress(DeviceLayer, "OpenThread SED interval is %" PRId32 "ms", curIntervalMS); } return err; diff --git a/src/platform/Tizen/AppPreference.cpp b/src/platform/Tizen/AppPreference.cpp index 722a0fd9eb9f54..bc6e8f1097ec35 100644 --- a/src/platform/Tizen/AppPreference.cpp +++ b/src/platform/Tizen/AppPreference.cpp @@ -16,10 +16,21 @@ */ #include "AppPreference.h" + +#include +#include +#include +#include +#include +#include + #include +#include + #include -#include -#include +#include +#include +#include namespace chip { namespace DeviceLayer { diff --git a/src/platform/Tizen/AppPreference.h b/src/platform/Tizen/AppPreference.h index 2fee34cc3bb263..26acf9d7f8c438 100644 --- a/src/platform/Tizen/AppPreference.h +++ b/src/platform/Tizen/AppPreference.h @@ -17,8 +17,9 @@ #pragma once -#include -#include +#include + +#include namespace chip { namespace DeviceLayer { diff --git a/src/platform/Tizen/BLEManagerImpl.cpp b/src/platform/Tizen/BLEManagerImpl.cpp index c60fb56f70417d..9b2d5e2537fe51 100644 --- a/src/platform/Tizen/BLEManagerImpl.cpp +++ b/src/platform/Tizen/BLEManagerImpl.cpp @@ -21,15 +21,47 @@ * Provides an implementation of the BLEManager singleton object * for Tizen platforms. */ -#include -#include -#include +/** + * Note: BLEManager requires ConnectivityManager to be defined beforehand, + * otherwise we will face circular dependency between them. */ +#include -#if CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE +/** + * Note: Use public include for BLEManager which includes our local + * platform//BLEManagerImpl.h after defining interface class. */ +#include "platform/internal/BLEManager.h" + +#include + +#include +#include +#include +#include +#include +#include -#include "MainLoop.h" #include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "CHIPDevicePlatformEvent.h" +#include "ChipDeviceScanner.h" +#include "MainLoop.h" namespace chip { namespace DeviceLayer { @@ -1383,5 +1415,3 @@ CHIP_ERROR BLEManagerImpl::CancelConnection() } // namespace Internal } // namespace DeviceLayer } // namespace chip - -#endif // CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE diff --git a/src/platform/Tizen/BLEManagerImpl.h b/src/platform/Tizen/BLEManagerImpl.h index f4c8e903b4e2d7..7723d2dcf62221 100644 --- a/src/platform/Tizen/BLEManagerImpl.h +++ b/src/platform/Tizen/BLEManagerImpl.h @@ -23,11 +23,23 @@ #pragma once -#if CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE +#include +#include +#include +#include +#include #include #include -#include + +#include +#include +#include +#include +#include +#include +#include +#include #include "ChipDeviceScanner.h" @@ -263,5 +275,3 @@ inline bool BLEManagerImpl::_IsAdvertising() } // namespace Internal } // namespace DeviceLayer } // namespace chip - -#endif // CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE diff --git a/src/platform/Tizen/BUILD.gn b/src/platform/Tizen/BUILD.gn index e25ab001e591c7..03a858fd2ec1c5 100644 --- a/src/platform/Tizen/BUILD.gn +++ b/src/platform/Tizen/BUILD.gn @@ -37,8 +37,6 @@ static_library("Tizen") { "CHIPDevicePlatformConfig.h", "CHIPDevicePlatformEvent.h", "CHIPPlatformConfig.h", - "ChipDeviceScanner.cpp", - "ChipDeviceScanner.h", "ConfigurationManagerImpl.cpp", "ConfigurationManagerImpl.h", "ConnectivityManagerImpl.cpp", @@ -88,6 +86,8 @@ static_library("Tizen") { "BLEManagerImpl.cpp", "BLEManagerImpl.h", "BlePlatformConfig.h", + "ChipDeviceScanner.cpp", + "ChipDeviceScanner.h", ] } diff --git a/src/platform/Tizen/ChipDeviceScanner.cpp b/src/platform/Tizen/ChipDeviceScanner.cpp index ec29a3f8a881eb..204895347cb45c 100644 --- a/src/platform/Tizen/ChipDeviceScanner.cpp +++ b/src/platform/Tizen/ChipDeviceScanner.cpp @@ -22,14 +22,18 @@ */ #include "ChipDeviceScanner.h" -#include -#include -#if CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE +#include +#include +#include -#include "MainLoop.h" +#include + +#include +#include #include -#include + +#include "MainLoop.h" namespace chip { namespace DeviceLayer { @@ -167,7 +171,7 @@ gboolean ChipDeviceScanner::TriggerScan(GMainLoop * mainLoop, gpointer userData) return false; } -static bool __IsScanFilterSupported(void) +static bool __IsScanFilterSupported() { // Tizen API: bt_adapter_le_is_scan_filter_supported() is currently internal // Defaulting to true @@ -221,7 +225,7 @@ CHIP_ERROR ChipDeviceScanner::StartChipScan(unsigned timeoutMs, ScanFilterType f return err; } -CHIP_ERROR ChipDeviceScanner::StopChipScan(void) +CHIP_ERROR ChipDeviceScanner::StopChipScan() { int ret = BT_ERROR_NONE; ReturnErrorCodeIf(!mIsScanning, CHIP_ERROR_INCORRECT_STATE); @@ -245,7 +249,7 @@ CHIP_ERROR ChipDeviceScanner::StopChipScan(void) return CHIP_NO_ERROR; } -void ChipDeviceScanner::UnRegisterScanFilter(void) +void ChipDeviceScanner::UnRegisterScanFilter() { if (mScanFilter) { @@ -308,5 +312,3 @@ int ChipDeviceScanner::CreateLEScanFilter(ScanFilterType filterType, ScanFilterD } // namespace Internal } // namespace DeviceLayer } // namespace chip - -#endif // CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE diff --git a/src/platform/Tizen/ChipDeviceScanner.h b/src/platform/Tizen/ChipDeviceScanner.h index 7eb2a9de3e248c..f95f4782ece551 100644 --- a/src/platform/Tizen/ChipDeviceScanner.h +++ b/src/platform/Tizen/ChipDeviceScanner.h @@ -23,18 +23,13 @@ #pragma once -#include - -#if CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE +#include +#include #include -#include #include #include -#include - -#include namespace chip { namespace DeviceLayer { @@ -115,5 +110,3 @@ class ChipDeviceScanner } // namespace Internal } // namespace DeviceLayer } // namespace chip - -#endif // CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE diff --git a/src/platform/Tizen/ConfigurationManagerImpl.cpp b/src/platform/Tizen/ConfigurationManagerImpl.cpp index c7255e8c21f47f..961df4130d4603 100644 --- a/src/platform/Tizen/ConfigurationManagerImpl.cpp +++ b/src/platform/Tizen/ConfigurationManagerImpl.cpp @@ -23,16 +23,16 @@ * for Tizen platforms. */ -#include +#include "ConfigurationManagerImpl.h" -#include #include -#include +#include #include #include -#include -#include -#include + +#include "PosixConfig.h" +#include "WiFiManager.h" +#include "platform/internal/GenericConfigurationManagerImpl.ipp" namespace chip { namespace DeviceLayer { @@ -43,7 +43,7 @@ ConfigurationManagerImpl & ConfigurationManagerImpl::GetDefaultInstance() return sInstance; } -CHIP_ERROR ConfigurationManagerImpl::Init(void) +CHIP_ERROR ConfigurationManagerImpl::Init() { CHIP_ERROR error; @@ -88,12 +88,12 @@ CHIP_ERROR ConfigurationManagerImpl::GetPrimaryWiFiMACAddress(uint8_t * buf) #endif } -bool ConfigurationManagerImpl::CanFactoryReset(void) +bool ConfigurationManagerImpl::CanFactoryReset() { return true; } -void ConfigurationManagerImpl::InitiateFactoryReset(void) {} +void ConfigurationManagerImpl::InitiateFactoryReset() {} CHIP_ERROR ConfigurationManagerImpl::ReadPersistedStorageValue(Platform::PersistedStorage::Key key, uint32_t & value) { @@ -170,7 +170,7 @@ CHIP_ERROR ConfigurationManagerImpl::WriteConfigValueBin(Key key, const uint8_t return Internal::PosixConfig::WriteConfigValueBin(key, data, dataLen); } -void ConfigurationManagerImpl::RunConfigUnitTest(void) +void ConfigurationManagerImpl::RunConfigUnitTest() { Internal::PosixConfig::RunConfigUnitTest(); } diff --git a/src/platform/Tizen/ConfigurationManagerImpl.h b/src/platform/Tizen/ConfigurationManagerImpl.h index 2dd07d77879c31..ee9ddc5b427b07 100644 --- a/src/platform/Tizen/ConfigurationManagerImpl.h +++ b/src/platform/Tizen/ConfigurationManagerImpl.h @@ -24,9 +24,15 @@ #pragma once -#include +#include +#include -#include +#include +#include +#include + +#include "PosixConfig.h" +#include "platform/internal/GenericConfigurationManagerImpl.h" namespace chip { namespace DeviceLayer { diff --git a/src/platform/Tizen/ConnectivityManagerImpl.cpp b/src/platform/Tizen/ConnectivityManagerImpl.cpp index 7c7e2eab0ad9be..75a5fb5e5473e0 100644 --- a/src/platform/Tizen/ConnectivityManagerImpl.cpp +++ b/src/platform/Tizen/ConnectivityManagerImpl.cpp @@ -17,32 +17,42 @@ * limitations under the License. */ -#include - +/** + * Note: Use public include for ConnectivityManager which includes our local + * platform//ConnectivityManagerImpl.h after defining interface + * class. */ #include -#include -#include +#if CHIP_DEVICE_CONFIG_ENABLE_WIFI +#include +#endif +#include +#include #include -#include - -#include - +#include +#include +#include +#include +#include +#include + +#include "platform/internal/GenericConnectivityManagerImpl_UDP.ipp" #if INET_CONFIG_ENABLE_TCP_ENDPOINT -#include +#include "platform/internal/GenericConnectivityManagerImpl_TCP.ipp" #endif - #if CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE -#include +#include "platform/internal/GenericConnectivityManagerImpl_BLE.ipp" #endif - #if CHIP_DEVICE_CONFIG_ENABLE_THREAD -#include +#include "platform/internal/GenericConnectivityManagerImpl_Thread.ipp" +#endif +#if CHIP_DEVICE_CONFIG_ENABLE_WIFI +#include "platform/internal/GenericConnectivityManagerImpl_WiFi.ipp" #endif #if CHIP_DEVICE_CONFIG_ENABLE_WIFI -#include +#include "WiFiManager.h" #endif namespace chip { @@ -50,7 +60,7 @@ namespace DeviceLayer { ConnectivityManagerImpl ConnectivityManagerImpl::sInstance; -CHIP_ERROR ConnectivityManagerImpl::_Init(void) +CHIP_ERROR ConnectivityManagerImpl::_Init() { CHIP_ERROR err = CHIP_NO_ERROR; @@ -72,7 +82,7 @@ void ConnectivityManagerImpl::_OnPlatformEvent(const ChipDeviceEvent * event) {} #if CHIP_DEVICE_CONFIG_ENABLE_WIFI -ConnectivityManager::WiFiStationMode ConnectivityManagerImpl::_GetWiFiStationMode(void) +ConnectivityManager::WiFiStationMode ConnectivityManagerImpl::_GetWiFiStationMode() { CHIP_ERROR err = CHIP_NO_ERROR; wifi_manager_device_state_e deviceState = WIFI_MANAGER_DEVICE_STATE_DEACTIVATED; @@ -113,7 +123,7 @@ CHIP_ERROR ConnectivityManagerImpl::_SetWiFiStationMode(ConnectivityManager::WiF return err; } -System::Clock::Timeout ConnectivityManagerImpl::_GetWiFiStationReconnectInterval(void) +System::Clock::Timeout ConnectivityManagerImpl::_GetWiFiStationReconnectInterval() { return mWiFiStationReconnectInterval; } @@ -125,7 +135,7 @@ CHIP_ERROR ConnectivityManagerImpl::_SetWiFiStationReconnectInterval(System::Clo return CHIP_NO_ERROR; } -bool ConnectivityManagerImpl::_IsWiFiStationEnabled(void) +bool ConnectivityManagerImpl::_IsWiFiStationEnabled() { bool isWiFiStationEnabled = false; @@ -134,7 +144,7 @@ bool ConnectivityManagerImpl::_IsWiFiStationEnabled(void) return isWiFiStationEnabled; } -bool ConnectivityManagerImpl::_IsWiFiStationConnected(void) +bool ConnectivityManagerImpl::_IsWiFiStationConnected() { CHIP_ERROR err = CHIP_NO_ERROR; wifi_manager_connection_state_e connectionState = WIFI_MANAGER_CONNECTION_STATE_DISCONNECTED; @@ -149,7 +159,7 @@ bool ConnectivityManagerImpl::_IsWiFiStationConnected(void) return isWiFiStationConnected; } -bool ConnectivityManagerImpl::_IsWiFiStationProvisioned(void) +bool ConnectivityManagerImpl::_IsWiFiStationProvisioned() { CHIP_ERROR err = CHIP_NO_ERROR; wifi_manager_connection_state_e connectionState = WIFI_MANAGER_CONNECTION_STATE_DISCONNECTED; @@ -164,12 +174,12 @@ bool ConnectivityManagerImpl::_IsWiFiStationProvisioned(void) return isWiFiStationProvisioned; } -void ConnectivityManagerImpl::_ClearWiFiStationProvision(void) +void ConnectivityManagerImpl::_ClearWiFiStationProvision() { Internal::WiFiMgr().RemoveAllConfigs(); } -bool ConnectivityManagerImpl::_CanStartWiFiScan(void) +bool ConnectivityManagerImpl::_CanStartWiFiScan() { return false; } @@ -189,20 +199,20 @@ bool ConnectivityManagerImpl::_IsWiFiAPActive() return mWiFiAPState == kWiFiAPState_Active; } -void ConnectivityManagerImpl::_DemandStartWiFiAP(void) {} +void ConnectivityManagerImpl::_DemandStartWiFiAP() {} -void ConnectivityManagerImpl::_StopOnDemandWiFiAP(void) {} +void ConnectivityManagerImpl::_StopOnDemandWiFiAP() {} -void ConnectivityManagerImpl::_MaintainOnDemandWiFiAP(void) {} +void ConnectivityManagerImpl::_MaintainOnDemandWiFiAP() {} void ConnectivityManagerImpl::_SetWiFiAPIdleTimeout(System::Clock::Timeout val) {} -void ConnectivityManagerImpl::StartWiFiManagement(void) +void ConnectivityManagerImpl::StartWiFiManagement() { SystemLayer().ScheduleWork(ActivateWiFiManager, nullptr); } -void ConnectivityManagerImpl::StopWiFiManagement(void) +void ConnectivityManagerImpl::StopWiFiManagement() { SystemLayer().ScheduleWork(DeactivateWiFiManager, nullptr); } diff --git a/src/platform/Tizen/ConnectivityManagerImpl.h b/src/platform/Tizen/ConnectivityManagerImpl.h index 69c4e05abb996f..b469b631347b3d 100644 --- a/src/platform/Tizen/ConnectivityManagerImpl.h +++ b/src/platform/Tizen/ConnectivityManagerImpl.h @@ -19,38 +19,37 @@ #pragma once -#include -#include -#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include "platform/internal/GenericConnectivityManagerImpl.h" +#include "platform/internal/GenericConnectivityManagerImpl_UDP.h" #if INET_CONFIG_ENABLE_TCP_ENDPOINT -#include +#include "platform/internal/GenericConnectivityManagerImpl_TCP.h" #endif #if CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE -#include +#include "platform/internal/GenericConnectivityManagerImpl_BLE.h" #else -#include +#include "platform/internal/GenericConnectivityManagerImpl_NoBLE.h" #endif #if CHIP_DEVICE_CONFIG_ENABLE_THREAD -#include +#include "platform/internal/GenericConnectivityManagerImpl_Thread.h" #else -#include +#include "platform/internal/GenericConnectivityManagerImpl_NoThread.h" #endif #if CHIP_DEVICE_CONFIG_ENABLE_WIFI -#include +#include "platform/internal/GenericConnectivityManagerImpl_WiFi.h" #else -#include +#include "platform/internal/GenericConnectivityManagerImpl_NoWiFi.h" #endif -#if CHIP_DEVICE_CONFIG_ENABLE_WIFI -#include "WiFiManager.h" -#endif - -namespace chip { -namespace Inet { -class IPAddress; -} // namespace Inet -} // namespace chip - namespace chip { namespace DeviceLayer { diff --git a/src/platform/Tizen/ConnectivityUtils.cpp b/src/platform/Tizen/ConnectivityUtils.cpp index 6ad5103d7a5b4d..5c5d56b8b9bf80 100644 --- a/src/platform/Tizen/ConnectivityUtils.cpp +++ b/src/platform/Tizen/ConnectivityUtils.cpp @@ -15,8 +15,7 @@ * limitations under the License. */ -#include -#include +#include "ConnectivityUtils.h" // XXX: This is a workaround for a bug in the Tizen SDK header files. It is not // possible to include both and at the same time. @@ -29,12 +28,16 @@ #include #include #include -#include +#include #include #include -#include +#include +#include + +#include #include +#include namespace chip { namespace DeviceLayer { diff --git a/src/platform/Tizen/ConnectivityUtils.h b/src/platform/Tizen/ConnectivityUtils.h index 439e427905ace1..6c8f5c85702d4f 100644 --- a/src/platform/Tizen/ConnectivityUtils.h +++ b/src/platform/Tizen/ConnectivityUtils.h @@ -17,8 +17,9 @@ #pragma once -#include -#include +#include + +#include "platform/internal/CHIPDeviceLayerInternal.h" namespace chip { namespace DeviceLayer { diff --git a/src/platform/Tizen/DeviceInstanceInfoProviderImpl.cpp b/src/platform/Tizen/DeviceInstanceInfoProviderImpl.cpp index 67133eaea0b170..93ad7a18015762 100644 --- a/src/platform/Tizen/DeviceInstanceInfoProviderImpl.cpp +++ b/src/platform/Tizen/DeviceInstanceInfoProviderImpl.cpp @@ -18,7 +18,7 @@ #include "DeviceInstanceInfoProviderImpl.h" -#include +#include "PosixConfig.h" namespace chip { namespace DeviceLayer { diff --git a/src/platform/Tizen/DeviceInstanceInfoProviderImpl.h b/src/platform/Tizen/DeviceInstanceInfoProviderImpl.h index b3b7992cb04aaf..32e6a2cc5abec0 100644 --- a/src/platform/Tizen/DeviceInstanceInfoProviderImpl.h +++ b/src/platform/Tizen/DeviceInstanceInfoProviderImpl.h @@ -18,8 +18,13 @@ #pragma once -#include -#include +#include + +#include + +#include "ConfigurationManagerImpl.h" +#include "PosixConfig.h" +#include "platform/internal/GenericDeviceInstanceInfoProvider.h" namespace chip { namespace DeviceLayer { diff --git a/src/platform/Tizen/DiagnosticDataProviderImpl.cpp b/src/platform/Tizen/DiagnosticDataProviderImpl.cpp index 17e11e56162f1e..ad143a4e642269 100644 --- a/src/platform/Tizen/DiagnosticDataProviderImpl.cpp +++ b/src/platform/Tizen/DiagnosticDataProviderImpl.cpp @@ -21,11 +21,9 @@ * for Tizen platform. */ -#include +#include "DiagnosticDataProviderImpl.h" -#include #include -#include namespace chip { namespace DeviceLayer { diff --git a/src/platform/Tizen/DnssdImpl.cpp b/src/platform/Tizen/DnssdImpl.cpp index 698b70b1c4b94b..2bd1ed282863da 100644 --- a/src/platform/Tizen/DnssdImpl.cpp +++ b/src/platform/Tizen/DnssdImpl.cpp @@ -16,23 +16,32 @@ */ #include "DnssdImpl.h" -#include "MainLoop.h" #include +#include +#include #include -#include #include +#include #include +// Note: Include dns-sd-internal.h is needed, this source file uses some undocumented functions. +#include +#include +#include #include -#include +#include + +#include #include #include #include -#include +#include +#include +#include + +#include "MainLoop.h" -#include -#include #if CHIP_DEVICE_CONFIG_ENABLE_THREAD #include #endif @@ -111,8 +120,8 @@ gboolean RegisterAsync(GMainLoop * mainLoop, gpointer userData) rCtx->mMainLoop = mainLoop; int ret = dnssd_register_local_service(rCtx->mServiceHandle, OnRegister, rCtx); - VerifyOrReturnError(ret == DNSSD_ERROR_NONE, - (ChipLogError(DeviceLayer, "dnssd_register_local_service() failed. ret: %d", ret), false)); + VerifyOrReturnValue(ret == DNSSD_ERROR_NONE, false, + ChipLogError(DeviceLayer, "dnssd_register_local_service() failed. ret: %d", ret)); rCtx->mIsRegistered = true; return true; @@ -200,8 +209,8 @@ void OnBrowse(dnssd_service_state_e state, dnssd_service_h service, void * data) VerifyOrExit(ret == DNSSD_ERROR_NONE, ChipLogError(DeviceLayer, "dnssd_service_get_interface() failed. ret: %d", ret)); interfaceId = if_nametoindex(ifaceName); - VerifyOrExit(interfaceId > 0, - (ChipLogError(DeviceLayer, "if_nametoindex() failed. errno: %d", errno), ret = DNSSD_ERROR_OPERATION_FAILED)); + VerifyOrExit(interfaceId > 0, ChipLogError(DeviceLayer, "if_nametoindex() failed. errno: %d", errno); + ret = DNSSD_ERROR_OPERATION_FAILED); if (state == DNSSD_SERVICE_STATE_AVAILABLE) { @@ -244,8 +253,8 @@ gboolean BrowseAsync(GMainLoop * mainLoop, gpointer userData) else { char iface[IF_NAMESIZE + 1] = ""; - VerifyOrReturnError(if_indextoname(interfaceId, iface) != nullptr, - (ChipLogError(DeviceLayer, "if_indextoname() failed. errno: %d", errno), false)); + VerifyOrReturnValue(if_indextoname(interfaceId, iface) != nullptr, false, + ChipLogError(DeviceLayer, "if_indextoname() failed. errno: %d", errno)); ret = dnssd_browse_service(bCtx->mType, iface, &bCtx->mBrowserHandle, OnBrowse, bCtx); } @@ -398,8 +407,7 @@ gboolean ResolveAsync(GMainLoop * mainLoop, gpointer userData) rCtx->mMainLoop = mainLoop; int ret = dnssd_resolve_service(rCtx->mServiceHandle, OnResolve, rCtx); - VerifyOrReturnError(ret == DNSSD_ERROR_NONE, - (ChipLogError(DeviceLayer, "dnssd_resolve_service() failed. ret: %d", ret), false)); + VerifyOrReturnValue(ret == DNSSD_ERROR_NONE, false, ChipLogError(DeviceLayer, "dnssd_resolve_service() failed. ret: %d", ret)); rCtx->mIsResolving = true; return true; @@ -511,7 +519,7 @@ CHIP_ERROR DnssdTizen::RegisterService(const DnssdService & service, DnssdPublis std::lock_guard lock(mMutex); auto iServiceCtx = std::find_if(mContexts.begin(), mContexts.end(), [fullType, service, interfaceId](const auto & ctx) { - VerifyOrReturnError(ctx->mContextType == ContextType::Register, false); + VerifyOrReturnValue(ctx->mContextType == ContextType::Register, false); auto * rCtx = static_cast(ctx.get()); return strcmp(rCtx->mName, service.mName) == 0 && strcmp(rCtx->mType, fullType.c_str()) == 0 && rCtx->mPort == service.mPort && rCtx->mInterfaceId == interfaceId; @@ -543,25 +551,26 @@ CHIP_ERROR DnssdTizen::RegisterService(const DnssdService & service, DnssdPublis // Local service will be freed by the RegisterContext destructor int ret = dnssd_create_local_service(fullType.c_str(), &serviceCtx->mServiceHandle); auto serviceHandle = serviceCtx->mServiceHandle; - VerifyOrExit(ret == DNSSD_ERROR_NONE, - (ChipLogError(DeviceLayer, "dnssd_create_local_service() failed. ret: %d", ret), err = GetChipError(ret))); + VerifyOrExit(ret == DNSSD_ERROR_NONE, ChipLogError(DeviceLayer, "dnssd_create_local_service() failed. ret: %d", ret); + err = GetChipError(ret)); ret = dnssd_service_set_name(serviceHandle, service.mName); - VerifyOrExit(ret == DNSSD_ERROR_NONE, - (ChipLogError(DeviceLayer, "dnssd_service_set_name() failed. ret: %d", ret), err = GetChipError(ret))); + VerifyOrExit(ret == DNSSD_ERROR_NONE, ChipLogError(DeviceLayer, "dnssd_service_set_name() failed. ret: %d", ret); + err = GetChipError(ret)); ret = dnssd_service_set_port(serviceHandle, service.mPort); - VerifyOrExit(ret == DNSSD_ERROR_NONE, - (ChipLogError(DeviceLayer, "dnssd_service_set_port() failed. ret: %d", ret), err = GetChipError(ret))); + VerifyOrExit(ret == DNSSD_ERROR_NONE, ChipLogError(DeviceLayer, "dnssd_service_set_port() failed. ret: %d", ret); + err = GetChipError(ret)); if (interfaceId > 0) { char iface[IF_NAMESIZE + 1] = ""; VerifyOrExit(if_indextoname(interfaceId, iface) != nullptr, - (ChipLogError(DeviceLayer, "if_indextoname() failed. errno: %d", errno), err = CHIP_ERROR_INTERNAL)); + ChipLogError(DeviceLayer, "if_indextoname() failed. errno: %d", errno); + err = CHIP_ERROR_INTERNAL); ret = dnssd_service_set_interface(serviceHandle, iface); - VerifyOrExit(ret == DNSSD_ERROR_NONE, - (ChipLogError(DeviceLayer, "dnssd_service_set_interface() failed. ret: %d", ret), err = GetChipError(ret))); + VerifyOrExit(ret == DNSSD_ERROR_NONE, ChipLogError(DeviceLayer, "dnssd_service_set_interface() failed. ret: %d", ret); + err = GetChipError(ret)); } for (size_t i = 0; i < service.mTextEntrySize; ++i) @@ -569,8 +578,8 @@ CHIP_ERROR DnssdTizen::RegisterService(const DnssdService & service, DnssdPublis TextEntry entry = service.mTextEntries[i]; VerifyOrReturnError(chip::CanCastTo(entry.mDataSize), CHIP_ERROR_INVALID_ARGUMENT); ret = dnssd_service_add_txt_record(serviceHandle, entry.mKey, static_cast(entry.mDataSize), entry.mData); - VerifyOrExit(ret == DNSSD_ERROR_NONE, - (ChipLogError(DeviceLayer, "dnssd_service_add_txt_record() failed. ret: %d", ret), err = GetChipError(ret))); + VerifyOrExit(ret == DNSSD_ERROR_NONE, ChipLogError(DeviceLayer, "dnssd_service_add_txt_record() failed. ret: %d", ret); + err = GetChipError(ret)); } ok = DeviceLayer::Internal::MainLoop::Instance().AsyncRequest(RegisterAsync, serviceCtx); @@ -646,12 +655,13 @@ CHIP_ERROR DnssdTizen::Resolve(const DnssdService & browseResult, chip::Inet::In { char iface[IF_NAMESIZE + 1] = ""; VerifyOrExit(if_indextoname(interfaceId, iface) != nullptr, - (ChipLogError(DeviceLayer, "if_indextoname() failed. errno: %d", errno), err = CHIP_ERROR_INTERNAL)); + ChipLogError(DeviceLayer, "if_indextoname() failed. errno: %d", errno); + err = CHIP_ERROR_INTERNAL); ret = dnssd_create_remote_service(fullType.c_str(), browseResult.mName, iface, &resolveCtx->mServiceHandle); } - VerifyOrExit(ret == DNSSD_ERROR_NONE, - (ChipLogError(DeviceLayer, "dnssd_create_remote_service() failed. ret: %d", ret), err = GetChipError(ret))); + VerifyOrExit(ret == DNSSD_ERROR_NONE, ChipLogError(DeviceLayer, "dnssd_create_remote_service() failed. ret: %d", ret); + err = GetChipError(ret)); ok = DeviceLayer::Internal::MainLoop::Instance().AsyncRequest(ResolveAsync, resolveCtx); VerifyOrExit(ok, err = CHIP_ERROR_INTERNAL); diff --git a/src/platform/Tizen/DnssdImpl.h b/src/platform/Tizen/DnssdImpl.h index 360f264bbbd158..5872fa01e58d14 100644 --- a/src/platform/Tizen/DnssdImpl.h +++ b/src/platform/Tizen/DnssdImpl.h @@ -17,18 +17,22 @@ #pragma once +#include +#include #include #include #include -#include -#include #include -#include - #include #include +#include +#include +#include +#include +#include + namespace chip { namespace Dnssd { diff --git a/src/platform/Tizen/KeyValueStoreManagerImpl.cpp b/src/platform/Tizen/KeyValueStoreManagerImpl.cpp index f1e1753f6399ab..18e4c15c97f190 100644 --- a/src/platform/Tizen/KeyValueStoreManagerImpl.cpp +++ b/src/platform/Tizen/KeyValueStoreManagerImpl.cpp @@ -21,9 +21,18 @@ * Platform-specific key value storage implementation for Tizen. */ -#include "AppPreference.h" +/** + * Note: Use public include for KeyValueStoreManager which includes our local + * platform//KeyValueStoreManagerImpl.h after defining interface + * class. */ #include +#include + +#include + +#include "AppPreference.h" + namespace chip { namespace DeviceLayer { namespace PersistedStorage { diff --git a/src/platform/Tizen/KeyValueStoreManagerImpl.h b/src/platform/Tizen/KeyValueStoreManagerImpl.h index 42f563346a926c..bf3395a38691c1 100644 --- a/src/platform/Tizen/KeyValueStoreManagerImpl.h +++ b/src/platform/Tizen/KeyValueStoreManagerImpl.h @@ -23,6 +23,10 @@ #pragma once +#include + +#include + namespace chip { namespace DeviceLayer { namespace PersistedStorage { diff --git a/src/platform/Tizen/Logging.cpp b/src/platform/Tizen/Logging.cpp index 4c5c8b8643cfa8..da29fc8926ef69 100644 --- a/src/platform/Tizen/Logging.cpp +++ b/src/platform/Tizen/Logging.cpp @@ -15,14 +15,15 @@ * limitations under the License. */ -#include +#include +#include + +#include -#include +#include #include #include - -#include -#include +#include namespace chip { namespace Logging { diff --git a/src/platform/Tizen/MainLoop.cpp b/src/platform/Tizen/MainLoop.cpp index ee46240a0403ff..56b5f28af87934 100644 --- a/src/platform/Tizen/MainLoop.cpp +++ b/src/platform/Tizen/MainLoop.cpp @@ -16,6 +16,10 @@ #include "MainLoop.h" +#include +#include +#include + #include #include @@ -100,7 +104,7 @@ bool MainLoop::Init(initFn_t initFn, gpointer userData) return true; } -void MainLoop::Deinit(void) +void MainLoop::Deinit() { for (auto & loopData : mLoopData) { @@ -144,7 +148,7 @@ bool MainLoop::AsyncRequest(asyncFn_t asyncFn, gpointer asyncUserData, guint tim return true; } -MainLoop & MainLoop::Instance(void) +MainLoop & MainLoop::Instance() { static MainLoop sMainLoop; return sMainLoop; diff --git a/src/platform/Tizen/MainLoop.h b/src/platform/Tizen/MainLoop.h index a4a67019c4de50..618d45aebe9803 100644 --- a/src/platform/Tizen/MainLoop.h +++ b/src/platform/Tizen/MainLoop.h @@ -18,9 +18,7 @@ #include #include - -#include -#include +#include #include diff --git a/src/platform/Tizen/NetworkCommissioningDriver.h b/src/platform/Tizen/NetworkCommissioningDriver.h index 50137033ccb95b..b9605c34e2b7a6 100644 --- a/src/platform/Tizen/NetworkCommissioningDriver.h +++ b/src/platform/Tizen/NetworkCommissioningDriver.h @@ -17,10 +17,11 @@ #pragma once -#include #include #include +#include + namespace chip { namespace DeviceLayer { namespace NetworkCommissioning { diff --git a/src/platform/Tizen/NetworkCommissioningEthernetDriver.cpp b/src/platform/Tizen/NetworkCommissioningEthernetDriver.cpp index d9e721f217ce0c..6a95f952d77429 100644 --- a/src/platform/Tizen/NetworkCommissioningEthernetDriver.cpp +++ b/src/platform/Tizen/NetworkCommissioningEthernetDriver.cpp @@ -15,17 +15,22 @@ * limitations under the License. */ -#include -#include -#include -#include +#include +#include #include -#include -#include +#include +#include #include +#include #include +#include +#include +#include +#include +#include + namespace chip { namespace DeviceLayer { namespace NetworkCommissioning { diff --git a/src/platform/Tizen/NetworkCommissioningThreadDriver.cpp b/src/platform/Tizen/NetworkCommissioningThreadDriver.cpp index 6a393b621f0a47..8d61c5c4bd3627 100644 --- a/src/platform/Tizen/NetworkCommissioningThreadDriver.cpp +++ b/src/platform/Tizen/NetworkCommissioningThreadDriver.cpp @@ -15,16 +15,20 @@ * limitations under the License. */ +#include +#include + +#include #include -#include -#include +#include +#include +#include +#include +#include #include -#include -#include -#include -#include -#include +#include "NetworkCommissioningDriver.h" +#include "ThreadStackManagerImpl.h" namespace chip { namespace DeviceLayer { diff --git a/src/platform/Tizen/NetworkCommissioningWiFiDriver.cpp b/src/platform/Tizen/NetworkCommissioningWiFiDriver.cpp index c45f1b2ec76440..a71c91455cdc59 100644 --- a/src/platform/Tizen/NetworkCommissioningWiFiDriver.cpp +++ b/src/platform/Tizen/NetworkCommissioningWiFiDriver.cpp @@ -15,14 +15,21 @@ * limitations under the License. */ -#include -#include -#include -#include - +#include +#include #include -#include -#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "NetworkCommissioningDriver.h" +#include "WiFiManager.h" namespace chip { namespace DeviceLayer { diff --git a/src/platform/Tizen/PlatformManagerImpl.cpp b/src/platform/Tizen/PlatformManagerImpl.cpp index cc36d91a3aa507..f893eb94ec4f5a 100644 --- a/src/platform/Tizen/PlatformManagerImpl.cpp +++ b/src/platform/Tizen/PlatformManagerImpl.cpp @@ -23,20 +23,29 @@ * for Tizen platforms. */ -#include +/** + * Note: Use public include for PlatformManager which includes our local + * platform//PlatformManager.h after defining interface + * class. */ +#include +#include +#include #include -#include #include -#include -#include + +#include "PosixConfig.h" +#include "platform/internal/GenericPlatformManagerImpl.h" +#include "platform/internal/GenericPlatformManagerImpl.ipp" +#include "platform/internal/GenericPlatformManagerImpl_POSIX.h" +#include "platform/internal/GenericPlatformManagerImpl_POSIX.ipp" namespace chip { namespace DeviceLayer { PlatformManagerImpl PlatformManagerImpl::sInstance; -CHIP_ERROR PlatformManagerImpl::_InitChipStack(void) +CHIP_ERROR PlatformManagerImpl::_InitChipStack() { ReturnErrorOnFailure(Internal::PosixConfig::Init()); diff --git a/src/platform/Tizen/PlatformManagerImpl.h b/src/platform/Tizen/PlatformManagerImpl.h index f21cfeae29e565..1c8cfd5502c623 100644 --- a/src/platform/Tizen/PlatformManagerImpl.h +++ b/src/platform/Tizen/PlatformManagerImpl.h @@ -23,7 +23,10 @@ #pragma once -#include +#include +#include + +#include "platform/internal/GenericPlatformManagerImpl_POSIX.h" namespace chip { namespace DeviceLayer { diff --git a/src/platform/Tizen/PosixConfig.cpp b/src/platform/Tizen/PosixConfig.cpp index 9b9e57a55ef0dc..f5c641a2fbc83e 100644 --- a/src/platform/Tizen/PosixConfig.cpp +++ b/src/platform/Tizen/PosixConfig.cpp @@ -24,13 +24,10 @@ * key-value config calls to the correct partition. */ -#include -#include +#include "PosixConfig.h" -#include #include #include -#include namespace chip { namespace DeviceLayer { diff --git a/src/platform/Tizen/PosixConfig.h b/src/platform/Tizen/PosixConfig.h index 459dd98c2ae9c9..197adad14e3907 100644 --- a/src/platform/Tizen/PosixConfig.h +++ b/src/platform/Tizen/PosixConfig.h @@ -23,8 +23,8 @@ #pragma once -#include -#include +#include +#include #include diff --git a/src/platform/Tizen/SystemPlatformConfig.h b/src/platform/Tizen/SystemPlatformConfig.h index 761a1c3a976516..d501e425c86516 100644 --- a/src/platform/Tizen/SystemPlatformConfig.h +++ b/src/platform/Tizen/SystemPlatformConfig.h @@ -24,7 +24,7 @@ #pragma once -#include +#include namespace chip { namespace DeviceLayer { diff --git a/src/platform/Tizen/SystemTimeSupport.cpp b/src/platform/Tizen/SystemTimeSupport.cpp index b885edae978713..bfc33b7dd23a9c 100644 --- a/src/platform/Tizen/SystemTimeSupport.cpp +++ b/src/platform/Tizen/SystemTimeSupport.cpp @@ -23,15 +23,19 @@ * time/clock functions that are suitable for use on the Tizen platform. */ -#include - -#include -#include +#include +#include #include -#include -#include -#include +#include +#include + +#include +#include +#include +#include +#include +#include namespace chip { namespace System { diff --git a/src/platform/Tizen/ThreadStackManagerImpl.cpp b/src/platform/Tizen/ThreadStackManagerImpl.cpp index 1a7087960c0ccc..75c2dec4c0aa1b 100644 --- a/src/platform/Tizen/ThreadStackManagerImpl.cpp +++ b/src/platform/Tizen/ThreadStackManagerImpl.cpp @@ -21,17 +21,38 @@ * for Tizen platform. */ -#include -#include +/** + * Note: ThreadStackManager requires ConnectivityManager to be defined + * beforehand, otherwise we will face circular dependency between them. */ +#include -#include -#include -#include +/** + * Note: Use public include for ThreadStackManager which includes our local + * platform//ThreadStackManagerImpl.h after defining interface + * class. */ #include -#include -#include "ThreadStackManagerImpl.h" +#include + +#include + +#include + +#include +#include +#include +#include +#include #include +#include +#include +#include +#include +#include +#include +#include + +#include namespace chip { namespace DeviceLayer { @@ -423,9 +444,8 @@ CHIP_ERROR ThreadStackManagerImpl::_GetPrimary802154MACAddress(uint8_t * buf) int threadErr; threadErr = thread_get_extended_address(mThreadInstance, &extAddr); - VerifyOrReturnError( - threadErr == THREAD_ERROR_NONE, - (ChipLogError(DeviceLayer, "thread_get_extended_address() failed. ret: %d", threadErr), CHIP_ERROR_INTERNAL)); + VerifyOrReturnError(threadErr == THREAD_ERROR_NONE, CHIP_ERROR_INTERNAL, + ChipLogError(DeviceLayer, "thread_get_extended_address() failed. ret: %d", threadErr)); extAddr = htobe64(extAddr); memcpy(buf, &extAddr, sizeof(extAddr)); @@ -571,8 +591,8 @@ CHIP_ERROR ThreadStackManagerImpl::_SetupSrpHost(const char * aHostName) /* Get external ip address */ threadErr = thread_get_ipaddr(mThreadInstance, _ThreadIpAddressCb, THREAD_IPADDR_TYPE_MLEID, nullptr); - VerifyOrReturnError(threadErr == THREAD_ERROR_NONE, - (ChipLogError(DeviceLayer, "thread_get_ipaddr() failed. ret: %d", threadErr), CHIP_ERROR_INTERNAL)); + VerifyOrReturnError(threadErr == THREAD_ERROR_NONE, CHIP_ERROR_INTERNAL, + ChipLogError(DeviceLayer, "thread_get_ipaddr() failed. ret: %d", threadErr)); return CHIP_NO_ERROR; } diff --git a/src/platform/Tizen/ThreadStackManagerImpl.h b/src/platform/Tizen/ThreadStackManagerImpl.h index 40a4cdca2ae9c8..5671853f24eb8f 100644 --- a/src/platform/Tizen/ThreadStackManagerImpl.h +++ b/src/platform/Tizen/ThreadStackManagerImpl.h @@ -23,14 +23,21 @@ #pragma once -#include +#include +#include + +#include +#include +#include +#include +#include #include -#include -#include +#include +#include +#include -#include -#include +#include "platform/internal/DeviceNetworkInfo.h" namespace chip { namespace DeviceLayer { diff --git a/src/platform/Tizen/WiFiManager.cpp b/src/platform/Tizen/WiFiManager.cpp index 73595d81aaa4ad..7731ffcb26aeb3 100644 --- a/src/platform/Tizen/WiFiManager.cpp +++ b/src/platform/Tizen/WiFiManager.cpp @@ -15,14 +15,22 @@ * limitations under the License. */ -#include +#include "WiFiManager.h" -#if CHIP_DEVICE_CONFIG_ENABLE_WIFI +#include +#include +#include #include +#include + +#include #include +#include +#include +#include + #include "MainLoop.h" -#include "WiFiManager.h" namespace { static constexpr const char * __WiFiDeviceStateToStr(wifi_manager_device_state_e state) @@ -329,7 +337,7 @@ gboolean WiFiManager::_WiFiInitialize(gpointer userData) return true; } -void WiFiManager::_WiFiDeinitialize(void) +void WiFiManager::_WiFiDeinitialize() { int wifiErr = WIFI_MANAGER_ERROR_NONE; @@ -421,7 +429,7 @@ gboolean WiFiManager::_WiFiConnect(GMainLoop * mainLoop, gpointer userData) return true; } -void WiFiManager::_WiFiSetStates(void) +void WiFiManager::_WiFiSetStates() { int wifiErr = WIFI_MANAGER_ERROR_NONE; bool isWiFiActivated = false; @@ -446,7 +454,7 @@ void WiFiManager::_WiFiSetStates(void) } } -void WiFiManager::_WiFiSetCallbacks(void) +void WiFiManager::_WiFiSetCallbacks() { int wifiErr = WIFI_MANAGER_ERROR_NONE; @@ -493,7 +501,7 @@ void WiFiManager::_WiFiSetCallbacks(void) } } -void WiFiManager::_WiFiUnsetCallbacks(void) +void WiFiManager::_WiFiUnsetCallbacks() { int wifiErr = WIFI_MANAGER_ERROR_NONE; @@ -558,7 +566,7 @@ void WiFiManager::_WiFiSetConnectionState(wifi_manager_connection_state_e connec ChipLogProgress(DeviceLayer, "Set WiFi connection state [%s]", __WiFiConnectionStateToStr(mConnectionState)); } -wifi_manager_ap_h WiFiManager::_WiFiGetFoundAP(void) +wifi_manager_ap_h WiFiManager::_WiFiGetFoundAP() { int wifiErr = WIFI_MANAGER_ERROR_NONE; wifi_manager_ap_h foundAp = nullptr; @@ -576,7 +584,7 @@ wifi_manager_ap_h WiFiManager::_WiFiGetFoundAP(void) return foundAp; } -void WiFiManager::Init(void) +void WiFiManager::Init() { sInstance.mDeviceState = WIFI_MANAGER_DEVICE_STATE_DEACTIVATED; sInstance.mModuleState = WIFI_MANAGER_MODULE_STATE_DETACHED; @@ -585,7 +593,7 @@ void WiFiManager::Init(void) MainLoop::Instance().Init(_WiFiInitialize); } -void WiFiManager::Deinit(void) +void WiFiManager::Deinit() { sInstance._WiFiDeinitialize(); MainLoop::Instance().Deinit(); @@ -610,7 +618,7 @@ CHIP_ERROR WiFiManager::IsActivated(bool * isWiFiActivated) return err; } -CHIP_ERROR WiFiManager::Activate(void) +CHIP_ERROR WiFiManager::Activate() { CHIP_ERROR err = CHIP_NO_ERROR; int wifiErr = WIFI_MANAGER_ERROR_NONE; @@ -633,7 +641,7 @@ CHIP_ERROR WiFiManager::Activate(void) return err; } -CHIP_ERROR WiFiManager::Deactivate(void) +CHIP_ERROR WiFiManager::Deactivate() { CHIP_ERROR err = CHIP_NO_ERROR; int wifiErr = WIFI_MANAGER_ERROR_NONE; @@ -733,7 +741,7 @@ CHIP_ERROR WiFiManager::Disconnect(const char * ssid) return err; } -CHIP_ERROR WiFiManager::RemoveAllConfigs(void) +CHIP_ERROR WiFiManager::RemoveAllConfigs() { CHIP_ERROR err = CHIP_NO_ERROR; int wifiErr = WIFI_MANAGER_ERROR_NONE; @@ -867,4 +875,3 @@ CHIP_ERROR WiFiManager::GetConnectionState(wifi_manager_connection_state_e * con } // namespace Internal } // namespace DeviceLayer } // namespace chip -#endif // CHIP_DEVICE_CONFIG_ENABLE_WIFI diff --git a/src/platform/Tizen/WiFiManager.h b/src/platform/Tizen/WiFiManager.h index acbe23157a8fbe..f37e2f1240b7b8 100644 --- a/src/platform/Tizen/WiFiManager.h +++ b/src/platform/Tizen/WiFiManager.h @@ -17,13 +17,17 @@ #pragma once -#if CHIP_DEVICE_CONFIG_ENABLE_WIFI -#include -#include +#include +#include #include #include +#include +#include + +#include "platform/internal/DeviceNetworkInfo.h" + namespace chip { namespace DeviceLayer { namespace Internal { @@ -103,5 +107,3 @@ inline WiFiManager & WiFiMgr() } // namespace Internal } // namespace DeviceLayer } // namespace chip - -#endif // CHIP_DEVICE_CONFIG_ENABLE_WIFI diff --git a/src/platform/Zephyr/CHIPDevicePlatformEvent.h b/src/platform/Zephyr/CHIPDevicePlatformEvent.h index 5687945287c2b1..ff329ec7590ea0 100644 --- a/src/platform/Zephyr/CHIPDevicePlatformEvent.h +++ b/src/platform/Zephyr/CHIPDevicePlatformEvent.h @@ -25,7 +25,7 @@ #include -#include +#include namespace chip { namespace DeviceLayer { diff --git a/src/platform/android/DnssdImpl.cpp b/src/platform/android/DnssdImpl.cpp index 36546689e1fc3e..482db002dbd9c0 100644 --- a/src/platform/android/DnssdImpl.cpp +++ b/src/platform/android/DnssdImpl.cpp @@ -183,6 +183,33 @@ CHIP_ERROR ChipDnssdStopBrowse(intptr_t browseIdentifier) return CHIP_ERROR_NOT_IMPLEMENTED; } +template +CHIP_ERROR extractProtocol(const char * serviceType, char (&outServiceName)[N], DnssdServiceProtocol & outProtocol) +{ + const char * dotPos = strrchr(serviceType, '.'); + ReturnErrorCodeIf(dotPos == nullptr, CHIP_ERROR_INVALID_ARGUMENT); + + size_t lengthWithoutProtocol = static_cast(dotPos - serviceType); + ReturnErrorCodeIf(lengthWithoutProtocol + 1 > N, CHIP_ERROR_INVALID_ARGUMENT); + + memcpy(outServiceName, serviceType, lengthWithoutProtocol); + outServiceName[lengthWithoutProtocol] = '\0'; // Set a null terminator + + outProtocol = DnssdServiceProtocol::kDnssdProtocolUnknown; + if (strcmp("._tcp", dotPos) == 0) + { + outProtocol = DnssdServiceProtocol::kDnssdProtocolTcp; + } + else if (strcmp("._udp", dotPos) == 0) + { + outProtocol = DnssdServiceProtocol::kDnssdProtocolUdp; + } + + ReturnErrorCodeIf(outProtocol == DnssdServiceProtocol::kDnssdProtocolUnknown, CHIP_ERROR_INVALID_ARGUMENT); + + return CHIP_NO_ERROR; +} + CHIP_ERROR ChipDnssdResolve(DnssdService * service, Inet::InterfaceId interface, DnssdResolveCallback callback, void * context) { VerifyOrReturnError(service != nullptr && callback != nullptr, CHIP_ERROR_INVALID_ARGUMENT); @@ -316,7 +343,10 @@ void HandleResolve(jstring instanceName, jstring serviceType, jstring hostName, DnssdService service = {}; CopyString(service.mName, jniInstanceName.c_str()); CopyString(service.mHostName, jnihostName.c_str()); - CopyString(service.mType, jniServiceType.c_str()); + + VerifyOrReturn(extractProtocol(jniServiceType.c_str(), service.mType, service.mProtocol) == CHIP_NO_ERROR, + dispatch(CHIP_ERROR_INVALID_ARGUMENT)); + service.mPort = static_cast(port); service.mInterface = iface; service.mTextEntrySize = 0; @@ -412,7 +442,8 @@ void HandleBrowse(jobjectArray instanceName, jstring serviceType, jlong callback dispatch(CHIP_ERROR_INVALID_ARGUMENT)); CopyString(service[i].mName, jniInstanceName.c_str()); - CopyString(service[i].mType, jniServiceType.c_str()); + VerifyOrReturn(extractProtocol(jniServiceType.c_str(), service[i].mType, service[i].mProtocol) == CHIP_NO_ERROR, + dispatch(CHIP_ERROR_INVALID_ARGUMENT)); } dispatch(CHIP_NO_ERROR, service, size); diff --git a/src/platform/bouffalolab/BL602/lwip_default_hooks.h b/src/platform/bouffalolab/BL602/lwip_default_hooks.h new file mode 100644 index 00000000000000..3c1d1d186c8836 --- /dev/null +++ b/src/platform/bouffalolab/BL602/lwip_default_hooks.h @@ -0,0 +1,17 @@ +#ifndef _LWIP_DEFAULT_HOOKS_H_ +#define _LWIP_DEFAULT_HOOKS_H_ +#include "lwip/arch.h" +#include "lwip/err.h" +#include "lwip/ip_addr.h" + +#ifdef CONFIG_LWIP_HOOK_IP6_ROUTE_DEFAULT +extern struct netif * lwip_hook_ip6_route(const ip6_addr_t * src, const ip6_addr_t * dest); +#define LWIP_HOOK_IP6_ROUTE lwip_hook_ip6_route +#endif + +#ifdef CONFIG_LWIP_HOOK_ND6_GET_GW_DEFAULT +extern const ip6_addr_t * lwip_hook_nd6_get_gw(struct netif * netif, const ip6_addr_t * dest); +#define LWIP_HOOK_ND6_GET_GW lwip_hook_nd6_get_gw +#endif + +#endif /* _LWIP_DEFAULT_HOOKS_H_ */ diff --git a/src/platform/device.gni b/src/platform/device.gni index 601d21ef2ff2f1..bddd80e6e8f973 100755 --- a/src/platform/device.gni +++ b/src/platform/device.gni @@ -16,7 +16,7 @@ import("//build_overrides/chip.gni") import("${chip_root}/src/ble/ble.gni") declare_args() { - # Device platform layer: cc13x2_26x2, cc32xx, darwin, efr32, esp32, external, freertos, linux, nrfconnect, k32w0, qpg, tizen, cyw30739, bl602, mw320, zephyr, beken, none. + # Device platform layer: cc13x2_26x2, cc32xx, darwin, efr32, esp32, external, freertos, linux, nrfconnect, k32w0, qpg, tizen, cyw30739, bl602, mw320, zephyr, beken, openiotsdk, none. chip_device_platform = "auto" chip_platform_target = "" @@ -86,7 +86,8 @@ declare_args() { chip_device_platform == "ameba" || chip_device_platform == "webos" || chip_device_platform == "cc32xx" || chip_device_platform == "bl602" || chip_device_platform == "mw320" || chip_device_platform == "beken" || - chip_device_platform == "mt793x") { + chip_device_platform == "mt793x" || + chip_device_platform == "openiotsdk") { chip_mdns = "minimal" } else if (chip_device_platform == "darwin" || chip_device_platform == "cc13x2_26x2" || current_os == "android" || @@ -113,6 +114,8 @@ if (chip_device_platform == "cc13x2_26x2") { _chip_device_layer = "Darwin" } else if (chip_device_platform == "efr32") { _chip_device_layer = "silabs" +} else if (chip_device_platform == "SiWx917") { + _chip_device_layer = "silabs" } else if (chip_device_platform == "esp32") { _chip_device_layer = "ESP32" } else if (chip_device_platform == "linux") { @@ -151,6 +154,8 @@ if (chip_device_platform == "cc13x2_26x2") { _chip_device_layer = "Beken" } else if (chip_device_platform == "mt793x") { _chip_device_layer = "mt793x" +} else if (chip_device_platform == "openiotsdk") { + _chip_device_layer = "openiotsdk" } if (chip_device_platform != "external") { @@ -180,7 +185,7 @@ declare_args() { build_tv_casting_common_a = false } -assert(chip_disable_platform_kvs == false || chip_device_platform == "darwin", +assert(!chip_disable_platform_kvs || chip_device_platform == "darwin", "Can only disable KVS on some platforms") if (_chip_device_layer != "none" && chip_device_platform != "external") { @@ -196,6 +201,11 @@ if (_chip_device_layer != "none" && chip_device_platform != "external") { "" } +declare_args() { + # Enable jlink/segger_rtt support. + chip_enable_segger_rtt = chip_device_platform != "qpg" +} + assert( (current_os != "freertos" && chip_device_platform == "none") || chip_device_platform == "fake" || @@ -212,5 +222,6 @@ assert( chip_device_platform == "webos" || chip_device_platform == "bl602" || chip_device_platform == "mw320" || chip_device_platform == "zephyr" || chip_device_platform == "beken" || chip_device_platform == "bl702" || - chip_device_platform == "mt793x", + chip_device_platform == "mt793x" || chip_device_platform == "SiWx917" || + chip_device_platform == "openiotsdk", "Please select a valid value for chip_device_platform") diff --git a/src/platform/logging/BUILD.gn b/src/platform/logging/BUILD.gn index 038f9421d819b2..402528315d5b81 100644 --- a/src/platform/logging/BUILD.gn +++ b/src/platform/logging/BUILD.gn @@ -16,7 +16,7 @@ if (current_os == "android") { deps = [ ":headers", "${chip_root}/src/lib/core:chip_config_header", - "${chip_root}/src/lib/support:enforce_format", + "${chip_root}/src/lib/support:attributes", "${chip_root}/src/lib/support:logging_constants", "${chip_root}/src/platform:platform_buildconfig", ] @@ -25,14 +25,38 @@ if (current_os == "android") { } } +# We need to reference the output file of ":stdio" at build time, +# but get_target_outputs() does not work for binary targets. As a +# workaround, define a reasonable path and make the target use it. +stdio_archive = "$root_out_dir/liblogging-stdio.a" + static_library("stdio") { sources = [ "impl/stdio/Logging.cpp" ] deps = [ ":headers", "${chip_root}/src/lib/core:chip_config_header", - "${chip_root}/src/lib/support:enforce_format", + "${chip_root}/src/lib/support:attributes", "${chip_root}/src/lib/support:logging_constants", "${chip_root}/src/platform:platform_buildconfig", ] + + # Ensure we end up with the expected output file name + output_dir = get_path_info(stdio_archive, "dir") + output_name = get_path_info(stdio_archive, "name") + output_extension = get_path_info(stdio_archive, "extension") + output_prefix_override = true +} + +# Depending on this target (via public_deps) pulls in the stdio +# logger and ensures it takes precendce over the platform backend. +group("force_stdio") { + deps = [ ":stdio" ] + public_configs = [ ":force_stdio_config" ] +} + +config("force_stdio_config") { + # Ensure the linker sees the stdio implementation first. This + # works because ldflags come before inputs on the command line. + ldflags = [ rebase_path(stdio_archive, root_build_dir) ] } diff --git a/src/platform/mt793x/DnssdContexts.cpp b/src/platform/mt793x/DnssdContexts.cpp index 2a1dec2de1176b..f8af3b450e9d87 100644 --- a/src/platform/mt793x/DnssdContexts.cpp +++ b/src/platform/mt793x/DnssdContexts.cpp @@ -112,12 +112,10 @@ DNSServiceProtocol GetProtocol(const chip::Inet::IPAddressType & addressType) return kDNSServiceProtocol_IPv6; #endif } - } // namespace namespace chip { namespace Dnssd { - CHIP_ERROR GenericContext::Finalize(DNSServiceErrorType err) { if (MdnsContexts::GetInstance().Has(this) == CHIP_NO_ERROR) @@ -139,6 +137,51 @@ CHIP_ERROR GenericContext::Finalize(DNSServiceErrorType err) return Error::ToChipError(err); } +RegisterContext::RegisterContext(const char * sType, const char * instanceName, DnssdPublishCallback cb, void * cbContext) +{ + type = ContextType::Register; + context = cbContext; + callback = cb; + + mType = sType; + mInstanceName = instanceName; +} + +void RegisterContext::DispatchFailure(DNSServiceErrorType err) +{ + ChipLogError(Discovery, "Mdns: Register failure (%s)", Error::ToString(err)); + callback(context, nullptr, nullptr, Error::ToChipError(err)); + MdnsContexts::GetInstance().Remove(this); +} + +void RegisterContext::DispatchSuccess() +{ + std::string typeWithoutSubTypes = GetFullTypeWithoutSubTypes(mType); + callback(context, typeWithoutSubTypes.c_str(), mInstanceName.c_str(), CHIP_NO_ERROR); + + // Once a service has been properly published it is normally unreachable because the hostname has not yet been + // registered against the dns daemon. Register the records mapping the hostname to our IP. + // mHostNameRegistrar.Register(); +} + +CHIP_ERROR MdnsContexts::GetRegisterContextOfType(const char * type, RegisterContext ** context) +{ + bool found = false; + std::vector::iterator iter; + + for (iter = mContexts.begin(); iter != mContexts.end(); iter++) + { + if ((*iter)->type == ContextType::Register && (static_cast(*iter))->matches(type)) + { + *context = static_cast(*iter); + found = true; + break; + } + } + + return found ? CHIP_NO_ERROR : CHIP_ERROR_KEY_NOT_FOUND; +} + MdnsContexts::~MdnsContexts() { std::vector::const_iterator iter = mContexts.cbegin(); @@ -500,6 +543,5 @@ InterfaceInfo::~InterfaceInfo() } Platform::MemoryFree(const_cast(service.mTextEntries)); } - } // namespace Dnssd } // namespace chip diff --git a/src/platform/mt793x/DnssdImpl.cpp b/src/platform/mt793x/DnssdImpl.cpp index 8fd7683191b22b..b1c8748437892f 100644 --- a/src/platform/mt793x/DnssdImpl.cpp +++ b/src/platform/mt793x/DnssdImpl.cpp @@ -28,6 +28,12 @@ #include "FreeRTOS.h" #include "event_groups.h" #include "lwip/sockets.h" +#undef write +#undef read +#include +#include +#include + #include "mDNSDebug.h" #include "task.h" #include "task_def.h" @@ -36,17 +42,144 @@ #include "platform/CHIPDeviceLayer.h" #include #include +#include #include +using namespace chip::Dnssd; + extern "C" { extern void mDNSPlatformWriteLogRedirect(void (*)(const char *, const char *)); } namespace { - +constexpr const char * kLocalDot = "local."; +constexpr const char * kProtocolTcp = "._tcp"; +constexpr const char * kProtocolUdp = "._udp"; static constexpr uint32_t kTimeoutMilli = 3000; static constexpr size_t kMaxResults = 20; +constexpr DNSServiceFlags kRegisterFlags = kDNSServiceFlagsNoAutoRename; +constexpr DNSServiceFlags kBrowseFlags = 0; +constexpr DNSServiceFlags kGetAddrInfoFlags = kDNSServiceFlagsTimeout | kDNSServiceFlagsShareConnection; +constexpr DNSServiceFlags kResolveFlags = kDNSServiceFlagsShareConnection; +constexpr DNSServiceFlags kReconfirmRecordFlags = 0; + +bool IsSupportedProtocol(DnssdServiceProtocol protocol) +{ + return (protocol == DnssdServiceProtocol::kDnssdProtocolUdp) || (protocol == DnssdServiceProtocol::kDnssdProtocolTcp); +} + +uint32_t GetInterfaceId(chip::Inet::InterfaceId interfaceId) +{ + return interfaceId.IsPresent() ? (uint32_t)(void *) interfaceId.GetPlatformInterface() : kDNSServiceInterfaceIndexAny; +} + +std::string GetFullType(const char * type, DnssdServiceProtocol protocol) +{ + std::ostringstream typeBuilder; + typeBuilder << type; + typeBuilder << (protocol == DnssdServiceProtocol::kDnssdProtocolUdp ? kProtocolUdp : kProtocolTcp); + return typeBuilder.str(); +} + +std::string GetFullType(const DnssdService * service) +{ + return GetFullType(service->mType, service->mProtocol); +} + +std::string GetFullTypeWithSubTypes(const char * type, DnssdServiceProtocol protocol, const char * subTypes[], size_t subTypeSize) +{ + std::ostringstream typeBuilder; + typeBuilder << type; + typeBuilder << (protocol == DnssdServiceProtocol::kDnssdProtocolUdp ? kProtocolUdp : kProtocolTcp); + for (int i = 0; i < (int) subTypeSize; i++) + { + typeBuilder << ","; + typeBuilder << subTypes[i]; + } + return typeBuilder.str(); +} + +std::string GetFullTypeWithSubTypes(const char * type, DnssdServiceProtocol protocol) +{ + auto fullType = GetFullType(type, protocol); + + std::string subtypeDelimiter = "._sub."; + size_t position = fullType.find(subtypeDelimiter); + if (position != std::string::npos) + { + fullType = fullType.substr(position + subtypeDelimiter.size()) + "," + fullType.substr(0, position); + } + + return fullType; +} + +std::string GetFullTypeWithSubTypes(const DnssdService * service) +{ + return GetFullTypeWithSubTypes(service->mType, service->mProtocol, service->mSubTypes, service->mSubTypeSize); +} + +std::string GetHostNameWithDomain(const char * hostname) +{ + return std::string(hostname) + '.' + kLocalDot; +} + +void LogOnFailure(const char * name, DNSServiceErrorType err) +{ + if (kDNSServiceErr_NoError != err) + { + ChipLogError(Discovery, "%s (%s)", name, Error::ToString(err)); + } +} + +class ScopedTXTRecord +{ +public: + ScopedTXTRecord() {} + + ~ScopedTXTRecord() + { + if (mDataSize != 0) + { + TXTRecordDeallocate(&mRecordRef); + } + } + + CHIP_ERROR Init(TextEntry * textEntries, size_t textEntrySize) + { + VerifyOrReturnError(textEntrySize <= kDnssdTextMaxSize, CHIP_ERROR_INVALID_ARGUMENT); + + TXTRecordCreate(&mRecordRef, sizeof(mRecordBuffer), mRecordBuffer); + + for (size_t i = 0; i < textEntrySize; i++) + { + TextEntry entry = textEntries[i]; + VerifyOrReturnError(chip::CanCastTo(entry.mDataSize), CHIP_ERROR_INVALID_ARGUMENT); + + auto err = TXTRecordSetValue(&mRecordRef, entry.mKey, static_cast(entry.mDataSize), entry.mData); + VerifyOrReturnError(err == kDNSServiceErr_NoError, CHIP_ERROR_INVALID_ARGUMENT); + } + + mDataSize = TXTRecordGetLength(&mRecordRef); + if (mDataSize == 0) + { + TXTRecordDeallocate(&mRecordRef); + } + + mData = TXTRecordGetBytesPtr(&mRecordRef); + return CHIP_NO_ERROR; + } + + uint16_t size() { return mDataSize; } + const void * data() { return mData; } + +private: + uint16_t mDataSize = 0; + const void * mData = nullptr; + + TXTRecordRef mRecordRef; + char mRecordBuffer[kDnssdTextMaxSize]; +}; } // namespace namespace chip { @@ -55,25 +188,54 @@ namespace Dnssd { #define SERVICE_DOMAIN ("local") MdnsContexts MdnsContexts::sInstance; -static DNSServiceRef client = NULL; -static TXTRecordRef PublishTxtRecord; +static DNSServiceRef BrowseClient = NULL; +static TaskHandle_t gResolveTask = NULL; +static EventGroupHandle_t gResolveTaskWakeEvent; void ChipDnssdMdnsLog(const char * level, const char * msg) { ChipLogProgress(ServiceProvisioning, "%s %s", StringOrNullMarker(level), StringOrNullMarker(msg)); } -/** - * @brief mDNS Daemon Task entry - * @param[in] void *not_used:Not used - * @return None - */ +static void OnRegister(DNSServiceRef sdRef, DNSServiceFlags flags, DNSServiceErrorType err, const char * name, const char * type, + const char * domain, void * context) +{ + ChipLogDetail(Discovery, "Mdns: %s name: %s, type: %s, domain: %s, flags: %ld", __func__, name, type, domain, flags); + + auto sdCtx = reinterpret_cast(context); + sdCtx->Finalize(err); +}; + +CHIP_ERROR Register(void * context, DnssdPublishCallback callback, uint32_t interfaceId, const char * type, const char * name, + uint16_t port, ScopedTXTRecord & record, Inet::IPAddressType addressType, const char * hostname) +{ + ChipLogDetail(Discovery, "Registering service %s on host %s with port %u and type: %s on interface id: %" PRIu32, name, + hostname, port, type, interfaceId); + + RegisterContext * sdCtx = nullptr; + if (CHIP_NO_ERROR == MdnsContexts::GetInstance().GetRegisterContextOfType(type, &sdCtx)) + { + auto err = DNSServiceUpdateRecord(sdCtx->serviceRef, nullptr, kRegisterFlags, record.size(), record.data(), 0 /* ttl */); + VerifyOrReturnError(kDNSServiceErr_NoError == err, sdCtx->Finalize(err)); + return CHIP_NO_ERROR; + } + + sdCtx = chip::Platform::New(type, name, callback, context); + VerifyOrReturnError(nullptr != sdCtx, CHIP_ERROR_NO_MEMORY); + + DNSServiceRef sdRef; + auto err = DNSServiceRegister(&sdRef, kRegisterFlags, interfaceId, name, type, kLocalDot, hostname, htons(port), record.size(), + record.data(), OnRegister, sdCtx); + VerifyOrReturnError(kDNSServiceErr_NoError == err, sdCtx->Finalize(err)); + + return MdnsContexts::GetInstance().Add(sdCtx, sdRef); +} + static void mdnsd_entry(void * not_used) { ChipLogProgress(ServiceProvisioning, "mdnsd_entry start"); mdnsd_start(); ChipLogProgress(ServiceProvisioning, "mdnsd_entry return"); - client = NULL; vTaskDelete(NULL); } @@ -95,23 +257,8 @@ CHIP_ERROR ChipDnssdInit(DnssdAsyncReturnCallback initCallback, DnssdAsyncReturn mDNSPlatformWriteLogRedirect(ChipDnssdMdnsLog); -#if 0 -#define MDNS_STACK_SIZE ((64 * 1024) / sizeof(portSTACK_TYPE)) - static StackType_t xMDnsStack[ MDNS_STACK_SIZE ]; - static StaticTask_t xMDnsTask; - - // xTaskHandle create mDNS daemon task - if ( NULL != xTaskCreateStatic( mdnsd_entry, - "mdnsd", - MDNS_STACK_SIZE, - NULL, - TASK_PRIORITY_NORMAL, - &xMDnsStack[0], - &xMDnsTask ) ) -#else // xTaskHandle create mDNS daemon task if (pdPASS != xTaskCreate(mdnsd_entry, "mdnsd", (15 * 1024) / sizeof(portSTACK_TYPE), NULL, TASK_PRIORITY_NORMAL, NULL)) -#endif { ChipLogProgress(ServiceProvisioning, "Cannot create mdnsd_task"); error = CHIP_ERROR_INTERNAL; @@ -134,82 +281,30 @@ static const char * GetProtocolString(DnssdServiceProtocol protocol) CHIP_ERROR ChipDnssdPublishService(const DnssdService * service, DnssdPublishCallback callback, void * context) { - CHIP_ERROR error = CHIP_NO_ERROR; - DNSServiceErrorType err; - DNSServiceFlags flags = 0; - char ServiceType[kDnssdTypeMaxSize + 10] = { 0 }; - - (void) callback; - (void) context; + VerifyOrReturnError(service != nullptr, CHIP_ERROR_INVALID_ARGUMENT); + VerifyOrReturnError(IsSupportedProtocol(service->mProtocol), CHIP_ERROR_INVALID_ARGUMENT); + VerifyOrReturnError(callback != nullptr, CHIP_ERROR_INVALID_ARGUMENT); + VerifyOrReturnError(strcmp(service->mHostName, "") != 0, CHIP_ERROR_INVALID_ARGUMENT); - ChipLogProgress(ServiceProvisioning, "ChipDnssdPublishService"); + ScopedTXTRecord record; + ReturnErrorOnFailure(record.Init(service->mTextEntries, service->mTextEntrySize)); - strcpy(ServiceType, service->mType); - strcat(ServiceType, "."); - strcat(ServiceType, GetProtocolString(service->mProtocol)); - - ChipLogProgress(ServiceProvisioning, "ServiceName: %s", service->mName); - ChipLogProgress(ServiceProvisioning, "ServiceType: %s", ServiceType); - ChipLogProgress(ServiceProvisioning, "ServiceDomain: %s", SERVICE_DOMAIN); - ChipLogProgress(ServiceProvisioning, "Hostname: %s", service->mHostName); - ChipLogProgress(ServiceProvisioning, "ServicePort: %d", (int) service->mPort); - - VerifyOrExit(service->mTextEntrySize <= UINT8_MAX, error = CHIP_ERROR_INVALID_ARGUMENT); - - if (service->mTextEntries) - { - // Create TXT Record - TXTRecordCreate(&PublishTxtRecord, 0, NULL); - for (size_t i = 0; i < service->mTextEntrySize; i++) - { - ChipLogProgress(ServiceProvisioning, "service: key %s size %d data %s", service->mTextEntries[i].mKey, - service->mTextEntries[i].mDataSize, service->mTextEntries[i].mData); - - err = TXTRecordSetValue(&PublishTxtRecord, service->mTextEntries[i].mKey, service->mTextEntries[i].mDataSize, - service->mTextEntries[i].mData); - VerifyOrExit(err == 0, error = CHIP_ERROR_INTERNAL); - } - } - - if (client != NULL) - { - // ChipLogProgress(ServiceProvisioning, "ChipDnssdPublishService - DNSServiceRefDeallocate"); - // DNSServiceRefDeallocate(client); - // client = NULL; - } + auto regtype = GetFullTypeWithSubTypes(service); + auto interfaceId = GetInterfaceId(service->mInterface); + auto hostname = GetHostNameWithDomain(service->mHostName); - ChipLogProgress(ServiceProvisioning, "ChipDnssdPublishService - client %p", client); - - ChipLogProgress(ServiceProvisioning, "ChipDnssdPublishService - DNSServiceRegister"); - - // Register Bonjour Service - err = DNSServiceRegister(&client, // DNSServiceRef - flags, // DNSServiceFlags - kDNSServiceInterfaceIndexAny, // interface index - service->mName, // service name - ServiceType, // service type - SERVICE_DOMAIN, // domain - NULL, // host - // service->mHostName, // host - htons(service->mPort), // port - TXTRecordGetLength(&PublishTxtRecord), // txt record length - TXTRecordGetBytesPtr(&PublishTxtRecord), // txt record pointer - NULL, // callback - NULL); // context - VerifyOrExit(err == 0, error = CHIP_ERROR_INTERNAL); - -exit: - // PublishTxtRecord is static global, no need to free - - return error; + return Register(context, callback, interfaceId, regtype.c_str(), service->mName, service->mPort, record, service->mAddressType, + hostname.c_str()); } CHIP_ERROR ChipDnssdRemoveServices() { - ChipLogProgress(ServiceProvisioning, "ChipDnssdRemoveServices"); - TXTRecordDeallocate(&PublishTxtRecord); - DNSServiceRefDeallocate(client); - return CHIP_NO_ERROR; + auto err = MdnsContexts::GetInstance().RemoveAllOfType(ContextType::Register); + if (CHIP_ERROR_KEY_NOT_FOUND == err) + { + err = CHIP_NO_ERROR; + } + return err; } CHIP_ERROR ChipDnssdFinalizeServiceUpdate() @@ -217,8 +312,6 @@ CHIP_ERROR ChipDnssdFinalizeServiceUpdate() return CHIP_NO_ERROR; } -static DNSServiceRef BrowseClient = NULL; - void ChipDNSServiceBrowseReply(DNSServiceRef sdRef, DNSServiceFlags flags, uint32_t interfaceIndex, DNSServiceErrorType errorCode, const char * serviceName, const char * regtype, const char * replyDomain, void * context) { @@ -262,9 +355,6 @@ CHIP_ERROR ChipDnssdStopBrowse(intptr_t browseIdentifier) return CHIP_ERROR_NOT_IMPLEMENTED; } -static TaskHandle_t gResolveTask = NULL; -static EventGroupHandle_t gResolveTaskWakeEvent; - static void resolve_client_task(void * parameter) { EventBits_t uxBits; @@ -393,11 +483,6 @@ void ChipDNSServiceResolveReply(DNSServiceRef sdRef, DNSServiceFlags flags, uint } } -uint32_t GetInterfaceId(chip::Inet::InterfaceId interfaceId) -{ - return interfaceId.IsPresent() ? (uint32_t)(void *) interfaceId.GetPlatformInterface() : kDNSServiceInterfaceIndexAny; -} - CHIP_ERROR ChipDnssdResolve(DnssdService * service, chip::Inet::InterfaceId interface, DnssdResolveCallback callback, void * context) { diff --git a/src/platform/mt793x/DnssdImpl.h b/src/platform/mt793x/DnssdImpl.h index ba4d213a6618a2..d1499b6b9a9be8 100644 --- a/src/platform/mt793x/DnssdImpl.h +++ b/src/platform/mt793x/DnssdImpl.h @@ -26,7 +26,6 @@ namespace chip { namespace Dnssd { - enum class ContextType { Register, @@ -91,6 +90,21 @@ class MdnsContexts std::vector mContexts; }; +struct RegisterContext : public GenericContext +{ + DnssdPublishCallback callback; + std::string mType; + std::string mInstanceName; + + RegisterContext(const char * sType, const char * instanceName, DnssdPublishCallback cb, void * cbContext); + virtual ~RegisterContext() {} + + void DispatchFailure(DNSServiceErrorType err) override; + void DispatchSuccess() override; + + bool matches(const char * sType) { return mType.compare(sType) == 0; } +}; + struct BrowseContext : public GenericContext { DnssdBrowseCallback callback; @@ -138,6 +152,5 @@ struct ResolveContext : public GenericContext const unsigned char * txtRecord); bool HasInterface(); }; - } // namespace Dnssd } // namespace chip diff --git a/src/platform/openiotsdk/BUILD.gn b/src/platform/openiotsdk/BUILD.gn new file mode 100644 index 00000000000000..2b80b49a8aeb6b --- /dev/null +++ b/src/platform/openiotsdk/BUILD.gn @@ -0,0 +1,51 @@ +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/chip.gni") + +import("${chip_root}/src/platform/device.gni") + +assert(chip_device_platform == "openiotsdk") + +static_library("openiotsdk") { + sources = [ + "../SingletonConfigurationManager.cpp", + "BlePlatformConfig.h", + "CHIPDevicePlatformConfig.h", + "CHIPDevicePlatformEvent.h", + "CHIPPlatformConfig.h", + "ConfigurationManagerImpl.cpp", + "ConfigurationManagerImpl.h", + "ConnectivityManagerImpl.cpp", + "ConnectivityManagerImpl.h", + "DiagnosticDataProviderImpl.cpp", + "DiagnosticDataProviderImpl.h", + "InetPlatformConfig.h", + "KeyValueStoreManagerImpl.cpp", + "KeyValueStoreManagerImpl.h", + "Logging.cpp", + "NetworkCommissioningDriver.h", + "NetworkCommissioningEthernetDriver.cpp", + "OpenIoTSDKArchUtils.c", + "OpenIoTSDKArchUtils.h", + "OpenIoTSDKConfig.cpp", + "OpenIoTSDKConfig.h", + "PlatformManagerImpl.cpp", + "PlatformManagerImpl.h", + "SystemPlatformConfig.h", + "SystemTimeSupport.cpp", + ] + + public_deps = [ "${chip_root}/src/platform:platform_base" ] +} diff --git a/src/platform/openiotsdk/BlePlatformConfig.h b/src/platform/openiotsdk/BlePlatformConfig.h new file mode 100644 index 00000000000000..55b4eccdebdbb4 --- /dev/null +++ b/src/platform/openiotsdk/BlePlatformConfig.h @@ -0,0 +1,30 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Platform-specific configuration overrides for the CHIP BLE + * Layer on Open IoT SDK platform. + * + */ + +#pragma once + +// ==================== Platform Adaptations ==================== + +// ========== Platform-specific Configuration Overrides ========= diff --git a/src/platform/openiotsdk/CHIPDevicePlatformConfig.h b/src/platform/openiotsdk/CHIPDevicePlatformConfig.h new file mode 100644 index 00000000000000..3e9c17c22edc67 --- /dev/null +++ b/src/platform/openiotsdk/CHIPDevicePlatformConfig.h @@ -0,0 +1,40 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Platform-specific configuration overrides for the chip Device Layer + * on Open IOT SDK platform. + */ + +#pragma once + +// ==================== Platform Adaptations ==================== + +#define CHIP_DEVICE_CONFIG_ENABLE_CHIP_TIME_SERVICE_TIME_SYNC 0 + +#define CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE 0 +#define CHIP_DEVICE_CONFIG_ENABLE_THREAD 0 + +// ========== Platform-specific Configuration Overrides ========= + +#define CHIP_DEVICE_CONFIG_LOG_PROVISIONING_HASH 0 + +#ifndef CHIP_DEVICE_CONFIG_CHIP_TASK_STACK_SIZE +#define CHIP_DEVICE_CONFIG_CHIP_TASK_STACK_SIZE 8192 +#endif // CHIP_DEVICE_CONFIG_CHIP_TASK_STACK_SIZE diff --git a/src/platform/openiotsdk/CHIPDevicePlatformEvent.h b/src/platform/openiotsdk/CHIPDevicePlatformEvent.h new file mode 100644 index 00000000000000..035bf1f168af5e --- /dev/null +++ b/src/platform/openiotsdk/CHIPDevicePlatformEvent.h @@ -0,0 +1,60 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Defines platform-specific event types and data for the chip + * Device Layer on the Open IOT SDK platform. + */ + +#pragma once + +#include + +namespace chip { +namespace DeviceLayer { + +namespace DeviceEventType { + +/** + * Enumerates Open IoT SDK platform-specific event types that are visible to the application. + */ +enum PublicPlatformSpecificEventTypes +{ + /* None currently defined */ +}; + +/** + * Enumerates Open IoT SDK platform-specific event types that are internal to the chip Device Layer. + */ +enum InternalPlatformSpecificEventTypes +{ + +}; + +} // namespace DeviceEventType + +/** + * Represents platform-specific event information for Open IoT SDK platform. + */ +struct ChipDevicePlatformEvent final +{ +}; + +} // namespace DeviceLayer +} // namespace chip diff --git a/src/darwin/Framework/CHIP/MTRMemory.h b/src/platform/openiotsdk/CHIPPlatformConfig.h similarity index 54% rename from src/darwin/Framework/CHIP/MTRMemory.h rename to src/platform/openiotsdk/CHIPPlatformConfig.h index 124e47e92fcecc..58da36298c27ef 100644 --- a/src/darwin/Framework/CHIP/MTRMemory.h +++ b/src/platform/openiotsdk/CHIPPlatformConfig.h @@ -1,5 +1,7 @@ -/** +/* + * * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -14,27 +16,20 @@ * limitations under the License. */ -#pragma once - /** - * Utility to initialize the Matter memory subsystem. Not a public framework - * header. + * @file + * Platform-specific configuration overrides for CHIP on + * Open IoT SDK platform. */ -#import +#pragma once -NS_ASSUME_NONNULL_BEGIN +#include -@interface MTRMemory : NSObject -/** - * Ensure Matter Platform::Memory is initialized. This only needs to happen - * once per process, because in practice we just use malloc/free so there is - * nothing to initialize, so this just needs to happen to avoid debug - * assertions. This class handles ensuring the initialization only happens - * once. - */ -+ (void)ensureInit; +// ==================== General Platform Adaptations ==================== + +#define CHIP_CONFIG_EXPECTED_LOW_PROCESSING_TIME 10 -@end +// ==================== Security Adaptations ==================== -NS_ASSUME_NONNULL_END +// ==================== General Configuration Overrides ==================== diff --git a/src/platform/openiotsdk/ConfigurationManagerImpl.cpp b/src/platform/openiotsdk/ConfigurationManagerImpl.cpp new file mode 100644 index 00000000000000..58e6e70c995509 --- /dev/null +++ b/src/platform/openiotsdk/ConfigurationManagerImpl.cpp @@ -0,0 +1,161 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides the implementation of the Device Layer ConfigurationManager class + * for the Open IOT SDK platform. + */ + +#include + +#include + +#include + +#include "cmsis.h" + +namespace chip { +namespace DeviceLayer { + +using namespace ::chip::DeviceLayer::Internal; + +ConfigurationManagerImpl & ConfigurationManagerImpl::GetDefaultInstance() +{ + static ConfigurationManagerImpl sInstance; + return sInstance; +} + +CHIP_ERROR ConfigurationManagerImpl::Init() +{ + CHIP_ERROR err; + + // Initialize the generic implementation base class. + err = Internal::GenericConfigurationManagerImpl::Init(); + SuccessOrExit(err); + +exit: + return err; +} + +bool ConfigurationManagerImpl::CanFactoryReset() +{ + return true; +} + +void ConfigurationManagerImpl::InitiateFactoryReset(void) +{ + PlatformMgr().ScheduleWork(DoFactoryReset); +} + +CHIP_ERROR ConfigurationManagerImpl::ReadPersistedStorageValue(::chip::Platform::PersistedStorage::Key key, uint32_t & value) +{ + CHIP_ERROR err = ReadConfigValue(key, value); + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + err = CHIP_ERROR_PERSISTED_STORAGE_VALUE_NOT_FOUND; + } + return err; +} + +CHIP_ERROR ConfigurationManagerImpl::WritePersistedStorageValue(::chip::Platform::PersistedStorage::Key key, uint32_t value) +{ + return OpenIoTSDKConfig::WriteCounter(key, value); +} + +CHIP_ERROR ConfigurationManagerImpl::ReadConfigValue(Key key, bool & val) +{ + return OpenIoTSDKConfig::ReadConfigValue(key, val); +} + +CHIP_ERROR ConfigurationManagerImpl::ReadConfigValue(Key key, uint32_t & val) +{ + return OpenIoTSDKConfig::ReadConfigValue(key, val); +} + +CHIP_ERROR ConfigurationManagerImpl::ReadConfigValue(Key key, uint64_t & val) +{ + return OpenIoTSDKConfig::ReadConfigValue(key, val); +} + +CHIP_ERROR ConfigurationManagerImpl::ReadConfigValueStr(Key key, char * buf, size_t bufSize, size_t & outLen) +{ + return OpenIoTSDKConfig::ReadConfigValueStr(key, buf, bufSize, outLen); +} + +CHIP_ERROR ConfigurationManagerImpl::ReadConfigValueBin(Key key, uint8_t * buf, size_t bufSize, size_t & outLen) +{ + return OpenIoTSDKConfig::ReadConfigValueBin(key, buf, bufSize, outLen); +} + +CHIP_ERROR ConfigurationManagerImpl::WriteConfigValue(Key key, bool val) +{ + return OpenIoTSDKConfig::WriteConfigValue(key, val); +} + +CHIP_ERROR ConfigurationManagerImpl::WriteConfigValue(Key key, uint32_t val) +{ + return OpenIoTSDKConfig::WriteConfigValue(key, val); +} + +CHIP_ERROR ConfigurationManagerImpl::WriteConfigValue(Key key, uint64_t val) +{ + return OpenIoTSDKConfig::WriteConfigValue(key, val); +} + +CHIP_ERROR ConfigurationManagerImpl::WriteConfigValueStr(Key key, const char * str) +{ + return OpenIoTSDKConfig::WriteConfigValueStr(key, str); +} + +CHIP_ERROR ConfigurationManagerImpl::WriteConfigValueStr(Key key, const char * str, size_t strLen) +{ + return OpenIoTSDKConfig::WriteConfigValueStr(key, str, strLen); +} + +CHIP_ERROR ConfigurationManagerImpl::WriteConfigValueBin(Key key, const uint8_t * data, size_t dataLen) +{ + return OpenIoTSDKConfig::WriteConfigValueBin(key, data, dataLen); +} + +void ConfigurationManagerImpl::RunConfigUnitTest(void) +{ + OpenIoTSDKConfig::RunConfigUnitTest(); +} + +void ConfigurationManagerImpl::DoFactoryReset(intptr_t arg) +{ + ChipLogProgress(DeviceLayer, "Performing factory reset"); + const CHIP_ERROR err = OpenIoTSDKConfig::FactoryResetConfig(); + if (err != CHIP_NO_ERROR) + { + ChipLogError(DeviceLayer, "FactoryResetConfig() failed: %s", ErrorStr(err)); + } + + // Restart the system. + ChipLogProgress(DeviceLayer, "System restarting"); + NVIC_SystemReset(); +} + +ConfigurationManager & ConfigurationMgrImpl() +{ + return ConfigurationManagerImpl::GetDefaultInstance(); +} + +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/openiotsdk/ConfigurationManagerImpl.h b/src/platform/openiotsdk/ConfigurationManagerImpl.h new file mode 100644 index 00000000000000..ad4effe0645978 --- /dev/null +++ b/src/platform/openiotsdk/ConfigurationManagerImpl.h @@ -0,0 +1,82 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides an implementation of the ConfigurationManager class + * for the Open IOT SDK platform. + */ + +#pragma once + +#include +#include + +namespace chip { +namespace DeviceLayer { + +/** + * Concrete implementation of the ConfigurationManager singleton object for the Zephyr platform. + */ +class ConfigurationManagerImpl : public Internal::GenericConfigurationManagerImpl +{ + +public: + // This returns an instance of this class. + static ConfigurationManagerImpl & GetDefaultInstance(); + +private: + // ===== Members that implement the ConfigurationManager public interface. + + CHIP_ERROR Init(void) override; + bool CanFactoryReset(void) override; + void InitiateFactoryReset(void) override; + CHIP_ERROR ReadPersistedStorageValue(::chip::Platform::PersistedStorage::Key key, uint32_t & value) override; + CHIP_ERROR WritePersistedStorageValue(::chip::Platform::PersistedStorage::Key key, uint32_t value) override; + + // NOTE: Other public interface methods are implemented by GenericConfigurationManagerImpl<>. + + // ===== Members that implement the GenericConfigurationManagerImpl protected interface. + CHIP_ERROR ReadConfigValue(Key key, bool & val) override; + CHIP_ERROR ReadConfigValue(Key key, uint32_t & val) override; + CHIP_ERROR ReadConfigValue(Key key, uint64_t & val) override; + CHIP_ERROR ReadConfigValueStr(Key key, char * buf, size_t bufSize, size_t & outLen) override; + CHIP_ERROR ReadConfigValueBin(Key key, uint8_t * buf, size_t bufSize, size_t & outLen) override; + CHIP_ERROR WriteConfigValue(Key key, bool val) override; + CHIP_ERROR WriteConfigValue(Key key, uint32_t val) override; + CHIP_ERROR WriteConfigValue(Key key, uint64_t val) override; + CHIP_ERROR WriteConfigValueStr(Key key, const char * str) override; + CHIP_ERROR WriteConfigValueStr(Key key, const char * str, size_t strLen) override; + CHIP_ERROR WriteConfigValueBin(Key key, const uint8_t * data, size_t dataLen) override; + void RunConfigUnitTest(void) override; + + // ===== Private members reserved for use by this class only. + + static void DoFactoryReset(intptr_t arg); +}; + +/** + * Returns the platform-specific implementation of the ConfigurationManager object. + * + * Applications can use this to gain access to features of the ConfigurationManager + * that are specific to the selected platform. + */ +ConfigurationManager & ConfigurationMgrImpl(); + +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/openiotsdk/ConnectivityManagerImpl.cpp b/src/platform/openiotsdk/ConnectivityManagerImpl.cpp new file mode 100644 index 00000000000000..438697dde666fc --- /dev/null +++ b/src/platform/openiotsdk/ConnectivityManagerImpl.cpp @@ -0,0 +1,69 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides the implementation of the Device Layer Connectivity Manager class + * for Open IOT SDK platform. + */ + +#include + +#include + +#include + +#if INET_CONFIG_ENABLE_TCP_ENDPOINT +#include +#endif + +namespace chip { +namespace DeviceLayer { + +ConnectivityManagerImpl ConnectivityManagerImpl::sInstance; + +// ==================== ConnectivityManager Platform Internal Methods ==================== +CHIP_ERROR ConnectivityManagerImpl::_Init() +{ + CHIP_ERROR err = CHIP_NO_ERROR; + return err; +} + +void ConnectivityManagerImpl::_OnPlatformEvent(const ChipDeviceEvent * event) {} + +CHIP_ERROR ConnectivityManagerImpl::PostEvent(const ChipDeviceEvent * event, bool die) +{ + CHIP_ERROR err = CHIP_NO_ERROR; + if (die) + { + PlatformMgr().PostEventOrDie(event); + } + else + { + err = PlatformMgr().PostEvent(event); + } + + return err; +} +void ConnectivityManagerImpl::AddTask(AsyncWorkFunct workFunct, intptr_t arg) +{ + PlatformMgr().ScheduleWork(workFunct, arg); +} + +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/openiotsdk/ConnectivityManagerImpl.h b/src/platform/openiotsdk/ConnectivityManagerImpl.h new file mode 100644 index 00000000000000..d558dbc2533c26 --- /dev/null +++ b/src/platform/openiotsdk/ConnectivityManagerImpl.h @@ -0,0 +1,98 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides the implementation of the Device Layer Connectivity Manager class + * for the Open IOT SDK platform. + */ + +#pragma once + +#include + +#include +#include +#include +#include +#include +#include + +#if INET_CONFIG_ENABLE_TCP_ENDPOINT +#include +#endif + +namespace chip { +namespace DeviceLayer { + +/** + * Concrete implementation of the ConnectivityManager singleton object for the Open IoT SDK platform. + */ +class ConnectivityManagerImpl final : public ConnectivityManager, + public Internal::GenericConnectivityManagerImpl, + public Internal::GenericConnectivityManagerImpl_UDP, +#if INET_CONFIG_ENABLE_TCP_ENDPOINT + public Internal::GenericConnectivityManagerImpl_TCP, +#endif + public Internal::GenericConnectivityManagerImpl_NoWiFi, + public Internal::GenericConnectivityManagerImpl_NoBLE, + public Internal::GenericConnectivityManagerImpl_NoThread + +{ + // Allow the ConnectivityManager interface class to delegate method calls to + // the implementation methods provided by this class. + friend class ConnectivityManager; + +private: + CHIP_ERROR _Init(void); + void _OnPlatformEvent(const ChipDeviceEvent * event); + + friend ConnectivityManager & ConnectivityMgr(void); + friend ConnectivityManagerImpl & ConnectivityMgrImpl(void); + + static ConnectivityManagerImpl sInstance; + +public: + CHIP_ERROR PostEvent(const ChipDeviceEvent * event, bool die); + void AddTask(AsyncWorkFunct workFunct, intptr_t arg); +}; + +/** + * Returns the public interface of the ConnectivityManager singleton object. + * + * chip applications should use this to access features of the ConnectivityManager object + * that are common to all platforms. + */ +inline ConnectivityManager & ConnectivityMgr(void) +{ + return ConnectivityManagerImpl::sInstance; +} + +/** + * Returns the platform-specific implementation of the ConnectivityManager singleton object. + * + * chip applications can use this to gain access to features of the ConnectivityManager + * that are specific to the Open IoT SDK platform. + */ +inline ConnectivityManagerImpl & ConnectivityMgrImpl(void) +{ + return ConnectivityManagerImpl::sInstance; +} + +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/openiotsdk/DiagnosticDataProviderImpl.cpp b/src/platform/openiotsdk/DiagnosticDataProviderImpl.cpp new file mode 100644 index 00000000000000..38d394b8d24864 --- /dev/null +++ b/src/platform/openiotsdk/DiagnosticDataProviderImpl.cpp @@ -0,0 +1,46 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides an implementation of the Diagnostic Data Provider class + * for Open IOT SDK platform. + */ + +#include + +#include +#include +#include + +namespace chip { +namespace DeviceLayer { + +DiagnosticDataProviderImpl & DiagnosticDataProviderImpl::GetDefaultInstance() +{ + static DiagnosticDataProviderImpl sInstance; + return sInstance; +} + +DiagnosticDataProvider & GetDiagnosticDataProviderImpl() +{ + return DiagnosticDataProviderImpl::GetDefaultInstance(); +} + +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/openiotsdk/DiagnosticDataProviderImpl.h b/src/platform/openiotsdk/DiagnosticDataProviderImpl.h new file mode 100644 index 00000000000000..c660cef8d43761 --- /dev/null +++ b/src/platform/openiotsdk/DiagnosticDataProviderImpl.h @@ -0,0 +1,50 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides an implementation of the Diagnostic Data Provider class + * for Open IOT SDK platform. + */ + +#pragma once + +#include + +namespace chip { +namespace DeviceLayer { + +/** + * Concrete implementation of the PlatformManager singleton object for Linux platforms. + */ +class DiagnosticDataProviderImpl : public DiagnosticDataProvider +{ +public: + static DiagnosticDataProviderImpl & GetDefaultInstance(); +}; + +/** + * Returns the platform-specific implementation of the DiagnosticDataProvider singleton object. + * + * Applications can use this to gain access to features of the DiagnosticDataProvider + * that are specific to the selected platform. + */ +DiagnosticDataProvider & GetDiagnosticDataProviderImpl(); + +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/openiotsdk/InetPlatformConfig.h b/src/platform/openiotsdk/InetPlatformConfig.h new file mode 100644 index 00000000000000..d571369d3820f7 --- /dev/null +++ b/src/platform/openiotsdk/InetPlatformConfig.h @@ -0,0 +1,30 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Platform-specific configuration overrides for the CHIP Inet + * Layer on Open IoT SDK platform. + * + */ + +#pragma once + +// ==================== Platform Adaptations ==================== + +// ========== Platform-specific Configuration Overrides ========= diff --git a/src/platform/openiotsdk/KeyValueStoreManagerImpl.cpp b/src/platform/openiotsdk/KeyValueStoreManagerImpl.cpp new file mode 100644 index 00000000000000..e88772995c41c0 --- /dev/null +++ b/src/platform/openiotsdk/KeyValueStoreManagerImpl.cpp @@ -0,0 +1,131 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides an implementation of the key-value storage manager class + * for Open IOT SDK platform. + */ + +#include +#include + +#include +#include +#include + +using chip::DeviceLayer::Internal::OpenIoTSDKConfig; + +namespace chip { +namespace DeviceLayer { +namespace PersistedStorage { + +class KeyBuilder +{ +public: + KeyBuilder(const char * key) + { + // Check sign by sign if key contains illegal characters + // Each illegal character will be replaced by '!' + capital encoded letter value + char * out = buffer + strlen(buffer); + char * illegal_ptr; + while ((out < buffer + sizeof(buffer) - 3) && *key) // 2 chars for potential illegal char + 1 for \0 + { + illegal_ptr = strchr(illegalCharacters, *key); + if (illegal_ptr) + { + *out++ = '!'; + *out++ = 'A' + (int) (illegal_ptr - illegalCharacters); + } + else + { + *out++ = *key; + } + key++; + } + valid = true; + } + + const char * str() const { return valid ? buffer : nullptr; } + +private: + char buffer[100] = "chip-kvs-"; + bool valid; + // Mbed KV storage does not accept these characters in the key definition + const char * illegalCharacters = " */?:;\"|<>\\"; +}; + +// NOTE: Currently this platform does not support partial and offset reads +// these will return CHIP_ERROR_NOT_IMPLEMENTED. +CHIP_ERROR +KeyValueStoreManagerImpl::_Get(const char * key, void * value, size_t value_size, size_t * read_bytes_size, size_t offset) +{ + if (offset > 0) + { + // Offset and partial reads are not supported. + // Support can be added in the future if this is needed. + return CHIP_ERROR_NOT_IMPLEMENTED; + } + + KeyBuilder key_builder(key); + if (!key_builder.str()) + { + return CHIP_ERROR_PERSISTED_STORAGE_FAILED; + } + + auto err = + OpenIoTSDKConfig::ReadConfigValueBin(key_builder.str(), reinterpret_cast(value), value_size, *read_bytes_size); + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + err = CHIP_ERROR_PERSISTED_STORAGE_VALUE_NOT_FOUND; + } + return err; +} + +CHIP_ERROR KeyValueStoreManagerImpl::_Delete(const char * key) +{ + KeyBuilder key_builder(key); + if (!key_builder.str()) + { + return CHIP_ERROR_PERSISTED_STORAGE_FAILED; + } + + auto err = OpenIoTSDKConfig::ClearConfigValue(key_builder.str()); + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + err = CHIP_ERROR_PERSISTED_STORAGE_VALUE_NOT_FOUND; + } + return err; +} + +CHIP_ERROR KeyValueStoreManagerImpl::_Put(const char * key, const void * value, size_t value_size) +{ + KeyBuilder key_builder(key); + if (!key_builder.str()) + { + return CHIP_ERROR_PERSISTED_STORAGE_FAILED; + } + + return OpenIoTSDKConfig::WriteConfigValueBin(key_builder.str(), reinterpret_cast(value), value_size); +} + +KeyValueStoreManagerImpl KeyValueStoreManagerImpl::sInstance; + +} // namespace PersistedStorage +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/openiotsdk/KeyValueStoreManagerImpl.h b/src/platform/openiotsdk/KeyValueStoreManagerImpl.h new file mode 100644 index 00000000000000..9257c33c6f25d7 --- /dev/null +++ b/src/platform/openiotsdk/KeyValueStoreManagerImpl.h @@ -0,0 +1,80 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides an implementation of the key-value storage manager class + * for Open IOT SDK platform. + */ + +#pragma once + +#include + +namespace chip { +namespace DeviceLayer { +namespace PersistedStorage { + +class KeyValueStoreManagerImpl final : public KeyValueStoreManager +{ + // Allow the KeyValueStoreManager interface class to delegate method calls to + // the implementation methods provided by this class. + friend class KeyValueStoreManager; + +public: + // NOTE: Currently this platform does not support partial and offset reads + // these will return CHIP_ERROR_NOT_IMPLEMENTED. + CHIP_ERROR _Get(const char * key, void * value, size_t value_size, size_t * read_bytes_size = nullptr, size_t offset = 0); + + CHIP_ERROR _Delete(const char * key); + + CHIP_ERROR _Put(const char * key, const void * value, size_t value_size); + +private: + // ===== Members for internal use by the following friends. + friend KeyValueStoreManager & KeyValueStoreMgr(); + friend KeyValueStoreManagerImpl & KeyValueStoreMgrImpl(); + + static KeyValueStoreManagerImpl sInstance; +}; + +/** + * Returns the public interface of the KeyValueStoreManager singleton object. + * + * Chip applications should use this to access features of the KeyValueStoreManager object + * that are common to all platforms. + */ +inline KeyValueStoreManager & KeyValueStoreMgr(void) +{ + return KeyValueStoreManagerImpl::sInstance; +} + +/** + * Returns the platform-specific implementation of the KeyValueStoreManager singleton object. + * + * Chip applications can use this to gain access to features of the KeyValueStoreManager + * that are specific to the OpenIoTSDK platform. + */ +inline KeyValueStoreManagerImpl & KeyValueStoreMgrImpl(void) +{ + return KeyValueStoreManagerImpl::sInstance; +} + +} // namespace PersistedStorage +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/openiotsdk/Logging.cpp b/src/platform/openiotsdk/Logging.cpp new file mode 100644 index 00000000000000..2a3ecfa7e64e7b --- /dev/null +++ b/src/platform/openiotsdk/Logging.cpp @@ -0,0 +1,90 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides an implementation of logging support + * for Open IOT SDK platform. + */ + +#include +#include +#include +#include +#include + +#include +#include + +namespace chip { +namespace DeviceLayer { + +/** + * Called whenever a log message is emitted by chip or LwIP. + * + * This function is intended be overridden by the application to, e.g., + * schedule output of queued log entries. + */ +void __attribute__((weak)) OnLogOutput() {} + +} // namespace DeviceLayer + +namespace Logging { +namespace Platform { + +/** + * Logging static buffer + */ +namespace { +char logMsgBuffer[CHIP_CONFIG_LOG_MESSAGE_MAX_SIZE]; +} + +/** + * CHIP log output functions. + */ +void ENFORCE_FORMAT(3, 0) LogV(const char * module, uint8_t category, const char * msg, va_list v) +{ + vsnprintf(logMsgBuffer, sizeof(logMsgBuffer), msg, v); + + const char * category_prefix; + switch (category) + { + case kLogCategory_Error: + category_prefix = "\x1b[31m[ERR]\x1b[0m"; + break; + case kLogCategory_Progress: + default: + category_prefix = "\x1b[32m[INF]\x1b[0m"; + break; + case kLogCategory_Detail: + category_prefix = "\x1b[90m[DBG]\x1b[0m"; + break; + case kLogCategory_Automation: + category_prefix = ""; + break; + } + + printf("%s [%s] %s\r\n", category_prefix, module, logMsgBuffer); + + // Let the application know that a log message has been emitted. + DeviceLayer::OnLogOutput(); +} + +} // namespace Platform +} // namespace Logging +} // namespace chip diff --git a/src/platform/openiotsdk/NetworkCommissioningDriver.h b/src/platform/openiotsdk/NetworkCommissioningDriver.h new file mode 100644 index 00000000000000..524f575e9e7bd8 --- /dev/null +++ b/src/platform/openiotsdk/NetworkCommissioningDriver.h @@ -0,0 +1,67 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides an implementation of the network commissioning drivers + * for Open IOT SDK platform. + */ + +#pragma once + +#include +#include + +namespace chip { +namespace DeviceLayer { +namespace NetworkCommissioning { + +class OpenIoTSDKEthernetDriver final : public EthernetDriver +{ +public: + struct EthernetNetworkIterator final : public NetworkIterator + { + EthernetNetworkIterator() = default; + size_t Count() override { return interfaceNameLen > 0 ? 1 : 0; } + bool Next(Network & item) override + { + if (exhausted) + { + return false; + } + exhausted = true; + memcpy(item.networkID, interfaceName, interfaceNameLen); + item.networkIDLen = interfaceNameLen; + item.connected = true; + return true; + } + void Release() override { delete this; } + ~EthernetNetworkIterator() override = default; + + // Public, but cannot be accessed via NetworkIterator interface. + uint8_t interfaceName[kMaxNetworkIDLen]; + uint8_t interfaceNameLen = 0; + bool exhausted = false; + }; + + uint8_t GetMaxNetworks() override { return 1; }; + NetworkIterator * GetNetworks() override; +}; + +} // namespace NetworkCommissioning +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/openiotsdk/NetworkCommissioningEthernetDriver.cpp b/src/platform/openiotsdk/NetworkCommissioningEthernetDriver.cpp new file mode 100644 index 00000000000000..df36092c5e2e8d --- /dev/null +++ b/src/platform/openiotsdk/NetworkCommissioningEthernetDriver.cpp @@ -0,0 +1,52 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides an implementation of the network commissioning drivers + * for Open IOT SDK platform. + */ + +#include +#include +#include + +using namespace ::chip::Inet; +using namespace ::chip::DeviceLayer; +using namespace ::chip::DeviceLayer::Internal; + +namespace chip { +namespace DeviceLayer { +namespace NetworkCommissioning { + +NetworkIterator * OpenIoTSDKEthernetDriver::GetNetworks() +{ + auto ret = new EthernetNetworkIterator(); + + char buf[NETIF_NAMESIZE]; + char * ifname = netif_index_to_name(0, buf); + + ret->interfaceNameLen = strlen(ifname); + memcpy(ret->interfaceName, ifname, ret->interfaceNameLen); + + return ret; +} + +} // namespace NetworkCommissioning +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/openiotsdk/OpenIoTSDKArchUtils.c b/src/platform/openiotsdk/OpenIoTSDKArchUtils.c new file mode 100644 index 00000000000000..d7c74ac5a21cae --- /dev/null +++ b/src/platform/openiotsdk/OpenIoTSDKArchUtils.c @@ -0,0 +1,138 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Open IOT SDK platform adaptation file + */ + +#include "OpenIoTSDKArchUtils.h" +#include +#ifdef __cplusplus +extern "C" { +#endif + +static uint32_t tick_h = 0U; +static uint32_t tick_l = 0U; + +// GetTick() needs to be called at least twice per tick overflow to work properly. +uint64_t GetTick(void) +{ + uint32_t tick = osKernelGetTickCount(); + + if (tick < tick_l) + { + tick_h++; + } + tick_l = tick; + + return (((uint64_t) tick_h << 32) | tick_l); +} + +/* Time to kernel ticks */ +uint32_t sec2tick(uint32_t sec) +{ + if (sec == 0U) + { + return (osWaitForever); + } + + return (sec * osKernelGetTickFreq()); +} + +uint32_t ms2tick(uint32_t ms) +{ + if (ms == 0U) + { + return (osWaitForever); + } + + return (uint32_t)(((uint64_t) ms * (uint64_t) osKernelGetTickFreq()) / 1000U); +} + +uint32_t us2tick(uint32_t usec) +{ + if (usec == 0U) + { + return osWaitForever; + } + + // round division up because our tick is so long this might become 0 + // we need the timer to sleep at least one tick as it otherwise breaks expectations + return (uint32_t)(((uint64_t) usec * osKernelGetTickFreq() + (1000000 - 1)) / 1000000); +} + +/* Kernel ticks to time */ +uint64_t tick2sec(uint64_t tick) +{ + if (osKernelGetTickFreq() == 0U) + { + return 0; + } + + return (tick / osKernelGetTickFreq()); +} + +uint64_t tick2ms(uint64_t tick) +{ + if (osKernelGetTickFreq() == 0U) + { + return 0; + } + + return ((tick * 1000U) / osKernelGetTickFreq()); +} + +uint64_t tick2us(uint64_t tick) +{ + if (osKernelGetTickFreq() == 0U) + { + return 0; + } + + return ((tick * 1000U * 1000U) / osKernelGetTickFreq()); +} + +void sleep(uint32_t sec) +{ + if (sec) + { + osDelay(sec2tick(sec)); + } +} + +void usleep(uint32_t usec) +{ + if (usec) + { + osDelay(us2tick(usec)); + } +} + +time_t time(time_t * __timer) +{ + time_t seconds = (time_t)(tick2sec(GetTick())); + if (__timer) + { + *__timer = seconds; + } + return seconds; +} + +#ifdef __cplusplus +} +#endif diff --git a/src/platform/openiotsdk/OpenIoTSDKArchUtils.h b/src/platform/openiotsdk/OpenIoTSDKArchUtils.h new file mode 100644 index 00000000000000..4fffbf7fc62efe --- /dev/null +++ b/src/platform/openiotsdk/OpenIoTSDKArchUtils.h @@ -0,0 +1,50 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Defines timing helper functions. + */ + +#pragma once + +#include "cmsis_os2.h" + +#ifdef __cplusplus +extern "C" { +#endif + +uint64_t GetTick(void); + +/* Time to kernel ticks */ +uint32_t sec2tick(uint32_t sec); + +uint32_t ms2tick(uint32_t ms); + +uint32_t us2tick(uint32_t usec); + +/* Kernel ticks to time */ +uint64_t tick2sec(uint64_t tick); + +uint64_t tick2ms(uint64_t tick); + +uint64_t tick2us(uint64_t tick); + +#ifdef __cplusplus +} +#endif diff --git a/src/platform/openiotsdk/OpenIoTSDKConfig.cpp b/src/platform/openiotsdk/OpenIoTSDKConfig.cpp new file mode 100644 index 00000000000000..d156e417ff324d --- /dev/null +++ b/src/platform/openiotsdk/OpenIoTSDKConfig.cpp @@ -0,0 +1,452 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Utilities for interacting with the the Open IoT SDK key-value storage. + */ + +#include + +#include +#include +#include +#include +#include + +namespace chip { +namespace DeviceLayer { +namespace Internal { + +// *** CAUTION ***: Changing the names or namespaces of these values will *break* existing devices. + +#define STR_EXPAND(tok) #tok + +// Note: An external mbed parameter could be useful so an application can put +// chip NVS values in a single place +#define CHIP_CONFIG_KV_STORE_PARTITION STR_EXPAND(MBED_CONF_STORAGE_DEFAULT_KV) + +// NVS namespaces used to store device configuration information. +#define CHIP_CONFIG_FACTORY_PREFIX "chip-factory-" +#define CHIP_CONFIG_CONFIG_PREFIX "chip-config-" +#define CHIP_CONFIG_COUNTER_PREFIX "chip-counters-" + +#define FACTORY_KEY(key) CHIP_CONFIG_KV_STORE_PARTITION CHIP_CONFIG_FACTORY_PREFIX key +#define CONFIG_KEY(key) CHIP_CONFIG_KV_STORE_PARTITION CHIP_CONFIG_CONFIG_PREFIX key + +const char OpenIoTSDKConfig::kConfigNamespace_ChipFactory[] = CHIP_CONFIG_KV_STORE_PARTITION CHIP_CONFIG_FACTORY_PREFIX; +const char OpenIoTSDKConfig::kConfigNamespace_ChipConfig[] = CHIP_CONFIG_KV_STORE_PARTITION CHIP_CONFIG_CONFIG_PREFIX; +const char OpenIoTSDKConfig::kConfigNamespace_ChipCounters[] = CHIP_CONFIG_KV_STORE_PARTITION CHIP_CONFIG_COUNTER_PREFIX; + +// Keys stored in the chip-factory namespace +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_SerialNum = { FACTORY_KEY("serial-num") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_MfrDeviceId = { FACTORY_KEY("device-id") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_MfrDeviceCert = { FACTORY_KEY("device-cert") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_MfrDeviceICACerts = { FACTORY_KEY("device-ca-certs") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_MfrDevicePrivateKey = { FACTORY_KEY("device-key") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_HardwareVersion = { FACTORY_KEY("hardware-ver") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_ManufacturingDate = { FACTORY_KEY("mfg-date") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_SetupPinCode = { FACTORY_KEY("pin-code") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_SetupDiscriminator = { FACTORY_KEY("discriminator") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_Spake2pIterationCount = { FACTORY_KEY("iteration-count") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_Spake2pSalt = { FACTORY_KEY("salt") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_Spake2pVerifier = { FACTORY_KEY("verifier") }; + +// Keys stored in the chip-config namespace +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_ServiceConfig = { CONFIG_KEY("service-config") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_PairedAccountId = { CONFIG_KEY("account-id") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_ServiceId = { CONFIG_KEY("service-id") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_LastUsedEpochKeyId = { CONFIG_KEY("last-ek-id") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_FailSafeArmed = { CONFIG_KEY("fail-safe-armed") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_WiFiStationSecType = { CONFIG_KEY("sta-sec-type") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_RegulatoryLocation = { CONFIG_KEY("regulatory-location") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_CountryCode = { CONFIG_KEY("country-code") }; +const OpenIoTSDKConfig::Key OpenIoTSDKConfig::kConfigKey_UniqueId = { CONFIG_KEY("unique-id") }; + +using iotsdk::storage::kv_status; +using iotsdk::storage::KVStore; + +CHIP_ERROR OpenIoTSDKConfig::ReadConfigValue(Key key, bool & val) +{ + if (Init() != CHIP_NO_ERROR) + { + return CHIP_ERROR_INTERNAL; + } + + if (!ConfigValueExists(key)) + { + return CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND; + } + + size_t actual_size = 0; + kv_status err = tdb->get(key, reinterpret_cast(&val), sizeof(val), &actual_size); + + if (err != kv_status::OK) + { + return CHIP_ERROR_INTERNAL; + } + + if (actual_size != sizeof(val)) + { + return CHIP_ERROR_BAD_REQUEST; + } + + return CHIP_NO_ERROR; +} + +CHIP_ERROR OpenIoTSDKConfig::ReadConfigValue(Key key, uint32_t & val) +{ + if (Init() != CHIP_NO_ERROR) + { + return CHIP_ERROR_INTERNAL; + } + + if (!ConfigValueExists(key)) + { + return CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND; + } + + size_t actual_size = 0; + kv_status err = tdb->get(key, reinterpret_cast(&val), sizeof(val), &actual_size); + + if (err != kv_status::OK) + { + return CHIP_ERROR_INTERNAL; + } + + if (actual_size != sizeof(val)) + { + return CHIP_ERROR_BAD_REQUEST; + } + + return CHIP_NO_ERROR; +} + +CHIP_ERROR OpenIoTSDKConfig::ReadConfigValue(Key key, uint64_t & val) +{ + if (Init() != CHIP_NO_ERROR) + { + return CHIP_ERROR_INTERNAL; + } + + if (!ConfigValueExists(key)) + { + return CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND; + } + + size_t actual_size = 0; + kv_status err = tdb->get(key, &val, sizeof(val), &actual_size); + + if (err != kv_status::OK) + { + return CHIP_ERROR_INTERNAL; + } + + if (actual_size != sizeof(val)) + { + return CHIP_ERROR_BAD_REQUEST; + } + + return CHIP_NO_ERROR; +} + +CHIP_ERROR OpenIoTSDKConfig::ReadConfigValueStr(Key key, char * buf, size_t bufSize, size_t & outLen) +{ + CHIP_ERROR err = ReadConfigValueBin(key, reinterpret_cast(buf), bufSize, outLen); + // Note: The system expect the trailing null to be added. + if (err != CHIP_NO_ERROR) + { + return err; + } + if (outLen >= bufSize) + { + return CHIP_ERROR_INVALID_ARGUMENT; + } + buf[outLen] = 0; + return CHIP_NO_ERROR; +} + +CHIP_ERROR OpenIoTSDKConfig::ReadConfigValueBin(Key key, uint8_t * buf, size_t bufSize, size_t & outLen) +{ + if (Init() != CHIP_NO_ERROR) + { + return CHIP_ERROR_INTERNAL; + } + + if (!ConfigValueExists(key)) + { + return CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND; + } + + KVStore::info_t info; + + kv_status err = tdb->get_info(key, &info); + if (err != kv_status::OK) + { + return CHIP_ERROR_INTERNAL; + } + + err = tdb->get(key, reinterpret_cast(buf), bufSize, &outLen); + if (err != kv_status::OK) + { + return CHIP_ERROR_INTERNAL; + } + + if (bufSize < info.size) + { + return CHIP_ERROR_BUFFER_TOO_SMALL; + } + + return CHIP_NO_ERROR; +} + +CHIP_ERROR OpenIoTSDKConfig::WriteConfigValue(Key key, bool val) +{ + if (Init() != CHIP_NO_ERROR) + { + return CHIP_ERROR_INTERNAL; + } + + kv_status err = tdb->set(key, reinterpret_cast(&val), sizeof(val), 0); + return err == kv_status::OK ? CHIP_NO_ERROR : CHIP_ERROR_INTERNAL; +} + +CHIP_ERROR OpenIoTSDKConfig::WriteConfigValue(Key key, uint32_t val) +{ + if (Init() != CHIP_NO_ERROR) + { + return CHIP_ERROR_INTERNAL; + } + + kv_status err = tdb->set(key, reinterpret_cast(&val), sizeof(val), 0); + return err == kv_status::OK ? CHIP_NO_ERROR : CHIP_ERROR_INTERNAL; +} + +CHIP_ERROR OpenIoTSDKConfig::WriteConfigValue(Key key, uint64_t val) +{ + if (Init() != CHIP_NO_ERROR) + { + return CHIP_ERROR_INTERNAL; + } + + kv_status err = tdb->set(key, reinterpret_cast(&val), sizeof(val), 0); + return err == kv_status::OK ? CHIP_NO_ERROR : CHIP_ERROR_INTERNAL; +} + +CHIP_ERROR OpenIoTSDKConfig::WriteConfigValueStr(Key key, const char * str) +{ + return WriteConfigValueBin(key, reinterpret_cast(str), strlen(str)); +} + +CHIP_ERROR OpenIoTSDKConfig::WriteConfigValueStr(Key key, const char * str, size_t strLen) +{ + return WriteConfigValueBin(key, reinterpret_cast(str), strLen); +} + +CHIP_ERROR OpenIoTSDKConfig::WriteConfigValueBin(Key key, const uint8_t * data, size_t dataLen) +{ + if (Init() != CHIP_NO_ERROR) + { + return CHIP_ERROR_INTERNAL; + } + + // Two different behavior: If the pointer is not null, the value is updated + // or create. If the pointer is null, the key is removed if it exist. + if (data != nullptr) + { + kv_status err = tdb->set(key, reinterpret_cast(data), dataLen, 0); + return err == kv_status::OK ? CHIP_NO_ERROR : CHIP_ERROR_INTERNAL; + } + else if (ConfigValueExists(key)) + { + return ClearConfigValue(key); + } + else + { + // Nothing to do, data is null and the key does not exist. + return CHIP_NO_ERROR; + } +} + +CHIP_ERROR OpenIoTSDKConfig::ClearConfigValue(Key key) +{ + if (Init() != CHIP_NO_ERROR) + { + return CHIP_ERROR_INTERNAL; + } + + kv_status err = tdb->remove(key); + if (err == kv_status::ITEM_NOT_FOUND) + { + return CHIP_ERROR_PERSISTED_STORAGE_VALUE_NOT_FOUND; + } + return err == kv_status::OK ? CHIP_NO_ERROR : CHIP_ERROR_INTERNAL; +} + +bool OpenIoTSDKConfig::ConfigValueExists(Key key) +{ + if (Init() != CHIP_NO_ERROR) + { + return false; + } + + KVStore::info_t info; + kv_status err = tdb->get_info(key, &info); + return err == kv_status::OK ? true : false; +} + +CHIP_ERROR OpenIoTSDKConfig::FactoryResetConfig() +{ + // tdb->reset is not used, we want to preserve other setting and factory + // configuration + auto err = ClearNamespace(kConfigNamespace_ChipConfig); + if (err != CHIP_NO_ERROR) + { + return err; + } + return ClearNamespace(kConfigNamespace_ChipCounters); +} + +CHIP_ERROR OpenIoTSDKConfig::ConstructCounterKey(Key id, char * buf, size_t bufSize) +{ + auto length = snprintf(buf, bufSize - 1, CHIP_CONFIG_KV_STORE_PARTITION CHIP_CONFIG_COUNTER_PREFIX "%s", id); + if (length < 0) + { + return CHIP_ERROR_INTERNAL; + } + else if ((size_t) length > (bufSize - 1)) + { + return CHIP_ERROR_INVALID_ARGUMENT; + } + else + { + return CHIP_NO_ERROR; + } +} + +CHIP_ERROR OpenIoTSDKConfig::ReadCounter(Key counterId, uint32_t & value) +{ + char key[50] = { 0 }; + auto err = ConstructCounterKey(counterId, key, sizeof(key)); + if (err != CHIP_NO_ERROR) + { + return err; + } + + return ReadConfigValue(key, value); +} + +CHIP_ERROR OpenIoTSDKConfig::WriteCounter(Key counterId, uint32_t value) +{ + char key[50] = { 0 }; + auto err = ConstructCounterKey(counterId, key, sizeof(key)); + if (err != CHIP_NO_ERROR) + { + return err; + } + + return WriteConfigValue(key, value); +} + +CHIP_ERROR OpenIoTSDKConfig::ClearNamespace(const char * ns) +{ + if (Init() != CHIP_NO_ERROR) + { + return CHIP_ERROR_INTERNAL; + } + + iotsdk::storage::KVStore::iterator_t it; + char key[iotsdk::storage::KVStore::MAX_KEY_SIZE]; + kv_status err = tdb->iterator_open(&it, ns); + if (err != kv_status::OK) + { + return CHIP_ERROR_INTERNAL; + } + + while (true) + { + err = tdb->iterator_next(it, key, sizeof(key)); + if (err == kv_status::OK) + { + tdb->remove(key); + memset(key, 0, sizeof(key)); + } + else if (err == kv_status::ITEM_NOT_FOUND) + { + break; + } + else + { + (void) tdb->iterator_close(it); + return CHIP_ERROR_INTERNAL; + } + } + + err = tdb->iterator_close(it); + return err == kv_status::OK ? CHIP_NO_ERROR : CHIP_ERROR_INTERNAL; +} + +void OpenIoTSDKConfig::RunConfigUnitTest() +{ + // Run common unit test. + ::chip::DeviceLayer::Internal::RunConfigUnitTest(); +} + +CHIP_ERROR OpenIoTSDKConfig::Init(void) +{ + if (tdb) + { + return CHIP_NO_ERROR; + } + + flash_bd = new iotsdk::storage::FlashIAPBlockDevice(get_ram_drive_instance(), 0, 0); + + if (!flash_bd) + { + return CHIP_ERROR_INTERNAL; + } + + // Create a TDBStore using the underlying storage + tdb = new iotsdk::storage::TDBStore(flash_bd); + + if (!tdb) + { + delete flash_bd; + return CHIP_ERROR_INTERNAL; + } + + // KVStore uses dual stage initialization so we can handle any errors + // Call the `init` method to setup the TDBStore + kv_status err = tdb->init(); + if (err != kv_status::OK) + { + delete flash_bd; + delete tdb; + // zero tdb as we use it keep track of init + tdb = nullptr; + return CHIP_ERROR_INTERNAL; + } + + return CHIP_NO_ERROR; +} + +iotsdk::storage::TDBStore * OpenIoTSDKConfig::tdb = nullptr; +iotsdk::storage::FlashIAPBlockDevice * OpenIoTSDKConfig::flash_bd = nullptr; + +} // namespace Internal +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/openiotsdk/OpenIoTSDKConfig.h b/src/platform/openiotsdk/OpenIoTSDKConfig.h new file mode 100644 index 00000000000000..ed056f1fd8f1c0 --- /dev/null +++ b/src/platform/openiotsdk/OpenIoTSDKConfig.h @@ -0,0 +1,113 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Utilities for interacting with the the Open IoT SDK key-value storage. + */ + +#pragma once + +#include +#include + +#include "iotsdk/BufferedBlockDevice.h" +#include "iotsdk/FlashIAPBlockDevice.h" + +extern "C" { +#include "flash_cs300.h" +#include "hal/flash_api.h" +#include "iotsdk/TDBStore.h" +} +#include + +namespace chip { +namespace DeviceLayer { +namespace Internal { + +/** + * Provides functions and definitions for accessing device configuration information on the ESP32. + * + * This class is designed to be mixed-in to concrete implementation classes as a means to + * provide access to configuration information to generic base classes. + */ +class OpenIoTSDKConfig +{ +public: + using Key = const char *; + + // NVS prefix used to store device configuration information. + static const char kConfigNamespace_ChipFactory[]; + static const char kConfigNamespace_ChipConfig[]; + static const char kConfigNamespace_ChipCounters[]; + + // Key definitions for well-known keys. + static const Key kConfigKey_SerialNum; + static const Key kConfigKey_UniqueId; + static const Key kConfigKey_MfrDeviceId; + static const Key kConfigKey_MfrDeviceCert; + static const Key kConfigKey_MfrDeviceICACerts; + static const Key kConfigKey_MfrDevicePrivateKey; + static const Key kConfigKey_HardwareVersion; + static const Key kConfigKey_ManufacturingDate; + static const Key kConfigKey_SetupPinCode; + static const Key kConfigKey_ServiceConfig; + static const Key kConfigKey_PairedAccountId; + static const Key kConfigKey_ServiceId; + static const Key kConfigKey_LastUsedEpochKeyId; + static const Key kConfigKey_FailSafeArmed; + static const Key kConfigKey_WiFiStationSecType; + static const Key kConfigKey_SetupDiscriminator; + static const Key kConfigKey_RegulatoryLocation; + static const Key kConfigKey_CountryCode; + static const Key kConfigKey_Spake2pIterationCount; + static const Key kConfigKey_Spake2pSalt; + static const Key kConfigKey_Spake2pVerifier; + + // Config value accessors. + static CHIP_ERROR ReadConfigValue(Key key, bool & val); + static CHIP_ERROR ReadConfigValue(Key key, uint32_t & val); + static CHIP_ERROR ReadConfigValue(Key key, uint64_t & val); + static CHIP_ERROR ReadConfigValueStr(Key key, char * buf, size_t bufSize, size_t & outLen); + static CHIP_ERROR ReadConfigValueBin(Key key, uint8_t * buf, size_t bufSize, size_t & outLen); + static CHIP_ERROR WriteConfigValue(Key key, bool val); + static CHIP_ERROR WriteConfigValue(Key key, uint32_t val); + static CHIP_ERROR WriteConfigValue(Key key, uint64_t val); + static CHIP_ERROR WriteConfigValueStr(Key key, const char * str); + static CHIP_ERROR WriteConfigValueStr(Key key, const char * str, size_t strLen); + static CHIP_ERROR WriteConfigValueBin(Key key, const uint8_t * data, size_t dataLen); + static CHIP_ERROR ClearConfigValue(Key key); + static bool ConfigValueExists(Key key); + static CHIP_ERROR FactoryResetConfig(); + static CHIP_ERROR Init(void); + + // NVS Namespace helper functions. + static CHIP_ERROR ConstructCounterKey(Key id, char * buf, size_t bufSize); + static CHIP_ERROR ReadCounter(Key counterId, uint32_t & value); + static CHIP_ERROR WriteCounter(Key counterId, uint32_t value); + static CHIP_ERROR ClearNamespace(const char * ns); + + static void RunConfigUnitTest(void); + +private: + static iotsdk::storage::TDBStore * tdb; + static iotsdk::storage::FlashIAPBlockDevice * flash_bd; +}; + +} // namespace Internal +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/openiotsdk/PlatformManagerImpl.cpp b/src/platform/openiotsdk/PlatformManagerImpl.cpp new file mode 100644 index 00000000000000..47b8a5293dafdf --- /dev/null +++ b/src/platform/openiotsdk/PlatformManagerImpl.cpp @@ -0,0 +1,316 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides the implementation of the Device Layer Platform Manager class + * for Open IOT SDK platform. + */ + +#include "OpenIoTSDKArchUtils.h" +#include "platform/internal/CHIPDeviceLayerInternal.h" +#include + +#include +#include +#include +#include + +using namespace ::chip; +using namespace ::chip::Inet; +using namespace ::chip::System; + +namespace chip { +namespace DeviceLayer { + +CHIP_ERROR PlatformManagerImpl::_InitChipStack(void) +{ + // Members are initialized by the stack + osMutexAttr_t mut_att = { .attr_bits = osMutexRecursive }; + + // Reinitialize the Mutexes + mChipStackMutex = osMutexNew(&mut_att); + mEventTaskMutex = osMutexNew(nullptr); + mPlatformFlags = osEventFlagsNew(nullptr); + mQueue = osMessageQueueNew(CHIP_DEVICE_CONFIG_MAX_EVENT_QUEUE_SIZE, sizeof(ChipDeviceEvent), nullptr); + mTimer = osTimerNew(TimerCallback, osTimerOnce, NULL, NULL); + + if (!mChipStackMutex || !mEventTaskMutex || !mPlatformFlags || !mQueue || !mTimer) + { + osMutexDelete(mChipStackMutex); + osMutexDelete(mEventTaskMutex); + osEventFlagsDelete(mPlatformFlags); + osMessageQueueDelete(mQueue); + osTimerDelete(mTimer); + mChipStackMutex = mEventTaskMutex = mPlatformFlags = mQueue = mTimer = nullptr; + + return CHIP_ERROR_INTERNAL; + } + + SetConfigurationMgr(&ConfigurationManagerImpl::GetDefaultInstance()); + SetDiagnosticDataProvider(&DiagnosticDataProviderImpl::GetDefaultInstance()); + + // Call up to the base class _InitChipStack() to perform the bulk of the initialization. + CHIP_ERROR err = GenericPlatformManagerImpl::_InitChipStack(); + SuccessOrExit(err); + +exit: + return err; +} + +void PlatformManagerImpl::_LockChipStack() +{ + osMutexAcquire(mChipStackMutex, osWaitForever); +} + +bool PlatformManagerImpl::_TryLockChipStack() +{ + if (osMutexAcquire(mChipStackMutex, 0U) == osOK) + { + return true; + } + else + { + return false; + } +} + +void PlatformManagerImpl::_UnlockChipStack() +{ + osMutexRelease(mChipStackMutex); +} + +CHIP_ERROR PlatformManagerImpl::_PostEvent(const ChipDeviceEvent * eventPtr) +{ + osStatus_t status = osMessageQueuePut(mQueue, eventPtr, 0, 0); + CHIP_ERROR ret = (status == osOK) ? CHIP_NO_ERROR : CHIP_ERROR_INTERNAL; + osEventFlagsSet(mPlatformFlags, kPostEventFlag); + return ret; +} + +void PlatformManagerImpl::HandlePostEvent() +{ + /* handle an event */ + ChipDeviceEvent event; + osStatus_t status = osMessageQueueGet(mQueue, &event, nullptr, 0); + if (status == osOK) + { + LockChipStack(); + DispatchEvent(&event); + UnlockChipStack(); + } +} + +void PlatformManagerImpl::HandleTimerEvent(void) +{ + const CHIP_ERROR err = static_cast(DeviceLayer::SystemLayer()).HandlePlatformTimer(); + if (err != CHIP_NO_ERROR) + { + ChipLogError(DeviceLayer, "HandlePlatformTimer %ld", err.AsInteger()); + } +} + +void PlatformManagerImpl::RunEventLoopInternal() +{ + uint32_t flags = 0; + while (true) + { + flags = osEventFlagsWait(mPlatformFlags, kPostEventFlag | kTimerEventFlag | kTaskStopEventFlag, + osFlagsWaitAny | osFlagsNoClear, ms2tick(1000)); + + // in case of error we still need to know the value of flags we're not waiting for + if (flags & osFlagsError) + { + flags = osEventFlagsGet(mPlatformFlags); + } + + if (flags & kTaskStopEventFlag) + { + osEventFlagsClear(mPlatformFlags, kTaskStopEventFlag); + osEventFlagsClear(mPlatformFlags, kTaskRunningEventFlag); + break; + } + + if (flags & kTimerEventFlag) + { + osEventFlagsClear(mPlatformFlags, kTimerEventFlag); + HandleTimerEvent(); + } + + if (flags & kPostEventFlag) + { + HandlePostEvent(); + + if (!osMessageQueueGetCount(mQueue)) + { + osEventFlagsClear(mPlatformFlags, kPostEventFlag); + } + } + + if ((flags & kTaskRunningEventFlag) == 0) + { + break; + } + } +} + +void PlatformManagerImpl::_RunEventLoop() +{ + osEventFlagsSet(mPlatformFlags, kTaskRunningEventFlag); + + RunEventLoopInternal(); +} + +void PlatformManagerImpl::EventLoopTask(void * arg) +{ + (void) arg; + PlatformMgrImpl().RunEventLoopInternal(); + osThreadTerminate(osThreadGetId()); +} + +CHIP_ERROR PlatformManagerImpl::_StartEventLoopTask() +{ + // this mutex only needed to guard against multiple launches + { + osMutexAcquire(mEventTaskMutex, osWaitForever); + + if (kTaskRunningEventFlag & osEventFlagsGet(mPlatformFlags)) + { + osMutexRelease(mEventTaskMutex); + return CHIP_ERROR_BUSY; + } + + const osThreadAttr_t tread_attr = { + .name = CHIP_DEVICE_CONFIG_CHIP_TASK_NAME, + .stack_size = CHIP_DEVICE_CONFIG_CHIP_TASK_STACK_SIZE, + .priority = osPriorityNormal, + + }; + + osEventFlagsSet(mPlatformFlags, kTaskRunningEventFlag); + + // this thread is self terminating + osThreadId_t mEventTask = osThreadNew(EventLoopTask, NULL, &tread_attr); + + if (mEventTask == nullptr) + { + osMutexRelease(mEventTaskMutex); + return CHIP_ERROR_INTERNAL; + } + + osMutexRelease(mEventTaskMutex); + } + + return CHIP_NO_ERROR; +} + +CHIP_ERROR PlatformManagerImpl::_StopEventLoopTask() +{ + // this mutex only needed to guard against multiple calls to stop + { + osMutexAcquire(mEventTaskMutex, osWaitForever); + + uint32_t flags = osEventFlagsGet(mPlatformFlags); + if ((kTaskRunningEventFlag & flags) == 0) + { + osMutexRelease(mEventTaskMutex); + return CHIP_ERROR_INCORRECT_STATE; + } + + if (kTaskStopEventFlag & flags) + { + osMutexRelease(mEventTaskMutex); + return CHIP_ERROR_INCORRECT_STATE; + } + + osEventFlagsSet(mPlatformFlags, kTaskStopEventFlag); + + osMutexRelease(mEventTaskMutex); + } + + return CHIP_NO_ERROR; +} + +void PlatformManagerImpl::SetEventFlags(uint32_t flags) +{ + osEventFlagsSet(mPlatformFlags, flags); +} + +void PlatformManagerImpl::TimerCallback(void * arg) +{ + PlatformMgrImpl().SetEventFlags(kTimerEventFlag); +} + +CHIP_ERROR PlatformManagerImpl::_StartChipTimer(System::Clock::Timeout duration) +{ + if (duration.count() == 0) + { + TimerCallback(0); + } + else + { + auto res = osTimerStart(mTimer, ms2tick(duration.count())); + if (res) + { + ChipLogError(DeviceLayer, "osTimerStart failed %d", res); + return CHIP_ERROR_INTERNAL; + } + } + return CHIP_NO_ERROR; +} + +void PlatformManagerImpl::_Shutdown() +{ + // + // Call up to the base class _Shutdown() to perform the actual stack de-initialization + // and clean-up + // + + (void) _StopEventLoopTask(); + + // the task thread is self terminating, we might have to wait if it's still processing + while (true) + { + uint32_t flags = osEventFlagsGet(mPlatformFlags); + if ((kTaskRunningEventFlag & flags) == 0) + { + break; + } + osDelay(1); + } + + osMutexDelete(mChipStackMutex); + osMutexDelete(mEventTaskMutex); + osEventFlagsDelete(mPlatformFlags); + osMessageQueueDelete(mQueue); + osTimerDelete(mTimer); + mChipStackMutex = nullptr; + mPlatformFlags = nullptr; + mEventTaskMutex = nullptr; + mQueue = nullptr; + mTimer = nullptr; + + GenericPlatformManagerImpl::_Shutdown(); +} + +// ===== Members for internal use by the following friends. + +PlatformManagerImpl PlatformManagerImpl::sInstance; + +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/openiotsdk/PlatformManagerImpl.h b/src/platform/openiotsdk/PlatformManagerImpl.h new file mode 100644 index 00000000000000..70664944002143 --- /dev/null +++ b/src/platform/openiotsdk/PlatformManagerImpl.h @@ -0,0 +1,128 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides the implementation of the Device Layer Platform Manager class + * for Open IOT SDK platform. + */ + +#pragma once + +#include "cmsis_os2.h" +#include "mbedtls/platform.h" +#include +#include +#include + +namespace chip { +namespace DeviceLayer { + +/** + * Concrete implementation of the PlatformManager singleton object for the nRF Connect SDK platforms. + */ +class PlatformManagerImpl final : public PlatformManager, public Internal::GenericPlatformManagerImpl +{ + // Allow the PlatformManager interface class to delegate method calls to + // the implementation methods provided by this class. + friend PlatformManager; + + // Allow the generic implementation base class to call helper methods on + // this class. +#ifndef DOXYGEN_SHOULD_SKIP_THIS + friend Internal::GenericPlatformManagerImpl; +#endif +public: + // ===== Platform-specific members that may be accessed directly by the application. + + /* none so far */ + +private: + static constexpr uint32_t kTaskRunningEventFlag = 1 << 0; + static constexpr uint32_t kTaskStopEventFlag = 1 << 1; + static constexpr uint32_t kPostEventFlag = 1 << 2; + static constexpr uint32_t kTimerEventFlag = 1 << 3; + + // ===== Methods that implement the PlatformManager abstract interface. + + CHIP_ERROR _InitChipStack(void); + void _LockChipStack(); + bool _TryLockChipStack(); + void _UnlockChipStack(); + + CHIP_ERROR _PostEvent(const ChipDeviceEvent * event); + + void _RunEventLoop(); + CHIP_ERROR _StartEventLoopTask(); + CHIP_ERROR _StopEventLoopTask(); + + CHIP_ERROR _StartChipTimer(System::Clock::Timeout duration); + void _Shutdown(); + + void SetEventFlags(uint32_t flags); + void HandleTimerEvent(void); + void HandlePostEvent(void); + + static void EventLoopTask(void * arg); + static void TimerCallback(void * arg); + + void RunEventLoopInternal(void); + + // ===== Members for internal use by the following friends. + + friend PlatformManager & PlatformMgr(void); + friend PlatformManagerImpl & PlatformMgrImpl(void); + friend class ConnectivityManagerImpl; + friend class GapEventHandler; + friend class CHIPService; + + using PlatformManager::PostEvent; + using PlatformManager::PostEventOrDie; + static PlatformManagerImpl sInstance; + + osEventFlagsId_t mPlatformFlags = nullptr; + osMutexId_t mChipStackMutex = nullptr; + osMutexId_t mEventTaskMutex = nullptr; + osMessageQueueId_t mQueue = nullptr; + osTimerId_t mTimer = nullptr; +}; + +/** + * Returns the public interface of the PlatformManager singleton object. + * + * chip applications should use this to access features of the PlatformManager object + * that are common to all platforms. + */ +inline PlatformManager & PlatformMgr(void) +{ + return PlatformManagerImpl::sInstance; +} + +/** + * Returns the platform-specific implementation of the PlatformManager singleton object. + * + * chip applications can use this to gain access to features of the PlatformManager + * that are specific to the Mbed platform. + */ +inline PlatformManagerImpl & PlatformMgrImpl() +{ + return PlatformManagerImpl::sInstance; +} + +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/openiotsdk/SystemPlatformConfig.h b/src/platform/openiotsdk/SystemPlatformConfig.h new file mode 100644 index 00000000000000..c17393375bbe4c --- /dev/null +++ b/src/platform/openiotsdk/SystemPlatformConfig.h @@ -0,0 +1,42 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Platform-specific configuration overrides for the CHIP System + * Layer on Open IoT SDK platform. + * + */ + +#pragma once + +#include + +// ==================== Platform Adaptations ==================== +#define CHIP_SYSTEM_CONFIG_POSIX_LOCKING 0 +#define CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING 0 +#define CHIP_SYSTEM_CONFIG_MBED_LOCKING 0 +#define CHIP_SYSTEM_CONFIG_NO_LOCKING 0 +#define CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING 1 + +#define CHIP_SYSTEM_CONFIG_PLATFORM_PROVIDES_TIME 1 +#ifndef CHIP_SYSTEM_CONFIG_USE_LWIP_MONOTONIC_TIME +#define CHIP_SYSTEM_CONFIG_USE_LWIP_MONOTONIC_TIME 0 +#endif // CHIP_SYSTEM_CONFIG_USE_LWIP_MONOTONIC_TIME + +// ========== Platform-specific Configuration Overrides ========= diff --git a/src/platform/openiotsdk/SystemTimeSupport.cpp b/src/platform/openiotsdk/SystemTimeSupport.cpp new file mode 100644 index 00000000000000..60b7dc0f00ebd6 --- /dev/null +++ b/src/platform/openiotsdk/SystemTimeSupport.cpp @@ -0,0 +1,71 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides an implementation of the system time support + * for Open IOT SDK platform. + */ + +#include +#include + +#include +#include +#include + +#include "OpenIoTSDKArchUtils.h" +#include "cmsis_os2.h" + +namespace chip { +namespace System { +namespace Clock { + +namespace Internal { + +ClockImpl gClockImpl; + +} // namespace Internal + +Clock::Microseconds64 ClockImpl::GetMonotonicMicroseconds64(void) +{ + return Clock::Microseconds64(tick2us(GetTick())); +} + +Clock::Milliseconds64 ClockImpl::GetMonotonicMilliseconds64(void) +{ + return Clock::Milliseconds64(tick2ms(GetTick())); +} + +CHIP_ERROR ClockImpl::GetClock_RealTime(Clock::Microseconds64 & aCurTime) +{ + return CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE; +} + +CHIP_ERROR ClockImpl::GetClock_RealTimeMS(Clock::Milliseconds64 & aCurTime) +{ + return CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE; +} + +CHIP_ERROR ClockImpl::SetClock_RealTime(Clock::Microseconds64 aNewCurTime) +{ + return CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE; +} + +} // namespace Clock +} // namespace System +} // namespace chip diff --git a/src/platform/qpg/ConfigurationManagerImpl.cpp b/src/platform/qpg/ConfigurationManagerImpl.cpp index 1825b101b3cbef..872b05cc6c08f6 100644 --- a/src/platform/qpg/ConfigurationManagerImpl.cpp +++ b/src/platform/qpg/ConfigurationManagerImpl.cpp @@ -48,6 +48,8 @@ CHIP_ERROR ConfigurationManagerImpl::Init() { CHIP_ERROR err; uint32_t rebootCount; + qvResetReason_t qvRebootReason; + BootReasonType bootReason; // Initialize the generic implementation base class. err = Internal::GenericConfigurationManagerImpl::Init(); @@ -74,12 +76,38 @@ CHIP_ERROR ConfigurationManagerImpl::Init() SuccessOrExit(err); } - if (!QPGConfig::ConfigValueExists(QPGConfig::kCounterKey_BootReason)) + qvRebootReason = qvCHIP_GetResetReason(); + + switch (qvRebootReason) { - err = StoreBootReason(to_underlying(BootReasonType::kUnspecified)); - SuccessOrExit(err); + case qvResetReason_HW_BrownOutDetected: { + bootReason = BootReasonType::kBrownOutReset; + break; + } + + case qvResetReason_HW_Watchdog: { + bootReason = BootReasonType::kHardwareWatchdogReset; + break; + } + + case qvResetReason_HW_Por: { + bootReason = BootReasonType::kPowerOnReboot; + break; } + case qvResetReason_SW_Por: { + bootReason = BootReasonType::kSoftwareReset; + break; + } + + default: + bootReason = BootReasonType::kUnspecified; + break; + } + + err = StoreBootReason(to_underlying(bootReason)); + SuccessOrExit(err); + err = CHIP_NO_ERROR; exit: diff --git a/src/platform/qpg/qpgConfig.cpp b/src/platform/qpg/qpgConfig.cpp index 0eec2eeecd4849..cb104485bedfca 100644 --- a/src/platform/qpg/qpgConfig.cpp +++ b/src/platform/qpg/qpgConfig.cpp @@ -211,7 +211,8 @@ CHIP_ERROR QPGConfig::ClearConfigValue(Key key) bool QPGConfig::ConfigValueExists(Key key) { - return qvCHIP_Nvm_ValueExists(key, NULL); + uint16_t dummy = 0; + return qvCHIP_Nvm_ValueExists(key, &dummy); } CHIP_ERROR QPGConfig::FactoryResetConfig(void) diff --git a/src/platform/silabs/BLEManagerImpl.h b/src/platform/silabs/BLEManagerImpl.h index 0f1d478f179b61..e0a04e5f356e7e 100644 --- a/src/platform/silabs/BLEManagerImpl.h +++ b/src/platform/silabs/BLEManagerImpl.h @@ -26,10 +26,22 @@ #if CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE #include "FreeRTOS.h" +#include "timers.h" +#ifdef RS91X_BLE_ENABLE +#ifdef __cplusplus +extern "C" { +#endif +#include +#include +#include +#ifdef __cplusplus +} +#endif +#else #include "gatt_db.h" #include "sl_bgapi.h" #include "sl_bt_api.h" -#include "timers.h" +#endif // RS91X_BLE_ENABLE namespace chip { namespace DeviceLayer { @@ -45,6 +57,16 @@ class BLEManagerImpl final : public BLEManager, private BleLayer, private BlePla public: void HandleBootEvent(void); + +#ifdef RS91X_BLE_ENABLE + void HandleConnectEvent(void); + void HandleConnectionCloseEvent(uint16_t reason); + void HandleWriteEvent(rsi_ble_event_write_t evt); + void UpdateMtu(rsi_ble_event_mtu_t evt); + void HandleTxConfirmationEvent(BLE_CONNECTION_OBJECT conId); + void HandleTXCharCCCDWrite(rsi_ble_event_write_t * evt); + void HandleSoftTimerEvent(void); +#else void HandleConnectEvent(volatile sl_bt_msg_t * evt); void HandleConnectionCloseEvent(volatile sl_bt_msg_t * evt); void HandleWriteEvent(volatile sl_bt_msg_t * evt); @@ -53,9 +75,17 @@ class BLEManagerImpl final : public BLEManager, private BleLayer, private BlePla void HandleTXCharCCCDWrite(volatile sl_bt_msg_t * evt); void HandleSoftTimerEvent(volatile sl_bt_msg_t * evt); +#endif // RS91X_BLE_ENABLE + +#if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING +#ifdef RS91X_BLE_ENABLE + static void HandleC3ReadRequest(void); +#else #if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING static void HandleC3ReadRequest(volatile sl_bt_msg_t * evt); #endif +#endif +#endif private: // Allow the BLEManager interface class to delegate method calls to @@ -125,7 +155,9 @@ class BLEManagerImpl final : public BLEManager, private BleLayer, private BlePla struct CHIPoBLEConState { +#ifndef RS91X_BLE_ENABLE bd_addr address; +#endif uint16_t mtu : 10; uint16_t allocated : 1; uint16_t subscribed : 1; @@ -153,7 +185,12 @@ class BLEManagerImpl final : public BLEManager, private BleLayer, private BlePla #if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING CHIP_ERROR EncodeAdditionalDataTlv(); #endif + +#ifdef RS91X_BLE_ENABLE + void HandleRXCharWrite(rsi_ble_event_write_t * evt); +#else void HandleRXCharWrite(volatile sl_bt_msg_t * evt); +#endif bool RemoveConnection(uint8_t connectionHandle); void AddConnection(uint8_t connectionHandle, uint8_t bondingHandle); void StartBleAdvTimeoutTimer(uint32_t aTimeoutInMs); diff --git a/src/platform/silabs/CHIPDevicePlatformConfig.h b/src/platform/silabs/CHIPDevicePlatformConfig.h index b2f46f2dbc40c5..30cfcf437f5b13 100644 --- a/src/platform/silabs/CHIPDevicePlatformConfig.h +++ b/src/platform/silabs/CHIPDevicePlatformConfig.h @@ -31,6 +31,15 @@ #define CHIP_DEVICE_CONFIG_ENABLE_WIFI_AP 0 +/** + * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING + * + * A string identifying the software version running on the device. + */ +#ifdef SL_MATTER_VERSION_STRING +#define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING SL_MATTER_VERSION_STRING +#endif + #if defined(SL_WIFI) #define CHIP_DEVICE_CONFIG_ENABLE_WIFI_STATION 1 #else @@ -81,6 +90,14 @@ #define CHIP_DEVICE_CONFIG_CHIP_TASK_STACK_SIZE (6 * 1024) #endif // CHIP_DEVICE_CONFIG_CHIP_TASK_STACK_SIZE +#ifndef CHIP_DEVICE_CONFIG_SED_IDLE_INTERVAL +#define CHIP_DEVICE_CONFIG_SED_IDLE_INTERVAL chip::System::Clock::Milliseconds32(SL_SLEEP_TIME_MS) +#endif // CHIP_DEVICE_CONFIG_SED_IDLE_INTERVAL + +#ifndef CHIP_DEVICE_CONFIG_SED_ACTIVE_INTERVAL +#define CHIP_DEVICE_CONFIG_SED_ACTIVE_INTERVAL chip::System::Clock::Milliseconds32(200) +#endif // CHIP_DEVICE_CONFIG_SED_ACTIVE_INTERVAL + #ifndef CHIP_DEVICE_CONFIG_THREAD_TASK_STACK_SIZE #if defined(EFR32MG21) #define CHIP_DEVICE_CONFIG_THREAD_TASK_STACK_SIZE (2 * 1024) diff --git a/src/platform/silabs/CHIPMem-Platform.cpp b/src/platform/silabs/CHIPMem-Platform.cpp index 4f8b938f5d26ec..a826ebe856ca1e 100644 --- a/src/platform/silabs/CHIPMem-Platform.cpp +++ b/src/platform/silabs/CHIPMem-Platform.cpp @@ -150,7 +150,12 @@ bool MemoryInternalCheckPointer(const void * p, size_t min_size) } // namespace Platform } // namespace chip +#ifdef BRD4325A +extern "C" void memMonitoringTrackAlloc(void * ptr, size_t size) {} +extern "C" void memMonitoringTrackFree(void * ptr, size_t size) {} +#else extern "C" __WEAK void memMonitoringTrackAlloc(void * ptr, size_t size) {} extern "C" __WEAK void memMonitoringTrackFree(void * ptr, size_t size) {} +#endif // BRD4325A #endif // CHIP_CONFIG_MEMORY_MGMT_PLATFORM diff --git a/src/platform/silabs/ConnectivityManagerImpl_WIFI.cpp b/src/platform/silabs/ConnectivityManagerImpl_WIFI.cpp index 7bb0741b83d1a6..effee8c67d71a5 100644 --- a/src/platform/silabs/ConnectivityManagerImpl_WIFI.cpp +++ b/src/platform/silabs/ConnectivityManagerImpl_WIFI.cpp @@ -262,6 +262,7 @@ void ConnectivityManagerImpl::DriveStationState() // If the WiFi station interface is no longer enabled, or no longer provisioned, // disconnect the station from the AP, unless the WiFi station mode is currently // under application control. +#ifndef CHIP_ONNETWORK_PAIRING if (mWiFiStationMode != kWiFiStationMode_ApplicationControlled && (mWiFiStationMode != kWiFiStationMode_Enabled || !IsWiFiStationProvisioned())) { @@ -275,6 +276,7 @@ void ConnectivityManagerImpl::DriveStationState() ChangeWiFiStationState(kWiFiStationState_Disconnecting); } +#endif } // Otherwise the station interface is NOT connected to an AP, so... else diff --git a/src/platform/silabs/DiagnosticDataProviderImpl.cpp b/src/platform/silabs/DiagnosticDataProviderImpl.cpp index 0b62542afbf3dd..9924f8f3a1691a 100644 --- a/src/platform/silabs/DiagnosticDataProviderImpl.cpp +++ b/src/platform/silabs/DiagnosticDataProviderImpl.cpp @@ -479,6 +479,18 @@ CHIP_ERROR DiagnosticDataProviderImpl::GetWiFiOverrunCount(uint64_t & overrunCou return CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE; } +CHIP_ERROR DiagnosticDataProviderImpl::GetWiFiBeaconRxCount(uint32_t & beaconRxCount) +{ + wfx_wifi_scan_ext_t extra_info; + int32_t err = wfx_get_ap_ext(&extra_info); + if (err == 0) + { + beaconRxCount = extra_info.beacon_rx_count; + return CHIP_NO_ERROR; + } + return CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE; +} + CHIP_ERROR DiagnosticDataProviderImpl::ResetWiFiNetworkDiagnosticsCounts() { int32_t err = wfx_reset_counts(); diff --git a/src/platform/silabs/DiagnosticDataProviderImpl.h b/src/platform/silabs/DiagnosticDataProviderImpl.h index b6f45c1b5d292b..869a50bc636319 100644 --- a/src/platform/silabs/DiagnosticDataProviderImpl.h +++ b/src/platform/silabs/DiagnosticDataProviderImpl.h @@ -63,6 +63,7 @@ class DiagnosticDataProviderImpl : public DiagnosticDataProvider CHIP_ERROR GetWiFiChannelNumber(uint16_t & channelNumber) override; CHIP_ERROR GetWiFiRssi(int8_t & rssi) override; CHIP_ERROR GetWiFiBeaconLostCount(uint32_t & beaconLostCount) override; + CHIP_ERROR GetWiFiBeaconRxCount(uint32_t & beaconRxCount) override; CHIP_ERROR GetWiFiPacketMulticastRxCount(uint32_t & packetMulticastRxCount) override; CHIP_ERROR GetWiFiPacketMulticastTxCount(uint32_t & packetMulticastTxCount) override; CHIP_ERROR GetWiFiPacketUnicastRxCount(uint32_t & packetUnicastRxCount) override; diff --git a/src/platform/silabs/SiWx917/BLEManagerImpl.cpp b/src/platform/silabs/SiWx917/BLEManagerImpl.cpp new file mode 100644 index 00000000000000..6563f4b5b2e790 --- /dev/null +++ b/src/platform/silabs/SiWx917/BLEManagerImpl.cpp @@ -0,0 +1,1031 @@ +/* + * + * Copyright (c) 2020-2021 Project CHIP Authors + * Copyright (c) 2019 Nest Labs, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides an implementation of the BLEManager singleton object + * for the Silicon Labs EFR32 platforms. + */ + +/* this file behaves like a config.h, comes first */ +#include +#if CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE + +#include +#define RSI_BLE_ENABLE 1 + +//#include "rail.h" +extern "C" { +#include "FreeRTOS.h" +#include "event_groups.h" +#include "task.h" +#include "timers.h" +#include "wfx_host_events.h" +#include "wfx_rsi.h" +#include "wfx_sl_ble_init.h" +#include +#include +#include +} +#include +#include +#include +#include +#include +#include + +#if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING +#include +#endif + +// static int32_t handleTxConfirmationFlag = 0; +extern uint16_t rsi_ble_measurement_hndl; +extern rsi_ble_event_conn_status_t conn_event_to_app; +extern sl_wfx_msg_t event_msg; + +// StaticTask_t busInitTaskStruct; + +/* wfxRsi Task will use as its stack */ +// StackType_t wfxRsiInitTaskStack[WFX_RSI_TASK_SZ] = { 0 }; + +using namespace ::chip; +using namespace ::chip::Ble; + +void rsi_ble_event_handling_task(void) +{ + int32_t event_id; + + // int32_t event_id; + WFX_RSI_LOG("StartAdvertising"); + // chip::DeviceLayer::Internal::BLEManagerImpl().StartAdvertising(); //TODO:: Called on after init of module + + // Application event map + while (1) + { + // checking for events list + event_id = rsi_ble_app_get_event(); + if (event_id == -1) + { + continue; + } + switch (event_id) + { + case RSI_BLE_CONN_EVENT: { + rsi_ble_app_clear_event(RSI_BLE_CONN_EVENT); + chip::DeviceLayer::Internal::BLEMgrImpl().HandleConnectEvent(); + WFX_RSI_LOG(" RSI_BLE : Module got connected"); + } + break; + case RSI_BLE_DISCONN_EVENT: { + // event invokes when disconnection was completed + WFX_RSI_LOG(" RSI_BLE : Module got Disconnected"); + chip::DeviceLayer::Internal::BLEMgrImpl().HandleConnectionCloseEvent(event_msg.reason); + // clear the served event + rsi_ble_app_clear_event(RSI_BLE_DISCONN_EVENT); + } + break; + case RSI_BLE_MTU_EVENT: { + // event invokes when write/notification events received + WFX_RSI_LOG("RSI_BLE:: RSI_BLE_MTU_EVENT"); + chip::DeviceLayer::Internal::BLEMgrImpl().UpdateMtu(event_msg.rsi_ble_mtu); + // clear the served event + rsi_ble_app_clear_event(RSI_BLE_MTU_EVENT); + } + break; + case RSI_BLE_GATT_WRITE_EVENT: { + // event invokes when write/notification events received + WFX_RSI_LOG("RSI_BLE : RSI_BLE_GATT_WRITE_EVENT"); + chip::DeviceLayer::Internal::BLEMgrImpl().HandleWriteEvent(event_msg.rsi_ble_write); + // clear the served event + rsi_ble_app_clear_event(RSI_BLE_GATT_WRITE_EVENT); + } + break; + case RSI_BLE_GATT_INDICATION_CONFIRMATION: { + WFX_RSI_LOG("RSI_BLE : indication confirmation"); + chip::DeviceLayer::Internal::BLEMgrImpl().HandleTxConfirmationEvent(1); + rsi_ble_app_clear_event(RSI_BLE_GATT_INDICATION_CONFIRMATION); + } + break; + + case RSI_BLE_RESP_ATT_VALUE: { + WFX_RSI_LOG("RSI_BLE : RESP_ATT confirmation"); + } + default: + break; + } + } + + WFX_RSI_LOG("%s END", __func__); +} + +namespace chip { +namespace DeviceLayer { +namespace Internal { + +namespace { + +#define CHIP_ADV_DATA_TYPE_FLAGS 0x01 +#define CHIP_ADV_DATA_TYPE_UUID 0x03 +#define CHIP_ADV_DATA_TYPE_NAME 0x09 +#define CHIP_ADV_DATA_TYPE_SERVICE_DATA 0x16 + +#define CHIP_ADV_DATA_FLAGS 0x06 + +#define CHIP_ADV_DATA 0 +#define CHIP_ADV_SCAN_RESPONSE_DATA 1 +#define CHIP_ADV_SHORT_UUID_LEN 2 + +#define MAX_RESPONSE_DATA_LEN 31 +#define MAX_ADV_DATA_LEN 31 + +// Timer Frequency used. +#define TIMER_CLK_FREQ ((uint32_t) 32768) + +// Convert msec to timer ticks. +#define TIMER_MS_2_TIMERTICK(ms) ((TIMER_CLK_FREQ * ms) / 1000) +#define TIMER_S_2_TIMERTICK(s) (TIMER_CLK_FREQ * s) + +#define BLE_MAX_BUFFER_SIZE (3076) +#define BLE_MAX_ADVERTISERS (1) +#define BLE_CONFIG_MAX_PERIODIC_ADVERTISING_SYNC (0) +#define BLE_CONFIG_MAX_SOFTWARE_TIMERS (4) +#define BLE_CONFIG_MIN_TX_POWER (-30) +#define BLE_CONFIG_MAX_TX_POWER (80) +#define BLE_CONFIG_RF_PATH_GAIN_TX (0) +#define BLE_CONFIG_RF_PATH_GAIN_RX (0) + +// Default Connection parameters +#define BLE_CONFIG_MIN_INTERVAL (16) // Time = Value x 1.25 ms = 30ms +#define BLE_CONFIG_MAX_INTERVAL (80) // Time = Value x 1.25 ms = 100ms +#define BLE_CONFIG_LATENCY (0) +#define BLE_CONFIG_TIMEOUT (100) // Time = Value x 10 ms = 1s +#define BLE_CONFIG_MIN_CE_LENGTH (0) // Leave to min value +#define BLE_CONFIG_MAX_CE_LENGTH (0xFFFF) // Leave to max value + +#define BLE__DEFAULT_TIMER_PERIOD 1 + +TimerHandle_t sbleAdvTimeoutTimer; // FreeRTOS sw timer. + +const uint8_t UUID_CHIPoBLEService[] = { 0xFB, 0x34, 0x9B, 0x5F, 0x80, 0x00, 0x00, 0x80, + 0x00, 0x10, 0x00, 0x00, 0xF6, 0xFF, 0x00, 0x00 }; +const uint8_t ShortUUID_CHIPoBLEService[] = { 0xF6, 0xFF }; +const ChipBleUUID ChipUUID_CHIPoBLEChar_RX = { { 0x18, 0xEE, 0x2E, 0xF5, 0x26, 0x3D, 0x45, 0x59, 0x95, 0x9F, 0x4F, 0x9C, 0x42, 0x9F, + 0x9D, 0x11 } }; +const ChipBleUUID ChipUUID_CHIPoBLEChar_TX = { { 0x18, 0xEE, 0x2E, 0xF5, 0x26, 0x3D, 0x45, 0x59, 0x95, 0x9F, 0x4F, 0x9C, 0x42, 0x9F, + 0x9D, 0x12 } }; + +} // namespace + +BLEManagerImpl BLEManagerImpl::sInstance; + +CHIP_ERROR BLEManagerImpl::_Init() +{ + CHIP_ERROR err; + ChipLogProgress(DeviceLayer, "%s Start ", __func__); + + // wfx_rsi.init_task = xTaskCreateStatic((TaskFunction_t) wfx_sl_module_init, "init_task", WFX_RSI_TASK_SZ, NULL, 1, + // wfxRsiInitTaskStack, &busInitTaskStruct); + + if (NULL == wfx_rsi.init_task) + { + WFX_RSI_LOG("%s: error: failed to create task.", __func__); + } + + // Initialize the CHIP BleLayer. + err = BleLayer::Init(this, this, &DeviceLayer::SystemLayer()); + SuccessOrExit(err); + + return err; + + ble_rsi_task(); + memset(mBleConnections, 0, sizeof(mBleConnections)); + memset(mIndConfId, kUnusedIndex, sizeof(mIndConfId)); + mServiceMode = ConnectivityManager::kCHIPoBLEServiceMode_Enabled; + + // Create FreeRTOS sw timer for BLE timeouts and interval change. + sbleAdvTimeoutTimer = xTimerCreate("BleAdvTimer", // Just a text name, not used by the RTOS kernel + BLE__DEFAULT_TIMER_PERIOD, // == default timer period (mS) + false, // no timer reload (==one-shot) + (void *) this, // init timer id = ble obj context + BleAdvTimeoutHandler // timer callback handler + ); + + mFlags.ClearAll().Set(Flags::kAdvertisingEnabled, CHIP_DEVICE_CONFIG_CHIPOBLE_ENABLE_ADVERTISING_AUTOSTART); + mFlags.Set(Flags::kFastAdvertisingEnabled, true); + PlatformMgr().ScheduleWork(DriveBLEState, 0); + +exit: + ChipLogProgress(DeviceLayer, "%s END ", __func__); + return err; +} + +uint16_t BLEManagerImpl::_NumConnections(void) +{ + uint16_t numCons = 0; + for (uint16_t i = 0; i < kMaxConnections; i++) + { + if (mBleConnections[i].allocated) + { + numCons++; + } + } + + return numCons; +} + +CHIP_ERROR BLEManagerImpl::_SetAdvertisingEnabled(bool val) +{ + CHIP_ERROR err = CHIP_NO_ERROR; + + VerifyOrExit(mServiceMode != ConnectivityManager::kCHIPoBLEServiceMode_NotSupported, err = CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE); + + if (mFlags.Has(Flags::kAdvertisingEnabled) != val) + { + mFlags.Set(Flags::kAdvertisingEnabled, val); + PlatformMgr().ScheduleWork(DriveBLEState, 0); + } + +exit: + return err; +} + +CHIP_ERROR BLEManagerImpl::_SetAdvertisingMode(BLEAdvertisingMode mode) +{ + switch (mode) + { + case BLEAdvertisingMode::kFastAdvertising: + mFlags.Set(Flags::kFastAdvertisingEnabled, true); + break; + case BLEAdvertisingMode::kSlowAdvertising: + mFlags.Set(Flags::kFastAdvertisingEnabled, false); + break; + default: + return CHIP_ERROR_INVALID_ARGUMENT; + } + mFlags.Set(Flags::kRestartAdvertising); + PlatformMgr().ScheduleWork(DriveBLEState, 0); + return CHIP_NO_ERROR; +} + +CHIP_ERROR BLEManagerImpl::_GetDeviceName(char * buf, size_t bufSize) +{ + if (strlen(mDeviceName) >= bufSize) + { + return CHIP_ERROR_BUFFER_TOO_SMALL; + } + strcpy(buf, mDeviceName); + return CHIP_NO_ERROR; +} + +CHIP_ERROR BLEManagerImpl::_SetDeviceName(const char * deviceName) +{ + ChipLogProgress(DeviceLayer, "_SetDeviceName Started"); + rsi_bt_set_local_name((uint8_t *) RSI_BLE_DEV_NAME); + if (mServiceMode == ConnectivityManager::kCHIPoBLEServiceMode_NotSupported) + { + ChipLogProgress(DeviceLayer, "_SetDeviceName CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE"); + return CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE; + } + if (deviceName != NULL && deviceName[0] != 0) + { + if (strlen(deviceName) >= kMaxDeviceNameLength) + { + ChipLogProgress(DeviceLayer, "_SetDeviceName CHIP_ERROR_INVALID_ARGUMENT"); + return CHIP_ERROR_INVALID_ARGUMENT; + } + strcpy(mDeviceName, deviceName); + mFlags.Set(Flags::kDeviceNameSet); + mFlags.Set(Flags::kRestartAdvertising); + ChipLogProgress(DeviceLayer, "Setting device name to : \"%s\"", mDeviceName); + } + else + { + mDeviceName[0] = 0; + } + PlatformMgr().ScheduleWork(DriveBLEState, 0); + ChipLogProgress(DeviceLayer, "_SetDeviceName Ended"); + return CHIP_NO_ERROR; +} + +void BLEManagerImpl::_OnPlatformEvent(const ChipDeviceEvent * event) +{ + switch (event->Type) + { + case DeviceEventType::kCHIPoBLESubscribe: { + ChipDeviceEvent connEstEvent; + + ChipLogProgress(DeviceLayer, "_OnPlatformEvent kCHIPoBLESubscribe"); + HandleSubscribeReceived(event->CHIPoBLESubscribe.ConId, &CHIP_BLE_SVC_ID, &ChipUUID_CHIPoBLEChar_TX); + connEstEvent.Type = DeviceEventType::kCHIPoBLEConnectionEstablished; + PlatformMgr().PostEventOrDie(&connEstEvent); + } + break; + + case DeviceEventType::kCHIPoBLEUnsubscribe: { + ChipLogProgress(DeviceLayer, "_OnPlatformEvent kCHIPoBLEUnsubscribe"); + HandleUnsubscribeReceived(event->CHIPoBLEUnsubscribe.ConId, &CHIP_BLE_SVC_ID, &ChipUUID_CHIPoBLEChar_TX); + } + break; + + case DeviceEventType::kCHIPoBLEWriteReceived: { + ChipLogProgress(DeviceLayer, "_OnPlatformEvent kCHIPoBLEWriteReceived"); + HandleWriteReceived(event->CHIPoBLEWriteReceived.ConId, &CHIP_BLE_SVC_ID, &ChipUUID_CHIPoBLEChar_RX, + PacketBufferHandle::Adopt(event->CHIPoBLEWriteReceived.Data)); + } + break; + + case DeviceEventType::kCHIPoBLEConnectionError: { + ChipLogProgress(DeviceLayer, "_OnPlatformEvent kCHIPoBLEConnectionError"); + HandleConnectionError(event->CHIPoBLEConnectionError.ConId, event->CHIPoBLEConnectionError.Reason); + } + break; + + case DeviceEventType::kCHIPoBLEIndicateConfirm: { + ChipLogProgress(DeviceLayer, "_OnPlatformEvent kCHIPoBLEIndicateConfirm"); + HandleIndicationConfirmation(event->CHIPoBLEIndicateConfirm.ConId, &CHIP_BLE_SVC_ID, &ChipUUID_CHIPoBLEChar_TX); + } + break; + + default: + ChipLogProgress(DeviceLayer, "_OnPlatformEvent default: event->Type = %d", event->Type); + break; + } +} + +bool BLEManagerImpl::SubscribeCharacteristic(BLE_CONNECTION_OBJECT conId, const ChipBleUUID * svcId, const ChipBleUUID * charId) +{ + ChipLogProgress(DeviceLayer, "BLEManagerImpl::SubscribeCharacteristic() not supported"); + return false; +} + +bool BLEManagerImpl::UnsubscribeCharacteristic(BLE_CONNECTION_OBJECT conId, const ChipBleUUID * svcId, const ChipBleUUID * charId) +{ + ChipLogProgress(DeviceLayer, "BLEManagerImpl::UnsubscribeCharacteristic() not supported"); + return false; +} + +bool BLEManagerImpl::CloseConnection(BLE_CONNECTION_OBJECT conId) +{ + CHIP_ERROR err = CHIP_NO_ERROR; + // int32_t ret; + + ChipLogProgress(DeviceLayer, "Closing BLE GATT connection (con %u)", conId); + + // ret = rsi_ble_disconnect(1); + // err = MapBLEError(ret); + + if (err != CHIP_NO_ERROR) + { + ChipLogError(DeviceLayer, "sl_bt_connection_close() failed: %s", ErrorStr(err)); + } + + return true; //(err == CHIP_NO_ERROR); +} + +uint16_t BLEManagerImpl::GetMTU(BLE_CONNECTION_OBJECT conId) const +{ + CHIPoBLEConState * conState = const_cast(this)->GetConnectionState(conId); + return (conState != NULL) ? conState->mtu : 0; +} + +bool BLEManagerImpl::SendIndication(BLE_CONNECTION_OBJECT conId, const ChipBleUUID * svcId, const ChipBleUUID * charId, + PacketBufferHandle data) +{ + int32_t status = 0; + WFX_RSI_LOG("In send indication"); + status = rsi_ble_indicate_value(event_msg.resp_enh_conn.dev_addr, event_msg.rsi_ble_measurement_hndl, (data->DataLength()), + data->Start()); + if (status != RSI_SUCCESS) + { + WFX_RSI_LOG("indication %d failed with error code %lx ", status); + } + + return true; +} + +bool BLEManagerImpl::SendWriteRequest(BLE_CONNECTION_OBJECT conId, const ChipBleUUID * svcId, const ChipBleUUID * charId, + PacketBufferHandle pBuf) +{ + ChipLogProgress(DeviceLayer, "BLEManagerImpl::SendWriteRequest() not supported"); + return false; +} + +bool BLEManagerImpl::SendReadRequest(BLE_CONNECTION_OBJECT conId, const ChipBleUUID * svcId, const ChipBleUUID * charId, + PacketBufferHandle pBuf) +{ + ChipLogProgress(DeviceLayer, "BLEManagerImpl::SendReadRequest() not supported"); + return false; +} + +bool BLEManagerImpl::SendReadResponse(BLE_CONNECTION_OBJECT conId, BLE_READ_REQUEST_CONTEXT requestContext, + const ChipBleUUID * svcId, const ChipBleUUID * charId) +{ + ChipLogProgress(DeviceLayer, "BLEManagerImpl::SendReadResponse() not supported"); + return false; +} + +void BLEManagerImpl::NotifyChipConnectionClosed(BLE_CONNECTION_OBJECT conId) +{ + // Nothing to do +} + +CHIP_ERROR BLEManagerImpl::MapBLEError(int bleErr) +{ + switch (bleErr) + { + case SL_STATUS_OK: + return CHIP_NO_ERROR; + case SL_STATUS_BT_ATT_INVALID_ATT_LENGTH: + return CHIP_ERROR_INVALID_STRING_LENGTH; + case SL_STATUS_INVALID_PARAMETER: + return CHIP_ERROR_INVALID_ARGUMENT; + case SL_STATUS_INVALID_STATE: + return CHIP_ERROR_INCORRECT_STATE; + case SL_STATUS_NOT_SUPPORTED: + return CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE; + default: + return CHIP_ERROR(ChipError::Range::kPlatform, bleErr + CHIP_DEVICE_CONFIG_SILABS_BLE_ERROR_MIN); + } +} + +void BLEManagerImpl::DriveBLEState(void) +{ + + ChipLogProgress(DeviceLayer, "DriveBLEState starting"); + CHIP_ERROR err = CHIP_NO_ERROR; + + // Check if BLE stack is initialized + // VerifyOrExit(mFlags.Has(Flags::kEFRBLEStackInitialized), /* */); + + ChipLogProgress(DeviceLayer, "Start advertising if needed..."); + // Start advertising if needed... + if (mServiceMode == ConnectivityManager::kCHIPoBLEServiceMode_Enabled && mFlags.Has(Flags::kAdvertisingEnabled) && + NumConnections() < kMaxConnections) + { + + ChipLogProgress(DeviceLayer, "Start/re-start advertising if not already started, or if there is a pending change"); + // Start/re-start advertising if not already started, or if there is a pending change + // to the advertising configuration. + if (!mFlags.Has(Flags::kAdvertising) || mFlags.Has(Flags::kRestartAdvertising)) + { + err = StartAdvertising(); + SuccessOrExit(err); + } + } + + // Otherwise, stop advertising if it is enabled. + else if (mFlags.Has(Flags::kAdvertising)) + { + err = StopAdvertising(); + SuccessOrExit(err); + } + +exit: + ChipLogProgress(DeviceLayer, "DriveBLEState End"); + if (err != CHIP_NO_ERROR) + { + ChipLogError(DeviceLayer, "Disabling CHIPoBLE service due to error: %s", ErrorStr(err)); + mServiceMode = ConnectivityManager::kCHIPoBLEServiceMode_Disabled; + } +} + +CHIP_ERROR BLEManagerImpl::ConfigureAdvertisingData(void) +{ + + ChipBLEDeviceIdentificationInfo mDeviceIdInfo; + CHIP_ERROR err; + int32_t result; + uint8_t responseData[MAX_RESPONSE_DATA_LEN]; + uint8_t advData[MAX_ADV_DATA_LEN]; + uint32_t index = 0; + uint32_t mDeviceNameLength = 0; + uint8_t mDeviceIdInfoLength = 0; + err = ConfigurationMgr().GetBLEDeviceIdentificationInfo(mDeviceIdInfo); + + ChipLogProgress(DeviceLayer, "ConfigureAdvertisingData start"); + + VerifyOrExit((kMaxDeviceNameLength + 1) < UINT8_MAX, err = CHIP_ERROR_INVALID_ARGUMENT); + + memset(responseData, 0, MAX_RESPONSE_DATA_LEN); + memset(advData, 0, MAX_ADV_DATA_LEN); + + SuccessOrExit(err); + + if (!mFlags.Has(Flags::kDeviceNameSet)) + { + uint16_t discriminator; + SuccessOrExit(err = GetCommissionableDataProvider()->GetSetupDiscriminator(discriminator)); + + snprintf(mDeviceName, sizeof(mDeviceName), "%s%04u", CHIP_DEVICE_CONFIG_BLE_DEVICE_NAME_PREFIX, discriminator); + + mDeviceName[kMaxDeviceNameLength] = 0; + mDeviceNameLength = strlen(mDeviceName); + + VerifyOrExit(mDeviceNameLength < kMaxDeviceNameLength, err = CHIP_ERROR_INVALID_ARGUMENT); + } + + mDeviceNameLength = strlen(mDeviceName); // Device Name length + length field + VerifyOrExit(mDeviceNameLength < kMaxDeviceNameLength, err = CHIP_ERROR_INVALID_ARGUMENT); + + mDeviceIdInfoLength = sizeof(mDeviceIdInfo); // Servicedatalen + length+ UUID (Short) + static_assert(sizeof(mDeviceIdInfo) + CHIP_ADV_SHORT_UUID_LEN + 1 <= UINT8_MAX, "Our length won't fit in a uint8_t"); + static_assert(2 + CHIP_ADV_SHORT_UUID_LEN + sizeof(mDeviceIdInfo) + 1 <= MAX_ADV_DATA_LEN, "Our buffer is not big enough"); + + index = 0; + advData[index++] = 0x02; // length + advData[index++] = CHIP_ADV_DATA_TYPE_FLAGS; // AD type : flags + advData[index++] = CHIP_ADV_DATA_FLAGS; // AD value + advData[index++] = static_cast(mDeviceIdInfoLength + CHIP_ADV_SHORT_UUID_LEN + 1); // AD length + advData[index++] = CHIP_ADV_DATA_TYPE_SERVICE_DATA; // AD type : Service Data + advData[index++] = ShortUUID_CHIPoBLEService[0]; // AD value + advData[index++] = ShortUUID_CHIPoBLEService[1]; + + // TODO:: replace the hardcoded values by calling the GetBLEDeviceIdentificationInfo + advData[index++] = 0; // OpCode + advData[index++] = 0; // DeviceDiscriminatorAndAdvVersion [] + advData[index++] = 15; // DeviceDiscriminatorAndAdvVersion [] + advData[index++] = 241; // DeviceVendorId [] + advData[index++] = 255; // DeviceVendorId [] + advData[index++] = 5; // DeviceProductId[] + advData[index++] = 128; // DeviceProductId[] + advData[index++] = 0; // AdditionalDataFlag + + //! prepare advertise data //local/device name + advData[index++] = strlen(RSI_BLE_DEV_NAME) + 1; + advData[index++] = 9; + + memcpy(&advData[index], RSI_BLE_DEV_NAME, strlen(RSI_BLE_DEV_NAME)); // AD value + index += strlen(RSI_BLE_DEV_NAME); + +#if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING + ReturnErrorOnFailure(EncodeAdditionalDataTlv()); +#endif + + result = rsi_ble_set_advertise_data(advData, index); + if (result != SL_STATUS_OK) + { + err = MapBLEError(result); + ChipLogError(DeviceLayer, "rsi_ble_set_advertise_data() failed: %ld", result); + ExitNow(); + } + else + { + ChipLogError(DeviceLayer, "rsi_ble_set_advertise_data() success: %ld", result); + } + + err = MapBLEError(result); + + ChipLogProgress(DeviceLayer, "ConfigureAdvertisingData End"); +exit: + return CHIP_NO_ERROR; +} + +CHIP_ERROR BLEManagerImpl::StartAdvertising(void) +{ + CHIP_ERROR err; + int32_t status = 0; + + ChipLogProgress(DeviceLayer, "StartAdvertising start"); + + // If already advertising, stop it, before changing values + if (mFlags.Has(Flags::kAdvertising)) + { + // sl_bt_advertiser_stop(advertising_set_handle); + } + else + { + ChipLogDetail(DeviceLayer, "Start BLE advertissement"); + } + + // bd_addr unusedBdAddr; // We can ignore this field when setting random address. + + // (void) unusedBdAddr; + + err = ConfigureAdvertisingData(); + SuccessOrExit(err); + + mFlags.Clear(Flags::kRestartAdvertising); + + sl_wfx_mac_address_t macaddr; + wfx_get_wifi_mac_addr(SL_WFX_STA_INTERFACE, &macaddr); + + //! Set local name + status = rsi_ble_start_advertising(); + if (status == RSI_SUCCESS) + { + ChipLogProgress(DeviceLayer, "rsi_ble_start_advertising Success"); + + if (mFlags.Has(Flags::kFastAdvertisingEnabled)) + { + StartBleAdvTimeoutTimer(CHIP_DEVICE_CONFIG_BLE_ADVERTISING_INTERVAL_CHANGE_TIME); + } + mFlags.Set(Flags::kAdvertising); + } + else + { + ChipLogProgress(DeviceLayer, "rsi_ble_start_advertising Failed with status: %lx", status); + } + +exit: + ChipLogError(DeviceLayer, "StartAdvertising() End error: %s", ErrorStr(err)); + return CHIP_NO_ERROR; // err; +} + +// TODO:: Implementation need to be done. +CHIP_ERROR BLEManagerImpl::StopAdvertising(void) +{ + CHIP_ERROR err = CHIP_NO_ERROR; + // sl_status_t ret; + + if (mFlags.Has(Flags::kAdvertising)) + { + mFlags.Clear(Flags::kAdvertising).Clear(Flags::kRestartAdvertising); + mFlags.Set(Flags::kFastAdvertisingEnabled, true); + + // ret = sl_bt_advertiser_stop(advertising_set_handle); + // sl_bt_advertiser_delete_set(advertising_set_handle); + advertising_set_handle = 0xff; + // err = MapBLEError(ret); + // SuccessOrExit(err); + + CancelBleAdvTimeoutTimer(); + } + + // exit: + return err; +} + +void BLEManagerImpl::UpdateMtu(rsi_ble_event_mtu_t evt) +{ + CHIPoBLEConState * bleConnState = GetConnectionState(event_msg.connectionHandle); + if (bleConnState != NULL) + { + // bleConnState->MTU is a 10-bit field inside a uint16_t. We're + // assigning to it from a uint16_t, and compilers warn about + // possibly not fitting. There's no way to suppress that warning + // via explicit cast; we have to disable the warning around the + // assignment. + // + // TODO: https://github.com/project-chip/connectedhomeip/issues/2569 + // tracks making this safe with a check or explaining why no check + // is needed. + ChipLogProgress(DeviceLayer, "DriveBLEState UpdateMtu %d", evt.mtu_size); +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wconversion" + bleConnState->mtu = evt.mtu_size; +#pragma GCC diagnostic pop + ; + } +} + +void BLEManagerImpl::HandleBootEvent(void) +{ + mFlags.Set(Flags::kEFRBLEStackInitialized); + PlatformMgr().ScheduleWork(DriveBLEState, 0); +} + +void BLEManagerImpl::HandleConnectEvent(void) +{ + ChipLogProgress(DeviceLayer, "Connect Event for handle : %d", event_msg.connectionHandle); + AddConnection(event_msg.connectionHandle, event_msg.bondingHandle); + + PlatformMgr().ScheduleWork(DriveBLEState, 0); +} + +// TODO:: Implementation need to be done. +void BLEManagerImpl::HandleConnectionCloseEvent(uint16_t reason) +{ + uint8_t connHandle = 1; + + ChipLogProgress(DeviceLayer, "Disconnect Event for handle : %d", connHandle); + + if (RemoveConnection(connHandle)) + { + ChipDeviceEvent event; + event.Type = DeviceEventType::kCHIPoBLEConnectionError; + event.CHIPoBLEConnectionError.ConId = connHandle; + + // switch (reason) + // { + // + // case RSI_REMOTE_DEV_TERMINATE_CONN: + // case RSI_BT_CTRL_REMOTE_DEVICE_TERMINATED_CONNECTION_DUE_TO_LOW_RESOURCES: + // case RSI_BT_CTRL_REMOTE_POWERING_OFF: + // event.CHIPoBLEConnectionError.Reason = BLE_ERROR_REMOTE_DEVICE_DISCONNECTED; + // break; + // default: + // event.CHIPoBLEConnectionError.Reason = BLE_ERROR_CHIPOBLE_PROTOCOL_ABORT; + // } + + // ChipLogProgress(DeviceLayer, "BLE GATT connection closed (con %u, reason %u)", connHandle, conn_evt->reason); + + PlatformMgr().PostEventOrDie(&event); + + // Arrange to re-enable connectable advertising in case it was disabled due to the + // maximum connection limit being reached. + mFlags.Set(Flags::kRestartAdvertising); + mFlags.Set(Flags::kFastAdvertisingEnabled); + PlatformMgr().ScheduleWork(DriveBLEState, 0); + } +} + +void BLEManagerImpl::HandleWriteEvent(rsi_ble_event_write_t evt) +{ + // RSI_BLE_WRITE_REQUEST_EVENT + ChipLogProgress(DeviceLayer, "Char Write Req, packet type %d", evt.pkt_type); + uint8_t attribute = (uint8_t) event_msg.rsi_ble_measurement_hndl; + + WFX_RSI_LOG("attribute = %d,rsi_ble_measurement_hndl = %d", attribute, event_msg.rsi_ble_measurement_hndl); + + if (evt.handle[0] == (uint8_t) event_msg.rsi_ble_gatt_server_client_config_hndl) // TODO:: compare the handle exactly + { + WFX_RSI_LOG("Inside HandleTXCharCCCDWrite "); + HandleTXCharCCCDWrite(&evt); + } + else + { + HandleRXCharWrite(&evt); + } +} + +void BLEManagerImpl::HandleTXCharCCCDWrite(rsi_ble_event_write_t * evt) +{ + CHIP_ERROR err = CHIP_NO_ERROR; + ChipDeviceEvent event; + // whether the client is enabling or disabling indications. + { + event.Type = DeviceEventType::kCHIPoBLESubscribe; + event.CHIPoBLESubscribe.ConId = 1; + err = PlatformMgr().PostEvent(&event); + } +} + +void BLEManagerImpl::HandleRXCharWrite(rsi_ble_event_write_t * evt) +{ + uint8_t conId = 1; + CHIP_ERROR err = CHIP_NO_ERROR; + System::PacketBufferHandle buf; + uint16_t writeLen = evt->length; + uint8_t * data = (uint8_t *) evt->att_value; + + for (int i = 0; i < evt->length; i++) + { + ChipLogDetail(DeviceLayer, "HandleRXCharWrite value : %d", evt->att_value[i]); + } + + // Copy the data to a packet buffer. + buf = System::PacketBufferHandle::NewWithData(data, writeLen, 0, 0); + VerifyOrExit(!buf.IsNull(), err = CHIP_ERROR_NO_MEMORY); + + ChipLogDetail(DeviceLayer, "Write request/command received for CHIPoBLE RX characteristic ( len %d)", writeLen); + + // Post an event to the CHIP queue to deliver the data into the CHIP stack. + { + ChipDeviceEvent event; + event.Type = DeviceEventType::kCHIPoBLEWriteReceived; + event.CHIPoBLEWriteReceived.ConId = conId; + event.CHIPoBLEWriteReceived.Data = std::move(buf).UnsafeRelease(); + err = PlatformMgr().PostEvent(&event); + } + +exit: + if (err != CHIP_NO_ERROR) + { + ChipLogError(DeviceLayer, "HandleRXCharWrite() failed: %s", ErrorStr(err)); + } +} + +void BLEManagerImpl::HandleTxConfirmationEvent(BLE_CONNECTION_OBJECT conId) +{ + ChipDeviceEvent event; + // uint8_t timerHandle = sInstance.GetTimerHandle(conId, false); + // + // ChipLogProgress(DeviceLayer, "Tx Confirmation received"); + // + // // stop indication confirmation timer // TODO:: Need to find the proper repleacement + // if (timerHandle < kMaxConnections) + // { + // ChipLogProgress(DeviceLayer, " stop soft timer"); + // // sl_bt_system_set_lazy_soft_timer(0, 0, timerHandle, false); + // } + + event.Type = DeviceEventType::kCHIPoBLEIndicateConfirm; + event.CHIPoBLEIndicateConfirm.ConId = conId; + PlatformMgr().PostEventOrDie(&event); +} + +// TODO:: Need to Implement +void BLEManagerImpl::HandleSoftTimerEvent(void) +{ + + // BLE Manager starts soft timers with timer handles less than kMaxConnections + // If we receive a callback for unknown timer handle ignore this. + // if (evt->data.evt_system_soft_timer.handle < kMaxConnections) + // { + // ChipLogProgress(DeviceLayer, "BLEManagerImpl::HandleSoftTimerEvent CHIPOBLE_PROTOCOL_ABORT"); + // ChipDeviceEvent event; + // event.Type = DeviceEventType::kCHIPoBLEConnectionError; + // event.CHIPoBLEConnectionError.ConId = mIndConfId[evt->data.evt_system_soft_timer.handle]; + // sInstance.mIndConfId[evt->data.evt_system_soft_timer.handle] = kUnusedIndex; + // event.CHIPoBLEConnectionError.Reason = BLE_ERROR_CHIPOBLE_PROTOCOL_ABORT; + // PlatformMgr().PostEventOrDie(&event); + // } +} + +bool BLEManagerImpl::RemoveConnection(uint8_t connectionHandle) +{ + CHIPoBLEConState * bleConnState = GetConnectionState(connectionHandle, true); + bool status = false; + + if (bleConnState != NULL) + { + memset(bleConnState, 0, sizeof(CHIPoBLEConState)); + status = true; + } + + return status; +} + +void BLEManagerImpl::AddConnection(uint8_t connectionHandle, uint8_t bondingHandle) +{ + CHIPoBLEConState * bleConnState = GetConnectionState(connectionHandle, true); + + if (bleConnState != NULL) + { + memset(bleConnState, 0, sizeof(CHIPoBLEConState)); + bleConnState->allocated = 1; + bleConnState->connectionHandle = connectionHandle; + bleConnState->bondingHandle = bondingHandle; + } +} + +BLEManagerImpl::CHIPoBLEConState * BLEManagerImpl::GetConnectionState(uint8_t connectionHandle, bool allocate) +{ + uint8_t freeIndex = kMaxConnections; + + for (uint8_t i = 0; i < kMaxConnections; i++) + { + if (mBleConnections[i].allocated == 1) + { + if (mBleConnections[i].connectionHandle == connectionHandle) + { + return &mBleConnections[i]; + } + } + + else if (i < freeIndex) + { + freeIndex = i; + } + } + + if (allocate) + { + if (freeIndex < kMaxConnections) + { + return &mBleConnections[freeIndex]; + } + + ChipLogError(DeviceLayer, "Failed to allocate CHIPoBLEConState"); + } + + return NULL; +} + +#if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING +CHIP_ERROR BLEManagerImpl::EncodeAdditionalDataTlv() +{ + CHIP_ERROR err = CHIP_NO_ERROR; + BitFlags additionalDataFields; + AdditionalDataPayloadGeneratorParams additionalDataPayloadParams; + +#if CHIP_ENABLE_ROTATING_DEVICE_ID && defined(CHIP_DEVICE_CONFIG_ROTATING_DEVICE_ID_UNIQUE_ID) + uint8_t rotatingDeviceIdUniqueId[ConfigurationManager::kRotatingDeviceIDUniqueIDLength] = {}; + MutableByteSpan rotatingDeviceIdUniqueIdSpan(rotatingDeviceIdUniqueId); + + err = DeviceLayer::GetDeviceInstanceInfoProvider()->GetRotatingDeviceIdUniqueId(rotatingDeviceIdUniqueIdSpan); + SuccessOrExit(err); + err = ConfigurationMgr().GetLifetimeCounter(additionalDataPayloadParams.rotatingDeviceIdLifetimeCounter); + SuccessOrExit(err); + additionalDataPayloadParams.rotatingDeviceIdUniqueId = rotatingDeviceIdUniqueIdSpan; + additionalDataFields.Set(AdditionalDataFields::RotatingDeviceId); +#endif /* CHIP_ENABLE_ROTATING_DEVICE_ID && defined(CHIP_DEVICE_CONFIG_ROTATING_DEVICE_ID_UNIQUE_ID) */ + + err = AdditionalDataPayloadGenerator().generateAdditionalDataPayload(additionalDataPayloadParams, c3AdditionalDataBufferHandle, + additionalDataFields); + +exit: + if (err != CHIP_NO_ERROR) + { + ChipLogError(DeviceLayer, "Failed to generate TLV encoded Additional Data (%s)", __func__); + } + + return err; +} + +// TODO:: Need the +void BLEManagerImpl::HandleC3ReadRequest(void) +{ + // sl_bt_evt_gatt_server_user_read_request_t * readReq = + // (sl_bt_evt_gatt_server_user_read_request_t *) &(evt->data.evt_gatt_server_user_read_request); + // ChipLogDetail(DeviceLayer, "Read request received for CHIPoBLEChar_C3 - opcode:%d", readReq->att_opcode); + // sl_status_t ret = sl_bt_gatt_server_send_user_read_response(readReq->connection, readReq->characteristic, 0, + // sInstance.c3AdditionalDataBufferHandle->DataLength(), + // sInstance.c3AdditionalDataBufferHandle->Start(), nullptr); + + // if (ret != SL_STATUS_OK) + // { + // ChipLogDetail(DeviceLayer, "Failed to send read response, err:%ld", ret); + // } +} +#endif // CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING + +uint8_t BLEManagerImpl::GetTimerHandle(uint8_t connectionHandle, bool allocate) +{ + uint8_t freeIndex = kMaxConnections; + + for (uint8_t i = 0; i < kMaxConnections; i++) + { + if (mIndConfId[i] == connectionHandle) + { + return i; + } + else if (allocate) + { + if (i < freeIndex) + { + freeIndex = i; + } + } + } + + if (freeIndex < kMaxConnections) + { + mIndConfId[freeIndex] = connectionHandle; + } + else + { + ChipLogError(DeviceLayer, "Failed to Save Conn Handle for indication"); + } + + return freeIndex; +} + +void BLEManagerImpl::BleAdvTimeoutHandler(TimerHandle_t xTimer) +{ + if (BLEMgrImpl().mFlags.Has(Flags::kFastAdvertisingEnabled)) + { + ChipLogDetail(DeviceLayer, "bleAdv Timeout : Start slow advertissment"); + BLEMgr().SetAdvertisingMode(BLEAdvertisingMode::kSlowAdvertising); + } +} + +void BLEManagerImpl::CancelBleAdvTimeoutTimer(void) +{ + if (xTimerStop(sbleAdvTimeoutTimer, 0) == pdFAIL) + { + ChipLogError(DeviceLayer, "Failed to stop BledAdv timeout timer"); + } +} + +void BLEManagerImpl::StartBleAdvTimeoutTimer(uint32_t aTimeoutInMs) +{ + if (xTimerIsTimerActive(sbleAdvTimeoutTimer)) + { + CancelBleAdvTimeoutTimer(); + } + + // timer is not active, change its period to required value (== restart). + // FreeRTOS- Block for a maximum of 100 ticks if the change period command + // cannot immediately be sent to the timer command queue. + if (xTimerChangePeriod(sbleAdvTimeoutTimer, aTimeoutInMs / portTICK_PERIOD_MS, 100) != pdPASS) + { + ChipLogError(DeviceLayer, "Failed to start BledAdv timeout timer"); + } +} + +void BLEManagerImpl::DriveBLEState(intptr_t arg) +{ + sInstance.DriveBLEState(); +} + +} // namespace Internal +} // namespace DeviceLayer +} // namespace chip + +#endif // CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE diff --git a/src/platform/silabs/SiWx917/BUILD.gn b/src/platform/silabs/SiWx917/BUILD.gn new file mode 100644 index 00000000000000..4026e1cd40c8f4 --- /dev/null +++ b/src/platform/silabs/SiWx917/BUILD.gn @@ -0,0 +1,88 @@ +# Copyright (c) 2021 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/chip.gni") +import("//build_overrides/pigweed.gni") + +import("${chip_root}/src/platform/device.gni") + +import("${chip_root}/build/chip/buildconfig_header.gni") +import("${chip_root}/src/crypto/crypto.gni") + +silabs_platform_dir = "${chip_root}/src/platform/silabs" + +assert(chip_device_platform == "SiWx917") + +if (chip_enable_openthread) { + import("//build_overrides/openthread.gni") +} + +static_library("SiWx917") { + sources = [ + "${silabs_platform_dir}/BLEManagerImpl.h", + "${silabs_platform_dir}/BlePlatformConfig.h", + "${silabs_platform_dir}/CHIPDevicePlatformConfig.h", + "${silabs_platform_dir}/CHIPDevicePlatformEvent.h", + "${silabs_platform_dir}/CHIPMem-Platform.cpp", + "${silabs_platform_dir}/CHIPPlatformConfig.h", + "${silabs_platform_dir}/ConfigurationManagerImpl.h", + "${silabs_platform_dir}/ConnectivityManagerImpl.h", + "${silabs_platform_dir}/DiagnosticDataProviderImpl.cpp", + "${silabs_platform_dir}/DiagnosticDataProviderImpl.h", + "${silabs_platform_dir}/InetPlatformConfig.h", + "${silabs_platform_dir}/KeyValueStoreManagerImpl.h", + "${silabs_platform_dir}/Logging.cpp", + "${silabs_platform_dir}/PlatformManagerImpl.h", + "${silabs_platform_dir}/SilabsConfig.cpp", + "${silabs_platform_dir}/SilabsConfig.h", + "${silabs_platform_dir}/SystemPlatformConfig.h", + "../../FreeRTOS/SystemTimeSupport.cpp", + "../../SingletonConfigurationManager.cpp", + "BLEManagerImpl.cpp", + "ConfigurationManagerImpl.cpp", + "KeyValueStoreManagerImpl.cpp", + "PlatformManagerImpl.cpp", + "bluetooth/rsi_ble_config.h", + "bluetooth/wfx_sl_ble_init.c", + "bluetooth/wfx_sl_ble_init.h", + ] + + # TODO: OTA on CCP platform + if (chip_enable_ota_requestor) { + sources += [ + #"OTAImageProcessorImpl.cpp", + #"OTAImageProcessorImpl.h", + ] + } + + public_deps = [ "${chip_root}/src/platform:platform_base" ] + + # Add pigweed KVS + deps = [ + "$dir_pw_kvs:crc16", + "$dir_pw_log", + ] + public_deps += [ + "$dir_pw_checksum", + "$dir_pw_kvs", + ] + + if (chip_enable_wifi) { + sources += [ + "${silabs_platform_dir}/ConnectivityManagerImpl_WIFI.cpp", + "${silabs_platform_dir}/NetworkCommissioningWiFiDriver.cpp", + "${silabs_platform_dir}/NetworkCommissioningWiFiDriver.h", + ] + } +} diff --git a/src/platform/silabs/SiWx917/ConfigurationManagerImpl.cpp b/src/platform/silabs/SiWx917/ConfigurationManagerImpl.cpp new file mode 100644 index 00000000000000..618b5a6a7703a8 --- /dev/null +++ b/src/platform/silabs/SiWx917/ConfigurationManagerImpl.cpp @@ -0,0 +1,315 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2019 Nest Labs, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides the implementation of the Device Layer ConfigurationManager object + * for SiWx917 platforms using the Silicon Labs SDK. + */ +/* this file behaves like a config.h, comes first */ +#include + +#include + +#include +#include +#include + +#include "core_cm4.h" + +#if CHIP_DEVICE_CONFIG_ENABLE_WIFI_STATION +#include "wfx_host_events.h" +#endif + +namespace chip { +namespace DeviceLayer { + +using namespace ::chip::DeviceLayer::Internal; + +ConfigurationManagerImpl & ConfigurationManagerImpl::GetDefaultInstance() +{ + static ConfigurationManagerImpl sInstance; + return sInstance; +} + +CHIP_ERROR ConfigurationManagerImpl::Init() +{ + CHIP_ERROR err; + + // Initialize the generic implementation base class. + err = Internal::GenericConfigurationManagerImpl::Init(); + SuccessOrExit(err); + + // TODO: Initialize the global GroupKeyStore object here (#1626) + + IncreaseBootCount(); + // It is possible to configure the possible reset sources with RMU_ResetControl + // In this case, we keep Reset control at default setting + + err = CHIP_NO_ERROR; + +exit: + return err; +} + +bool ConfigurationManagerImpl::CanFactoryReset() +{ + // TODO: query the application to determine if factory reset is allowed. + return true; +} + +void ConfigurationManagerImpl::InitiateFactoryReset() +{ + PlatformMgr().ScheduleWork(DoFactoryReset); +} + +CHIP_ERROR ConfigurationManagerImpl::GetRebootCount(uint32_t & rebootCount) +{ + return SILABSConfig::ReadConfigValue(SILABSConfig::kConfigKey_BootCount, rebootCount); +} + +CHIP_ERROR ConfigurationManagerImpl::IncreaseBootCount(void) +{ + uint32_t bootCount = 0; + + if (SILABSConfig::ConfigValueExists(SILABSConfig::kConfigKey_BootCount)) + { + GetRebootCount(bootCount); + } + + return SILABSConfig::WriteConfigValue(SILABSConfig::kConfigKey_BootCount, bootCount + 1); +} + +CHIP_ERROR ConfigurationManagerImpl::GetBootReason(uint32_t & bootReason) +{ + // rebootCause is obtained at bootup. + BootReasonType matterBootCause; +#if defined(_SILICON_LABS_32B_SERIES_1) + if (rebootCause & RMU_RSTCAUSE_PORST || rebootCause & RMU_RSTCAUSE_EXTRST) // PowerOn or External pin reset + { + matterBootCause = BootReasonType::kPowerOnReboot; + } + else if (rebootCause & RMU_RSTCAUSE_AVDDBOD || rebootCause & RMU_RSTCAUSE_DVDDBOD || rebootCause & RMU_RSTCAUSE_DECBOD) + { + matterBootCause = BootReasonType::kBrownOutReset; + } + else if (rebootCause & RMU_RSTCAUSE_SYSREQRST) + { + matterBootCause = BootReasonType::kSoftwareReset; + } + else if (rebootCause & RMU_RSTCAUSE_WDOGRST) + { + matterBootCause = BootReasonType::kSoftwareWatchdogReset; + } + else + { + matterBootCause = BootReasonType::kUnspecified; + } + // Not tracked HARDWARE_WATCHDOG_RESET && SOFTWARE_UPDATE_COMPLETED +#elif defined(_SILICON_LABS_32B_SERIES_2) + if (rebootCause & EMU_RSTCAUSE_POR || rebootCause & EMU_RSTCAUSE_PIN) // PowerOn or External pin reset + { + matterBootCause = BootReasonType::kPowerOnReboot; + } + else if (rebootCause & EMU_RSTCAUSE_AVDDBOD || rebootCause & EMU_RSTCAUSE_DVDDBOD || rebootCause & EMU_RSTCAUSE_DECBOD || + rebootCause & EMU_RSTCAUSE_VREGIN || rebootCause & EMU_RSTCAUSE_IOVDD0BOD || rebootCause & EMU_RSTCAUSE_DVDDLEBOD) + { + matterBootCause = BootReasonType::kBrownOutReset; + } + else if (rebootCause & EMU_RSTCAUSE_SYSREQ) + { + matterBootCause = BootReasonType::kSoftwareReset; + } + else if (rebootCause & EMU_RSTCAUSE_WDOG0 || rebootCause & EMU_RSTCAUSE_WDOG1) + { + matterBootCause = BootReasonType::kSoftwareWatchdogReset; + } + else + { + matterBootCause = BootReasonType::kUnspecified; + } + // Not tracked HARDWARE_WATCHDOG_RESET && SOFTWARE_UPDATE_COMPLETED +#else + matterBootCause = BootReasonType::kUnspecified; +#endif + + bootReason = to_underlying(matterBootCause); + return CHIP_NO_ERROR; +} + +CHIP_ERROR ConfigurationManagerImpl::GetTotalOperationalHours(uint32_t & totalOperationalHours) +{ + if (!SILABSConfig::ConfigValueExists(SILABSConfig::kConfigKey_TotalOperationalHours)) + { + totalOperationalHours = 0; + return CHIP_NO_ERROR; + } + + return SILABSConfig::ReadConfigValue(SILABSConfig::kConfigKey_TotalOperationalHours, totalOperationalHours); +} + +CHIP_ERROR ConfigurationManagerImpl::StoreTotalOperationalHours(uint32_t totalOperationalHours) +{ + return SILABSConfig::WriteConfigValue(SILABSConfig::kConfigKey_TotalOperationalHours, totalOperationalHours); +} + +CHIP_ERROR ConfigurationManagerImpl::ReadPersistedStorageValue(::chip::Platform::PersistedStorage::Key persistedStorageKey, + uint32_t & value) +{ + // This method reads CHIP Persisted Counter type nvm3 objects. + // (where persistedStorageKey represents an index to the counter). + CHIP_ERROR err; + + err = SILABSConfig::ReadConfigValueCounter(persistedStorageKey, value); + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + err = CHIP_ERROR_PERSISTED_STORAGE_VALUE_NOT_FOUND; + } + SuccessOrExit(err); + +exit: + return err; +} + +CHIP_ERROR ConfigurationManagerImpl::WritePersistedStorageValue(::chip::Platform::PersistedStorage::Key persistedStorageKey, + uint32_t value) +{ + // This method reads CHIP Persisted Counter type nvm3 objects. + // (where persistedStorageKey represents an index to the counter). + CHIP_ERROR err; + + err = SILABSConfig::WriteConfigValueCounter(persistedStorageKey, value); + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + err = CHIP_ERROR_PERSISTED_STORAGE_VALUE_NOT_FOUND; + } + SuccessOrExit(err); + +exit: + return err; +} + +CHIP_ERROR ConfigurationManagerImpl::ReadConfigValue(Key key, bool & val) +{ + return SILABSConfig::ReadConfigValue(key, val); +} + +CHIP_ERROR ConfigurationManagerImpl::ReadConfigValue(Key key, uint32_t & val) +{ + return SILABSConfig::ReadConfigValue(key, val); +} + +CHIP_ERROR ConfigurationManagerImpl::ReadConfigValue(Key key, uint64_t & val) +{ + return SILABSConfig::ReadConfigValue(key, val); +} + +CHIP_ERROR ConfigurationManagerImpl::ReadConfigValueStr(Key key, char * buf, size_t bufSize, size_t & outLen) +{ + return SILABSConfig::ReadConfigValueStr(key, buf, bufSize, outLen); +} + +CHIP_ERROR ConfigurationManagerImpl::ReadConfigValueBin(Key key, uint8_t * buf, size_t bufSize, size_t & outLen) +{ + return SILABSConfig::ReadConfigValueBin(key, buf, bufSize, outLen); +} + +CHIP_ERROR ConfigurationManagerImpl::WriteConfigValue(Key key, bool val) +{ + return SILABSConfig::WriteConfigValue(key, val); +} + +CHIP_ERROR ConfigurationManagerImpl::WriteConfigValue(Key key, uint32_t val) +{ + return SILABSConfig::WriteConfigValue(key, val); +} + +CHIP_ERROR ConfigurationManagerImpl::WriteConfigValue(Key key, uint64_t val) +{ + return SILABSConfig::WriteConfigValue(key, val); +} + +CHIP_ERROR ConfigurationManagerImpl::WriteConfigValueStr(Key key, const char * str) +{ + return SILABSConfig::WriteConfigValueStr(key, str); +} + +CHIP_ERROR ConfigurationManagerImpl::WriteConfigValueStr(Key key, const char * str, size_t strLen) +{ + return SILABSConfig::WriteConfigValueStr(key, str, strLen); +} + +CHIP_ERROR ConfigurationManagerImpl::WriteConfigValueBin(Key key, const uint8_t * data, size_t dataLen) +{ + return SILABSConfig::WriteConfigValueBin(key, data, dataLen); +} + +void ConfigurationManagerImpl::RunConfigUnitTest(void) +{ + SILABSConfig::RunConfigUnitTest(); +} + +void ConfigurationManagerImpl::DoFactoryReset(intptr_t arg) +{ + CHIP_ERROR err; + + ChipLogProgress(DeviceLayer, "Performing factory reset"); + + err = SILABSConfig::FactoryResetConfig(); + if (err != CHIP_NO_ERROR) + { + ChipLogError(DeviceLayer, "FactoryResetConfig() failed: %s", chip::ErrorStr(err)); + } + +#if CHIP_DEVICE_CONFIG_ENABLE_THREAD + + ChipLogProgress(DeviceLayer, "Clearing Thread provision"); + ThreadStackMgr().ErasePersistentInfo(); + +#endif // CHIP_DEVICE_CONFIG_ENABLE_THREAD + + PersistedStorage::KeyValueStoreMgrImpl().ErasePartition(); + +#if CHIP_DEVICE_CONFIG_ENABLE_WIFI_STATION + ChipLogProgress(DeviceLayer, "Clearing WiFi provision"); + wfx_clear_wifi_provision(); +#endif // CHIP_DEVICE_CONFIG_ENABLE_WIFI_STATION + + // Restart the system. + ChipLogProgress(DeviceLayer, "System restarting"); + NVIC_SystemReset(); +} + +#ifdef SL_WIFI +CHIP_ERROR ConfigurationManagerImpl::GetPrimaryWiFiMACAddress(uint8_t * buf) +{ + sl_wfx_mac_address_t macaddr; + wfx_get_wifi_mac_addr(SL_WFX_STA_INTERFACE, &macaddr); + memcpy(buf, &macaddr.octet[0], sizeof(macaddr.octet)); + + return CHIP_NO_ERROR; +} +#endif + +ConfigurationManager & ConfigurationMgrImpl() +{ + return ConfigurationManagerImpl::GetDefaultInstance(); +} + +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/silabs/SiWx917/KeyValueStoreManagerImpl.cpp b/src/platform/silabs/SiWx917/KeyValueStoreManagerImpl.cpp new file mode 100644 index 00000000000000..c752c757eb9cdb --- /dev/null +++ b/src/platform/silabs/SiWx917/KeyValueStoreManagerImpl.cpp @@ -0,0 +1,213 @@ +/* + * + * Copyright (c) 2021-2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Platform-specific key value storage implementation for SILABS + */ + +#include +#include +#include +#include +#include +#include +#include + +using namespace ::chip; +using namespace ::chip::DeviceLayer::Internal; + +#define CONVERT_KEYMAP_INDEX_TO_NVM3KEY(index) (SILABSConfig::kConfigKey_KvsFirstKeySlot + index) +#define CONVERT_NVM3KEY_TO_KEYMAP_INDEX(nvm3Key) (nvm3Key - SILABSConfig::kConfigKey_KvsFirstKeySlot) + +namespace chip { +namespace DeviceLayer { +namespace PersistedStorage { + +KeyValueStoreManagerImpl KeyValueStoreManagerImpl::sInstance; +char mKvsStoredKeyString[KeyValueStoreManagerImpl::kMaxEntries][PersistentStorageDelegate::kKeyLengthMax + 1]; + +CHIP_ERROR KeyValueStoreManagerImpl::Init(void) +{ + CHIP_ERROR err; + err = SILABSConfig::Init(); + SuccessOrExit(err); + + memset(mKvsStoredKeyString, 0, sizeof(mKvsStoredKeyString)); + size_t outLen; + err = SILABSConfig::ReadConfigValueBin(SILABSConfig::kConfigKey_KvsStringKeyMap, + reinterpret_cast(mKvsStoredKeyString), sizeof(mKvsStoredKeyString), outLen); + + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) // Initial boot + { + err = CHIP_NO_ERROR; + } + +exit: + return err; +} + +bool KeyValueStoreManagerImpl::IsValidKvsNvm3Key(uint32_t nvm3Key) const +{ + return ((SILABSConfig::kConfigKey_KvsFirstKeySlot <= nvm3Key) && (nvm3Key <= SILABSConfig::kConfigKey_KvsLastKeySlot)); +} + +CHIP_ERROR KeyValueStoreManagerImpl::MapKvsKeyToNvm3(const char * key, uint32_t & nvm3Key, bool isSlotNeeded) const +{ + CHIP_ERROR err; + uint8_t firstEmptyKeySlot = kMaxEntries; + for (uint8_t keyIndex = 0; keyIndex < kMaxEntries; keyIndex++) + { + if (strcmp(key, mKvsStoredKeyString[keyIndex]) == 0) + { + nvm3Key = CONVERT_KEYMAP_INDEX_TO_NVM3KEY(keyIndex); + VerifyOrDie(IsValidKvsNvm3Key(nvm3Key) == true); + return CHIP_NO_ERROR; + } + + if (isSlotNeeded && (firstEmptyKeySlot == kMaxEntries) && (mKvsStoredKeyString[keyIndex][0] == 0)) + { + firstEmptyKeySlot = keyIndex; + } + } + + if (isSlotNeeded) + { + if (firstEmptyKeySlot != kMaxEntries) + { + nvm3Key = CONVERT_KEYMAP_INDEX_TO_NVM3KEY(firstEmptyKeySlot); + VerifyOrDie(IsValidKvsNvm3Key(nvm3Key) == true); + err = CHIP_NO_ERROR; + } + else + { + err = CHIP_ERROR_PERSISTED_STORAGE_FAILED; + } + } + else + { + err = CHIP_ERROR_PERSISTED_STORAGE_VALUE_NOT_FOUND; + } + return err; +} + +void KeyValueStoreManagerImpl::ForceKeyMapSave() +{ + OnScheduledKeyMapSave(nullptr, nullptr); +} + +void KeyValueStoreManagerImpl::OnScheduledKeyMapSave(System::Layer * systemLayer, void * appState) +{ + SILABSConfig::WriteConfigValueBin(SILABSConfig::kConfigKey_KvsStringKeyMap, + reinterpret_cast(mKvsStoredKeyString), sizeof(mKvsStoredKeyString)); +} + +void KeyValueStoreManagerImpl::ScheduleKeyMapSave(void) +{ + /* + During commissioning, the key map will be modified multiples times subsequently. + Commit the key map in nvm once it as stabilized. + */ + SystemLayer().StartTimer( + std::chrono::duration_cast(System::Clock::Seconds32(SILABS_KVS_SAVE_DELAY_SECONDS)), + KeyValueStoreManagerImpl::OnScheduledKeyMapSave, NULL); +} + +CHIP_ERROR KeyValueStoreManagerImpl::_Get(const char * key, void * value, size_t value_size, size_t * read_bytes_size, + size_t offset_bytes) const +{ + VerifyOrReturnError(key != nullptr, CHIP_ERROR_INVALID_ARGUMENT); + + uint32_t nvm3Key; + CHIP_ERROR err = MapKvsKeyToNvm3(key, nvm3Key); + VerifyOrReturnError(err == CHIP_NO_ERROR, err); + + size_t outLen; + err = SILABSConfig::ReadConfigValueBin(nvm3Key, reinterpret_cast(value), value_size, outLen, offset_bytes); + if (read_bytes_size) + { + *read_bytes_size = outLen; + } + + if (err == CHIP_DEVICE_ERROR_CONFIG_NOT_FOUND) + { + return CHIP_ERROR_PERSISTED_STORAGE_VALUE_NOT_FOUND; + } + + return err; +} + +CHIP_ERROR KeyValueStoreManagerImpl::_Put(const char * key, const void * value, size_t value_size) +{ + VerifyOrReturnError(key != nullptr, CHIP_ERROR_INVALID_ARGUMENT); + + uint32_t nvm3Key; + CHIP_ERROR err = MapKvsKeyToNvm3(key, nvm3Key, /* isSlotNeeded */ true); + VerifyOrReturnError(err == CHIP_NO_ERROR, err); + + err = SILABSConfig::WriteConfigValueBin(nvm3Key, reinterpret_cast(value), value_size); + if (err == CHIP_NO_ERROR) + { + uint32_t keyIndex = nvm3Key - SILABSConfig::kConfigKey_KvsFirstKeySlot; + Platform::CopyString(mKvsStoredKeyString[keyIndex], key); + ScheduleKeyMapSave(); + } + + return err; +} + +CHIP_ERROR KeyValueStoreManagerImpl::_Delete(const char * key) +{ + VerifyOrReturnError(key != nullptr, CHIP_ERROR_INVALID_ARGUMENT); + + uint32_t nvm3Key; + CHIP_ERROR err = MapKvsKeyToNvm3(key, nvm3Key); + VerifyOrReturnError(err == CHIP_NO_ERROR, err); + + err = SILABSConfig::ClearConfigValue(nvm3Key); + if (err == CHIP_NO_ERROR) + { + uint32_t keyIndex = CONVERT_NVM3KEY_TO_KEYMAP_INDEX(nvm3Key); + memset(mKvsStoredKeyString[keyIndex], 0, sizeof(mKvsStoredKeyString[keyIndex])); + ScheduleKeyMapSave(); + } + + return err; +} + +CHIP_ERROR KeyValueStoreManagerImpl::ErasePartition(void) +{ + // Iterate over all the Matter Kvs nvm3 records and delete each one... + CHIP_ERROR err = CHIP_NO_ERROR; + for (uint32_t nvm3Key = SILABSConfig::kMinConfigKey_MatterKvs; nvm3Key < SILABSConfig::kMaxConfigKey_MatterKvs; nvm3Key++) + { + err = SILABSConfig::ClearConfigValue(nvm3Key); + + if (err != CHIP_NO_ERROR) + { + break; + } + } + + memset(mKvsStoredKeyString, 0, sizeof(mKvsStoredKeyString)); + return err; +} + +} // namespace PersistedStorage +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/silabs/SiWx917/OTAImageProcessorImpl.cpp b/src/platform/silabs/SiWx917/OTAImageProcessorImpl.cpp new file mode 100644 index 00000000000000..f07fd947d03c17 --- /dev/null +++ b/src/platform/silabs/SiWx917/OTAImageProcessorImpl.cpp @@ -0,0 +1,335 @@ +/* + * + * Copyright (c) 2021 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 "OTAImageProcessorImpl.h" +#include +#include + +extern "C" { +#include "btl_interface.h" +#include "em_bus.h" // For CORE_CRITICAL_SECTION +} + +#include + +/// No error, operation OK +#define SL_BOOTLOADER_OK 0L + +namespace chip { + +// Define static memebers +uint8_t OTAImageProcessorImpl::mSlotId = 0; +uint32_t OTAImageProcessorImpl::mWriteOffset = 0; +uint16_t OTAImageProcessorImpl::writeBufOffset = 0; +uint8_t OTAImageProcessorImpl::writeBuffer[kAlignmentBytes] __attribute__((aligned(4))) = { 0 }; + +CHIP_ERROR OTAImageProcessorImpl::PrepareDownload() +{ + DeviceLayer::PlatformMgr().ScheduleWork(HandlePrepareDownload, reinterpret_cast(this)); + return CHIP_NO_ERROR; +} + +CHIP_ERROR OTAImageProcessorImpl::Finalize() +{ + DeviceLayer::PlatformMgr().ScheduleWork(HandleFinalize, reinterpret_cast(this)); + return CHIP_NO_ERROR; +} +CHIP_ERROR OTAImageProcessorImpl::Apply() +{ + DeviceLayer::PlatformMgr().ScheduleWork(HandleApply, reinterpret_cast(this)); + return CHIP_NO_ERROR; +} + +CHIP_ERROR OTAImageProcessorImpl::Abort() +{ + DeviceLayer::PlatformMgr().ScheduleWork(HandleAbort, reinterpret_cast(this)); + return CHIP_NO_ERROR; +} + +CHIP_ERROR OTAImageProcessorImpl::ProcessBlock(ByteSpan & block) +{ + if ((block.data() == nullptr) || block.empty()) + { + return CHIP_ERROR_INVALID_ARGUMENT; + } + + // Store block data for HandleProcessBlock to access + CHIP_ERROR err = SetBlock(block); + if (err != CHIP_NO_ERROR) + { + ChipLogError(SoftwareUpdate, "Cannot set block data: %" CHIP_ERROR_FORMAT, err.Format()); + } + + DeviceLayer::PlatformMgr().ScheduleWork(HandleProcessBlock, reinterpret_cast(this)); + return CHIP_NO_ERROR; +} + +bool OTAImageProcessorImpl::IsFirstImageRun() +{ + OTARequestorInterface * requestor = chip::GetRequestorInstance(); + if (requestor == nullptr) + { + return false; + } + + return requestor->GetCurrentUpdateState() == OTARequestorInterface::OTAUpdateStateEnum::kApplying; +} + +CHIP_ERROR OTAImageProcessorImpl::ConfirmCurrentImage() +{ + OTARequestorInterface * requestor = chip::GetRequestorInstance(); + if (requestor == nullptr) + { + return CHIP_ERROR_INTERNAL; + } + + uint32_t currentVersion; + uint32_t targetVersion = requestor->GetTargetVersion(); + ReturnErrorOnFailure(DeviceLayer::ConfigurationMgr().GetSoftwareVersion(currentVersion)); + if (currentVersion != targetVersion) + { + ChipLogError(SoftwareUpdate, "Current software version = %" PRIu32 ", expected software version = %" PRIu32, currentVersion, + targetVersion); + return CHIP_ERROR_INCORRECT_STATE; + } + + return CHIP_NO_ERROR; +} + +void OTAImageProcessorImpl::HandlePrepareDownload(intptr_t context) +{ + int32_t err = SL_BOOTLOADER_OK; + auto * imageProcessor = reinterpret_cast(context); + + if (imageProcessor == nullptr) + { + ChipLogError(SoftwareUpdate, "ImageProcessor context is null"); + return; + } + else if (imageProcessor->mDownloader == nullptr) + { + ChipLogError(SoftwareUpdate, "mDownloader is null"); + return; + } + + ChipLogProgress(SoftwareUpdate, "HandlePrepareDownload"); + + CORE_CRITICAL_SECTION(bootloader_init();) + mSlotId = 0; // Single slot until we support multiple images + writeBufOffset = 0; + mWriteOffset = 0; + imageProcessor->mParams.downloadedBytes = 0; + + imageProcessor->mHeaderParser.Init(); + + // Not calling bootloader_eraseStorageSlot(mSlotId) here because we erase during each write + + imageProcessor->mDownloader->OnPreparedForDownload(err == SL_BOOTLOADER_OK ? CHIP_NO_ERROR : CHIP_ERROR_INTERNAL); +} + +void OTAImageProcessorImpl::HandleFinalize(intptr_t context) +{ + uint32_t err = SL_BOOTLOADER_OK; + auto * imageProcessor = reinterpret_cast(context); + if (imageProcessor == nullptr) + { + return; + } + + // Pad the remainder of the write buffer with zeros and write it to bootloader storage + if (writeBufOffset != 0) + { + // Account for last bytes of the image not yet written to storage + imageProcessor->mParams.downloadedBytes += writeBufOffset; + + while (writeBufOffset != kAlignmentBytes) + { + writeBuffer[writeBufOffset] = 0; + writeBufOffset++; + } + + CORE_CRITICAL_SECTION(err = bootloader_eraseWriteStorage(mSlotId, mWriteOffset, writeBuffer, kAlignmentBytes);) + if (err) + { + ChipLogError(SoftwareUpdate, "ERROR: In HandleFinalize bootloader_eraseWriteStorage() error %ld", err); + imageProcessor->mDownloader->EndDownload(CHIP_ERROR_WRITE_FAILED); + return; + } + } + + imageProcessor->ReleaseBlock(); + + ChipLogProgress(SoftwareUpdate, "OTA image downloaded successfully"); +} + +void OTAImageProcessorImpl::HandleApply(intptr_t context) +{ + uint32_t err = SL_BOOTLOADER_OK; + + ChipLogProgress(SoftwareUpdate, "OTAImageProcessorImpl::HandleApply()"); + + // Force KVS to store pending keys such as data from StoreCurrentUpdateInfo() + chip::DeviceLayer::PersistedStorage::KeyValueStoreMgrImpl().ForceKeyMapSave(); + + CORE_CRITICAL_SECTION(err = bootloader_verifyImage(mSlotId, NULL);) + if (err != SL_BOOTLOADER_OK) + { + ChipLogError(SoftwareUpdate, "ERROR: bootloader_verifyImage() error %ld", err); + + return; + } + + CORE_CRITICAL_SECTION(err = bootloader_setImageToBootload(mSlotId);) + if (err != SL_BOOTLOADER_OK) + { + ChipLogError(SoftwareUpdate, "ERROR: bootloader_setImageToBootload() error %ld", err); + + return; + } + + // This reboots the device + CORE_CRITICAL_SECTION(bootloader_rebootAndInstall();) +} + +void OTAImageProcessorImpl::HandleAbort(intptr_t context) +{ + auto * imageProcessor = reinterpret_cast(context); + if (imageProcessor == nullptr) + { + return; + } + + // Not clearing the image storage area as it is done during each write + imageProcessor->ReleaseBlock(); +} + +void OTAImageProcessorImpl::HandleProcessBlock(intptr_t context) +{ + uint32_t err = SL_BOOTLOADER_OK; + auto * imageProcessor = reinterpret_cast(context); + if (imageProcessor == nullptr) + { + ChipLogError(SoftwareUpdate, "ImageProcessor context is null"); + return; + } + else if (imageProcessor->mDownloader == nullptr) + { + ChipLogError(SoftwareUpdate, "mDownloader is null"); + return; + } + + ByteSpan block = imageProcessor->mBlock; + CHIP_ERROR chip_error = imageProcessor->ProcessHeader(block); + + if (chip_error != CHIP_NO_ERROR) + { + ChipLogError(SoftwareUpdate, "Matter image header parser error %s", chip::ErrorStr(chip_error)); + imageProcessor->mDownloader->EndDownload(CHIP_ERROR_INVALID_FILE_IDENTIFIER); + return; + } + + // Copy data into the word-aligned writeBuffer, once it fills write its contents to the bootloader storage + // Final data block is handled in HandleFinalize(). + uint32_t blockReadOffset = 0; + while (blockReadOffset < block.size()) + { + writeBuffer[writeBufOffset] = *((block.data()) + blockReadOffset); + writeBufOffset++; + blockReadOffset++; + if (writeBufOffset == kAlignmentBytes) + { + writeBufOffset = 0; + + CORE_CRITICAL_SECTION(err = bootloader_eraseWriteStorage(mSlotId, mWriteOffset, writeBuffer, kAlignmentBytes);) + if (err) + { + ChipLogError(SoftwareUpdate, "ERROR: In HandleProcessBlock bootloader_eraseWriteStorage() error %ld", err); + imageProcessor->mDownloader->EndDownload(CHIP_ERROR_WRITE_FAILED); + return; + } + mWriteOffset += kAlignmentBytes; + imageProcessor->mParams.downloadedBytes += kAlignmentBytes; + } + } + + imageProcessor->mDownloader->FetchNextData(); +} + +CHIP_ERROR OTAImageProcessorImpl::ProcessHeader(ByteSpan & block) +{ + if (mHeaderParser.IsInitialized()) + { + OTAImageHeader header; + CHIP_ERROR error = mHeaderParser.AccumulateAndDecode(block, header); + + // Needs more data to decode the header + ReturnErrorCodeIf(error == CHIP_ERROR_BUFFER_TOO_SMALL, CHIP_NO_ERROR); + ReturnErrorOnFailure(error); + + // SL TODO -- store version somewhere + ChipLogProgress(SoftwareUpdate, "Image Header software version: %ld payload size: %lu", header.mSoftwareVersion, + (long unsigned int) header.mPayloadSize); + mParams.totalFileBytes = header.mPayloadSize; + mHeaderParser.Clear(); + } + return CHIP_NO_ERROR; +} + +// Store block data for HandleProcessBlock to access +CHIP_ERROR OTAImageProcessorImpl::SetBlock(ByteSpan & block) +{ + if ((block.data() == nullptr) || block.empty()) + { + return CHIP_NO_ERROR; + } + + // Allocate memory for block data if we don't have enough already + if (mBlock.size() < block.size()) + { + ReleaseBlock(); + + mBlock = MutableByteSpan(static_cast(chip::Platform::MemoryAlloc(block.size())), block.size()); + if (mBlock.data() == nullptr) + { + return CHIP_ERROR_NO_MEMORY; + } + } + + // Store the actual block data + CHIP_ERROR err = CopySpanToMutableSpan(block, mBlock); + if (err != CHIP_NO_ERROR) + { + ChipLogError(SoftwareUpdate, "Cannot copy block data: %" CHIP_ERROR_FORMAT, err.Format()); + return err; + } + + return CHIP_NO_ERROR; +} + +CHIP_ERROR OTAImageProcessorImpl::ReleaseBlock() +{ + if (mBlock.data() != nullptr) + { + chip::Platform::MemoryFree(mBlock.data()); + } + + mBlock = MutableByteSpan(); + return CHIP_NO_ERROR; +} + +} // namespace chip diff --git a/src/platform/silabs/SiWx917/OTAImageProcessorImpl.h b/src/platform/silabs/SiWx917/OTAImageProcessorImpl.h new file mode 100644 index 00000000000000..30709bd7f32f3a --- /dev/null +++ b/src/platform/silabs/SiWx917/OTAImageProcessorImpl.h @@ -0,0 +1,80 @@ +/* + * + * Copyright (c) 2021 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 +#include +#include +#include + +#include + +namespace chip { + +class OTAImageProcessorImpl : public OTAImageProcessorInterface +{ +public: + //////////// OTAImageProcessorInterface Implementation /////////////// + CHIP_ERROR PrepareDownload() override; + CHIP_ERROR Finalize() override; + CHIP_ERROR Apply() override; + CHIP_ERROR Abort() override; + CHIP_ERROR ProcessBlock(ByteSpan & block) override; + bool IsFirstImageRun() override; + CHIP_ERROR ConfirmCurrentImage() override; + + void SetOTADownloader(OTADownloader * downloader) { mDownloader = downloader; } + void SetOTAImageFile(const char * imageFile) { mImageFile = imageFile; } + +private: + //////////// Actual handlers for the OTAImageProcessorInterface /////////////// + static void HandlePrepareDownload(intptr_t context); + static void HandleFinalize(intptr_t context); + static void HandleApply(intptr_t context); + static void HandleAbort(intptr_t context); + static void HandleProcessBlock(intptr_t context); + CHIP_ERROR ProcessHeader(ByteSpan & block); + + /** + * Called to allocate memory for mBlock if necessary and set it to block + */ + CHIP_ERROR SetBlock(ByteSpan & block); + + /** + * Called to release allocated memory for mBlock + */ + CHIP_ERROR ReleaseBlock(); + + // EFR32 platform creates a single instance of OTAImageProcessorImpl class. + // If that changes then the use of static members and functions must be revisited + static uint32_t mWriteOffset; // End of last written block + static uint8_t mSlotId; // Bootloader storage slot + MutableByteSpan mBlock; + OTADownloader * mDownloader; + OTAImageHeaderParser mHeaderParser; + const char * mImageFile = nullptr; + static constexpr size_t kAlignmentBytes = 64; + // Intermediate, word-aligned buffer for writing to the bootloader storage. + // Bootloader storage API requires the buffer size to be a multiple of 4. + static uint8_t writeBuffer[kAlignmentBytes] __attribute__((aligned(4))); + // Offset indicates how far the write buffer has been filled + static uint16_t writeBufOffset; +}; + +} // namespace chip diff --git a/src/platform/silabs/SiWx917/PlatformManagerImpl.cpp b/src/platform/silabs/SiWx917/PlatformManagerImpl.cpp new file mode 100644 index 00000000000000..8032c840210804 --- /dev/null +++ b/src/platform/silabs/SiWx917/PlatformManagerImpl.cpp @@ -0,0 +1,185 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * Copyright (c) 2019 Nest Labs, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Provides an implementation of the PlatformManager object + * for Silabs platforms using the Silicon Labs SDK. + */ +/* this file behaves like a config.h, comes first */ +#include + +#include +#include +#include +#include +#include +#include + +#if CHIP_SYSTEM_CONFIG_USE_LWIP +#include +#endif // CHIP_SYSTEM_CONFIG_USE_LWIP + +#include "AppConfig.h" +#include "FreeRTOS.h" + +namespace chip { +namespace DeviceLayer { + +PlatformManagerImpl PlatformManagerImpl::sInstance; + +static void app_get_random(uint8_t * aOutput, size_t aLen) +{ + size_t i; + + for (i = 0; i < aLen; i++) + { + aOutput[i] = rand(); + } +} + +static int app_entropy_source(void * data, unsigned char * output, size_t len, size_t * olen) +{ + app_get_random(reinterpret_cast(output), static_cast(len)); + *olen = len; + + return 0; +} + +CHIP_ERROR PlatformManagerImpl::_InitChipStack(void) +{ + CHIP_ERROR err; + + // Initialize the configuration system. + err = chip::DeviceLayer::PersistedStorage::KeyValueStoreMgrImpl().Init(); + SuccessOrExit(err); + +#if CHIP_SYSTEM_CONFIG_USE_LWIP + // Initialize LwIP. + tcpip_init(NULL, NULL); +#endif // CHIP_SYSTEM_CONFIG_USE_LWIP + + ReturnErrorOnFailure(System::Clock::InitClock_RealTime()); + + // 16 : Threshold value + ReturnErrorOnFailure(chip::Crypto::add_entropy_source(app_entropy_source, NULL, 16)); + + // Call _InitChipStack() on the generic implementation base class + // to finish the initialization process. + err = Internal::GenericPlatformManagerImpl_FreeRTOS::_InitChipStack(); + SuccessOrExit(err); + +exit: + return err; +} + +void PlatformManagerImpl::_Shutdown() +{ + uint64_t upTime = 0; + + if (GetDiagnosticDataProvider().GetUpTime(upTime) == CHIP_NO_ERROR) + { + uint32_t totalOperationalHours = 0; + + if (ConfigurationMgr().GetTotalOperationalHours(totalOperationalHours) == CHIP_NO_ERROR) + { + ConfigurationMgr().StoreTotalOperationalHours(totalOperationalHours + static_cast(upTime / 3600)); + } + else + { + ChipLogError(DeviceLayer, "Failed to get total operational hours of the Node"); + } + } + else + { + ChipLogError(DeviceLayer, "Failed to get current uptime since the Node’s last reboot"); + } + + Internal::GenericPlatformManagerImpl_FreeRTOS::_Shutdown(); +} +#if CHIP_DEVICE_CONFIG_ENABLE_WIFI_STATION +void PlatformManagerImpl::HandleWFXSystemEvent(wfx_event_base_t eventBase, sl_wfx_generic_message_t * eventData) +{ + ChipDeviceEvent event; + memset(&event, 0, sizeof(event)); + event.Type = DeviceEventType::kWFXSystemEvent; + event.Platform.WFXSystemEvent.eventBase = eventBase; + + if (eventBase == WIFI_EVENT) + { + switch (eventData->header.id) + { + case SL_WFX_STARTUP_IND_ID: + memcpy(&event.Platform.WFXSystemEvent.data.startupEvent, eventData, + sizeof(event.Platform.WFXSystemEvent.data.startupEvent)); + break; + case SL_WFX_CONNECT_IND_ID: + memcpy(&event.Platform.WFXSystemEvent.data.connectEvent, eventData, + sizeof(event.Platform.WFXSystemEvent.data.connectEvent)); + break; + case SL_WFX_DISCONNECT_IND_ID: + memcpy(&event.Platform.WFXSystemEvent.data.disconnectEvent, eventData, + sizeof(event.Platform.WFXSystemEvent.data.disconnectEvent)); + break; + // case SL_WFX_RECEIVED_IND_ID: + // memcpy(&event.Platform.WFXSystemEvent.data.receivedEvent, eventData, + // sizeof(event.Platform.WFXSystemEvent.data.receivedEvent)); + // break; + // case SL_WFX_GENERIC_IND_ID: + // memcpy(&event.Platform.WFXSystemEvent.data.genericEvent, eventData, + // sizeof(event.Platform.WFXSystemEvent.data.genericEvent)); + // break; + // case SL_WFX_EXCEPTION_IND_ID: + // memcpy(&event.Platform.WFXSystemEvent.data.exceptionEvent, eventData, + // sizeof(event.Platform.WFXSystemEvent.data.exceptionEvent)); + // break; + // case SL_WFX_ERROR_IND_ID: + // memcpy(&event.Platform.WFXSystemEvent.data.errorEvent, eventData, + // sizeof(event.Platform.WFXSystemEvent.data.errorEvent)); + // break; + default: + break; + } + } + else if (eventBase == IP_EVENT) + { + switch (eventData->header.id) + { + case IP_EVENT_STA_GOT_IP: + memcpy(&event.Platform.WFXSystemEvent.data.genericMsgEvent, eventData, + sizeof(event.Platform.WFXSystemEvent.data.genericMsgEvent)); + break; + case IP_EVENT_GOT_IP6: + memcpy(&event.Platform.WFXSystemEvent.data.genericMsgEvent, eventData, + sizeof(event.Platform.WFXSystemEvent.data.genericMsgEvent)); + break; + case IP_EVENT_STA_LOST_IP: + memcpy(&event.Platform.WFXSystemEvent.data.genericMsgEvent, eventData, + sizeof(event.Platform.WFXSystemEvent.data.genericMsgEvent)); + break; + default: + break; + } + } + + (void) sInstance.PostEvent(&event); +} +#endif + +} // namespace DeviceLayer +} // namespace chip diff --git a/src/platform/silabs/SiWx917/args.gni b/src/platform/silabs/SiWx917/args.gni new file mode 100644 index 00000000000000..4fa9a22d40ac18 --- /dev/null +++ b/src/platform/silabs/SiWx917/args.gni @@ -0,0 +1,56 @@ +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/chip.gni") +import("//build_overrides/efr32_sdk.gni") +import("//build_overrides/pigweed.gni") + +import("${chip_root}/examples/platform/silabs/SiWx917/args.gni") +import("${chip_root}/src/crypto/crypto.gni") + +# ARM architecture flags will be set based on silabs_family. +arm_platform_config = "${efr32_sdk_build_root}/efr32_arm.gni" + +mbedtls_target = "${efr32_sdk_build_root}:efr32_sdk" + +openthread_external_mbedtls = mbedtls_target + +chip_device_platform = "SiWx917" + +#Net work configuration OpenThread +lwip_platform = "efr32" +chip_mdns = "platform" +chip_inet_config_enable_ipv4 = false +chip_inet_config_enable_tcp_endpoint = false +chip_system_config_use_open_thread_inet_endpoints = true +chip_with_lwip = false + +chip_build_tests = false + +# Transitional CommissionableDataProvider not used anymore +# examples/platform/silabs/SiWx917/SiWx917DeviceDataProvider is now used. +chip_use_transitional_commissionable_data_provider = false + +openthread_root = "${chip_root}/third_party/openthread/ot-efr32/openthread" +openthread_core_config_platform_check_file = + "openthread-core-efr32-config-check.h" +openthread_project_core_config_file = "OpenThreadConfig.h" +openthread_core_config_deps = [ "${chip_root}/examples/platform/silabs/efr32:openthread_core_config_efr32_chip_examples" ] + +chip_config_memory_management = "platform" + +pw_build_LINK_DEPS = [ + "$dir_pw_assert:impl", + "$dir_pw_log:impl", +] diff --git a/src/platform/silabs/SiWx917/bluetooth/rsi_ble_config.h b/src/platform/silabs/SiWx917/bluetooth/rsi_ble_config.h new file mode 100644 index 00000000000000..7849747dd28152 --- /dev/null +++ b/src/platform/silabs/SiWx917/bluetooth/rsi_ble_config.h @@ -0,0 +1,269 @@ +/******************************************************************************* + * @file rsi_ble_config.h + * @brief + ******************************************************************************* + * # License + * Copyright 2020 Silicon Laboratories Inc. www.silabs.com + ******************************************************************************* + * + * The licensor of this software is Silicon Laboratories Inc. Your use of this + * software is governed by the terms of Silicon Labs Master Software License + * Agreement (MSLA) available at + * www.silabs.com/about-us/legal/master-software-license-agreement. This + * software is distributed to you in Source Code format and is governed by the + * sections of the MSLA applicable to Source Code. + * + ******************************************************************************/ + +#ifndef RSI_BLE_CONFIG_H +#define RSI_BLE_CONFIG_H + +#include "rsi_ble_apis.h" +#include +/****************************************************** + * * Macros + * ******************************************************/ +//! application event list +#define RSI_BLE_CONN_EVENT 0x01 +#define RSI_BLE_DISCONN_EVENT 0x02 +#define RSI_BLE_GATT_WRITE_EVENT 0x03 +#define RSI_BLE_MTU_EVENT 0x04 +#define RSI_BLE_GATT_INDICATION_CONFIRMATION 0x05 +#define RSI_BLE_RESP_ATT_VALUE 0x06 +#define RSI_SSID 0x0D +#define RSI_SECTYPE 0x0E +#define RSI_BLE_WLAN_DISCONN_NOTIFY 0x0F +#define RSI_WLAN_ALREADY 0x10 +#define RSI_WLAN_NOT_ALREADY 0x11 +#define RSI_BLE_WLAN_TIMEOUT_NOTIFY 0x12 +#define RSI_BLE_WLAN_JOIN_STATUS 0x15 +#define RSI_APP_FW_VERSION 0x13 +#define RSI_BLE_WLAN_DISCONNECT_STATUS 0x14 + +#define RSI_REM_DEV_ADDR_LEN 18 +#define RSI_REM_DEV_NAME_LEN 31 + +#define RSI_BLE_DEV_NAME "CCP_DEVICE" +#define RSI_BLE_SET_RAND_ADDR "00:23:A7:12:34:56" + +#define CLEAR_WHITELIST 0x00 +#define ADD_DEVICE_TO_WHITELIST 0x01 +#define DELETE_DEVICE_FROM_WHITELIST 0x02 + +#define ALL_PHYS 0x00 + +#define RSI_BLE_DEV_ADDR_RESOLUTION_ENABLE 0 + +#define RSI_OPERMODE_WLAN_BLE 13 + +/***********************************************************************************************************************************************/ +//! Characteristic Presenatation Format Fields +/***********************************************************************************************************************************************/ +#define RSI_BLE_UINT8_FORMAT 0x04 +#define RSI_BLE_EXPONENT 0x00 +#define RSI_BLE_PERCENTAGE_UNITS_UUID 0x27AD +#define RSI_BLE_NAME_SPACE 0x01 +#define RSI_BLE_DESCRIPTION 0x010B + +//! BLE characteristic custom service uuid +#define RSI_BLE_CUSTOM_SERVICE_UUID 0xFFF6 +#define RSI_BLE_CUSTOM_LEVEL_UUID 0x1FF1 + +#ifdef RSI_M4_INTERFACE +#define RSI_BLE_MAX_NBR_ATT_REC 20 +#define RSI_BLE_MAX_NBR_SLAVES 1 +#define RSI_BLE_NUM_CONN_EVENTS 2 +#else +#define RSI_BLE_MAX_NBR_ATT_REC 80 +#define RSI_BLE_MAX_NBR_SLAVES 3 +#define RSI_BLE_NUM_CONN_EVENTS 20 +#endif + +#define RSI_BLE_MAX_NBR_ATT_SERV 10 + +#define RSI_BLE_MAX_NBR_MASTERS 1 +#define RSI_BLE_GATT_ASYNC_ENABLE 1 +#define RSI_BLE_GATT_INIT 0 + +#define RSI_BLE_START_SCAN 0x01 +#define RSI_BLE_STOP_SCAN 0x00 + +#define RSI_BLE_SCAN_TYPE SCAN_TYPE_ACTIVE +#define RSI_BLE_SCAN_FILTER_TYPE SCAN_FILTER_TYPE_ALL +/* Number of BLE GATT RECORD SIZE IN (n*16 BYTES), eg:(0x40*16)=1024 bytes */ +#define RSI_BLE_NUM_REC_BYTES 0x40 + +#define RSI_BLE_INDICATE_CONFIRMATION_FROM_HOST 0 + +/*=======================================================================*/ +//! Advertising command parameters +/*=======================================================================*/ + +#define RSI_BLE_ADV_TYPE UNDIR_CONN +#define RSI_BLE_ADV_FILTER_TYPE ALLOW_SCAN_REQ_ANY_CONN_REQ_ANY +#define RSI_BLE_ADV_DIR_ADDR_TYPE LE_PUBLIC_ADDRESS +#define RSI_BLE_ADV_DIR_ADDR "00:15:83:6A:64:17" + +#define RSI_BLE_ADV_INT_MIN 0x100 +#define RSI_BLE_ADV_INT_MAX 0x200 +#define RSI_BLE_ADV_CHANNEL_MAP 0x07 + +//! Advertise status +//! Start the advertising process +#define RSI_BLE_START_ADV 0x01 +//! Stop the advertising process +#define RSI_BLE_STOP_ADV 0x00 + +//! BLE Tx Power Index On Air +#define RSI_BLE_PWR_INX 30 + +//! BLE Active H/w Pwr Features +#define BLE_DISABLE_DUTY_CYCLING 0 +#define BLE_DUTY_CYCLING 1 +#define BLR_DUTY_CYCLING 2 +#define BLE_4X_PWR_SAVE_MODE 4 +#define RSI_BLE_PWR_SAVE_OPTIONS BLE_DISABLE_DUTY_CYCLING + +//! Advertise types + +/* Advertising will be visible(discoverable) to all the devices. + * Scanning/Connection is also accepted from all devices + * */ +#define UNDIR_CONN 0x80 + +/* Advertising will be visible(discoverable) to the particular device + * mentioned in RSI_BLE_ADV_DIR_ADDR only. + * Scanning and Connection will be accepted from that device only. + * */ +#define DIR_CONN 0x81 + +/* Advertising will be visible(discoverable) to all the devices. + * Scanning will be accepted from all the devices. + * Connection will be not be accepted from any device. + * */ +#define UNDIR_SCAN 0x82 + +/* Advertising will be visible(discoverable) to all the devices. + * Scanning and Connection will not be accepted from any device + * */ +#define UNDIR_NON_CONN 0x83 + +/* Advertising will be visible(discoverable) to the particular device + * mentioned in RSI_BLE_ADV_DIR_ADDR only. + * Scanning and Connection will be accepted from that device only. + * */ +#define DIR_CONN_LOW_DUTY_CYCLE 0x84 + +//! Advertising flags +#define LE_LIMITED_DISCOVERABLE 0x01 +#define LE_GENERAL_DISCOVERABLE 0x02 +#define LE_BR_EDR_NOT_SUPPORTED 0x04 + +//! Advertise filters +#define ALLOW_SCAN_REQ_ANY_CONN_REQ_ANY 0x00 +#define ALLOW_SCAN_REQ_WHITE_LIST_CONN_REQ_ANY 0x01 +#define ALLOW_SCAN_REQ_ANY_CONN_REQ_WHITE_LIST 0x02 +#define ALLOW_SCAN_REQ_WHITE_LIST_CONN_REQ_WHITE_LIST 0x03 + +//! Address types +#define LE_PUBLIC_ADDRESS 0x00 +#define LE_RANDOM_ADDRESS 0x01 +#define LE_RESOLVABLE_PUBLIC_ADDRESS 0x02 +#define LE_RESOLVABLE_RANDOM_ADDRESS 0x03 + +/*=======================================================================*/ + +/*=======================================================================*/ +//! Connection parameters +/*=======================================================================*/ +#define LE_SCAN_INTERVAL 0x0100 +#define LE_SCAN_WINDOW 0x0050 + +#define CONNECTION_INTERVAL_MIN 0x00A0 +#define CONNECTION_INTERVAL_MAX 0x00A0 + +#define CONNECTION_LATENCY 0x0000 +#define SUPERVISION_TIMEOUT 0x07D0 // 2000 + +/*=======================================================================*/ + +/*=======================================================================*/ +//! Scan command parameters +/*=======================================================================*/ + +#define SL_WFX_BLE_SCAN_TYPE SCAN_TYPE_ACTIVE +#define SL_WFX_BLE_SCAN_FILTER_TYPE SCAN_FILTER_TYPE_ALL + +//! Scan status +#define SL_WFX_BLE_START_SCAN 0x01 +#define SL_WFX_BLE_STOP_SCAN 0x00 + +//! Scan types +#define SCAN_TYPE_ACTIVE 0x01 +#define SCAN_TYPE_PASSIVE 0x00 + +//! Scan filters +#define SCAN_FILTER_TYPE_ALL 0x00 +#define SCAN_FILTER_TYPE_ONLY_WHITE_LIST 0x01 + +#define SL_WFX_SEL_INTERNAL_ANTENNA 0x00 +#define SL_WFX_SEL_EXTERNAL_ANTENNA 0x01 + +#define SL_WFX_BT_CTRL_REMOTE_USER_TERMINATED 0x4E13 +#define SL_WFX_BT_CTRL_REMOTE_DEVICE_TERMINATED_CONNECTION_DUE_TO_LOW_RESOURCES 0x4E14 +#define SL_WFX_BT_CTRL_REMOTE_POWERING_OFF 0x4E15 +#define SL_WFX_BT_CTRL_TERMINATED_MIC_FAILURE 0x4E3D +#define SL_WFX_BT_FAILED_TO_ESTABLISH_CONN 0x4E3E +#define SL_WFX_BT_INVALID_RANGE 0x4E60 + +/***********************************************************************************************************************************************/ +//! RS9116 Firmware Configurations +/***********************************************************************************************************************************************/ + +/*=======================================================================*/ +//! Opermode command parameters +/*=======================================================================*/ +/* +#define RSI_FEATURE_BIT_MAP \ + (FEAT_ULP_GPIO_BASED_HANDSHAKE | FEAT_DEV_TO_HOST_ULP_GPIO_1) //! To set wlan feature select bit map +#define RSI_TCP_IP_BYPASS RSI_DISABLE //! TCP IP BYPASS feature check +#define RSI_TCP_IP_FEATURE_BIT_MAP \ + (TCP_IP_FEAT_DHCPV4_CLIENT) //! TCP/IP feature select bitmap for selecting TCP/IP features +#define RSI_EXT_TCPIP_FEATURE_BITMAP 0 + +#define RSI_CUSTOM_FEATURE_BIT_MAP FEAT_CUSTOM_FEAT_EXTENTION_VALID //! To set custom feature select bit map + +#define RSI_EXT_CUSTOM_FEATURE_BIT_MAP (EXT_FEAT_LOW_POWER_MODE | EXT_FEAT_XTAL_CLK_ENABLE | EXT_FEAT_384K_MODE) + +#define RSI_BT_FEATURE_BITMAP (BT_RF_TYPE | ENABLE_BLE_PROTOCOL) +*/ +/*=======================================================================*/ +//! Power save command parameters +/*=======================================================================*/ +//! set handshake type of power mode +//#define RSI_HAND_SHAKE_TYPE GPIO_BASED + +#define BLE_ATT_REC_SIZE 500 +#define NO_OF_VAL_ATT 5 //! Attribute value count + +/***********************************************************************************************************************************************/ +//! user defined structure +/***********************************************************************************************************************************************/ +typedef struct rsi_ble_att_list_s +{ + uuid_t char_uuid; + uint16_t handle; + uint16_t value_len; + uint16_t max_value_len; + uint8_t char_val_prop; + void * value; +} rsi_ble_att_list_t; +typedef struct rsi_ble_s +{ + uint8_t DATA[BLE_ATT_REC_SIZE]; + uint16_t DATA_ix; + uint16_t att_rec_list_count; + rsi_ble_att_list_t att_rec_list[NO_OF_VAL_ATT]; +} rsi_ble_t; + +#endif \ No newline at end of file diff --git a/src/platform/silabs/SiWx917/bluetooth/wfx_sl_ble_init.c b/src/platform/silabs/SiWx917/bluetooth/wfx_sl_ble_init.c new file mode 100644 index 00000000000000..115e5c16ffdcec --- /dev/null +++ b/src/platform/silabs/SiWx917/bluetooth/wfx_sl_ble_init.c @@ -0,0 +1,539 @@ +/******************************************************************************* + * @file wfx_sl_ble_init.c + * @brief + ******************************************************************************* + * # License + * Copyright 2021 Silicon Laboratories Inc. www.silabs.com + ******************************************************************************* + * + * The licensor of this software is Silicon Laboratories Inc. Your use of this + * software is governed by the terms of Silicon Labs Master Software License + * Agreement (MSLA) available at + * www.silabs.com/about-us/legal/master-software-license-agreement. This + * software is distributed to you in Source Code format and is governed by the + * sections of the MSLA applicable to Source Code. + * + ******************************************************************************/ +/************************************************************************* + * + */ + +/*================================================================================ +* @brief : This file contains example application for Wlan Station BLE +* Provisioning +* @section Description : +* This application explains how to get the WLAN connection functionality using +* BLE provisioning. +* Silicon Labs Module starts advertising and with BLE Provisioning the Access Point +* details are fetched. +* Silicon Labs device is configured as a WiFi station and connects to an Access Point. +=================================================================================*/ + +#include "wfx_sl_ble_init.h" +#include "rsi_ble_config.h" + +// application defines +rsi_ble_event_conn_status_t conn_event_to_app; +rsi_ble_t att_list; +sl_wfx_msg_t event_msg; + +// Memory to initialize driver +uint8_t bt_global_buf[BT_GLOBAL_BUFF_LEN]; +static uint8_t wfx_rsi_drv_buf[WFX_RSI_BUF_SZ]; +const uint8_t ShortUUID_CHIPoBLEService[] = { 0xF6, 0xFF }; + +/* Rsi driver Task will use as its stack */ +// StackType_t driverRsiTaskStack[WFX_RSI_WLAN_TASK_SZ] = { 0 }; + +/* Structure that will hold the TCB of the wfxRsi Task being created. */ +// StaticTask_t driverRsiTaskBuffer; + +StaticTask_t rsiBLETaskStruct; + +/* wfxRsi Task will use as its stack */ +StackType_t wfxBLETaskStack[WFX_RSI_TASK_SZ] = { 0 }; + +int32_t ble_rsi_task(void) +{ + int32_t status; + uint8_t buf[RSI_RESPONSE_HOLD_BUFF_SIZE]; + // extern void rsi_hal_board_init(void); + // + // WFX_RSI_LOG("%s: starting(HEAP_SZ = %d)", __func__, SL_HEAP_SIZE); + // + // //! Driver initialization + // status = rsi_driver_init(wfx_rsi_drv_buf, WFX_RSI_BUF_SZ); + // if ((status < RSI_DRIVER_STATUS) || (status > WFX_RSI_BUF_SZ)) + // { + // WFX_RSI_LOG("%s: error: RSI Driver initialization failed with status: %02x", __func__, status); + // return status; + // } + // + // WFX_RSI_LOG("%s: rsi_device_init", __func__); + // + // /* ! Redpine module intialisation */ + // if ((status = rsi_device_init(LOAD_NWP_FW)) != RSI_SUCCESS) + // { + // WFX_RSI_LOG("%s: error: rsi_device_init failed with status: %02x", __func__, status); + // return status; + // } + // WFX_RSI_LOG("%s: start wireless drv task", __func__); + // + // /* + // * Create the driver task + // */ + // wfx_rsi.drv_task = xTaskCreateStatic((TaskFunction_t) rsi_wireless_driver_task, "rsi_drv", WFX_RSI_WLAN_TASK_SZ, NULL, + // 1, driverRsiTaskStack, &driverRsiTaskBuffer); + // if (NULL == wfx_rsi.drv_task) + // { + // WFX_RSI_LOG("%s: error: Create the driver task failed", __func__); + // return RSI_ERROR_INVALID_PARAM; + // } + // + // /* Initialize WiSeConnect or Module features. */ + // WFX_RSI_LOG("%s: rsi_wireless_init", __func__); + // if ((status = rsi_wireless_init(OPER_MODE_0, RSI_OPERMODE_WLAN_BLE)) != RSI_SUCCESS) + // { + // WFX_RSI_LOG("%s: error: Initialize WiSeConnect failed with status: %02x", __func__, status); + // return status; + // } + // + // WFX_RSI_LOG("%s: get FW version..", __func__); + // + // /* + // * Get the MAC and other info to let the user know about it. + // */ + // if (rsi_wlan_get(RSI_FW_VERSION, buf, sizeof(buf)) != RSI_SUCCESS) + // { + // WFX_RSI_LOG("%s: error: rsi_wlan_get(RSI_FW_VERSION) failed with status: %02x", __func__, status); + // return status; + // } + // + // buf[sizeof(buf) - 1] = 0; + // WFX_RSI_LOG("%s: RSI firmware version: %s", __func__, buf); + // //! Send feature frame + // if ((status = rsi_send_feature_frame()) != RSI_SUCCESS) + // { + // WFX_RSI_LOG("%s: error: rsi_send_feature_frame failed with status: %02x", __func__, status); + // return status; + // } + // + // WFX_RSI_LOG("%s: sent rsi_send_feature_frame", __func__); + // /* initializes wlan radio parameters and WLAN supplicant parameters. + // */ + // (void) rsi_wlan_radio_init(); /* Required so we can get MAC address */ + // if ((status = rsi_wlan_get(RSI_MAC_ADDRESS, &wfx_rsi.sta_mac.octet[0], RESP_BUFF_SIZE)) != RSI_SUCCESS) + // { + // WFX_RSI_LOG("%s: error: rsi_wlan_get failed with status: %02x", __func__, status); + // return status; + // } + + // registering the GAP callback functions + rsi_ble_gap_register_callbacks(NULL, NULL, rsi_ble_on_disconnect_event, NULL, NULL, NULL, rsi_ble_on_enhance_conn_status_event, + NULL, NULL, NULL); + + // registering the GATT call back functions + rsi_ble_gatt_register_callbacks(NULL, NULL, NULL, NULL, NULL, NULL, NULL, rsi_ble_on_gatt_write_event, NULL, NULL, NULL, + rsi_ble_on_mtu_event, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, + rsi_ble_on_event_indication_confirmation, NULL); + + WFX_RSI_LOG("registering rsi_ble_add_service"); + + // Exchange of GATT info with BLE stack + rsi_ble_add_matter_service(); + + // initializing the application events map + rsi_ble_app_init_events(); + + wfx_rsi.ble_task = xTaskCreateStatic((TaskFunction_t) rsi_ble_event_handling_task, "rsi_ble", WFX_RSI_TASK_SZ, NULL, 2, + wfxBLETaskStack, &rsiBLETaskStruct); + WFX_RSI_LOG("%s: rsi_task_suspend init_task ", __func__); + if (wfx_rsi.ble_task == NULL) + { + WFX_RSI_LOG("%s: error: failed to create ble task.", __func__); + } + + WFX_RSI_LOG("%s complete", __func__); + // rsi_task_destroy((rsi_task_handle_t *)wfx_rsi.init_task); + return RSI_SUCCESS; +} + +/*==============================================*/ +/** + * @fn rsi_ble_app_init_events + * @brief initializes the event parameter. + * @param[in] none. + * @return none. + * @section description + * This function is used during BLE initialization. + */ +void rsi_ble_app_init_events() +{ + event_msg.ble_app_event_map = 0; + event_msg.ble_app_event_mask = 0xFFFFFFFF; + event_msg.ble_app_event_mask = event_msg.ble_app_event_mask; // To suppress warning while compiling + WFX_RSI_LOG("Function :: rsi_ble_app_init_events"); + return; +} + +/*==============================================*/ +/** + * @fn rsi_ble_app_clear_event + * @brief clears the specific event. + * @param[in] event_num, specific event number. + * @return none. + * @section description + * This function is used to clear the specific event. + */ +void rsi_ble_app_clear_event(uint32_t event_num) +{ + event_msg.event_num = event_num; + event_msg.ble_app_event_map &= ~BIT(event_num); + return; +} + +/*==============================================*/ +/** + * @fn rsi_ble_on_mtu_event + * @brief its invoked when mtu exhange event is received. + * @param[in] rsi_ble_mtu, mtu event paramaters. + * @return none. + * @section description + * This callback function is invoked when mtu exhange event is received + */ +void rsi_ble_on_mtu_event(rsi_ble_event_mtu_t * rsi_ble_mtu) +{ + WFX_RSI_LOG(" RSI_BLE : rsi_ble_on_mtu_event"); + memset(&event_msg.rsi_ble_mtu, 0, sizeof(rsi_ble_event_mtu_t)); + memcpy(&event_msg.rsi_ble_mtu, rsi_ble_mtu, sizeof(rsi_ble_event_mtu_t)); + rsi_ble_app_set_event(RSI_BLE_MTU_EVENT); +} + +/*==============================================*/ +/** + * @fn rsi_ble_on_gatt_write_event + * @brief its invoked when write/notify/indication events are received. + * @param[in] event_id, it indicates write/notification event id. + * @param[in] rsi_ble_write, write event parameters. + * @return none. + * @section description + * This callback function is invoked when write/notify/indication events are received + */ +void rsi_ble_on_gatt_write_event(uint16_t event_id, rsi_ble_event_write_t * rsi_ble_write) +{ + WFX_RSI_LOG(" RSI_BLE : rsi_ble_on_gatt_write_event"); + memset(&event_msg.rsi_ble_write, 0, sizeof(rsi_ble_event_write_t)); + event_msg.event_id = event_id; + memcpy(&event_msg.rsi_ble_write, rsi_ble_write, sizeof(rsi_ble_event_write_t)); + rsi_ble_app_set_event(RSI_BLE_GATT_WRITE_EVENT); +} + +/*==============================================*/ +/** + * @fn rsi_ble_on_enhance_conn_status_event + * @brief invoked when enhanced connection complete event is received + * @param[out] resp_conn, connected remote device information + * @return none. + * @section description + * This callback function indicates the status of the connection + */ +void rsi_ble_on_enhance_conn_status_event(rsi_ble_event_enhance_conn_status_t * resp_enh_conn) +{ + WFX_RSI_LOG(" RSI_BLE : rsi_ble_on_enhance_conn_status_event"); + event_msg.connectionHandle = 1; + event_msg.bondingHandle = 255; + memcpy(event_msg.resp_enh_conn.dev_addr, resp_enh_conn->dev_addr, RSI_DEV_ADDR_LEN); + rsi_ble_app_set_event(RSI_BLE_CONN_EVENT); +} + +/*==============================================*/ +/** + * @fn rsi_ble_on_disconnect_event + * @brief invoked when disconnection event is received + * @param[in] resp_disconnect, disconnected remote device information + * @param[in] reason, reason for disconnection. + * @return none. + * @section description + * This callback function indicates disconnected device information and status + */ +void rsi_ble_on_disconnect_event(rsi_ble_event_disconnect_t * resp_disconnect, uint16_t reason) +{ + WFX_RSI_LOG(" RSI_BLE : rsi_ble_on_disconnect_event"); + event_msg.reason = reason; + memcpy(event_msg.resp_disconnect, resp_disconnect, sizeof(rsi_ble_event_disconnect_t)); + rsi_ble_app_set_event(RSI_BLE_DISCONN_EVENT); +} + +/*==============================================*/ +/** + * @fn rsi_ble_on_event_indication_confirmation + * @brief this function will invoke when received indication confirmation event + * @param[out] resp_id, response id + * @param[out] status, status of the response + * @return none + * @section description + */ +void rsi_ble_on_event_indication_confirmation(uint16_t resp_status, rsi_ble_set_att_resp_t * rsi_ble_event_set_att_rsp) +{ + WFX_RSI_LOG(" RSI_BLE : rsi_ble_on_event_indication_confirmation"); + event_msg.resp_status = resp_status; + memcpy(&event_msg.rsi_ble_event_set_att_rsp, rsi_ble_event_set_att_rsp, sizeof(rsi_ble_set_att_resp_t)); + rsi_ble_app_set_event(RSI_BLE_GATT_INDICATION_CONFIRMATION); +} + +/*==============================================*/ +/** + * @fn rsi_ble_app_get_event + * @brief returns the first set event based on priority + * @param[in] none. + * @return int32_t + * > 0 = event number + * -1 = not received any event + * @section description + * This function returns the highest priority event among all the set events + */ +int32_t rsi_ble_app_get_event(void) +{ + uint32_t ix; + + for (ix = 0; ix < 32; ix++) + { + if (event_msg.ble_app_event_map & (1 << ix)) + { + return ix; + } + } + + return (-1); +} + +/*==============================================*/ +/** + * @fn rsi_ble_app_set_event + * @brief set the specific event. + * @param[in] event_num, specific event number. + * @return none. + * @section description + * This function is used to set/raise the specific event. + */ +void rsi_ble_app_set_event(uint32_t event_num) +{ + event_msg.ble_app_event_map |= BIT(event_num); + return; +} + +/*==============================================*/ +/** + * @fn rsi_gatt_add_attribute_to_list + * @brief This function is used to store characteristic service attribute. + * @param[in] p_val, pointer to homekit structure + * @param[in] handle, characteristic service attribute handle. + * @param[in] data_len, characteristic value length + * @param[in] data, characteristic value pointer + * @param[in] uuid, characteristic value uuid + * @return none. + * @section description + * This function is used to store all attribute records + */ +void rsi_gatt_add_attribute_to_list(rsi_ble_t * p_val, uint16_t handle, uint16_t data_len, uint8_t * data, uuid_t uuid, + uint8_t char_prop) +{ + if ((p_val->DATA_ix + data_len) >= BLE_ATT_REC_SIZE) + { //! Check for max data length for the characteristic value + LOG_PRINT("\r\n no data memory for att rec values \r\n"); + return; + } + + p_val->att_rec_list[p_val->att_rec_list_count].char_uuid = uuid; + p_val->att_rec_list[p_val->att_rec_list_count].handle = handle; + p_val->att_rec_list[p_val->att_rec_list_count].value_len = data_len; + p_val->att_rec_list[p_val->att_rec_list_count].max_value_len = data_len; + p_val->att_rec_list[p_val->att_rec_list_count].char_val_prop = char_prop; + memcpy(p_val->DATA + p_val->DATA_ix, data, data_len); + p_val->att_rec_list[p_val->att_rec_list_count].value = p_val->DATA + p_val->DATA_ix; + p_val->att_rec_list_count++; + p_val->DATA_ix += p_val->att_rec_list[p_val->att_rec_list_count].max_value_len; + + return; +} + +/*==============================================*/ +/** + * @fn rsi_ble_add_char_serv_att + * @brief this function is used to add characteristic service attribute.. + * @param[in] serv_handler, service handler. + * @param[in] handle, characteristic service attribute handle. + * @param[in] val_prop, characteristic value property. + * @param[in] att_val_handle, characteristic value handle + * @param[in] att_val_uuid, characteristic value uuid + * @return none. + * @section description + * This function is used at application to add characteristic attribute + */ +void rsi_ble_add_char_serv_att(void * serv_handler, uint16_t handle, uint8_t val_prop, uint16_t att_val_handle, uuid_t att_val_uuid) +{ + rsi_ble_req_add_att_t new_att = { 0 }; + + //! preparing the attribute service structure + new_att.serv_handler = serv_handler; + new_att.handle = handle; + new_att.att_uuid.size = 2; + new_att.att_uuid.val.val16 = RSI_BLE_CHAR_SERV_UUID; + new_att.property = RSI_BLE_ATT_PROPERTY_READ; + + //! preparing the characteristic attribute value + new_att.data_len = att_val_uuid.size + 4; + new_att.data[0] = val_prop; + rsi_uint16_to_2bytes(&new_att.data[2], att_val_handle); + if (new_att.data_len == 6) + { + rsi_uint16_to_2bytes(&new_att.data[4], att_val_uuid.val.val16); + } + else if (new_att.data_len == 8) + { + rsi_uint32_to_4bytes(&new_att.data[4], att_val_uuid.val.val32); + } + else if (new_att.data_len == 20) + { + memcpy(&new_att.data[4], &att_val_uuid.val.val128, att_val_uuid.size); + } + //! Add attribute to the service + rsi_ble_add_attribute(&new_att); + + return; +} + +/*==============================================*/ +/** + * @fn rsi_ble_add_char_val_att + * @brief this function is used to add characteristic value attribute. + * @param[in] serv_handler, new service handler. + * @param[in] handle, characteristic value attribute handle. + * @param[in] att_type_uuid, attribute uuid value. + * @param[in] val_prop, characteristic value property. + * @param[in] data, characteristic value data pointer. + * @param[in] data_len, characteristic value length. + * @return none. + * @section description + * This function is used at application to create new service. + */ + +void rsi_ble_add_char_val_att(void * serv_handler, uint16_t handle, uuid_t att_type_uuid, uint8_t val_prop, uint8_t * data, + uint8_t data_len, uint8_t auth_read) +{ + rsi_ble_req_add_att_t new_att = { 0 }; + + memset(&new_att, 0, sizeof(rsi_ble_req_add_att_t)); + //! preparing the attributes + new_att.serv_handler = serv_handler; + new_att.handle = handle; + new_att.config_bitmap = auth_read; + memcpy(&new_att.att_uuid, &att_type_uuid, sizeof(uuid_t)); + new_att.property = val_prop; + + if (data != NULL) + memcpy(new_att.data, data, RSI_MIN(sizeof(new_att.data), data_len)); + + //! preparing the attribute value + new_att.data_len = data_len; + + //! add attribute to the service + rsi_ble_add_attribute(&new_att); + + if ((auth_read == ATT_REC_MAINTAIN_IN_HOST) || (data_len > 20)) + { + if (data != NULL) + { + rsi_gatt_add_attribute_to_list(&att_list, handle, data_len, data, att_type_uuid, val_prop); + } + } + + //! check the attribute property with notification/Indication + if ((val_prop & RSI_BLE_ATT_PROPERTY_NOTIFY) || (val_prop & RSI_BLE_ATT_PROPERTY_INDICATE)) + { + //! if notification/indication property supports then we need to add client characteristic service. + + //! preparing the client characteristic attribute & values + memset(&new_att, 0, sizeof(rsi_ble_req_add_att_t)); + new_att.serv_handler = serv_handler; + new_att.handle = handle + 1; + new_att.att_uuid.size = 2; + new_att.att_uuid.val.val16 = RSI_BLE_CLIENT_CHAR_UUID; + new_att.property = RSI_BLE_ATT_PROPERTY_READ | RSI_BLE_ATT_PROPERTY_WRITE; + new_att.data_len = 2; + + //! add attribute to the service + rsi_ble_add_attribute(&new_att); + } + + return; +} + +/*==============================================*/ +/** + * @fn rsi_ble_add_matter_service + * @brief this function is used to add service for matter + * @return status (uint32_t) 0 for success. + * @section description + * This function is used at application to create new service. + */ + +uint32_t rsi_ble_add_matter_service(void) +{ + uuid_t custom_service = { RSI_BLE_MATTER_CUSTOM_SERVICE_UUID }; + custom_service.size = RSI_BLE_MATTER_CUSTOM_SERVICE_SIZE; + custom_service.val.val16 = RSI_BLE_MATTER_CUSTOM_SERVICE_VALUE_16; + uint8_t data[230] = { RSI_BLE_MATTER_CUSTOM_SERVICE_DATA }; + + static const uuid_t custom_characteristic_RX = { .size = RSI_BLE_CUSTOM_CHARACTERISTIC_RX_SIZE, + .reserved = { RSI_BLE_CUSTOM_CHARACTERISTIC_RX_RESERVED }, + .val.val128.data1 = RSI_BLE_CUSTOM_CHARACTERISTIC_RX_VALUE_128_DATA_1, + .val.val128.data2 = RSI_BLE_CUSTOM_CHARACTERISTIC_RX_VALUE_128_DATA_2, + .val.val128.data3 = RSI_BLE_CUSTOM_CHARACTERISTIC_RX_VALUE_128_DATA_3, + .val.val128.data4 = { RSI_BLE_CUSTOM_CHARACTERISTIC_RX_VALUE_128_DATA_4 } }; + + rsi_ble_resp_add_serv_t new_serv_resp = { 0 }; + rsi_ble_add_service(custom_service, &new_serv_resp); + + // Adding custom characteristic declaration to the custom service + rsi_ble_add_char_serv_att( + new_serv_resp.serv_handler, new_serv_resp.start_handle + RSI_BLE_CHARACTERISTIC_RX_ATTRIBUTE_HANDLE_LOCATION, + RSI_BLE_ATT_PROPERTY_WRITE | RSI_BLE_ATT_PROPERTY_READ, // Set read, write, write without response + new_serv_resp.start_handle + RSI_BLE_CHARACTERISTIC_RX_VALUE_HANDLE_LOCATION, custom_characteristic_RX); + + // Adding characteristic value attribute to the service + rsi_ble_add_char_val_att(new_serv_resp.serv_handler, + new_serv_resp.start_handle + RSI_BLE_CHARACTERISTIC_RX_VALUE_HANDLE_LOCATION, custom_characteristic_RX, + RSI_BLE_ATT_PROPERTY_WRITE | RSI_BLE_ATT_PROPERTY_READ, // Set read, write, write without response + data, sizeof(data), ATT_REC_IN_HOST); + + static const uuid_t custom_characteristic_TX = { .size = RSI_BLE_CUSTOM_CHARACTERISTIC_TX_SIZE, + .reserved = { RSI_BLE_CUSTOM_CHARACTERISTIC_TX_RESERVED }, + .val.val128.data1 = RSI_BLE_CUSTOM_CHARACTERISTIC_TX_VALUE_128_DATA_1, + .val.val128.data2 = RSI_BLE_CUSTOM_CHARACTERISTIC_TX_VALUE_128_DATA_2, + .val.val128.data3 = RSI_BLE_CUSTOM_CHARACTERISTIC_TX_VALUE_128_DATA_3, + .val.val128.data4 = { RSI_BLE_CUSTOM_CHARACTERISTIC_TX_VALUE_128_DATA_4 } }; + + // Adding custom characteristic declaration to the custom service + rsi_ble_add_char_serv_att( + new_serv_resp.serv_handler, new_serv_resp.start_handle + RSI_BLE_CHARACTERISTIC_TX_ATTRIBUTE_HANDLE_LOCATION, + RSI_BLE_ATT_PROPERTY_WRITE_NO_RESPONSE | RSI_BLE_ATT_PROPERTY_WRITE | RSI_BLE_ATT_PROPERTY_READ | + RSI_BLE_ATT_PROPERTY_NOTIFY | RSI_BLE_ATT_PROPERTY_INDICATE, // Set read, write, write without response + new_serv_resp.start_handle + RSI_BLE_CHARACTERISTIC_TX_MEASUREMENT_HANDLE_LOCATION, custom_characteristic_TX); + + // Adding characteristic value attribute to the service + event_msg.rsi_ble_measurement_hndl = new_serv_resp.start_handle + RSI_BLE_CHARACTERISTIC_TX_MEASUREMENT_HANDLE_LOCATION; + + // Adding characteristic value attribute to the service + event_msg.rsi_ble_gatt_server_client_config_hndl = + new_serv_resp.start_handle + RSI_BLE_CHARACTERISTIC_TX_GATT_SERVER_CLIENT_HANDLE_LOCATION; + + rsi_ble_add_char_val_att(new_serv_resp.serv_handler, event_msg.rsi_ble_measurement_hndl, custom_characteristic_TX, + RSI_BLE_ATT_PROPERTY_WRITE_NO_RESPONSE | RSI_BLE_ATT_PROPERTY_WRITE | RSI_BLE_ATT_PROPERTY_READ | + RSI_BLE_ATT_PROPERTY_NOTIFY | + RSI_BLE_ATT_PROPERTY_INDICATE, // Set read, write, write without response + data, sizeof(data), ATT_REC_MAINTAIN_IN_HOST); + + memset(&data, 0, sizeof(data)); + return 0; +} \ No newline at end of file diff --git a/src/platform/silabs/SiWx917/bluetooth/wfx_sl_ble_init.h b/src/platform/silabs/SiWx917/bluetooth/wfx_sl_ble_init.h new file mode 100644 index 00000000000000..497d2b5ee33bfe --- /dev/null +++ b/src/platform/silabs/SiWx917/bluetooth/wfx_sl_ble_init.h @@ -0,0 +1,121 @@ +/******************************************************************************* + * @file wfx_sl_ble_init.h + * @brief + ******************************************************************************* + * # License + * Copyright 2021 Silicon Laboratories Inc. www.silabs.com + ******************************************************************************* + * + * The licensor of this software is Silicon Laboratories Inc. Your use of this + * software is governed by the terms of Silicon Labs Master Software License + * Agreement (MSLA) available at + * www.silabs.com/about-us/legal/master-software-license-agreement. This + * software is distributed to you in Source Code format and is governed by the + * sections of the MSLA applicable to Source Code. + * + ******************************************************************************/ +/************************************************************************* + * + */ + +/** + * Include files + * */ + +#ifndef WFX_SL_BLE_INIT +#define WFX_SL_BLE_INIT +#define RSI_BLE_ENABLE 1 + +// BLE include file to refer BLE APIs +#include "FreeRTOS.h" +#include "event_groups.h" +#include "rsi_ble_config.h" +#include "task.h" +#include "timers.h" +#include "wfx_host_events.h" +#include "wfx_rsi.h" +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#ifdef RSI_M4_INTERFACE +#include "rsi_board.h" +#endif + +#define ATT_REC_IN_HOST 0 + +#define RSI_BLE_MATTER_CUSTOM_SERVICE_UUID 0 +#define RSI_BLE_MATTER_CUSTOM_SERVICE_SIZE 2 +#define RSI_BLE_MATTER_CUSTOM_SERVICE_VALUE_16 0xFFF6 +#define RSI_BLE_MATTER_CUSTOM_SERVICE_DATA 0x00 + +#define RSI_BLE_CUSTOM_CHARACTERISTIC_RX_SIZE 16 +#define RSI_BLE_CUSTOM_CHARACTERISTIC_RX_RESERVED 0x00, 0x00, 0x00 +#define RSI_BLE_CUSTOM_CHARACTERISTIC_RX_VALUE_128_DATA_1 0x18EE2EF5 +#define RSI_BLE_CUSTOM_CHARACTERISTIC_RX_VALUE_128_DATA_2 0x263D +#define RSI_BLE_CUSTOM_CHARACTERISTIC_RX_VALUE_128_DATA_3 0x4559 +#define RSI_BLE_CUSTOM_CHARACTERISTIC_RX_VALUE_128_DATA_4 0x9F, 0x95, 0x9C, 0x4F, 0x11, 0x9D, 0x9F, 0x42 +#define RSI_BLE_CHARACTERISTIC_RX_ATTRIBUTE_HANDLE_LOCATION 1 +#define RSI_BLE_CHARACTERISTIC_RX_VALUE_HANDLE_LOCATION 2 + +#define RSI_BLE_CUSTOM_CHARACTERISTIC_TX_SIZE 16 +#define RSI_BLE_CUSTOM_CHARACTERISTIC_TX_RESERVED 0x00, 0x00, 0x00 +#define RSI_BLE_CUSTOM_CHARACTERISTIC_TX_VALUE_128_DATA_1 0x18EE2EF5 +#define RSI_BLE_CUSTOM_CHARACTERISTIC_TX_VALUE_128_DATA_2 0x263D +#define RSI_BLE_CUSTOM_CHARACTERISTIC_TX_VALUE_128_DATA_3 0x4559 +#define RSI_BLE_CUSTOM_CHARACTERISTIC_TX_VALUE_128_DATA_4 0x9F, 0x95, 0x9C, 0x4F, 0x12, 0x9D, 0x9F, 0x42 +#define RSI_BLE_CHARACTERISTIC_TX_ATTRIBUTE_HANDLE_LOCATION 3 +#define RSI_BLE_CHARACTERISTIC_TX_MEASUREMENT_HANDLE_LOCATION 4 +#define RSI_BLE_CHARACTERISTIC_TX_GATT_SERVER_CLIENT_HANDLE_LOCATION 5 + +typedef struct sl_wfx_msg_s +{ + uint8_t connectionHandle; + uint8_t bondingHandle; + uint32_t event_num; + uint16_t reason; + uint16_t event_id; + uint16_t resp_status; + rsi_ble_event_mtu_t rsi_ble_mtu; + rsi_ble_event_write_t rsi_ble_write; + rsi_ble_event_enhance_conn_status_t resp_enh_conn; + rsi_ble_event_disconnect_t * resp_disconnect; + rsi_ble_set_att_resp_t rsi_ble_event_set_att_rsp; + uint32_t ble_app_event_map; + uint32_t ble_app_event_mask; + uint16_t rsi_ble_measurement_hndl; + uint16_t rsi_ble_gatt_server_client_config_hndl; +} sl_wfx_msg_t; + +int32_t ble_rsi_task(void); +void rsi_ble_on_connect_event(rsi_ble_event_conn_status_t * resp_conn); +void rsi_ble_on_disconnect_event(rsi_ble_event_disconnect_t * resp_disconnect, uint16_t reason); +void rsi_ble_on_enhance_conn_status_event(rsi_ble_event_enhance_conn_status_t * resp_enh_conn); +void rsi_ble_on_gatt_write_event(uint16_t event_id, rsi_ble_event_write_t * rsi_ble_write); +void rsi_ble_on_mtu_event(rsi_ble_event_mtu_t * rsi_ble_mtu); +void rsi_ble_on_event_indication_confirmation(uint16_t resp_status, rsi_ble_set_att_resp_t * rsi_ble_event_set_att_rsp); +void rsi_gatt_add_attribute_to_list(rsi_ble_t * p_val, uint16_t handle, uint16_t data_len, uint8_t * data, uuid_t uuid, + uint8_t char_prop); +void rsi_ble_add_char_serv_att(void * serv_handler, uint16_t handle, uint8_t val_prop, uint16_t att_val_handle, + uuid_t att_val_uuid); +void rsi_ble_add_char_val_att(void * serv_handler, uint16_t handle, uuid_t att_type_uuid, uint8_t val_prop, uint8_t * data, + uint8_t data_len, uint8_t auth_read); +uint32_t rsi_ble_add_matter_service(void); +void rsi_ble_app_set_event(uint32_t event_num); +int32_t rsi_ble_app_get_event(void); +void rsi_ble_app_clear_event(uint32_t event_num); +void rsi_ble_app_init_events(); +void rsi_ble_event_handling_task(void); + +#endif \ No newline at end of file diff --git a/src/platform/silabs/SiWx917/siwx917-chip-mbedtls-config.h b/src/platform/silabs/SiWx917/siwx917-chip-mbedtls-config.h new file mode 100644 index 00000000000000..41126c51c0482c --- /dev/null +++ b/src/platform/silabs/SiWx917/siwx917-chip-mbedtls-config.h @@ -0,0 +1,132 @@ +/* + * Copyright (c) 2021, The OpenThread Authors. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the copyright holder nor the + * names of its contributors may be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" + * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE + * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN + * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + */ + +#pragma once + +#include +#include +#include +/** + * Enable FreeRTOS threading support + */ +#define MBEDTLS_FREERTOS + +/** + * Enable H Crypto and Entropy modules + */ +#define MBEDTLS_AES_C +#define MBEDTLS_ECP_C +#define MBEDTLS_ECDH_C +#define MBEDTLS_ENTROPY_C +#define MBEDTLS_SHA256_C +#define MBEDTLS_CIPHER_MODE_CTR +#define MBEDTLS_TRNG_C + +#define MBEDTLS_NO_PLATFORM_ENTROPY +#define MBEDTLS_NO_DEFAULT_ENTROPY_SOURCES + +#if defined(MBEDTLS_ECP_ALT) && !defined(MBEDTLS_ECP_RESTARTABLE) +typedef void mbedtls_ecp_restart_ctx; +#endif + +#define MBEDTLS_PLATFORM_SNPRINTF_MACRO snprintf + +#define MBEDTLS_AES_ROM_TABLES +#define MBEDTLS_ASN1_PARSE_C +#define MBEDTLS_ASN1_WRITE_C +#define MBEDTLS_BASE64_C +#define MBEDTLS_BIGNUM_C +#define MBEDTLS_CCM_C +#define MBEDTLS_CIPHER_C +#define MBEDTLS_CIPHER_MODE_CBC +#define MBEDTLS_CIPHER_MODE_CFB +#define MBEDTLS_CMAC_C +#define MBEDTLS_CTR_DRBG_C +#define MBEDTLS_ECDH_LEGACY_CONTEXT +#define MBEDTLS_ECDSA_C +#define MBEDTLS_ECDSA_DETERMINISTIC +#define MBEDTLS_ECJPAKE_C +#define MBEDTLS_ECP_DP_SECP256R1_ENABLED +#define MBEDTLS_ECP_NIST_OPTIM +#define MBEDTLS_ENTROPY_FORCE_SHA256 +// TODO: 3R +// #define MBEDTLS_ENTROPY_HARDWARE_ALT + +#define MBEDTLS_ERROR_STRERROR_DUMMY +#define MBEDTLS_HAVE_ASM +#define MBEDTLS_HKDF_C +#define MBEDTLS_HMAC_DRBG_C +#define MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED +#define MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED +#define MBEDTLS_KEY_EXCHANGE_PSK_ENABLED +#define MBEDTLS_MD_C +#define MBEDTLS_OID_C +#define MBEDTLS_PEM_PARSE_C +#define MBEDTLS_PEM_WRITE_C +#define MBEDTLS_PK_C +#define MBEDTLS_PK_PARSE_C +#define MBEDTLS_PK_WRITE_C +#define MBEDTLS_PKCS5_C +#define MBEDTLS_PLATFORM_C +#define MBEDTLS_PLATFORM_MEMORY +#define MBEDTLS_SHA256_SMALLER +#define MBEDTLS_SHA512_C +#define MBEDTLS_SSL_CLI_C +#define MBEDTLS_SSL_COOKIE_C +#define MBEDTLS_SSL_DTLS_ANTI_REPLAY +#define MBEDTLS_SSL_DTLS_HELLO_VERIFY +#define MBEDTLS_SSL_EXPORT_KEYS +#define MBEDTLS_SSL_KEEP_PEER_CERTIFICATE +#define MBEDTLS_SSL_MAX_FRAGMENT_LENGTH +#define MBEDTLS_SSL_PROTO_TLS1_2 +#define MBEDTLS_SSL_PROTO_DTLS +#define MBEDTLS_SSL_SRV_C +#define MBEDTLS_SSL_TLS_C +#define MBEDTLS_X509_CREATE_C +#define MBEDTLS_X509_CSR_WRITE_C +#define MBEDTLS_X509_CRL_PARSE_C +#define MBEDTLS_X509_CRT_PARSE_C +#define MBEDTLS_X509_CSR_PARSE_C +#define MBEDTLS_X509_USE_C + +#define MBEDTLS_MPI_WINDOW_SIZE 1 /**< Maximum windows size used. */ +#define MBEDTLS_MPI_MAX_SIZE 32 /**< Maximum number of bytes for usable MPIs. */ +#define MBEDTLS_ECP_MAX_BITS 256 /**< Maximum bit size of groups */ +#define MBEDTLS_ECP_WINDOW_SIZE 2 /**< Maximum window size used */ +#define MBEDTLS_ECP_FIXED_POINT_OPTIM 0 /**< Enable fixed-point speed-up */ +#define MBEDTLS_ENTROPY_MAX_SOURCES 2 /**< Maximum number of sources supported */ + +#if OPENTHREAD_CONFIG_COAP_SECURE_API_ENABLE +#define MBEDTLS_SSL_MAX_CONTENT_LEN 900 /**< Maxium fragment length in bytes */ +#else +#define MBEDTLS_SSL_MAX_CONTENT_LEN 768 /**< Maxium fragment length in bytes */ +#endif + +#define MBEDTLS_SSL_CIPHERSUITES MBEDTLS_TLS_ECJPAKE_WITH_AES_128_CCM_8 + +#include "mbedtls/check_config.h" diff --git a/src/platform/silabs/SiWx917/wifi/dhcp_client.cpp b/src/platform/silabs/SiWx917/wifi/dhcp_client.cpp new file mode 100644 index 00000000000000..e45f38bcaeaf8e --- /dev/null +++ b/src/platform/silabs/SiWx917/wifi/dhcp_client.cpp @@ -0,0 +1,143 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#if LWIP_IPV4 && LWIP_DHCP + +#include +#include +#include + +#include "dhcp_client.h" +#include "lwip/dhcp.h" +#include "wfx_host_events.h" +#include "wifi_config.h" + +#include "AppConfig.h" +#include "FreeRTOS.h" +#include "event_groups.h" + +#define MAX_DHCP_TRIES 4 +#define NETIF_IPV4_ADDRESS(X, Y) (((X) >> (8 * Y)) & 0xFF) + +/* Station IP address */ +uint8_t sta_ip_addr0 = STA_IP_ADDR0_DEFAULT; +uint8_t sta_ip_addr1 = STA_IP_ADDR1_DEFAULT; +uint8_t sta_ip_addr2 = STA_IP_ADDR2_DEFAULT; +uint8_t sta_ip_addr3 = STA_IP_ADDR3_DEFAULT; +uint8_t sta_netmask_addr0 = STA_NETMASK_ADDR0_DEFAULT; +uint8_t sta_netmask_addr1 = STA_NETMASK_ADDR1_DEFAULT; +uint8_t sta_netmask_addr2 = STA_NETMASK_ADDR2_DEFAULT; +uint8_t sta_netmask_addr3 = STA_NETMASK_ADDR3_DEFAULT; +uint8_t sta_gw_addr0 = STA_GW_ADDR0_DEFAULT; +uint8_t sta_gw_addr1 = STA_GW_ADDR1_DEFAULT; +uint8_t sta_gw_addr2 = STA_GW_ADDR2_DEFAULT; +uint8_t sta_gw_addr3 = STA_GW_ADDR3_DEFAULT; + +/// Current DHCP state machine state. +static volatile uint8_t dhcp_state = DHCP_OFF; + +/***************************************************************************** + * @fn void dhcpclient_set_link_state(int link_up) + * @brief + * Notify DHCP client task about the wifi status + * @param link_up link status + * @return None + ******************************************************************************/ +void dhcpclient_set_link_state(int link_up) +{ + if (link_up) + { + dhcp_state = DHCP_START; + SILABS_LOG("DHCP: Starting"); + } + else + { + /* Update DHCP state machine */ + dhcp_state = DHCP_LINK_DOWN; + } +} + +/********************************************************************************** + * @fn uint8_t dhcpclient_poll(void *arg) + * @brief + * Don't need a task here. We get polled every 250ms + * @return None + ************************************************************************************/ +uint8_t dhcpclient_poll(void * arg) +{ + struct netif * netif = (struct netif *) arg; + ip_addr_t ipaddr; + ip_addr_t netmask; + ip_addr_t gw; + struct dhcp * dhcp; + + switch (dhcp_state) + { + case DHCP_START: + SILABS_LOG("DHCP: Wait addr"); + ip_addr_set_zero_ip4(&netif->ip_addr); + ip_addr_set_zero_ip4(&netif->netmask); + ip_addr_set_zero_ip4(&netif->gw); + dhcp_start(netif); + dhcp_state = DHCP_WAIT_ADDRESS; + break; + + case DHCP_WAIT_ADDRESS: + if (dhcp_supplied_address(netif)) + { + dhcp_state = DHCP_ADDRESS_ASSIGNED; + + uint64_t addr = netif->ip_addr.u_addr.ip4.addr; + SILABS_LOG("DHCP IP: %d.%d.%d.%d", NETIF_IPV4_ADDRESS(addr, 0), NETIF_IPV4_ADDRESS(addr, 1), + NETIF_IPV4_ADDRESS(addr, 2), NETIF_IPV4_ADDRESS(addr, 3)); + } + else + { + dhcp = (struct dhcp *) netif_get_client_data(netif, LWIP_NETIF_CLIENT_DATA_INDEX_DHCP); + + /* DHCP timeout */ + if (dhcp->tries > MAX_DHCP_TRIES) + { + dhcp_state = DHCP_TIMEOUT; + + SILABS_LOG("*ERR*DHCP: Failed"); + /* Stop DHCP */ + dhcp_stop(netif); + + /* TODO - I am not sure that this is best */ + /* Static address used */ + IP_ADDR4(&ipaddr, sta_ip_addr0, sta_ip_addr1, sta_ip_addr2, sta_ip_addr3); + IP_ADDR4(&netmask, sta_netmask_addr0, sta_netmask_addr1, sta_netmask_addr2, sta_netmask_addr3); + IP_ADDR4(&gw, sta_gw_addr0, sta_gw_addr1, sta_gw_addr2, sta_gw_addr3); + netif_set_addr(netif, ip_2_ip4(&ipaddr), ip_2_ip4(&netmask), ip_2_ip4(&gw)); + } + } + break; + + case DHCP_LINK_DOWN: + /* Stop DHCP */ + SILABS_LOG("*ERR*DHCP Link down"); + dhcp_stop(netif); + dhcp_state = DHCP_OFF; + break; + default: + break; + } + return dhcp_state; +} + +#endif /* LWIP_IPV4 && LWIP_DHCP */ diff --git a/src/platform/silabs/SiWx917/wifi/dhcp_client.h b/src/platform/silabs/SiWx917/wifi/dhcp_client.h new file mode 100644 index 00000000000000..3040f7112fb954 --- /dev/null +++ b/src/platform/silabs/SiWx917/wifi/dhcp_client.h @@ -0,0 +1,45 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#if LWIP_IPV4 && LWIP_DHCP + +#pragma once +#ifdef __cplusplus +extern "C" { +#endif + +// DHCP client states +#define DHCP_OFF (uint8_t) 0 +#define DHCP_START (uint8_t) 1 +#define DHCP_WAIT_ADDRESS (uint8_t) 2 +#define DHCP_ADDRESS_ASSIGNED (uint8_t) 3 +#define DHCP_TIMEOUT (uint8_t) 4 +#define DHCP_LINK_DOWN (uint8_t) 5 + +/***************************************************************************** + * @fn void dhcpclient_set_link_state(int link_up) + * @brief + * Notify DHCP client task about the wifi status + * @param link_up link status + ******************************************************************************/ +void dhcpclient_set_link_state(int link_up); +uint8_t dhcpclient_poll(void * arg); +#ifdef __cplusplus +} +#endif + +#endif /* LWIP_IPV4 && LWIP_DHCP */ diff --git a/src/platform/silabs/SiWx917/wifi/ethernetif.cpp b/src/platform/silabs/SiWx917/wifi/ethernetif.cpp new file mode 100644 index 00000000000000..13cc843d0e705d --- /dev/null +++ b/src/platform/silabs/SiWx917/wifi/ethernetif.cpp @@ -0,0 +1,318 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/* Includes */ + +#include +#include +#include + +#ifndef WF200_WIFI +#include "FreeRTOS.h" +#include "event_groups.h" +#include "task.h" +#endif + +#include "wfx_host_events.h" +#include "wifi_config.h" +#ifdef WF200_WIFI +#include "sl_wfx.h" +#endif +/* LwIP includes. */ +#include "ethernetif.h" +#include "lwip/ethip6.h" +#include "lwip/timeouts.h" +#include "netif/etharp.h" + +#ifndef SILABS_LOG +extern "C" { +void efr32Log(const char * aFormat, ...); +#define SILABS_LOG(...) efr32Log(__VA_ARGS__); +} +#endif + +StaticSemaphore_t xEthernetIfSemaBuffer; + +/***************************************************************************** + * Defines + ******************************************************************************/ +#define STATION_NETIF0 's' +#define STATION_NETIF1 't' + +#define LWIP_FRAME_ALIGNMENT 60 + +uint32_t gOverrunCount = 0; + +/***************************************************************************** + * Variables + ******************************************************************************/ + +/***************************************************************************** + * @fn static void low_level_init(struct netif *netif) + * @brief + * Initializes the hardware parameters. Called from ethernetif_init(). + * + * @param[in] netif: the already initialized lwip network interface structure + * + * @return + * None + ******************************************************************************/ +static void low_level_init(struct netif * netif) +{ + /* set netif MAC hardware address length */ + netif->hwaddr_len = ETH_HWADDR_LEN; + + /* Set netif MAC hardware address */ + sl_wfx_mac_address_t mac_addr; + + wfx_get_wifi_mac_addr(SL_WFX_STA_INTERFACE, &mac_addr); + + netif->hwaddr[0] = mac_addr.octet[0]; + netif->hwaddr[1] = mac_addr.octet[1]; + netif->hwaddr[2] = mac_addr.octet[2]; + netif->hwaddr[3] = mac_addr.octet[3]; + netif->hwaddr[4] = mac_addr.octet[4]; + netif->hwaddr[5] = mac_addr.octet[5]; + + /* Set netif maximum transfer unit */ + netif->mtu = 1500; + + /* Accept broadcast address and ARP traffic */ + netif->flags |= NETIF_FLAG_BROADCAST | NETIF_FLAG_ETHARP | NETIF_FLAG_IGMP; + +#if LWIP_IPV6_MLD + netif->flags |= NETIF_FLAG_MLD6; +#endif /* LWIP_IPV6_MLD */ +} + +/******************************************************************************** + * @fn static void low_level_input(struct netif *netif, uint8_t *b, uint16_t len) + * @brief + * Make PBUF out of a linear buffer - that can be fed into lwip + * @param[in] netif: the already initialized lwip network interface structure + * @param[in] len: length + * @return + * None + ************************************************************************************/ +static void low_level_input(struct netif * netif, uint8_t * b, uint16_t len) +{ + struct pbuf *p, *q; + uint32_t bufferoffset; + + if (len <= 0) + { + return; + } + if (len < LWIP_FRAME_ALIGNMENT) + { /* 60 : LWIP frame alignment */ + len = LWIP_FRAME_ALIGNMENT; + } + + /* Drop packets originated from the same interface and is not destined for the said interface */ + const uint8_t * src_mac = b + netif->hwaddr_len; + const uint8_t * dst_mac = b; + + if (!(ip6_addr_ispreferred(netif_ip6_addr_state(netif, 0))) && (memcmp(netif->hwaddr, src_mac, netif->hwaddr_len) == 0) && + (memcmp(netif->hwaddr, dst_mac, netif->hwaddr_len) != 0)) + { +#ifdef WIFI_DEBUG_ENABLED + SILABS_LOG("%s: DROP, [%02x:%02x:%02x:%02x:%02x:%02x]<-[%02x:%02x:%02x:%02x:%02x:%02x] type=%02x%02x", __func__, + + dst_mac[0], dst_mac[1], dst_mac[2], dst_mac[3], dst_mac[4], dst_mac[5], + + src_mac[0], src_mac[1], src_mac[2], src_mac[3], src_mac[4], src_mac[5], + + b[12], b[13]); +#endif + return; + } + + /* We allocate a pbuf chain of pbufs from the Lwip buffer pool + * and copy the data to the pbuf chain + */ + if ((p = pbuf_alloc(PBUF_RAW, len, PBUF_POOL)) != STRUCT_PBUF) + { + for (q = p, bufferoffset = 0; q != NULL; q = q->next) + { + memcpy((uint8_t *) q->payload, (uint8_t *) b + bufferoffset, q->len); + bufferoffset += q->len; + } +#ifdef WIFI_DEBUG_ENABLED + SILABS_LOG("%s: ACCEPT %d, [%02x:%02x:%02x:%02x:%02x:%02x]<-[%02x:%02x:%02x:%02x:%02x:%02x] type=%02x%02x", __func__, + bufferoffset, + + dst_mac[0], dst_mac[1], dst_mac[2], dst_mac[3], dst_mac[4], dst_mac[5], + + src_mac[0], src_mac[1], src_mac[2], src_mac[3], src_mac[4], src_mac[5], + + b[12], b[13]); +#endif + + if (netif->input(p, netif) != ERR_OK) + { + gOverrunCount++; + SILABS_LOG("overrun count entering when fail to alloc value %d", gOverrunCount); + pbuf_free(p); + } + } + else + { + gOverrunCount++; + SILABS_LOG("overrun count entering when fail to alloc value %d", gOverrunCount); + } +} + +static SemaphoreHandle_t ethout_sem; +/***************************************************************************** + * @fn static err_t low_level_output(struct netif *netif, struct pbuf *p) + * @brief + * This function is called from LWIP task when LWIP stack + * has some data to be forwarded over WiFi Network + * + * @param[in] netif: lwip network interface + * + * @param[in] p: the packet to send + * + * @return + * ERR_OK if successful + ******************************************************************************/ +static err_t low_level_output(struct netif * netif, struct pbuf * p) +{ + void * rsipkt; + struct pbuf * q; + uint16_t framelength; + + if (xSemaphoreTake(ethout_sem, portMAX_DELAY) != pdTRUE) + { + return ERR_IF; + } +#ifdef WIFI_DEBUG_ENABLED + SILABS_LOG("EN-RSI: Output"); +#endif + if ((netif->flags & (NETIF_FLAG_LINK_UP | NETIF_FLAG_UP)) != (NETIF_FLAG_LINK_UP | NETIF_FLAG_UP)) + { + SILABS_LOG("EN-RSI:NOT UP"); + xSemaphoreGive(ethout_sem); + return ERR_IF; + } + /* Confirm if packet is allocated */ + rsipkt = wfx_rsi_alloc_pkt(); + if (!rsipkt) + { + SILABS_LOG("EN-RSI:No buf"); + xSemaphoreGive(ethout_sem); + return ERR_IF; + } + +#ifdef WIFI_DEBUG_ENABLED + uint8_t * b = (uint8_t *) p->payload; + SILABS_LOG("EN-RSI: Out [%02x:%02x:%02x:%02x:%02x:%02x][%02x:%02x:%02x:%02x:%02x:%02x]type=%02x%02x", b[0], b[1], b[2], b[3], + b[4], b[5], b[6], b[7], b[8], b[9], b[10], b[11], b[12], b[13]); +#endif + /* Generate the packet */ + for (q = p, framelength = 0; q != NULL; q = q->next) + { + wfx_rsi_pkt_add_data(rsipkt, (uint8_t *) (q->payload), (uint16_t) q->len, framelength); + framelength += q->len; + } + if (framelength < LWIP_FRAME_ALIGNMENT) + { + /* Add junk data to the end for frame alignment if framelength is less than 60 */ + wfx_rsi_pkt_add_data(rsipkt, (uint8_t *) (p->payload), LWIP_FRAME_ALIGNMENT - framelength, framelength); + } +#ifdef WIFI_DEBUG_ENABLED + SILABS_LOG("EN-RSI: Sending %d", framelength); +#endif + + /* forward the generated packet to RSI to + * send the data over wifi network + */ + if (wfx_rsi_send_data(rsipkt, framelength)) + { + SILABS_LOG("*ERR*EN-RSI:Send fail"); + xSemaphoreGive(ethout_sem); + return ERR_IF; + } + +#ifdef WIFI_DEBUG_ENABLED + SILABS_LOG("EN-RSI:Xmit %d", framelength); +#endif + xSemaphoreGive(ethout_sem); + + return ERR_OK; +} + +/***************************************************************************** + * @fn void wfx_host_received_sta_frame_cb(uint8_t *buf, int len) + * @brief + * host received frame cb + * + * @param[in] buf: buffer + * + * @param[in] len: length + * + * @return + * None + ******************************************************************************/ +void wfx_host_received_sta_frame_cb(uint8_t * buf, int len) +{ + struct netif * ifp; + + /* get the network interface for STATION interface, + * and forward the received frame buffer to LWIP + */ + if ((ifp = wfx_get_netif(SL_WFX_STA_INTERFACE)) != (struct netif *) 0) + { + low_level_input(ifp, buf, len); + } +} + +/***************************************************************************** + * @fn err_t sta_ethernetif_init(struct netif *netif) + * @brief + * sta ethernet if initialization + * + * @param[in] netif: the lwip network interface structure + * + * @return + * ERR_OK if successful + ******************************************************************************/ +err_t sta_ethernetif_init(struct netif * netif) +{ + LWIP_ASSERT("netif != NULL", (netif != NULL)); + + /* Set the netif name to identify the interface */ + netif->name[0] = STATION_NETIF0; + netif->name[1] = STATION_NETIF1; + +#if LWIP_IPV4 && LWIP_ARP + netif->output = etharp_output; +#endif /* #if LWIP_IPV4 && LWIP_ARP */ +#if LWIP_IPV6 && LWIP_ETHERNET + netif->output_ip6 = ethip6_output; +#endif /* LWIP_IPV6 && LWIP_ETHERNET */ + netif->linkoutput = low_level_output; + + /* initialize the hardware */ + low_level_init(netif); + + /* Need single output only */ + ethout_sem = xSemaphoreCreateBinaryStatic(&xEthernetIfSemaBuffer); + xSemaphoreGive(ethout_sem); + + return ERR_OK; +} diff --git a/src/platform/silabs/SiWx917/wifi/ethernetif.h b/src/platform/silabs/SiWx917/wifi/ethernetif.h new file mode 100644 index 00000000000000..bac51b9258cd85 --- /dev/null +++ b/src/platform/silabs/SiWx917/wifi/ethernetif.h @@ -0,0 +1,49 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +#include "lwip/err.h" +#include "lwip/netif.h" +#ifdef __cplusplus +extern "C" { +#endif +/*************************************************************************** + * @fn err_t sta_ethernetif_init(struct netif *netif) + * @brief + * Sets up the station network interface. + * + * @param netif the lwip network interface structure + * @returns ERR_OK if successful + ******************************************************************************/ +err_t sta_ethernetif_init(struct netif * netif); + +/*************************************************************************** + * @fn err_t ap_ethernetif_init(struct netif *netif + * @brief + * Sets up the AP network interface. + * + * @param netif the lwip network interface structure + * @returns ERR_OK if successful + ******************************************************************************/ +err_t ap_ethernetif_init(struct netif * netif); + +void wfx_host_received_sta_frame_cb(uint8_t * buf, int len); + +#ifdef __cplusplus +} +#endif diff --git a/src/platform/silabs/SiWx917/wifi/lwip_netif.cpp b/src/platform/silabs/SiWx917/wifi/lwip_netif.cpp new file mode 100644 index 00000000000000..913f5895a94e53 --- /dev/null +++ b/src/platform/silabs/SiWx917/wifi/lwip_netif.cpp @@ -0,0 +1,153 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef RS911X_SOCKETS +#include +#include +#include + +#include "wfx_host_events.h" +#include "wifi_config.h" + +#include "AppConfig.h" +#include "dhcp_client.h" +#include "ethernetif.h" + +#include "FreeRTOS.h" +#include "event_groups.h" +#include "task.h" + +#include +using namespace ::chip; +using namespace ::chip::DeviceLayer; +static struct netif sta_netif; + +#ifdef SL_WFX_CONFIG_SOFTAP +static struct netif ap_netif; +#endif + +/**************************************************************************** + * @fn static void netif_config(struct netif *sta_if, struct netif *ap_if) + * @brief + * netif configuration + * @param[in] sta_if: + * @param[in] ap_if: + * @return None + *****************************************************************************/ +static void netif_config(struct netif * sta_if, struct netif * ap_if) +{ + if (sta_if != NULL) + { +#if LWIP_IPV4 + ip_addr_t sta_ipaddr; + ip_addr_t sta_netmask; + ip_addr_t sta_gw; + + /* Initialize the Station information */ + ip_addr_set_zero_ip4(&sta_ipaddr); + ip_addr_set_zero_ip4(&sta_netmask); + ip_addr_set_zero_ip4(&sta_gw); +#endif /* LWIP_IPV4 */ + + /* Add station interfaces */ + netif_add(sta_if, +#if LWIP_IPV4 + (const ip4_addr_t *) &sta_ipaddr, (const ip4_addr_t *) &sta_netmask, (const ip4_addr_t *) &sta_gw, +#endif /* LWIP_IPV4 */ + NULL, &sta_ethernetif_init, &tcpip_input); + + /* Registers the default network interface */ + netif_set_default(sta_if); + } +} + +/**************************************************************************** + * @fn void wfx_lwip_set_sta_link_up(void) + * @brief + * Set station link status to up. + * @param[in] None + * @return None + *****************************************************************************/ +void wfx_lwip_set_sta_link_up(void) +{ + netifapi_netif_set_up(&sta_netif); + netifapi_netif_set_link_up(&sta_netif); +#if LWIP_IPV4 && LWIP_DHCP + dhcpclient_set_link_state(LINK_UP); +#endif /* LWIP_IPV4 && LWIP_DHCP */ + /* + * Enable IPV6 + */ + +#if LWIP_IPV6_AUTOCONFIG + sta_netif.ip6_autoconfig_enabled = 1; +#endif /* LWIP_IPV6_AUTOCONFIG */ + netif_create_ip6_linklocal_address(&sta_netif, MAC_48_BIT_SET); +} + +/*************************************************************************** + * @fn void wfx_lwip_set_sta_link_down(void) + * @brief + * Set station link status to down. + * @param[in] None + * @return None + *****************************************************************************/ +void wfx_lwip_set_sta_link_down(void) +{ +#if LWIP_IPV4 && LWIP_DHCP + dhcpclient_set_link_state(LINK_DOWN); +#endif /* LWIP_IPV4 && LWIP_DHCP */ + netifapi_netif_set_link_down(&sta_netif); + netifapi_netif_set_down(&sta_netif); +} + +/*************************************************************************** + * @fn void wfx_lwip_start(void) + * @brief + * Initialize the LwIP stack + * @param[in] None + * @return None + *****************************************************************************/ +void wfx_lwip_start(void) +{ + /* Initialize the LwIP stack */ + netif_config(&sta_netif, NULL); +} + +/*************************************************************************** + * @fn struct netif *wfx_get_netif(sl_wfx_interface_t interface) + * @brief + * get the netif + * @param[in] interface: + * @return None + *****************************************************************************/ +struct netif * wfx_get_netif(sl_wfx_interface_t interface) +{ + if (interface == SL_WFX_STA_INTERFACE) + { + return &sta_netif; + } +#ifdef SL_WFX_CONFIG_SOFTAP + else if (interface == SL_WFX_SOFTAP_INTERFACE) + { + return &ap_netif; + } +#endif + return (struct netif *) 0; +} + +#endif /* RS911X_SOCKETS */ diff --git a/src/platform/silabs/SiWx917/wifi/wfx_host_events.h b/src/platform/silabs/SiWx917/wifi/wfx_host_events.h new file mode 100644 index 00000000000000..66e161d5f3b8cf --- /dev/null +++ b/src/platform/silabs/SiWx917/wifi/wfx_host_events.h @@ -0,0 +1,282 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +#include "stdbool.h" +#include "wfx_msgs.h" + +/* Wi-Fi events*/ +#define SL_WFX_STARTUP_IND_ID 1 +#define SL_WFX_CONNECT_IND_ID 2 +#define SL_WFX_DISCONNECT_IND_ID 3 +#define SL_WFX_SCAN_COMPLETE_ID 4 +#define WFX_RSI_SSID_SIZE 64 + +#ifndef RS911X_SOCKETS +/* LwIP includes. */ +#include "lwip/apps/httpd.h" +#include "lwip/ip_addr.h" +#include "lwip/netif.h" +#include "lwip/netifapi.h" +#include "lwip/tcpip.h" + +/* Wi-Fi bitmask events - for the task */ +#define SL_WFX_CONNECT (1 << 1) +#define SL_WFX_DISCONNECT (1 << 2) +#define SL_WFX_START_AP (1 << 3) +#define SL_WFX_STOP_AP (1 << 4) +#define SL_WFX_SCAN_START (1 << 5) +#define SL_WFX_SCAN_COMPLETE (1 << 6) +#define SL_WFX_RETRY_CONNECT (1 << 7) + +#endif /* RS911X_SOCKETS */ + +#include "sl_status.h" + +#define WLAN_TASK_STACK_SIZE 1024 +#define WLAN_TASK_PRIORITY 3 +#define WLAN_DRIVER_TASK_PRIORITY 2 +#define MAX_JOIN_RETRIES_COUNT 5 + +// WLAN related Macros +#define ETH_FRAME 0 +#define CMP_SUCCESS 0 +#define BSSID_MAX_STR_LEN 6 +#define MAC_ADDRESS_FIRST_OCTET 6 +#define AP_START_SUCCESS 0 +#define BITS_TO_WAIT 0 +#define CONNECTION_STATUS_SUCCESS 1 +#define IP_STATUS_FAIL 0 +#define GET_IPV6_SUCCESS 1 +#define GET_IPV6_FAIL 0 +#define BEACON_1 0 +#define CHANNEL_LIST (const uint8_t *) 0 +#define CHANNEL_COUNT 0 +#define IE_DATA (const uint8_t *) 0 +#define IE_DATA_LENGTH 0 +#define BSSID_SCAN (const uint8_t *) 0 +#define CHANNEL_0 0 +#define PREVENT_ROAMING 1 +#define DISABLE_PMF_MODE 0 +#define STA_IP_FAIL 0 +#define IP_STATUS_SUCCESS 1 +#define ACTIVE_CHANNEL_TIME_100 100 +#define PASSIVE_CHANNEL_TIME_0 0 +#define PROBE_NUM_REQ_1 1 + +#define PINOUT_CLEAR_STATUS 0 +#define TICKS_TO_WAIT_0 0 +#define TICKS_TO_WAIT_3 3 +#define TICKS_TO_WAIT_1 1 +#define TICKS_TO_WAIT_500 500 + +// TASK and Interrupt Macros +#define SUCCESS_STATUS 1 +#define LINK_UP 1 +#define LINK_DOWN 0 +#define MAC_48_BIT_SET 1 +#define STRUCT_PBUF (struct pbuf *) 0 +#define PRIORITY_0 0 +#define HEX_VALUE_FF 0XFF + +// Timer Delay +#define MAX_XLEN 16 +#define MIN_XLEN 0 +#define PINOUT_CLEAR 0 +#define PINOUT_SET 1 +#define WFX_SPI_NVIC_PRIORITY 5 +#define WFX_GPIO_NVIC_PRIORITY 5 +#define CB_VALUE (DMADRV_Callback_t) 0 + +/* TIMER_TICKS_TO_WAIT Specifies the time, in ticks, that the calling task should + * be held in the Blocked state to wait for the start command to be successfully + * sent to the timer command queue. + */ +#define TIMER_TICKS_TO_WAIT_0 0 + +#define CONVERT_SEC_TO_MSEC 1000 +#define CONVERT_USEC_TO_MSEC (1 / 1000) + +#define RSI_RESPONSE_MAX_SIZE 28 +#define RSI_RESPONSE_HOLD_BUFF_SIZE 128 +#define RSI_DRIVER_STATUS 0 +#define OPER_MODE_0 0 +#define COEX_MODE_0 0 +#define RESP_BUFF_SIZE 6 +#define AP_CHANNEL_NO_0 0 +#define SCAN_BITMAP_OPTN_1 1 +#define IP_CONF_RSP_BUFF_LENGTH_4 4 +#define STATION 0 +#define BG_SCAN_RES_SIZE 500 + +#define SPI_CONFIG_SUCCESS 0 +#define WPA3_SECURITY 3 + +typedef enum +{ + WIFI_EVENT, + IP_EVENT, +} wfx_event_base_t; + +typedef enum +{ + IP_EVENT_STA_GOT_IP, + IP_EVENT_GOT_IP6, + IP_EVENT_STA_LOST_IP, +} ip_event_id_t; + +/* Note that these are same as RSI_security */ +typedef enum +{ + WFX_SEC_NONE = 0, + WFX_SEC_WPA = 1, + WFX_SEC_WPA2 = 2, + WFX_SEC_WEP = 3, + WFX_SEC_WPA_EAP = 4, + WFX_SEC_WPA2_EAP = 5, + WFX_SEC_WPA_WPA2_MIXED = 6, + WFX_SEC_WPA_PMK = 7, + WFX_SEC_WPA2_PMK = 8, + WFX_SEC_WPS_PIN = 9, + WFX_SEC_GEN_WPS_PIN = 10, + WFX_SEC_PUSH_BTN = 11, + WFX_SEC_WPA3 = 11, +} wfx_sec_t; + +#define WPA3_SECURITY 3 + +typedef struct +{ + char ssid[32 + 1]; + char passkey[64 + 1]; + uint8_t security; +} wfx_wifi_provision_t; + +typedef enum +{ + WIFI_MODE_NULL = 0, + WIFI_MODE_STA, + WIFI_MODE_AP, + WIFI_MODE_APSTA, + WIFI_MODE_MAX, +} wifi_mode_t; + +typedef struct wfx_wifi_scan_result +{ + char ssid[32 + 1]; + uint8_t security; + uint8_t bssid[6]; + uint8_t chan; + int16_t rssi; /* I suspect this is in dBm - so signed */ +} wfx_wifi_scan_result_t; + +typedef struct wfx_wifi_scan_ext +{ + uint32_t beacon_lost_count; + uint32_t beacon_rx_count; + uint32_t mcast_rx_count; + uint32_t mcast_tx_count; + uint32_t ucast_rx_count; + uint32_t ucast_tx_count; + uint32_t overrun_count; +} wfx_wifi_scan_ext_t; + +#ifdef RS911X_WIFI +/* + * This Sh%t is here to support WFXUtils - and the Matter stuff that uses it + * We took it from the SDK (for WF200) + */ +typedef enum +{ + SL_WFX_NOT_INIT = 0, + SL_WFX_STARTED = 1, + SL_WFX_STA_INTERFACE_CONNECTED = 2, + SL_WFX_AP_INTERFACE_UP = 3, + SL_WFX_SLEEPING = 4, + SL_WFX_POWER_SAVE_ACTIVE = 5, +} sl_wfx_state_t; + +typedef enum +{ + SL_WFX_STA_INTERFACE = 0, ///< Interface 0, linked to the station + SL_WFX_SOFTAP_INTERFACE = 1, ///< Interface 1, linked to the softap +} sl_wfx_interface_t; + +#endif /* RS911X_WIFI */ +#ifdef __cplusplus +extern "C" { +#endif + +void sl_wfx_host_gpio_init(void); +sl_status_t wfx_wifi_start(void); +void wfx_enable_sta_mode(void); +sl_wfx_state_t wfx_get_wifi_state(void); +void wfx_get_wifi_mac_addr(sl_wfx_interface_t interface, sl_wfx_mac_address_t * addr); +void wfx_set_wifi_provision(wfx_wifi_provision_t * wifiConfig); +bool wfx_get_wifi_provision(wfx_wifi_provision_t * wifiConfig); +bool wfx_is_sta_provisioned(void); +bool wfx_is_sta_mode_enabled(void); +int32_t wfx_get_ap_info(wfx_wifi_scan_result_t * ap); +int32_t wfx_get_ap_ext(wfx_wifi_scan_ext_t * extra_info); +int32_t wfx_reset_counts(); +int32_t wfx_rsi_platform(); + +void wfx_clear_wifi_provision(void); +sl_status_t wfx_connect_to_ap(void); +void wfx_setup_ip6_link_local(sl_wfx_interface_t); +bool wfx_is_sta_connected(void); +sl_status_t wfx_sta_discon(void); +#if CHIP_DEVICE_CONFIG_ENABLE_IPV4 +bool wfx_have_ipv4_addr(sl_wfx_interface_t); +#endif /* CHIP_DEVICE_CONFIG_ENABLE_IPV4 */ +bool wfx_have_ipv6_addr(sl_wfx_interface_t); +wifi_mode_t wfx_get_wifi_mode(void); +bool wfx_start_scan(char * ssid, void (*scan_cb)(wfx_wifi_scan_result_t *)); /* true returned if successfully started */ +void wfx_cancel_scan(void); + +/* + * Call backs into the Matter Platform code + */ +void wfx_started_notify(void); +void wfx_connected_notify(int32_t status, sl_wfx_mac_address_t * ap); +void wfx_disconnected_notify(int32_t status); +/* Implemented for LWIP */ +void wfx_host_received_sta_frame_cb(uint8_t * buf, int len); +void wfx_lwip_set_sta_link_up(void); +void wfx_lwip_set_sta_link_down(void); +void wfx_lwip_start(void); +struct netif * wfx_get_netif(sl_wfx_interface_t interface); +#if CHIP_DEVICE_CONFIG_ENABLE_IPV4 +void wfx_dhcp_got_ipv4(uint32_t); +#endif /* CHIP_DEVICE_CONFIG_ENABLE_IPV4 */ +bool wfx_hw_ready(void); +#if CHIP_DEVICE_CONFIG_ENABLE_IPV4 +void wfx_ip_changed_notify(int got_ip); +#endif /* CHIP_DEVICE_CONFIG_ENABLE_IPV4 */ +void wfx_ipv6_notify(int got_ip); + +#ifdef RS911X_WIFI +/* RSI for LWIP */ +void * wfx_rsi_alloc_pkt(void); +void wfx_rsi_pkt_add_data(void * p, uint8_t * buf, uint16_t len, uint16_t off); +int32_t wfx_rsi_send_data(void * p, uint16_t len); +#endif /* RS911X_WIFI */ + +#ifdef __cplusplus +} +#endif diff --git a/src/platform/silabs/SiWx917/wifi/wfx_msgs.h b/src/platform/silabs/SiWx917/wifi/wfx_msgs.h new file mode 100644 index 00000000000000..edf0aec5828fa7 --- /dev/null +++ b/src/platform/silabs/SiWx917/wifi/wfx_msgs.h @@ -0,0 +1,182 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef _WFX_MSGS_H_ +#define _WFX_MSGS_H_ +/* + * Taken from sl_wfx firmware - so I can re-use. + * I need to do a better job than to use this stuff + * in the CPP files of Matter + */ +typedef struct +{ + uint8_t octet[6]; ///< Table to store a MAC address +} sl_wfx_mac_address_t; +/** + * @brief General Message header structure + * + */ +typedef struct __attribute__((__packed__)) sl_wfx_header_s +{ + uint16_t length; ///< Message length in bytes including this uint16_t. + ///< Maximum value is 8188 but maximum Request size is FW dependent and reported in the + ///< ::sl_wfx_startup_ind_body_t::size_inp_ch_buf. + uint8_t id; ///< Contains the message Id indexed by sl_wfx_general_commands_ids_t or sl_wfx_message_ids_t. + uint8_t info; ///< TODO comment missing +} sl_wfx_header_t; + +/** + * @brief Generic message structure for all requests, confirmations and indications + * + */ +typedef struct __attribute__((__packed__)) sl_wfx_generic_message_s +{ + sl_wfx_header_t header; ///< 4 bytes header + uint8_t body[]; ///< variable size payload of the message +} sl_wfx_generic_message_t; +#define SL_WFX_OPN_SIZE 14 +#define SL_WFX_UID_SIZE 8 +#define SL_WFX_DISABLED_CHANNEL_LIST_SIZE 2 +#define SL_WFX_FIRMWARE_LABEL_SIZE 128 +/** + * @brief Startup Indication message. + * This is the first message sent to the host to confirm boot success. + * It gives detailed information on the HW and FW versions and capabilities + */ +typedef struct __attribute__((__packed__)) sl_wfx_startup_ind_body_s +{ + uint32_t + status; ///< Initialization status. A value of zero indicates the boot is completed successfully (see enum sl_wfx_status_t) + uint16_t hardware_id; ///<=RO misc_read_reg7 register value +#if 0 /* Not used in RS911x for now - use stuff here for the port */ + uint8_t opn[SL_WFX_OPN_SIZE]; ///<=OTP part_OPN + uint8_t uid[SL_WFX_UID_SIZE]; ///<=OTP UID + uint16_t num_inp_ch_bufs; ///WFM_STATUS_SUCCESS: the connection request was completed successfully. + *
any other value: the connection request failed. + *
See sl_wfx_fmac_status_t for enumeration values. + */ + uint32_t status; + /** + * @brief MAC address of the connected access point. + */ + uint8_t mac[6]; + /** + * @brief Channel of the connected access point. + * @details 1 - 13: Channel number. + */ + uint16_t channel; + /** + * @brief Beacon Interval of the connected access point. + */ + uint8_t beacon_interval; + /** + * @brief DTIM period of the connected access point. + * @details 1 - 255: DTIM period. + */ + uint8_t dtim_period; + /** + * @brief Maximum PHY data rate supported by the connection. + * @details See sl_wfx_rate_index_t for enumeration values. + */ + uint16_t max_phy_rate; +} sl_wfx_connect_ind_body_t; + +/** + * @brief Indication message used to signal the completion of a connection operation. + * @details The device will send this indication to signal the connection request initiated + * with sl_wfx_connect_req_t has been completed. The indication is also sent when + * the device autonomously roams to another access point. + * @ingroup WFM_GROUP_MODE_IDLE + */ +typedef struct __attribute__((__packed__)) sl_wfx_connect_ind_s +{ + /** Common message header. */ + sl_wfx_header_t header; + /** Indication message body. */ + sl_wfx_connect_ind_body_t body; +} sl_wfx_connect_ind_t; +/** + * @brief Indication message body for sl_wfx_disconnect_ind_t. + */ +typedef struct __attribute__((__packed__)) sl_wfx_disconnect_ind_body_s +{ + /** + * @brief MAC address of the access point. + */ + uint8_t mac[6]; + /** + * @brief Reason for disconnection. + * @details WFM_DISCONNECTED_REASON_UNSPECIFIED: The device disconnected because of an internal error. + *
WFM_DISCONNECTED_REASON_AP_LOST: The device lost the AP beacons for too long. + *
WFM_DISCONNECTED_REASON_REJECTED: The device was disconnected by the AP. + *
WFM_DISCONNECTED_REASON_LEAVING_BSS: Disconnection was requested through the device API. + *
WFM_DISCONNECTED_REASON_WPA_COUNTERMEASURES: WPA countermeasures triggered a disconnection + *
See sl_wfx_disconnected_reason_t for enumeration values. + */ + uint16_t reason; +} sl_wfx_disconnect_ind_body_t; + +/** + * @brief Indication message used to signal the completion of a disconnection operation. + * @details The device will send this indication to signal the disconnection request initiated + * with sl_wfx_disconnect_req_t has been completed. The indication is also sent when + * the device has lost the connection to an access point and has been unable to regain it. + * @ingroup WFM_GROUP_MODE_STA + */ +typedef struct __attribute__((__packed__)) sl_wfx_disconnect_ind_s +{ + /** Common message header. */ + sl_wfx_header_t header; + /** Indication message body. */ + sl_wfx_disconnect_ind_body_t body; +} sl_wfx_disconnect_ind_t; + +#endif /* _WFX_MSGS_H_ */ diff --git a/src/platform/silabs/SiWx917/wifi/wfx_notify.cpp b/src/platform/silabs/SiWx917/wifi/wfx_notify.cpp new file mode 100644 index 00000000000000..86bba1931446e7 --- /dev/null +++ b/src/platform/silabs/SiWx917/wifi/wfx_notify.cpp @@ -0,0 +1,182 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include +#include + +#include "AppConfig.h" + +#include "FreeRTOS.h" +#include "event_groups.h" +#include "task.h" + +#include "wfx_host_events.h" + +#ifdef RS911X_WIFI +#include "wfx_rsi.h" +#endif + +#include +//#include +#include +#include + +using namespace ::chip; +using namespace ::chip::DeviceLayer; + +/* + * Notifications to the upper-layer + * All done in the context of the RSI/WiFi task (rsi_if.c) + */ + +/*********************************************************************************** + * @fn wfx_started_notify() + * @brief + * Wifi device started notification + * @param[in]: None + * @return None + *************************************************************************************/ +void wfx_started_notify() +{ + sl_wfx_startup_ind_t evt; + sl_wfx_mac_address_t mac; + + SILABS_LOG("%s: started.", __func__); + + memset(&evt, 0, sizeof(evt)); + evt.header.id = SL_WFX_STARTUP_IND_ID; + evt.header.length = sizeof evt; + evt.body.status = 0; + wfx_get_wifi_mac_addr(SL_WFX_STA_INTERFACE, &mac); + memcpy(&evt.body.mac_addr[0], &mac.octet[0], MAC_ADDRESS_FIRST_OCTET); + + PlatformMgrImpl().HandleWFXSystemEvent(WIFI_EVENT, (sl_wfx_generic_message_t *) &evt); +} + +/*********************************************************************************** + * @fn void wfx_connected_notify(int32_t status, sl_wfx_mac_address_t *ap) + * @brief + * For now we are not notifying anything other than AP Mac - + * Other stuff such as DTIM etc. may be required for later + * @param[in] status: + * @param[in] ap: access point + * @return None + *************************************************************************************/ +void wfx_connected_notify(int32_t status, sl_wfx_mac_address_t * ap) +{ + sl_wfx_connect_ind_t evt; + + SILABS_LOG("%s: started.", __func__); + + if (status != SUCCESS_STATUS) + { + SILABS_LOG("%s: error: failed status: %d.", __func__, status); + return; + } + + SILABS_LOG("%s: connected.", __func__); + + memset(&evt, 0, sizeof(evt)); + evt.header.id = SL_WFX_CONNECT_IND_ID; + evt.header.length = sizeof evt; + +#ifdef RS911X_WIFI + evt.body.channel = wfx_rsi.ap_chan; +#endif + memcpy(&evt.body.mac[0], &ap->octet[0], MAC_ADDRESS_FIRST_OCTET); + + PlatformMgrImpl().HandleWFXSystemEvent(WIFI_EVENT, (sl_wfx_generic_message_t *) &evt); +} + +/************************************************************************************** + * @fn void wfx_disconnected_notify(int32_t status) + * @brief + * notification of disconnection + * @param[in] status: + * @return None + ********************************************************************************************/ +void wfx_disconnected_notify(int32_t status) +{ + sl_wfx_disconnect_ind_t evt; + + SILABS_LOG("%s: started.", __func__); + + memset(&evt, 0, sizeof(evt)); + evt.header.id = SL_WFX_DISCONNECT_IND_ID; + evt.header.length = sizeof evt; + evt.body.reason = status; + PlatformMgrImpl().HandleWFXSystemEvent(WIFI_EVENT, (sl_wfx_generic_message_t *) &evt); +} + +/************************************************************************************** + * @fn void wfx_ipv6_notify(int got_ip) + * @brief + * notification of ipv6 + * @param[in] got_ip: + * @return None + ********************************************************************************************/ +void wfx_ipv6_notify(int got_ip) +{ + sl_wfx_generic_message_t eventData; + + SILABS_LOG("%s: started.", __func__); + + memset(&eventData, 0, sizeof(eventData)); + eventData.header.id = got_ip ? IP_EVENT_GOT_IP6 : IP_EVENT_STA_LOST_IP; + eventData.header.length = sizeof(eventData.header); + PlatformMgrImpl().HandleWFXSystemEvent(IP_EVENT, &eventData); + + /* So the other threads can run and have the connectivity OK */ + if (got_ip) + { + /* Should remember this */ + vTaskDelay(1); + chip::DeviceLayer::PlatformMgr().LockChipStack(); + chip::app::DnssdServer::Instance().StartServer(/*Dnssd::CommissioningMode::kEnabledBasic*/); + chip::DeviceLayer::PlatformMgr().UnlockChipStack(); + } +} + +/************************************************************************************** + * @fn void wfx_ip_changed_notify(int got_ip) + * @brief + * notification of ip change + * @param[in] got_ip: + * @return None + ********************************************************************************************/ +void wfx_ip_changed_notify(int got_ip) +{ + sl_wfx_generic_message_t eventData; + + SILABS_LOG("%s: started.", __func__); + + memset(&eventData, 0, sizeof(eventData)); + eventData.header.id = got_ip ? IP_EVENT_STA_GOT_IP : IP_EVENT_STA_LOST_IP; + eventData.header.length = sizeof(eventData.header); + PlatformMgrImpl().HandleWFXSystemEvent(IP_EVENT, &eventData); + + /* So the other threads can run and have the connectivity OK */ + if (got_ip) + { + /* Should remember this */ + vTaskDelay(1); + chip::DeviceLayer::PlatformMgr().LockChipStack(); + chip::app::DnssdServer::Instance().StartServer(/*Dnssd::CommissioningMode::kEnabledBasic*/); + chip::DeviceLayer::PlatformMgr().UnlockChipStack(); + } +} diff --git a/src/platform/silabs/SiWx917/wifi/wifi_config.h b/src/platform/silabs/SiWx917/wifi/wifi_config.h new file mode 100644 index 00000000000000..88ad34b5741649 --- /dev/null +++ b/src/platform/silabs/SiWx917/wifi/wifi_config.h @@ -0,0 +1,71 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef DEMO_CONFIG_H +#define DEMO_CONFIG_H + +#define USE_DHCP_CLIENT_DEFAULT 1 ///< If defined, DHCP is enabled, otherwise static address below is used + +/************************** Station Static Default ****************************/ +#define STA_IP_ADDR0_DEFAULT (uint8_t) 192 ///< Static IP: IP address value 0 +#define STA_IP_ADDR1_DEFAULT (uint8_t) 168 ///< Static IP: IP address value 1 +#define STA_IP_ADDR2_DEFAULT (uint8_t) 0 ///< Static IP: IP address value 2 +#define STA_IP_ADDR3_DEFAULT (uint8_t) 1 ///< Static IP: IP address value 3 + +/*NETMASK*/ +#define STA_NETMASK_ADDR0_DEFAULT (uint8_t) 255 ///< Static IP: Netmask value 0 +#define STA_NETMASK_ADDR1_DEFAULT (uint8_t) 255 ///< Static IP: Netmask value 1 +#define STA_NETMASK_ADDR2_DEFAULT (uint8_t) 255 ///< Static IP: Netmask value 2 +#define STA_NETMASK_ADDR3_DEFAULT (uint8_t) 0 ///< Static IP: Netmask value 3 + +/*Gateway Address*/ +#define STA_GW_ADDR0_DEFAULT (uint8_t) 0 ///< Static IP: Gateway value 0 +#define STA_GW_ADDR1_DEFAULT (uint8_t) 0 ///< Static IP: Gateway value 1 +#define STA_GW_ADDR2_DEFAULT (uint8_t) 0 ///< Static IP: Gateway value 2 +#define STA_GW_ADDR3_DEFAULT (uint8_t) 0 ///< Static IP: Gateway value 3 + +/************************** Access Point Static Default ****************************/ +// #define AP_IP_ADDR0_DEFAULT (uint8_t) 10 ///< Static IP: IP address value 0 +// #define AP_IP_ADDR1_DEFAULT (uint8_t) 10 ///< Static IP: IP address value 1 +// #define AP_IP_ADDR2_DEFAULT (uint8_t) 0 ///< Static IP: IP address value 2 +// #define AP_IP_ADDR3_DEFAULT (uint8_t) 1 ///< Static IP: IP address value 3 + +/*NETMASK*/ +// #define AP_NETMASK_ADDR0_DEFAULT (uint8_t) 255 ///< Static IP: Netmask value 0 +// #define AP_NETMASK_ADDR1_DEFAULT (uint8_t) 255 ///< Static IP: Netmask value 1 +// #define AP_NETMASK_ADDR2_DEFAULT (uint8_t) 255 ///< Static IP: Netmask value 2 +// #define AP_NETMASK_ADDR3_DEFAULT (uint8_t) 0 ///< Static IP: Netmask value 3 + +/*Gateway Address*/ +// #define AP_GW_ADDR0_DEFAULT (uint8_t) 0 ///< Static IP: Gateway value 0 +// #define AP_GW_ADDR1_DEFAULT (uint8_t) 0 ///< Static IP: Gateway value 1 +// #define AP_GW_ADDR2_DEFAULT (uint8_t) 0 ///< Static IP: Gateway value 2 +// #define AP_GW_ADDR3_DEFAULT (uint8_t) 0 ///< Static IP: Gateway value 3 + +#define WLAN_SSID_DEFAULT "AP_name" ///< wifi ssid for client mode +#define WLAN_PASSKEY_DEFAULT "passkey" ///< wifi password for client mode +#define WLAN_SECURITY_DEFAULT WFM_SECURITY_MODE_WPA2_PSK ///< wifi security mode for client mode: +///< WFM_SECURITY_MODE_OPEN/WFM_SECURITY_MODE_WEP/WFM_SECURITY_MODE_WPA2_WPA1_PSK + +#define SOFTAP_SSID_DEFAULT "silabs_softap" ///< wifi ssid for soft ap mode +#define SOFTAP_PASSKEY_DEFAULT "changeme" ///< wifi password for soft ap mode +#define SOFTAP_SECURITY_DEFAULT WFM_SECURITY_MODE_WPA2_PSK ///< wifi security for soft ap mode: +///< WFM_SECURITY_MODE_OPEN/WFM_SECURITY_MODE_WEP/WFM_SECURITY_MODE_WPA2_WPA1_PSK + +#define SOFTAP_CHANNEL_DEFAULT 6 ///< wifi channel for soft ap + +#endif // DEMO_CONFIG_H diff --git a/src/platform/silabs/SiWx917/wifi_args.gni b/src/platform/silabs/SiWx917/wifi_args.gni new file mode 100644 index 00000000000000..88d554d2f1040b --- /dev/null +++ b/src/platform/silabs/SiWx917/wifi_args.gni @@ -0,0 +1,53 @@ +# Copyright (c) 2021 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/build.gni") +import("//build_overrides/chip.gni") +import("//build_overrides/efr32_sdk.gni") +import("//build_overrides/pigweed.gni") + +import("${chip_root}/examples/platform/silabs/SiWx917/args.gni") +import("${chip_root}/src/crypto/crypto.gni") + +# ARM architecture flags will be set based on silabs_family. +arm_platform_config = "${efr32_sdk_build_root}/efr32_arm.gni" + +mbedtls_target = "${efr32_sdk_build_root}:efr32_sdk" + +# Transitional CommissionableDataProvider not used anymore +# examples/platform/efr32/EFR32DeviceDataProvider is now used. +chip_use_transitional_commissionable_data_provider = false + +#lwip_platform = "external" +lwip_platform = "efr32" +lwip_ipv6 = true +lwip_ipv4 = true +lwip_api = true +lwip_ethernet = true + +chip_device_platform = "SiWx917" +chip_enable_openthread = false +chip_inet_config_enable_ipv4 = true +chip_inet_config_enable_dns_resolver = false +chip_inet_config_enable_tcp_endpoint = true + +chip_build_tests = false +chip_config_memory_management = "platform" +chip_mdns = "minimal" +chip_enable_pw_rpc = false + +pw_build_LINK_DEPS = [ + "$dir_pw_assert:impl", + "$dir_pw_log:impl", +] diff --git a/src/platform/telink/BLEManagerImpl.cpp b/src/platform/telink/BLEManagerImpl.cpp index d07b2ca3a30459..d22a2a8ddbec08 100644 --- a/src/platform/telink/BLEManagerImpl.cpp +++ b/src/platform/telink/BLEManagerImpl.cpp @@ -18,31 +18,32 @@ /** * @file * Provides an implementation of the BLEManager singleton object - * for the Telink platform. + * for Telink platforms. */ -/* this file behaves like a config.h, comes first */ + #include #if CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE -#include -#include -#include +#include +#include #include #include +#include +#include +#if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING +#include +#endif -/*Includes for ieee802154 switchings */ -#define DT_DRV_COMPAT telink_b91_zb -#include -#include +#include +#include +#include +#include +#include -/* Telink headers */ -#include "drivers.h" -#include "ext_driver/ext_misc.h" -#include "stack/ble/ble.h" -#include "tl_common.h" -#include "types.h" +// Includes for ieee802154 switchings +#include using namespace ::chip; using namespace ::chip::Ble; @@ -54,80 +55,16 @@ namespace Internal { namespace { -typedef enum -{ - ATT_H_START = 0, - - /* GAP service */ - GenericAccess_PS_H, // UUID: 2800, VALUE: uuid 1800 - GenericAccess_DeviceName_CD_H, // UUID: 2803, VALUE: Prop: Read | Notify - GenericAccess_DeviceName_DP_H, // UUID: 2A00, VALUE: device name - GenericAccess_Appearance_CD_H, // UUID: 2803, VALUE: Prop: Read - GenericAccess_Appearance_DP_H, // UUID: 2A01, VALUE: appearance - CONN_PARAM_CD_H, // UUID: 2803, VALUE: Prop: Read - CONN_PARAM_DP_H, // UUID: 2A04, VALUE: connParameter - - /* GATT service */ - GenericAttribute_PS_H, // UUID: 2800, VALUE: uuid 1801 - GenericAttribute_ServiceChanged_CD_H, // UUID: 2803, VALUE: Prop: Indicate - GenericAttribute_ServiceChanged_DP_H, // UUID: 2A05, VALUE: service change - GenericAttribute_ServiceChanged_CCB_H, // UUID: 2902, VALUE: serviceChangeCCC - - /* Matter service */ - Matter_PS_H, - Matter_RX_CD_H, - Matter_RX_DP_H, - Matter_TX_CD_H, - Matter_TX_DP_H, - Matter_TX_CCC_H, - - ATT_END_H, - -} ATT_HANDLE; - -typedef struct -{ - /** Minimum value for the connection event (interval. 0x0006 - 0x0C80 * 1.25 ms) */ - u16 intervalMin; - /** Maximum value for the connection event (interval. 0x0006 - 0x0C80 * 1.25 ms) */ - u16 intervalMax; - /** Number of LL latency connection events (0x0000 - 0x03e8) */ - u16 latency; - /** Connection Timeout (0x000A - 0x0C80 * 10 ms) */ - u16 timeout; -} gap_periConnectParams_t; - -#define CHIP_MAC_LEN 6 -#define CHIP_MTU_SIZE 244 -#define CHIP_MAX_ADV_DATA_LEN 31 -#define CHIP_MAX_RESPONSE_DATA_LEN 31 -#define CHIP_SHORT_UUID_LEN 2 - -#define CHIP_ADE_DATA_LEN_FLAGS 0x02 -#define CHIP_ADV_DATA_TYPE_FLAGS 0x01 -#define CHIP_ADV_DATA_FLAGS 0x06 -#define CHIP_ADV_DATA_TYPE_UUID 0x03 -#define CHIP_ADV_DATA_TYPE_NAME 0x09 -#define CHIP_ADV_DATA_TYPE_SERVICE_DATA 0x16 -#define CHIP_ADV_SERVICE_DATA_LEN (sizeof(ChipBLEDeviceIdentificationInfo) + CHIP_SHORT_UUID_LEN + 1) - -#define CHIP_BLE_TX_FIFO_SIZE 48 -#define CHIP_BLE_TX_FIFO_NUM 33 -#define CHIP_BLE_RX_FIFO_SIZE 48 -#define CHIP_BLE_RX_FIFO_NUM 8 - -#define CHIP_BLE_THREAD_STACK_SIZE 2048 -#define CHIP_BLE_THREAD_PRIORITY 2 - -#define CHIP_BLE_DISCONNECT_REASON 8 - -#define CHIP_RF_PACKET_HEADER_SIZE 3 - -#define STIMER_IRQ_NUM 1 -#define RF_IRQ_NUM 15 - -#define CHIP_RX_CHAR_UUID 0x11, 0x9D, 0x9F, 0x42, 0x9C, 0x4F, 0x9F, 0x95, 0x59, 0x45, 0x3D, 0x26, 0xF5, 0x2E, 0xEE, 0x18 -#define CHIP_TX_CHAR_UUID 0x12, 0x9D, 0x9F, 0x42, 0x9C, 0x4F, 0x9F, 0x95, 0x59, 0x45, 0x3D, 0x26, 0xF5, 0x2E, 0xEE, 0x18 +const bt_uuid_128 UUID128_CHIPoBLEChar_RX = + BT_UUID_INIT_128(0x11, 0x9D, 0x9F, 0x42, 0x9C, 0x4F, 0x9F, 0x95, 0x59, 0x45, 0x3D, 0x26, 0xF5, 0x2E, 0xEE, 0x18); +const bt_uuid_128 UUID128_CHIPoBLEChar_TX = + BT_UUID_INIT_128(0x12, 0x9D, 0x9F, 0x42, 0x9C, 0x4F, 0x9F, 0x95, 0x59, 0x45, 0x3D, 0x26, 0xF5, 0x2E, 0xEE, 0x18); +#if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING +const bt_uuid_128 UUID128_CHIPoBLEChar_C3 = + BT_UUID_INIT_128(0x04, 0x8F, 0x21, 0x83, 0x8A, 0x74, 0x7D, 0xB8, 0xF2, 0x45, 0x72, 0x87, 0x38, 0x02, 0x63, 0x64); +#endif + +bt_uuid_16 UUID16_CHIPoBLEService = BT_UUID_INIT_16(0xFFF6); const ChipBleUUID chipUUID_CHIPoBLEChar_RX = { { 0x18, 0xEE, 0x2E, 0xF5, 0x26, 0x3D, 0x45, 0x59, 0x95, 0x9F, 0x4F, 0x9C, 0x42, 0x9F, 0x9D, 0x11 } }; @@ -135,39 +72,80 @@ const ChipBleUUID chipUUID_CHIPoBLEChar_RX = { { 0x18, 0xEE, 0x2E, 0xF5, 0x26, 0 const ChipBleUUID chipUUID_CHIPoBLEChar_TX = { { 0x18, 0xEE, 0x2E, 0xF5, 0x26, 0x3D, 0x45, 0x59, 0x95, 0x9F, 0x4F, 0x9C, 0x42, 0x9F, 0x9D, 0x12 } }; -static const uint8_t matterServiceUUID[CHIP_SHORT_UUID_LEN] = { 0xF6, 0xFF }; // service UUID +_bt_gatt_ccc CHIPoBLEChar_TX_CCC = BT_GATT_CCC_INITIALIZER(nullptr, BLEManagerImpl::HandleTXCCCWrite, nullptr); + +// clang-format off + +struct bt_gatt_attr sChipoBleAttributes[] = { + BT_GATT_PRIMARY_SERVICE(&UUID16_CHIPoBLEService.uuid), + BT_GATT_CHARACTERISTIC(&UUID128_CHIPoBLEChar_RX.uuid, + BT_GATT_CHRC_WRITE | BT_GATT_CHRC_WRITE_WITHOUT_RESP, + BT_GATT_PERM_READ | BT_GATT_PERM_WRITE, + nullptr, BLEManagerImpl::HandleRXWrite, nullptr), + BT_GATT_CHARACTERISTIC(&UUID128_CHIPoBLEChar_TX.uuid, + BT_GATT_CHRC_INDICATE, + BT_GATT_PERM_NONE, + nullptr, nullptr, nullptr), + BT_GATT_CCC_MANAGED(&CHIPoBLEChar_TX_CCC, BT_GATT_PERM_READ | BT_GATT_PERM_WRITE), +#if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING + BT_GATT_CHARACTERISTIC(&UUID128_CHIPoBLEChar_C3.uuid, + BT_GATT_CHRC_READ, + BT_GATT_PERM_READ, + BLEManagerImpl::HandleC3Read, nullptr, nullptr), +#endif +}; -} // unnamed namespace +struct bt_gatt_service sChipoBleService = BT_GATT_SERVICE(sChipoBleAttributes); -BLEManagerImpl BLEManagerImpl::sInstance; +// clang-format on -void rf_irq_handler(const void * paramiter) -{ - irq_blt_sdk_handler(); -} +// Index of the CCC descriptor in the CHIPoBLE_Service array of attributes. +// This value should be adjusted accordingly if the service declaration changes. +constexpr int kCHIPoBLE_CCC_AttributeIndex = 3; -void stimer_irq_handler(const void * paramiter) +CHIP_ERROR InitRandomStaticAddress() { - irq_blt_sdk_handler(); -} + // Generate a random static address for the default identity. + // This must be done before bt_enable() as after that updating the default identity is not possible. + int error = 0; + bt_addr_le_t addr; -void BLEManagerImpl::BleEntry(void *, void *, void *) -{ - while (true) + // generating the address + addr.type = BT_ADDR_LE_RANDOM; + error = sys_csrand_get(addr.a.val, sizeof(addr.a.val)); + BT_ADDR_SET_STATIC(&addr.a); + + if (error) { - blt_sdk_main_loop(); + ChipLogError(DeviceLayer, "Failed to create BLE address: %d", error); + return System::MapErrorZephyr(error); + } - k_msleep(10); + error = bt_id_create(&addr, nullptr); + + if (error < 0) + { + ChipLogError(DeviceLayer, "Failed to create BLE identity: %d", error); + return System::MapErrorZephyr(error); } + + ChipLogProgress(DeviceLayer, "BLE address: %02X:%02X:%02X:%02X:%02X:%02X", addr.a.val[5], addr.a.val[4], addr.a.val[3], + addr.a.val[2], addr.a.val[1], addr.a.val[0]); + return CHIP_NO_ERROR; } -/* Thread for running BLE main loop */ -K_THREAD_DEFINE(chipBleThread, CHIP_BLE_THREAD_STACK_SIZE, BLEManagerImpl::BleEntry, NULL, NULL, NULL, CHIP_BLE_THREAD_PRIORITY, 0, - 0); +} // unnamed namespace + +BLEManagerImpl BLEManagerImpl::sInstance; + +bool ThreadConnectivityReady; +bool BLERadioInitialized; CHIP_ERROR BLEManagerImpl::_Init() { ThreadConnectivityReady = false; + BLERadioInitialized = false; + mconId = NULL; mServiceMode = ConnectivityManager::kCHIPoBLEServiceMode_Enabled; mFlags.ClearAll().Set(Flags::kAdvertisingEnabled, CHIP_DEVICE_CONFIG_CHIPOBLE_ENABLE_ADVERTISING_AUTOSTART); @@ -176,11 +154,20 @@ CHIP_ERROR BLEManagerImpl::_Init() memset(mSubscribedConns, 0, sizeof(mSubscribedConns)); + ReturnErrorOnFailure(InitRandomStaticAddress()); + // int err = bt_enable(NULL); // Can't init BLE stack here due to abscense of non-cuncurrent mode + // VerifyOrReturnError(err == 0, MapErrorZephyr(err)); + + memset(&mConnCallbacks, 0, sizeof(mConnCallbacks)); + mConnCallbacks.connected = HandleConnect; + mConnCallbacks.disconnected = HandleDisconnect; + + bt_conn_cb_register(&mConnCallbacks); + // Initialize the CHIP BleLayer. ReturnErrorOnFailure(BleLayer::Init(this, this, &DeviceLayer::SystemLayer())); - // Suspend BLE Task - k_thread_suspend(chipBleThread); + PlatformMgr().ScheduleWork(DriveBLEState, 0); return CHIP_NO_ERROR; } @@ -225,6 +212,20 @@ void BLEManagerImpl::DriveBLEState() err = StopAdvertising(); SuccessOrExit(err); } + + // If no connections are active unregister also CHIPoBLE GATT service + if (NumConnections() == 0 && mFlags.Has(Flags::kChipoBleGattServiceRegister)) + { + // Unregister CHIPoBLE service to not allow discovering it when pairing is disabled. + if (bt_gatt_service_unregister(&sChipoBleService) != 0) + { + ChipLogError(DeviceLayer, "Failed to unregister CHIPoBLE GATT service"); + } + else + { + mFlags.Clear(Flags::kChipoBleGattServiceRegister); + } + } } exit: @@ -235,432 +236,89 @@ void BLEManagerImpl::DriveBLEState() } } -int BLEManagerImpl::RxWriteCallback(uint16_t connHandle, void * p) -{ - rf_packet_att_t * packet = (rf_packet_att_t *) p; - size_t dataLen = packet->l2capLen - CHIP_RF_PACKET_HEADER_SIZE; - ChipDeviceEvent event; - - PacketBufferHandle packetBuf = PacketBufferHandle::NewWithData(packet->dat, dataLen); - - // If successful... - if (packetBuf.IsNull()) - { - ChipLogError(DeviceLayer, "Failed to allocate buffer"); - - return 0; - } - - // Arrange to post a CHIPoBLERXWriteEvent event to the CHIP queue. - event.Type = DeviceEventType::kPlatformTelinkBleRXWrite; - event.Platform.BleRXWriteEvent.connHandle = connHandle; - event.Platform.BleRXWriteEvent.Data = std::move(packetBuf).UnsafeRelease(); - - PlatformMgr().PostEventOrDie(&event); - - return 0; -} - -void BLEManagerImpl::ConnectCallback(uint8_t bleEvent, uint8_t * data, int len) -{ - ChipDeviceEvent event; - ble_sts_t status = BLE_SUCCESS; - - event.Type = DeviceEventType::kPlatformTelinkBleConnected; - event.Platform.BleConnEvent.connHandle = BLS_CONN_HANDLE; - event.Platform.BleConnEvent.HciResult = BLE_SUCCESS; - - PlatformMgr().PostEventOrDie(&event); -} - -void BLEManagerImpl::DisconnectCallback(uint8_t bleEvent, uint8_t * data, int len) -{ - ChipDeviceEvent event; - - event.Type = DeviceEventType::kPlatformTelinkBleDisconnected; - event.Platform.BleConnEvent.connHandle = BLS_CONN_HANDLE; - event.Platform.BleConnEvent.HciResult = *data; // Reason of disconnection stored in first data byte - - PlatformMgr().PostEventOrDie(&event); -} - -int BLEManagerImpl::TxCccWriteCallback(uint16_t connHandle, void * p) +struct BLEManagerImpl::ServiceData { - ChipDeviceEvent event; - rf_packet_att_t * packet = (rf_packet_att_t *) p; - int dataLen = packet->rf_len - CHIP_RF_PACKET_HEADER_SIZE; - uint16_t value = *((uint16_t *) packet->dat); - - event.Type = DeviceEventType::kPlatformTelinkBleCCCWrite; - event.Platform.BleCCCWriteEvent.connHandle = connHandle; - event.Platform.BleCCCWriteEvent.Value = value; - - PlatformMgr().PostEventOrDie(&event); - - return 0; -} - -int BLEManagerImpl::GapEventHandler(uint32_t gapEvent, uint8_t * data, int size) -{ - ChipDeviceEvent event; - - if ((gapEvent & 0xFF) == GAP_EVT_GATT_HANDLE_VLAUE_CONFIRM) - { - /* Send TX complete event if everything is fine */ - event.Type = DeviceEventType::kPlatformTelinkBleTXComplete; - event.Platform.BleTXCompleteEvent.connHandle = BLS_CONN_HANDLE; - - PlatformMgr().PostEventOrDie(&event); - } - - return 0; -} + uint8_t uuid[2]; + ChipBLEDeviceIdentificationInfo deviceIdInfo; +} __attribute__((packed)); -CHIP_ERROR BLEManagerImpl::_InitStack(void) +CHIP_ERROR BLEManagerImpl::StartAdvertising(void) { - CHIP_ERROR err = CHIP_NO_ERROR; + int err = 0; - uint8_t macPublic[CHIP_MAC_LEN] = { 0 }; - uint8_t macRandomStatic[CHIP_MAC_LEN] = { 0 }; - int ret = 0; + // At first run always select fast advertising, on the next attempt slow down interval. + const uint32_t intervalMin = mFlags.Has(Flags::kFastAdvertisingEnabled) ? CHIP_DEVICE_CONFIG_BLE_FAST_ADVERTISING_INTERVAL_MIN + : CHIP_DEVICE_CONFIG_BLE_SLOW_ADVERTISING_INTERVAL_MIN; + const uint32_t intervalMax = mFlags.Has(Flags::kFastAdvertisingEnabled) ? CHIP_DEVICE_CONFIG_BLE_FAST_ADVERTISING_INTERVAL_MAX + : CHIP_DEVICE_CONFIG_BLE_SLOW_ADVERTISING_INTERVAL_MAX; if (ConnectivityMgr().IsThreadProvisioned()) { - ChipLogProgress(DeviceLayer, "Thread Provisioned. Ignore"); - - return CHIP_ERROR_INCORRECT_STATE; - } - - /* Reset Radio */ - rf_radio_reset(); - - /* Reset DMA */ - rf_reset_dma(); - - /* Init Radio driver */ - ble_radio_init(); - - /* Generate MAC address if it does not exist or read it from flash if it is exist already */ - blc_initMacAddress(CFG_ADR_MAC_1M_FLASH, macPublic, macRandomStatic); - - /* Init interrupts and DMA for BLE module ??? */ - blc_ll_initBasicMCU(); - - /* Setup MAC Address */ - blc_ll_initStandby_module(macPublic); - - /* Init advertisement */ - blc_ll_initAdvertising_module(); - - /* Init slave role */ - blc_ll_initSlaveRole_module(); - - /* Init connection mode */ - blc_ll_initConnection_module(); - - /* Init GAP */ - err = _InitGap(); - SuccessOrExit(err); - - /* Resetup stimer interrupt to handle BLE stack */ - ret = irq_connect_dynamic(STIMER_IRQ_NUM + CONFIG_2ND_LVL_ISR_TBL_OFFSET, 2, stimer_irq_handler, NULL, 0); - ChipLogDetail(DeviceLayer, "Stimer IRQ assigned vector %d", ret); - - /* Resetup rf interrupt to handle BLE stack */ - ret = irq_connect_dynamic(RF_IRQ_NUM + CONFIG_2ND_LVL_ISR_TBL_OFFSET, 2, rf_irq_handler, NULL, 0); - ChipLogDetail(DeviceLayer, "RF IRQ assigned vector %d", ret); - -exit: - - return err; -} - -CHIP_ERROR BLEManagerImpl::_InitGap(void) -{ - ble_sts_t status = BLE_SUCCESS; - /* Fifo buffers */ - static u8 txFifoBuff[CHIP_BLE_TX_FIFO_SIZE * CHIP_BLE_TX_FIFO_NUM] = { 0 }; - static u8 rxFifoBuff[CHIP_BLE_RX_FIFO_SIZE * CHIP_BLE_RX_FIFO_NUM] = { 0 }; - - status = blc_ll_initAclConnTxFifo(txFifoBuff, CHIP_BLE_TX_FIFO_SIZE, CHIP_BLE_TX_FIFO_NUM); - if (status != BLE_SUCCESS) - { - ChipLogError(DeviceLayer, "Fail to init BLE TX FIFO. Error %d", status); - - return CHIP_ERROR_INCORRECT_STATE; - } - - status = blc_ll_initAclConnRxFifo(rxFifoBuff, CHIP_BLE_RX_FIFO_SIZE, CHIP_BLE_RX_FIFO_NUM); - if (status != BLE_SUCCESS) - { - ChipLogError(DeviceLayer, "Fail to init BLE RX FIFO. Error %d", status); - - return CHIP_ERROR_INCORRECT_STATE; - } - - status = blc_controller_check_appBufferInitialization(); - if (status != BLE_SUCCESS) - { - ChipLogError(DeviceLayer, "Buffer initialization check failed. Error %d", status); - - return CHIP_ERROR_INCORRECT_STATE; - } - - /* Init GAP */ - blc_gap_peripheral_init(); - - /* Set up GATT Services */ - _InitGatt(); - - /* L2CAP Initialization */ - blc_l2cap_register_handler((void *) blc_l2cap_packet_receive); - - /* Setup connect/terminate callbacks */ - bls_app_registerEventCallback(BLT_EV_FLAG_CONNECT, BLEManagerImpl::ConnectCallback); - bls_app_registerEventCallback(BLT_EV_FLAG_TERMINATE, BLEManagerImpl::DisconnectCallback); - - /* Add GAP event handler to handle indication send */ - blc_gap_registerHostEventHandler(BLEManagerImpl::GapEventHandler); - blc_gap_setEventMask(GAP_EVT_MASK_GATT_HANDLE_VLAUE_CONFIRM); - - /* Set MTU */ - status = blc_att_setRxMtuSize(CHIP_MTU_SIZE); - if (status != BLE_SUCCESS) - { - ChipLogError(DeviceLayer, "Fail to set MTU size. Error %d", status); - - return CHIP_ERROR_INCORRECT_STATE; - } - - return CHIP_NO_ERROR; -} - -void BLEManagerImpl::_InitGatt(void) -{ - /* UUIDs */ - static const u16 primaryServiceUUID = GATT_UUID_PRIMARY_SERVICE; - static const u16 gapServiceUUID = SERVICE_UUID_GENERIC_ACCESS; - static const u16 characterUUID = GATT_UUID_CHARACTER; - static const u16 devNameUUID = GATT_UUID_DEVICE_NAME; - static const u16 gattServiceUUID = SERVICE_UUID_GENERIC_ATTRIBUTE; - static const u16 serviceChangeUUID = GATT_UUID_SERVICE_CHANGE; - static const u16 clientCharacterCfgUUID = GATT_UUID_CLIENT_CHAR_CFG; - static const u16 devServiceUUID = SERVICE_UUID_DEVICE_INFORMATION; - static const u16 appearanceUUID = GATT_UUID_APPEARANCE; - static const u16 periConnParamUUID = GATT_UUID_PERI_CONN_PARAM; - static const u8 MatterRxCharUUID[] = WRAPPING_BRACES(CHIP_RX_CHAR_UUID); - static const u8 MatterTxCharUUID[] = WRAPPING_BRACES(CHIP_TX_CHAR_UUID); - - /* Characteristics */ - static const u8 devNameCharVal[] = { CHAR_PROP_READ | CHAR_PROP_NOTIFY, U16_LO(GenericAccess_DeviceName_DP_H), - U16_HI(GenericAccess_DeviceName_DP_H), U16_LO(GATT_UUID_DEVICE_NAME), - U16_HI(GATT_UUID_DEVICE_NAME) }; - - static const u8 appearanceCharVal[] = { CHAR_PROP_READ, U16_LO(GenericAccess_Appearance_DP_H), - U16_HI(GenericAccess_Appearance_DP_H), U16_LO(GATT_UUID_APPEARANCE), - U16_HI(GATT_UUID_APPEARANCE) }; - - static const u8 periConnParamCharVal[] = { CHAR_PROP_READ, U16_LO(CONN_PARAM_DP_H), U16_HI(CONN_PARAM_DP_H), - U16_LO(GATT_UUID_PERI_CONN_PARAM), U16_HI(GATT_UUID_PERI_CONN_PARAM) }; - - static const u8 serviceChangeCharVal[] = { CHAR_PROP_INDICATE, U16_LO(GenericAttribute_ServiceChanged_DP_H), - U16_HI(GenericAttribute_ServiceChanged_DP_H), U16_LO(GATT_UUID_SERVICE_CHANGE), - U16_HI(GATT_UUID_SERVICE_CHANGE) }; - - static const u8 MatterRxCharVal[] = { CHAR_PROP_WRITE | CHAR_PROP_WRITE_WITHOUT_RSP, U16_LO(Matter_RX_DP_H), - U16_HI(Matter_RX_DP_H), CHIP_RX_CHAR_UUID }; - - static const u8 MatterTxCharVal[] = { CHAR_PROP_INDICATE, U16_LO(Matter_TX_DP_H), U16_HI(Matter_TX_DP_H), CHIP_TX_CHAR_UUID }; - - /* Values */ - static const u16 appearance = GAP_APPEARE_UNKNOWN; - static const gap_periConnectParams_t periConnParameters = { 8, 11, 0, 1000 }; - static u16 serviceChangeVal[2] = { 0 }; - static u8 serviceChangeCCC[2] = { 0 }; - static u8 matterTxCCC[2] = { 0 }; - - static const attribute_t gattTable[] = { - /* Total number of attributes */ - { ATT_END_H - 1, 0, 0, 0, 0, 0 }, - - /* 0001 - 0007 GAP service */ - { 7, ATT_PERMISSIONS_READ, 2, 2, (u8 *) (&primaryServiceUUID), (u8 *) (&gapServiceUUID), 0 }, - { 0, ATT_PERMISSIONS_READ, 2, sizeof(devNameCharVal), (u8 *) (&characterUUID), (u8 *) (devNameCharVal), 0 }, - { 0, ATT_PERMISSIONS_READ, 2, (u32) kMaxDeviceNameLength, (u8 *) (&devNameUUID), (u8 *) (mDeviceName), 0 }, - { 0, ATT_PERMISSIONS_READ, 2, sizeof(appearanceCharVal), (u8 *) (&characterUUID), (u8 *) (appearanceCharVal), 0 }, - { 0, ATT_PERMISSIONS_READ, 2, sizeof(appearance), (u8 *) (&appearanceUUID), (u8 *) (&appearance), 0 }, - { 0, ATT_PERMISSIONS_READ, 2, sizeof(periConnParamCharVal), (u8 *) (&characterUUID), (u8 *) (periConnParamCharVal), 0 }, - { 0, ATT_PERMISSIONS_READ, 2, sizeof(periConnParameters), (u8 *) (&periConnParamUUID), (u8 *) (&periConnParameters), 0 }, - - /* 0008 - 000b GATT */ - { 4, ATT_PERMISSIONS_READ, 2, 2, (u8 *) (&primaryServiceUUID), (u8 *) (&gattServiceUUID), 0 }, - { 0, ATT_PERMISSIONS_READ, 2, sizeof(serviceChangeCharVal), (u8 *) (&characterUUID), (u8 *) (serviceChangeCharVal), 0 }, - { 0, ATT_PERMISSIONS_READ, 2, sizeof(serviceChangeVal), (u8 *) (&serviceChangeUUID), (u8 *) (&serviceChangeVal), 0 }, - { 0, ATT_PERMISSIONS_RDWR, 2, sizeof(serviceChangeCCC), (u8 *) (&clientCharacterCfgUUID), (u8 *) (serviceChangeCCC), 0 }, - - /* 000c - 0011 Matter service */ - { 6, ATT_PERMISSIONS_READ, 2, 2, (u8 *) (&primaryServiceUUID), (u8 *) (&matterServiceUUID), 0 }, - { 0, ATT_PERMISSIONS_READ, 2, sizeof(MatterRxCharVal), (u8 *) (&characterUUID), (u8 *) (MatterRxCharVal), 0 }, - { 0, ATT_PERMISSIONS_RDWR, 16, sizeof(mRxDataBuff), (u8 *) (&MatterRxCharUUID), mRxDataBuff, RxWriteCallback, NULL }, - { 0, ATT_PERMISSIONS_READ, 2, sizeof(MatterTxCharVal), (u8 *) (&characterUUID), (u8 *) (MatterTxCharVal), 0 }, - { 0, ATT_PERMISSIONS_RDWR, 16, sizeof(mTxDataBuff), (u8 *) (&MatterTxCharUUID), mTxDataBuff, 0 }, - { 0, ATT_PERMISSIONS_RDWR, 2, sizeof(matterTxCCC), (u8 *) (&clientCharacterCfgUUID), (u8 *) (matterTxCCC), - TxCccWriteCallback, NULL } - }; - - bls_att_setAttributeTable((u8 *) gattTable); -} - -CHIP_ERROR BLEManagerImpl::ConfigureAdvertisingData(void) -{ - ble_sts_t status = BLE_SUCCESS; - CHIP_ERROR err = CHIP_NO_ERROR; - uint8_t index = 0; - uint8_t devNameLen = 0; - ChipBLEDeviceIdentificationInfo deviceIdInfo; - u8 adv[CHIP_MAX_ADV_DATA_LEN] = { 0 }; - u8 srsp[CHIP_MAX_RESPONSE_DATA_LEN] = { 0 }; - - ChipLogProgress(DeviceLayer, "BLEManagerImpl::ConfigureAdvertisingData"); - - /* Get BLE device identification info */ - err = ConfigurationMgr().GetBLEDeviceIdentificationInfo(deviceIdInfo); - SuccessOrExit(err); - - /* Check device name */ - if (!mFlags.Has(Flags::kDeviceNameSet)) - { - err = _SetDeviceName("TelinkMatter"); - SuccessOrExit(err); - } - - /* Fulfill BLE advertisement data */ - /* Set flags */ - adv[index++] = CHIP_ADE_DATA_LEN_FLAGS; - adv[index++] = CHIP_ADV_DATA_TYPE_FLAGS; - adv[index++] = CHIP_ADV_DATA_FLAGS; - - /* Set Service Data */ - adv[index++] = CHIP_ADV_SERVICE_DATA_LEN; - adv[index++] = CHIP_ADV_DATA_TYPE_SERVICE_DATA; - adv[index++] = matterServiceUUID[0]; - adv[index++] = matterServiceUUID[1]; - memcpy(&adv[index], (void *) &deviceIdInfo, sizeof(deviceIdInfo)); - index += sizeof(deviceIdInfo); - - /* Set device name */ - devNameLen = strlen(mDeviceName); - adv[index++] = devNameLen + 1; - adv[index++] = CHIP_ADV_DATA_TYPE_NAME; - memcpy(&adv[index], mDeviceName, devNameLen); - index += devNameLen; - - /* Set advetisment data */ - status = bls_ll_setAdvData(adv, index); - if (status != BLE_SUCCESS) - { - ChipLogError(DeviceLayer, "Fail to set BLE advertisement data. Error %d", status); - - return CHIP_ERROR_INCORRECT_STATE; - } - - index = 0; - srsp[index++] = CHIP_SHORT_UUID_LEN + 1; - srsp[index++] = CHIP_ADV_DATA_TYPE_UUID; - srsp[index++] = matterServiceUUID[0]; - srsp[index++] = matterServiceUUID[1]; - - /* Set scan response data */ - status = bls_ll_setScanRspData(srsp, sizeof(srsp)); - if (status != BLE_SUCCESS) - { - ChipLogError(DeviceLayer, "Fail to set BLE scan response data. Error %d", status); + ChipLogProgress(DeviceLayer, "Thread provisioned. Start advertisement not possible"); return CHIP_ERROR_INCORRECT_STATE; } -exit: - return err; -} - -CHIP_ERROR BLEManagerImpl::_SetAdvertisingEnabled(bool val) -{ - CHIP_ERROR err = CHIP_NO_ERROR; - - VerifyOrReturnError(mServiceMode != ConnectivityManager::kCHIPoBLEServiceMode_NotSupported, - CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE); - - if (mFlags.Has(Flags::kAdvertisingEnabled) != val) + if (!BLERadioInitialized) { - ChipLogDetail(DeviceLayer, "CHIPoBLE advertising set to %s", val ? "on" : "off"); + char bt_dev_name[CONFIG_BT_DEVICE_NAME_MAX]; + strncpy(bt_dev_name, bt_get_name(), sizeof(bt_dev_name)); + /* Block IEEE802154 */ + /* @todo: move to RadioSwitch module*/ + const struct device * radio_dev = DEVICE_DT_GET(DT_CHOSEN(zephyr_ieee802154)); + __ASSERT(radio_dev != NULL, "Fail to get radio device"); + b91_deinit(radio_dev); - mFlags.Set(Flags::kAdvertisingEnabled, val); - PlatformMgr().ScheduleWork(DriveBLEState, 0); + /* Init BLE stack */ + err = bt_enable(NULL); + VerifyOrReturnError(err == 0, MapErrorZephyr(err)); + (void) bt_set_name(bt_dev_name); + BLERadioInitialized = true; } - return err; -} + bt_le_adv_param advParams = + BT_LE_ADV_PARAM_INIT(BT_LE_ADV_OPT_CONNECTABLE | BT_LE_ADV_OPT_ONE_TIME, intervalMin, intervalMax, nullptr); -CHIP_ERROR BLEManagerImpl::StartAdvertising(void) -{ - CHIP_ERROR err = CHIP_NO_ERROR; - ble_sts_t status = BLE_SUCCESS; - - /* At first run always select fast advertising, on the next attempt slow down interval. */ - u16 intervalMin = mFlags.Has(Flags::kFastAdvertisingEnabled) ? CHIP_DEVICE_CONFIG_BLE_FAST_ADVERTISING_INTERVAL_MIN - : CHIP_DEVICE_CONFIG_BLE_SLOW_ADVERTISING_INTERVAL_MIN; - u16 intervalMax = mFlags.Has(Flags::kFastAdvertisingEnabled) ? CHIP_DEVICE_CONFIG_BLE_FAST_ADVERTISING_INTERVAL_MAX - : CHIP_DEVICE_CONFIG_BLE_SLOW_ADVERTISING_INTERVAL_MAX; - - if (ConnectivityMgr().IsThreadProvisioned()) - { - ChipLogProgress(DeviceLayer, "Thread provisioned. Start advertisement not possible"); - - return CHIP_ERROR_INCORRECT_STATE; - } + // Define advertising and, if BLE device name is set, scan response data + ServiceData serviceData; + const uint8_t advFlags = BT_LE_AD_GENERAL | BT_LE_AD_NO_BREDR; + const bt_data advertisingData[] = { BT_DATA(BT_DATA_FLAGS, &advFlags, sizeof(advFlags)), + BT_DATA(BT_DATA_SVC_DATA16, &serviceData, sizeof(serviceData)) }; - /* Block IEEE802154 */ - /* @todo: move to RadioSwitch module*/ - const struct device * radio_dev = device_get_binding(CONFIG_NET_CONFIG_IEEE802154_DEV_NAME); - __ASSERT(radio_dev != NULL, "Fail to get radio device"); - b91_deinit(radio_dev); + const char * deviceName = bt_get_name(); + const uint8_t deviceNameSize = static_cast(strlen(deviceName)); + const bt_data scanResponseData[] = { BT_DATA(BT_DATA_NAME_COMPLETE, deviceName, deviceNameSize) }; + const bt_data * scanResponseDataPtr = deviceNameSize > 0 ? scanResponseData : nullptr; + const size_t scanResponseDataLen = deviceNameSize > 0 ? ARRAY_SIZE(scanResponseData) : 0u; - /* It is time to init BLE stack */ - err = _InitStack(); - if (err != CHIP_NO_ERROR) + // Register dynamically CHIPoBLE GATT service + if (!mFlags.Has(Flags::kChipoBleGattServiceRegister)) { - ChipLogError(DeviceLayer, "Fail to init BLE stack"); + err = bt_gatt_service_register(&sChipoBleService); - return err; - } + if (err != 0) + ChipLogError(DeviceLayer, "Failed to register CHIPoBLE GATT service"); - /* Configure CHIP BLE advertisement data */ - err = ConfigureAdvertisingData(); - if (err != CHIP_NO_ERROR) - { - ChipLogError(DeviceLayer, "Fail to config BLE advertisement data"); + VerifyOrReturnError(err == 0, MapErrorZephyr(err)); - return err; + mFlags.Set(Flags::kChipoBleGattServiceRegister); } - /* Setup advertisement parameters */ - status = bls_ll_setAdvParam(intervalMin, intervalMax, ADV_TYPE_CONNECTABLE_UNDIRECTED, OWN_ADDRESS_PUBLIC, 0, NULL, - BLT_ENABLE_ADV_ALL, ADV_FP_NONE); - if (status != BLE_SUCCESS) - { - ChipLogError(DeviceLayer, "Fail to set BLE advertisement parameters. Error %d", status); + // Initialize service data + static_assert(sizeof(serviceData) == 10, "Size of BLE advertisement data changed! Was that intentional?"); + chip::Encoding::LittleEndian::Put16(serviceData.uuid, UUID16_CHIPoBLEService.val); + ReturnErrorOnFailure(ConfigurationMgr().GetBLEDeviceIdentificationInfo(serviceData.deviceIdInfo)); - return CHIP_ERROR_INCORRECT_STATE; - } +#if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING + ReturnErrorOnFailure(PrepareC3CharData()); +#endif - /* Enable advertisement */ - status = bls_ll_setAdvEnable(BLC_ADV_ENABLE); - if (status != BLE_SUCCESS) - { - ChipLogError(DeviceLayer, "Fail to start BLE advertisement. Error %d", status); + // Restart advertising + err = bt_le_adv_stop(); + VerifyOrReturnError(err == 0, MapErrorZephyr(err)); - return CHIP_ERROR_INCORRECT_STATE; - } + err = bt_le_adv_start(&advParams, advertisingData, ARRAY_SIZE(advertisingData), scanResponseDataPtr, scanResponseDataLen); + VerifyOrReturnError(err == 0, MapErrorZephyr(err)); // Transition to the Advertising state... if (!mFlags.Has(Flags::kAdvertising)) @@ -686,16 +344,11 @@ CHIP_ERROR BLEManagerImpl::StartAdvertising(void) } } - /* Start BLE Task */ - k_thread_resume(chipBleThread); - - return err; + return CHIP_NO_ERROR; } CHIP_ERROR BLEManagerImpl::StopAdvertising(void) { - ble_sts_t status = BLE_SUCCESS; - if (ConnectivityMgr().IsThreadProvisioned()) { ChipLogProgress(DeviceLayer, "Thread provisioned. Advertisement already stopped at this stage"); @@ -703,14 +356,8 @@ CHIP_ERROR BLEManagerImpl::StopAdvertising(void) return CHIP_ERROR_INCORRECT_STATE; } - /* Disable advertisement */ - status = bls_ll_setAdvEnable(BLC_ADV_DISABLE); - if (status != BLE_SUCCESS) - { - ChipLogError(DeviceLayer, "Fail to stop BLE advertisement. Error %d", status); - - return CHIP_ERROR_INCORRECT_STATE; - } + int err = bt_le_adv_stop(); + VerifyOrReturnError(err == 0, MapErrorZephyr(err)); // Transition to the not Advertising state... if (mFlags.Has(Flags::kAdvertising)) @@ -735,6 +382,22 @@ CHIP_ERROR BLEManagerImpl::StopAdvertising(void) return CHIP_NO_ERROR; } +CHIP_ERROR BLEManagerImpl::_SetAdvertisingEnabled(bool val) +{ + VerifyOrReturnError(mServiceMode != ConnectivityManager::kCHIPoBLEServiceMode_NotSupported, + CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE); + + if (mFlags.Has(Flags::kAdvertisingEnabled) != val) + { + ChipLogDetail(DeviceLayer, "CHIPoBLE advertising set to %s", val ? "on" : "off"); + + mFlags.Set(Flags::kAdvertisingEnabled, val); + PlatformMgr().ScheduleWork(DriveBLEState, 0); + } + + return CHIP_NO_ERROR; +} + CHIP_ERROR BLEManagerImpl::_SetAdvertisingMode(BLEAdvertisingMode mode) { switch (mode) @@ -755,47 +418,190 @@ CHIP_ERROR BLEManagerImpl::_SetAdvertisingMode(BLEAdvertisingMode mode) CHIP_ERROR BLEManagerImpl::_GetDeviceName(char * buf, size_t bufSize) { - if (strlen(mDeviceName) >= bufSize) - { - return CHIP_ERROR_BUFFER_TOO_SMALL; - } - strcpy(buf, mDeviceName); + Platform::CopyString(buf, bufSize, bt_get_name()); return CHIP_NO_ERROR; } -CHIP_ERROR BLEManagerImpl::_SetDeviceName(const char * devName) +CHIP_ERROR BLEManagerImpl::_SetDeviceName(const char * deviceName) { - if (mServiceMode == ConnectivityManager::kCHIPoBLEServiceMode_NotSupported) { - ChipLogError(DeviceLayer, "Unsupported"); - return CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE; } - if (devName == NULL || devName[0] == 0) + ChipLogDetail(DeviceLayer, "Device name set to: %s", deviceName); + return MapErrorZephyr(bt_set_name(deviceName)); +} + +CHIP_ERROR BLEManagerImpl::HandleGAPConnect(const ChipDeviceEvent * event) +{ + const BleConnEventType * connEvent = &event->Platform.BleConnEvent; + + if (connEvent->HciResult == BT_HCI_ERR_SUCCESS) + { + ChipLogProgress(DeviceLayer, "BLE connection established (ConnId: 0x%02x)", bt_conn_index(connEvent->BtConn)); + mGAPConns++; + } + else { - ChipLogError(DeviceLayer, "Invalid name"); + ChipLogError(DeviceLayer, "BLE connection failed (reason: 0x%02x)", connEvent->HciResult); + } - return CHIP_ERROR_INVALID_ARGUMENT; + ChipLogProgress(DeviceLayer, "Current number of connections: %u/%u", NumConnections(), CONFIG_BT_MAX_CONN); + + mFlags.Set(Flags::kAdvertisingRefreshNeeded); + PlatformMgr().ScheduleWork(DriveBLEState, 0); + + mconId = connEvent->BtConn; + bt_conn_unref(connEvent->BtConn); + + return CHIP_NO_ERROR; +} + +CHIP_ERROR BLEManagerImpl::HandleGAPDisconnect(const ChipDeviceEvent * event) +{ + const BleConnEventType * connEvent = &event->Platform.BleConnEvent; + + ChipLogProgress(DeviceLayer, "BLE GAP connection terminated (reason 0x%02x)", connEvent->HciResult); + + mGAPConns--; + + // If indications were enabled for this connection, record that they are now disabled and + // notify the BLE Layer of a disconnect. + if (UnsetSubscribed(connEvent->BtConn)) + { + CHIP_ERROR disconReason; + switch (connEvent->HciResult) + { + case BT_HCI_ERR_REMOTE_USER_TERM_CONN: + // Do not treat proper connection termination as an error and exit. + VerifyOrExit(!ConfigurationMgr().IsFullyProvisioned(), ); + disconReason = BLE_ERROR_REMOTE_DEVICE_DISCONNECTED; + break; + case BT_HCI_ERR_LOCALHOST_TERM_CONN: + disconReason = BLE_ERROR_APP_CLOSED_CONNECTION; + break; + default: + disconReason = BLE_ERROR_CHIPOBLE_PROTOCOL_ABORT; + break; + } + HandleConnectionError(connEvent->BtConn, disconReason); } - if (strlen(devName) >= kMaxDeviceNameLength) +exit: + // Unref bt_conn before scheduling DriveBLEState. + bt_conn_unref(connEvent->BtConn); + + ChipLogProgress(DeviceLayer, "Current number of connections: %u/%u", NumConnections(), CONFIG_BT_MAX_CONN); + + ChipDeviceEvent disconnectEvent; + disconnectEvent.Type = DeviceEventType::kCHIPoBLEConnectionClosed; + ReturnErrorOnFailure(PlatformMgr().PostEvent(&disconnectEvent)); + + // Force a reconfiguration of advertising in case we switched to non-connectable mode when + // the BLE connection was established. + mFlags.Set(Flags::kAdvertisingRefreshNeeded); + PlatformMgr().ScheduleWork(DriveBLEState, 0); + + return CHIP_NO_ERROR; +} + +CHIP_ERROR BLEManagerImpl::HandleTXCharCCCDWrite(const ChipDeviceEvent * event) +{ + const BleCCCWriteEventType * writeEvent = &event->Platform.BleCCCWriteEvent; + + ChipLogDetail(DeviceLayer, "ConnId: 0x%02x, New CCCD value: 0x%04x", bt_conn_index(writeEvent->BtConn), writeEvent->Value); + + // If the client has requested to enable indications and if it is not yet subscribed + if (writeEvent->Value == BT_GATT_CCC_INDICATE && SetSubscribed(writeEvent->BtConn)) { - ChipLogError(DeviceLayer, "BLE device name is to long"); + // Alert the BLE layer that CHIPoBLE "subscribe" has been received and increment the bt_conn reference counter. + HandleSubscribeReceived(writeEvent->BtConn, &CHIP_BLE_SVC_ID, &chipUUID_CHIPoBLEChar_TX); - return CHIP_ERROR_INVALID_ARGUMENT; + ChipLogProgress(DeviceLayer, "CHIPoBLE connection established (ConnId: 0x%02x, GATT MTU: %u)", + bt_conn_index(writeEvent->BtConn), GetMTU(writeEvent->BtConn)); + + // Post a CHIPoBLEConnectionEstablished event to the DeviceLayer and the application. + { + ChipDeviceEvent conEstEvent; + conEstEvent.Type = DeviceEventType::kCHIPoBLEConnectionEstablished; + ReturnErrorOnFailure(PlatformMgr().PostEvent(&conEstEvent)); + } } + else + { + if (UnsetSubscribed(writeEvent->BtConn)) + { + HandleUnsubscribeReceived(writeEvent->BtConn, &CHIP_BLE_SVC_ID, &chipUUID_CHIPoBLEChar_TX); + } + } + + bt_conn_unref(writeEvent->BtConn); + + return CHIP_NO_ERROR; +} + +CHIP_ERROR BLEManagerImpl::HandleRXCharWrite(const ChipDeviceEvent * event) +{ + const BleC1WriteEventType * c1WriteEvent = &event->Platform.BleC1WriteEvent; - strcpy(mDeviceName, devName); - mFlags.Set(Flags::kDeviceNameSet); + ChipLogDetail(DeviceLayer, "Write request received for CHIPoBLE RX characteristic (ConnId 0x%02x)", + bt_conn_index(c1WriteEvent->BtConn)); - ChipLogProgress(DeviceLayer, "Setting device name to : \"%s\"", devName); + HandleWriteReceived(c1WriteEvent->BtConn, &CHIP_BLE_SVC_ID, &chipUUID_CHIPoBLEChar_RX, + PacketBufferHandle::Adopt(c1WriteEvent->Data)); + bt_conn_unref(c1WriteEvent->BtConn); return CHIP_NO_ERROR; } +CHIP_ERROR BLEManagerImpl::HandleTXCharComplete(const ChipDeviceEvent * event) +{ + const BleC2IndDoneEventType * c2IndDoneEvent = &event->Platform.BleC2IndDoneEvent; + + ChipLogDetail(DeviceLayer, "Indication for CHIPoBLE TX characteristic done (ConnId 0x%02x, result 0x%02x)", + bt_conn_index(c2IndDoneEvent->BtConn), c2IndDoneEvent->Result); + + // Signal the BLE Layer that the outstanding indication is complete. + HandleIndicationConfirmation(c2IndDoneEvent->BtConn, &CHIP_BLE_SVC_ID, &chipUUID_CHIPoBLEChar_TX); + bt_conn_unref(c2IndDoneEvent->BtConn); + + return CHIP_NO_ERROR; +} + +#if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING +CHIP_ERROR BLEManagerImpl::PrepareC3CharData() +{ + CHIP_ERROR err = CHIP_NO_ERROR; + BitFlags additionalDataFields; + AdditionalDataPayloadGeneratorParams additionalDataPayloadParams; + +#if CHIP_ENABLE_ROTATING_DEVICE_ID && defined(CHIP_DEVICE_CONFIG_ROTATING_DEVICE_ID_UNIQUE_ID) + uint8_t rotatingDeviceIdUniqueId[ConfigurationManager::kRotatingDeviceIDUniqueIDLength] = {}; + MutableByteSpan rotatingDeviceIdUniqueIdSpan(rotatingDeviceIdUniqueId); + + err = DeviceLayer::GetDeviceInstanceInfoProvider()->GetRotatingDeviceIdUniqueId(rotatingDeviceIdUniqueIdSpan); + SuccessOrExit(err); + err = ConfigurationMgr().GetLifetimeCounter(additionalDataPayloadParams.rotatingDeviceIdLifetimeCounter); + SuccessOrExit(err); + additionalDataPayloadParams.rotatingDeviceIdUniqueId = rotatingDeviceIdUniqueIdSpan; + additionalDataFields.Set(AdditionalDataFields::RotatingDeviceId); +#endif /* CHIP_ENABLE_ROTATING_DEVICE_ID && defined(CHIP_DEVICE_CONFIG_ROTATING_DEVICE_ID_UNIQUE_ID) */ + + err = AdditionalDataPayloadGenerator().generateAdditionalDataPayload(additionalDataPayloadParams, c3CharDataBufferHandle, + additionalDataFields); + +exit: + if (err != CHIP_NO_ERROR) + { + ChipLogError(DeviceLayer, "Failed to generate TLV encoded Additional Data (%s)", __func__); + } + + return err; +} +#endif + void BLEManagerImpl::HandleBLEAdvertisementIntervalChange(System::Layer * layer, void * param) { BLEMgr().SetAdvertisingMode(BLEAdvertisingMode::kSlowAdvertising); @@ -808,27 +614,23 @@ void BLEManagerImpl::_OnPlatformEvent(const ChipDeviceEvent * event) switch (event->Type) { - case DeviceEventType::kPlatformTelinkBleConnected: + case DeviceEventType::kPlatformZephyrBleConnected: err = HandleGAPConnect(event); break; - case DeviceEventType::kPlatformTelinkBleDisconnected: + case DeviceEventType::kPlatformZephyrBleDisconnected: err = HandleGAPDisconnect(event); break; - case DeviceEventType::kPlatformTelinkBleDisconnectRequest: - err = HandleDisconnectRequest(event); + case DeviceEventType::kPlatformZephyrBleCCCWrite: + err = HandleTXCharCCCDWrite(event); break; - case DeviceEventType::kPlatformTelinkBleRXWrite: + case DeviceEventType::kPlatformZephyrBleC1WriteEvent: err = HandleRXCharWrite(event); break; - case DeviceEventType::kPlatformTelinkBleCCCWrite: - err = HandleTXCharCCCDWrite(event); - break; - - case DeviceEventType::kPlatformTelinkBleTXComplete: + case DeviceEventType::kPlatformZephyrBleC2IndDoneEvent: err = HandleTXCharComplete(event); break; @@ -845,216 +647,261 @@ void BLEManagerImpl::_OnPlatformEvent(const ChipDeviceEvent * event) break; default: - ChipLogDetail(DeviceLayer, "Event: Unknown (0x%04x)", event->Type); + break; } if (err != CHIP_NO_ERROR) { - ChipLogError(DeviceLayer, "Fail to handle 0x%04x event. Error: %s", event->Type, ErrorStr(err)); + ChipLogError(DeviceLayer, "Disabling CHIPoBLE service due to error: %" CHIP_ERROR_FORMAT, err.Format()); mServiceMode = ConnectivityManager::kCHIPoBLEServiceMode_Disabled; PlatformMgr().ScheduleWork(DriveBLEState, 0); } } -bool BLEManagerImpl::SubscribeCharacteristic(BLE_CONNECTION_OBJECT conId, const ChipBleUUID * svcId, const ChipBleUUID * charId) +uint16_t BLEManagerImpl::_NumConnections(void) { - return false; + return mGAPConns; } -bool BLEManagerImpl::UnsubscribeCharacteristic(BLE_CONNECTION_OBJECT conId, const ChipBleUUID * svcId, const ChipBleUUID * charId) +bool BLEManagerImpl::CloseConnection(BLE_CONNECTION_OBJECT conId) { - return false; + ChipLogProgress(DeviceLayer, "Closing BLE GATT connection (ConnId %02x)", bt_conn_index(conId)); + return bt_conn_disconnect(conId, BT_HCI_ERR_REMOTE_USER_TERM_CONN) == 0; } -bool BLEManagerImpl::CloseConnection(BLE_CONNECTION_OBJECT conId) +uint16_t BLEManagerImpl::GetMTU(BLE_CONNECTION_OBJECT conId) const { - return false; + return bt_gatt_get_mtu(conId); } -uint16_t BLEManagerImpl::GetMTU(BLE_CONNECTION_OBJECT conId) const +bool BLEManagerImpl::SubscribeCharacteristic(BLE_CONNECTION_OBJECT conId, const ChipBleUUID * svcId, const ChipBleUUID * charId) { - return blc_att_getEffectiveMtuSize(conId); + ChipLogError(DeviceLayer, "%s: NOT IMPLEMENTED", __PRETTY_FUNCTION__); + return true; +} + +bool BLEManagerImpl::UnsubscribeCharacteristic(BLE_CONNECTION_OBJECT conId, const ChipBleUUID * svcId, const ChipBleUUID * charId) +{ + ChipLogError(DeviceLayer, "%s: NOT IMPLEMENTED", __PRETTY_FUNCTION__); + return true; } bool BLEManagerImpl::SendIndication(BLE_CONNECTION_OBJECT conId, const ChipBleUUID * svcId, const ChipBleUUID * charId, PacketBufferHandle pBuf) { - ble_sts_t status = BLE_SUCCESS; + CHIP_ERROR err = CHIP_NO_ERROR; + int status = 0; + uint8_t index = bt_conn_index(conId); + bt_gatt_indicate_params * params = &mIndicateParams[index]; - do - { - if (status != BLE_SUCCESS) - { - k_msleep(1); - } - status = blc_gatt_pushHandleValueIndicate(conId, Matter_TX_DP_H, pBuf->Start(), pBuf->DataLength()); - } while (status == GATT_ERR_DATA_PENDING_DUE_TO_SERVICE_DISCOVERY_BUSY); - if (status != BLE_SUCCESS) - { - ChipLogError(DeviceLayer, "Fail to send indication. Error %d", status); + VerifyOrExit(IsSubscribed(conId) == true, err = CHIP_ERROR_INVALID_ARGUMENT); + + ChipLogDetail(DeviceLayer, "Sending indication for CHIPoBLE TX characteristic (ConnId %02x, len %u)", index, + pBuf->DataLength()); + + params->uuid = nullptr; + params->attr = &sChipoBleAttributes[kCHIPoBLE_CCC_AttributeIndex]; + params->func = HandleTXIndicated; + params->data = pBuf->Start(); + params->len = pBuf->DataLength(); - return false; + status = bt_gatt_indicate(conId, params); + VerifyOrExit(status == 0, err = MapErrorZephyr(status)); + +exit: + if (err != CHIP_NO_ERROR) + { + ChipLogError(DeviceLayer, "BLEManagerImpl::SendIndication() failed: %" CHIP_ERROR_FORMAT, err.Format()); } - return true; + return err == CHIP_NO_ERROR; } bool BLEManagerImpl::SendWriteRequest(BLE_CONNECTION_OBJECT conId, const ChipBleUUID * svcId, const ChipBleUUID * charId, PacketBufferHandle pBuf) { - ChipLogProgress(DeviceLayer, "BLEManagerImpl::SendWriteRequest() not supported"); - return false; + ChipLogError(DeviceLayer, "%s: NOT IMPLEMENTED", __PRETTY_FUNCTION__); + return true; } bool BLEManagerImpl::SendReadRequest(BLE_CONNECTION_OBJECT conId, const ChipBleUUID * svcId, const ChipBleUUID * charId, PacketBufferHandle pBuf) { - ChipLogProgress(DeviceLayer, "BLEManagerImpl::SendReadRequest() not supported"); - return false; + ChipLogError(DeviceLayer, "%s: NOT IMPLEMENTED", __PRETTY_FUNCTION__); + return true; } bool BLEManagerImpl::SendReadResponse(BLE_CONNECTION_OBJECT conId, BLE_READ_REQUEST_CONTEXT requestContext, const ChipBleUUID * svcId, const ChipBleUUID * charId) { - ChipLogProgress(DeviceLayer, "BLEManagerImpl::SendReadResponse() not supported"); - return false; + ChipLogError(DeviceLayer, "%s: NOT IMPLEMENTED", __PRETTY_FUNCTION__); + return true; } -/* @todo: move to RadioSwitch module */ -void BLEManagerImpl::SwitchToIeee802154(void) +void BLEManagerImpl::NotifyChipConnectionClosed(BLE_CONNECTION_OBJECT conId) { - int result = 0; + CloseConnection(conId); +} - ChipLogProgress(DeviceLayer, "BLEManagerImpl::Switch to IEEE802154"); +bool BLEManagerImpl::IsSubscribed(bt_conn * conn) +{ + return mSubscribedConns[bt_conn_index(conn)]; +} - /* Stop BLE */ - _SetAdvertisingEnabled(false); +bool BLEManagerImpl::SetSubscribed(bt_conn * conn) +{ + uint8_t index = bt_conn_index(conn); + bool isSubscribed = mSubscribedConns[index]; + mSubscribedConns[index] = true; - /* Stop BLE task */ - k_thread_suspend(chipBleThread); + // If we were not subscribed previously, increment the reference counter of the connection. + if (!isSubscribed) + { + bt_conn_ref(conn); + } - /* Reset Radio */ - rf_radio_reset(); + return !isSubscribed; +} - /* Reset DMA */ - rf_reset_dma(); +bool BLEManagerImpl::UnsetSubscribed(bt_conn * conn) +{ + uint8_t index = bt_conn_index(conn); + bool isSubscribed = mSubscribedConns[index]; + mSubscribedConns[index] = false; - const struct device * radio_dev = device_get_binding(CONFIG_NET_CONFIG_IEEE802154_DEV_NAME); - __ASSERT(radio_dev != NULL, "Fail to get radio device"); + // If we were subscribed previously, decrement the reference counter of the connection. + if (isSubscribed) + { + bt_conn_unref(conn); + } - /* Init IEEE802154 */ - result = b91_init(radio_dev); - __ASSERT(result == 0, "Fail to init IEEE802154 radio. Error: %d", result); + return isSubscribed; } -void BLEManagerImpl::NotifyChipConnectionClosed(BLE_CONNECTION_OBJECT conId) {} - -uint16_t BLEManagerImpl::_NumConnections(void) +ssize_t BLEManagerImpl::HandleRXWrite(struct bt_conn * conId, const struct bt_gatt_attr * attr, const void * buf, uint16_t len, + uint16_t offset, uint8_t flags) { - return mGAPConns; -} + ChipDeviceEvent event; + PacketBufferHandle packetBuf = PacketBufferHandle::NewWithData(buf, len); -/// @todo implement multicinnection subscription -CHIP_ERROR BLEManagerImpl::SetSubscribed(uint16_t conId) -{ + if (!packetBuf.IsNull()) + { + // Arrange to post a CHIPoBLERXWriteEvent event to the CHIP queue. + event.Type = DeviceEventType::kPlatformZephyrBleC1WriteEvent; + event.Platform.BleC1WriteEvent.BtConn = bt_conn_ref(conId); + event.Platform.BleC1WriteEvent.Data = std::move(packetBuf).UnsafeRelease(); + } + + // If we failed to allocate a buffer, post a kPlatformZephyrBleOutOfBuffersEvent event. + else + { + event.Type = DeviceEventType::kPlatformZephyrBleOutOfBuffersEvent; + } - mSubscribedConns[0] = true; + PlatformMgr().PostEventOrDie(&event); - return CHIP_NO_ERROR; + return len; } -/// @todo implement multicinnection subscription -bool BLEManagerImpl::UnsetSubscribed(uint16_t conId) +ssize_t BLEManagerImpl::HandleTXCCCWrite(struct bt_conn * conId, const struct bt_gatt_attr * attr, uint16_t value) { + ChipDeviceEvent event; - mSubscribedConns[0] = false; + if (value != BT_GATT_CCC_INDICATE && value != 0) + { + return BT_GATT_ERR(BT_ATT_ERR_VALUE_NOT_ALLOWED); + } - return true; + event.Type = DeviceEventType::kPlatformZephyrBleCCCWrite; + event.Platform.BleCCCWriteEvent.BtConn = bt_conn_ref(conId); + event.Platform.BleCCCWriteEvent.Value = value; + + PlatformMgr().PostEventOrDie(&event); + + return sizeof(value); } -/// @todo implement multicinnection subscription -bool BLEManagerImpl::IsSubscribed(uint16_t conId) +void BLEManagerImpl::HandleTXIndicated(struct bt_conn * conId, struct bt_gatt_indicate_params * attr, uint8_t err) { - return mSubscribedConns[0]; + ChipDeviceEvent event; + + event.Type = DeviceEventType::kPlatformZephyrBleC2IndDoneEvent; + event.Platform.BleC2IndDoneEvent.BtConn = bt_conn_ref(conId); + event.Platform.BleC2IndDoneEvent.Result = err; + + PlatformMgr().PostEventOrDie(&event); } -CHIP_ERROR BLEManagerImpl::HandleGAPConnect(const ChipDeviceEvent * event) +void BLEManagerImpl::HandleConnect(struct bt_conn * conId, uint8_t err) { - const BleConnEventType * connEvent = &event->Platform.BleConnEvent; + ChipDeviceEvent event; - ChipLogProgress(DeviceLayer, "BLE connection established (ConnId: 0x%02x)", connEvent->connHandle); - mGAPConns++; - ChipLogProgress(DeviceLayer, "Current number of connections: %u/%u", NumConnections(), kMaxConnections); + PlatformMgr().LockChipStack(); - mFlags.Set(Flags::kAdvertisingRefreshNeeded); - PlatformMgr().ScheduleWork(DriveBLEState, 0); + // Don't handle BLE connecting events when it is not related to CHIPoBLE + VerifyOrExit(sInstance.mFlags.Has(Flags::kChipoBleGattServiceRegister), ); - return CHIP_NO_ERROR; -} + event.Type = DeviceEventType::kPlatformZephyrBleConnected; + event.Platform.BleConnEvent.BtConn = bt_conn_ref(conId); + event.Platform.BleConnEvent.HciResult = err; -CHIP_ERROR BLEManagerImpl::HandleGAPDisconnect(const ChipDeviceEvent * event) -{ - const BleConnEventType * connEvent = &event->Platform.BleConnEvent; + PlatformMgr().PostEventOrDie(&event); - ChipLogProgress(DeviceLayer, "BLE GAP connection terminated (reason 0x%02x)", connEvent->HciResult); +exit: + PlatformMgr().UnlockChipStack(); +} - mGAPConns--; +void BLEManagerImpl::HandleDisconnect(struct bt_conn * conId, uint8_t reason) +{ + ChipDeviceEvent event; - ChipLogProgress(DeviceLayer, "Current number of connections: %u/%u", NumConnections(), kMaxConnections); + PlatformMgr().LockChipStack(); - // Unsubscribe - if (UnsetSubscribed(connEvent->connHandle)) - { - HandleUnsubscribeReceived(connEvent->connHandle, &CHIP_BLE_SVC_ID, &chipUUID_CHIPoBLEChar_TX); - } + // Don't handle BLE disconnecting events when it is not related to CHIPoBLE + VerifyOrExit(sInstance.mFlags.Has(Flags::kChipoBleGattServiceRegister), ); - ChipDeviceEvent disconnectEvent; - disconnectEvent.Type = DeviceEventType::kCHIPoBLEConnectionClosed; - ReturnErrorOnFailure(PlatformMgr().PostEvent(&disconnectEvent)); + event.Type = DeviceEventType::kPlatformZephyrBleDisconnected; + event.Platform.BleConnEvent.BtConn = bt_conn_ref(conId); + event.Platform.BleConnEvent.HciResult = reason; - // Force a reconfiguration of advertising in case we switched to non-connectable mode when - // the BLE connection was established. - mFlags.Set(Flags::kAdvertisingRefreshNeeded); - PlatformMgr().ScheduleWork(DriveBLEState, 0); + PlatformMgr().PostEventOrDie(&event); - return CHIP_NO_ERROR; +exit: + PlatformMgr().UnlockChipStack(); } -CHIP_ERROR BLEManagerImpl::HandleDisconnectRequest(const ChipDeviceEvent * event) +#if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING +ssize_t BLEManagerImpl::HandleC3Read(struct bt_conn * conId, const struct bt_gatt_attr * attr, void * buf, uint16_t len, + uint16_t offset) { - ble_sts_t status = BLE_SUCCESS; - uint16_t handle = event->Platform.BleConnEvent.connHandle; - uint8_t reason = event->Platform.BleConnEvent.HciResult; - - ChipLogDetail(DeviceLayer, "HandleDisconnectRequest"); + ChipLogDetail(DeviceLayer, "Read request received for CHIPoBLE C3 (ConnId 0x%02x)", bt_conn_index(conId)); - /* Trigger disconnect. DisconnectCallback call occures on completion */ - status = blc_ll_disconnect(handle, reason); - if (status != BLE_SUCCESS && status != LL_ERR_CONNECTION_NOT_ESTABLISH) + if (sInstance.c3CharDataBufferHandle.IsNull()) { - ChipLogError(DeviceLayer, "Fail to disconnect. Error %d", status); - - return CHIP_ERROR_INCORRECT_STATE; + return 0; } - // Force a reconfiguration of advertising in case we switched to non-connectable mode when - // the BLE connection was established. - mFlags.Set(Flags::kAdvertisingRefreshNeeded); - PlatformMgr().ScheduleWork(DriveBLEState, 0); + return bt_gatt_attr_read(conId, attr, buf, len, offset, sInstance.c3CharDataBufferHandle->Start(), + sInstance.c3CharDataBufferHandle->DataLength()); +} +#endif - return CHIP_NO_ERROR; +void BLEManagerImpl::BLEConnDisconnect(System::Layer * layer, void * param) +{ + int error = bt_conn_disconnect(BLEMgrImpl().mconId, BT_HCI_ERR_LOCALHOST_TERM_CONN); + if (error) + { + ChipLogError(DeviceLayer, "Failed to close BLE connection, error: %d", error); + } } CHIP_ERROR BLEManagerImpl::HandleOperationalNetworkEnabled(const ChipDeviceEvent * event) { - ChipDeviceEvent disconnectEvent; ChipLogDetail(DeviceLayer, "HandleOperationalNetworkEnabled"); - disconnectEvent.Type = DeviceEventType::kPlatformTelinkBleDisconnectRequest; - disconnectEvent.Platform.BleConnEvent.connHandle = BLS_CONN_HANDLE; - disconnectEvent.Platform.BleConnEvent.HciResult = CHIP_BLE_DISCONNECT_REASON; - ReturnErrorOnFailure(PlatformMgr().PostEvent(&disconnectEvent)); + // Start timer to close BLE connection. + DeviceLayer::SystemLayer().StartTimer(System::Clock::Milliseconds32(20), BLEConnDisconnect, this); return CHIP_NO_ERROR; } @@ -1094,61 +941,27 @@ CHIP_ERROR BLEManagerImpl::HandleBleConnectionClosed(const ChipDeviceEvent * eve return CHIP_NO_ERROR; } -CHIP_ERROR BLEManagerImpl::HandleRXCharWrite(const ChipDeviceEvent * event) -{ - const BleRXWriteEventType * writeEvent = &event->Platform.BleRXWriteEvent; - - ChipLogDetail(DeviceLayer, "Write request received for CHIPoBLE RX (ConnId 0x%02x)", writeEvent->connHandle); - - HandleWriteReceived(writeEvent->connHandle, &CHIP_BLE_SVC_ID, &chipUUID_CHIPoBLEChar_RX, - PacketBufferHandle::Adopt(writeEvent->Data)); - - return CHIP_NO_ERROR; -} - -CHIP_ERROR BLEManagerImpl::HandleTXCharComplete(const ChipDeviceEvent * event) -{ - const BleTXCompleteEventType * completeEvent = &event->Platform.BleTXCompleteEvent; - - ChipLogDetail(DeviceLayer, "Notification for CHIPoBLE TX done (ConnId 0x%02x)", completeEvent->connHandle); - - // Signal the BLE Layer that the outstanding notification is complete. - HandleIndicationConfirmation(completeEvent->connHandle, &CHIP_BLE_SVC_ID, &chipUUID_CHIPoBLEChar_TX); - - return CHIP_NO_ERROR; -} - -CHIP_ERROR BLEManagerImpl::HandleTXCharCCCDWrite(const ChipDeviceEvent * event) +/* @todo: move to RadioSwitch module */ +void BLEManagerImpl::SwitchToIeee802154(void) { - const BleCCCWriteEventType * writeEvent = &event->Platform.BleCCCWriteEvent; + int result = 0; - ChipLogDetail(DeviceLayer, "ConnId: 0x%02x, New CCCD value: 0x%04x", writeEvent->connHandle, writeEvent->Value); + ChipLogProgress(DeviceLayer, "BLEManagerImpl::Switch to IEEE802154"); - /* If the client has requested to enable notifications and if it is not yet subscribed */ - if (writeEvent->Value != 0 && SetSubscribed(writeEvent->connHandle) == CHIP_NO_ERROR) - { - /* Alert the BLE layer that CHIPoBLE "subscribe" has been received and increment the bt_conn reference counter. */ - HandleSubscribeReceived(writeEvent->connHandle, &CHIP_BLE_SVC_ID, &chipUUID_CHIPoBLEChar_TX); + /* Stop BLE */ + StopAdvertising(); - ChipLogProgress(DeviceLayer, "CHIPoBLE connection established (ConnId: 0x%02x, GATT MTU: %d)", writeEvent->connHandle, - GetMTU(writeEvent->connHandle)); + /* Deinit BLE stack */ + bt_disable(); + // irq_disable(IRQ1_SYSTIMER); + BLERadioInitialized = false; - /* Post a CHIPoBLEConnectionEstablished event to the DeviceLayer and the application. */ - { - ChipDeviceEvent conEstEvent; - conEstEvent.Type = DeviceEventType::kCHIPoBLEConnectionEstablished; - ReturnErrorOnFailure(PlatformMgr().PostEvent(&conEstEvent)); - } - } - else - { - if (UnsetSubscribed(writeEvent->connHandle)) - { - HandleUnsubscribeReceived(writeEvent->connHandle, &CHIP_BLE_SVC_ID, &chipUUID_CHIPoBLEChar_TX); - } - } + const struct device * radio_dev = DEVICE_DT_GET(DT_CHOSEN(zephyr_ieee802154)); + __ASSERT(radio_dev != NULL, "Fail to get radio device"); - return CHIP_NO_ERROR; + /* Init IEEE802154 */ + result = b91_init(radio_dev); + __ASSERT(result == 0, "Fail to init IEEE802154 radio. Error: %d", result); } } // namespace Internal diff --git a/src/platform/telink/BLEManagerImpl.h b/src/platform/telink/BLEManagerImpl.h index d1b79718b347b7..f6fcbf87c8e584 100644 --- a/src/platform/telink/BLEManagerImpl.h +++ b/src/platform/telink/BLEManagerImpl.h @@ -1,6 +1,6 @@ /* * - * Copyright (c) 2021 Project CHIP Authors + * Copyright (c) 2022 Project CHIP Authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -18,13 +18,20 @@ /** * @file * Provides an implementation of the BLEManager object - * for Telink platform. + * for Telink platforms, by including Zephyr platform + * implementation. */ #pragma once #if CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE +#include +#include +#include + +#include + namespace chip { namespace DeviceLayer { namespace Internal { @@ -32,7 +39,7 @@ namespace Internal { using namespace chip::Ble; /** - * Concrete implementation of the BLEManager singleton object for the platform. + * Concrete implementation of the BLEManager singleton object for the Zephyr platforms. */ class BLEManagerImpl final : public BLEManager, private BleLayer, private BlePlatformDelegate, private BleApplicationDelegate { @@ -41,10 +48,10 @@ class BLEManagerImpl final : public BLEManager, private BleLayer, private BlePla friend BLEManager; private: - // Members that implement the BLEManager internal interface. + // ===== Members that implement the BLEManager internal interface. CHIP_ERROR _Init(void); - void _Shutdown(); + void _Shutdown() {} bool _IsAdvertisingEnabled(void); CHIP_ERROR _SetAdvertisingEnabled(bool val); bool _IsAdvertising(void); @@ -55,7 +62,7 @@ class BLEManagerImpl final : public BLEManager, private BleLayer, private BlePla void _OnPlatformEvent(const ChipDeviceEvent * event); BleLayer * _GetBleLayer(void); - // Members that implement virtual methods on BlePlatformDelegate. + // ===== Members that implement virtual methods on BlePlatformDelegate. bool SubscribeCharacteristic(BLE_CONNECTION_OBJECT conId, const ChipBleUUID * svcId, const ChipBleUUID * charId) override; bool UnsubscribeCharacteristic(BLE_CONNECTION_OBJECT conId, const ChipBleUUID * svcId, const ChipBleUUID * charId) override; @@ -70,62 +77,42 @@ class BLEManagerImpl final : public BLEManager, private BleLayer, private BlePla bool SendReadResponse(BLE_CONNECTION_OBJECT conId, BLE_READ_REQUEST_CONTEXT requestContext, const ChipBleUUID * svcId, const ChipBleUUID * charId) override; - // Members that implement virtual methods on BleApplicationDelegate. + // ===== Members that implement virtual methods on BleApplicationDelegate. void NotifyChipConnectionClosed(BLE_CONNECTION_OBJECT conId) override; - // Members for internal use by the following friends. - - friend BLEManager & BLEMgr(void); - friend BLEManagerImpl & BLEMgrImpl(void); - - static BLEManagerImpl sInstance; - - // Private members reserved for use by this class only. + // ===== Private members reserved for use by this class only. - enum class Flags : uint16_t + enum class Flags : uint8_t { - kAsyncInitCompleted = 0x0001, /**< One-time asynchronous initialization actions have been performed. */ - kAdvertisingEnabled = 0x0002, /**< The application has enabled CHIPoBLE advertising. */ - kFastAdvertisingEnabled = 0x0004, /**< The application has enabled fast advertising. */ - kAdvertising = 0x0008, /**< The system is currently CHIPoBLE advertising. */ - kAdvertisingRefreshNeeded = 0x0010, /**< The advertising state/configuration state in the BLE layer needs to be updated. */ - kDeviceNameSet = 0x0020, /**< The device name has been set. */ - kRestartAdvertising = 0x0040, /**< The advertising will be restarted when stop advertising confirmation is received and this - flag is set*/ + kAsyncInitCompleted = 0x0001, /**< One-time asynchronous initialization actions have been performed. */ + kAdvertisingEnabled = 0x0002, /**< The application has enabled CHIPoBLE advertising. */ + kFastAdvertisingEnabled = 0x0004, /**< The application has enabled fast advertising. */ + kAdvertising = 0x0008, /**< The system is currently CHIPoBLE advertising. */ + kAdvertisingRefreshNeeded = + 0x0010, /**< The advertising state/configuration has changed, but the SoftDevice has yet to be updated. */ + kChipoBleGattServiceRegister = 0x0020, /**< The system has currently CHIPoBLE GATT service registered. */ }; - enum - { - kMaxConnections = BLE_LAYER_NUM_BLE_ENDPOINTS, - kMaxDeviceNameLength = 16, - kMaxAdvertisementDataSetSize = 31, - kMaxRxDataBuffSize = 20, - kMaxTxDataBuffSize = 20 - }; + struct ServiceData; - CHIPoBLEServiceMode mServiceMode; BitFlags mFlags; - char mDeviceName[kMaxDeviceNameLength + 1]; uint16_t mGAPConns; - bool mSubscribedConns[kMaxConnections]; - uint8_t mAdvDataBuf[kMaxAdvertisementDataSetSize]; - uint8_t mScanRespDataBuf[kMaxAdvertisementDataSetSize]; - uint8_t mRxDataBuff[kMaxRxDataBuffSize]; - uint8_t mTxDataBuff[kMaxRxDataBuffSize]; - bool ThreadConnectivityReady; + CHIPoBLEServiceMode mServiceMode; + bool mSubscribedConns[CONFIG_BT_MAX_CONN]; + bt_gatt_indicate_params mIndicateParams[CONFIG_BT_MAX_CONN]; + bt_conn_cb mConnCallbacks; + bt_conn * mconId; +#if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING + PacketBufferHandle c3CharDataBufferHandle; +#endif void DriveBLEState(void); - CHIP_ERROR ConfigureAdvertisingData(void); + CHIP_ERROR ConfigureAdvertising(void); CHIP_ERROR StartAdvertising(void); CHIP_ERROR StopAdvertising(void); - CHIP_ERROR SetSubscribed(uint16_t conId); - bool UnsetSubscribed(uint16_t conId); - bool IsSubscribed(uint16_t conId); - CHIP_ERROR HandleGAPConnect(const ChipDeviceEvent * event); CHIP_ERROR HandleGAPDisconnect(const ChipDeviceEvent * event); - CHIP_ERROR HandleDisconnectRequest(const ChipDeviceEvent * event); CHIP_ERROR HandleRXCharWrite(const ChipDeviceEvent * event); CHIP_ERROR HandleTXCharCCCDWrite(const ChipDeviceEvent * event); CHIP_ERROR HandleTXCharComplete(const ChipDeviceEvent * event); @@ -140,33 +127,43 @@ class BLEManagerImpl final : public BLEManager, private BleLayer, private BlePla */ CHIP_ERROR HandleThreadStateChange(const ChipDeviceEvent * event); CHIP_ERROR HandleOperationalNetworkEnabled(const ChipDeviceEvent * event); + static void BLEConnDisconnect(chip::System::Layer * aLayer, void * aAppState); + +#if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING + CHIP_ERROR PrepareC3CharData(); +#endif + bool IsSubscribed(bt_conn * conn); + bool SetSubscribed(bt_conn * conn); + bool UnsetSubscribed(bt_conn * conn); + uint32_t GetAdvertisingInterval(); - /* Callbacks from BLE stack*/ static void DriveBLEState(intptr_t arg); + // Below callbacks run from the system workqueue context and have a limited stack capacity. + static void HandleTXIndicated(bt_conn * conn, bt_gatt_indicate_params * attr, uint8_t err); + static void HandleConnect(bt_conn * conn, uint8_t err); + static void HandleDisconnect(bt_conn * conn, uint8_t reason); static void HandleBLEAdvertisementIntervalChange(System::Layer * layer, void * param); - /* Handlers for stack events */ - static void CancelBleAdvTimeoutTimer(void); - static void StartBleAdvTimeoutTimer(uint32_t aTimeoutInMs); + // ===== Members for internal use by the following friends. + + friend BLEManager & BLEMgr(void); + friend BLEManagerImpl & BLEMgrImpl(void); - /* Other init functions */ - CHIP_ERROR _InitStack(void); - void _InitGatt(void); - CHIP_ERROR _InitGap(void); + static BLEManagerImpl sInstance; public: - static int RxWriteCallback(uint16_t connHandle, void * p); - static int TxCccWriteCallback(uint16_t connHandle, void * p); - static void ConnectCallback(uint8_t event, uint8_t * data, int len); - static void DisconnectCallback(uint8_t event, uint8_t * data, int len); - static int GapEventHandler(uint32_t event, uint8_t * data, int size); + // Below callbacks are public in order to be visible from the global scope. + static ssize_t HandleRXWrite(bt_conn * conn, const bt_gatt_attr * attr, const void * buf, uint16_t len, uint16_t offset, + uint8_t flags); + static ssize_t HandleTXCCCWrite(bt_conn * conn, const bt_gatt_attr * attr, uint16_t value); + +#if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING + static ssize_t HandleC3Read(struct bt_conn * conn, const struct bt_gatt_attr * attr, void * buf, uint16_t len, uint16_t offset); +#endif /* Switch to IEEE802154 interface. @todo: remove to other module? */ void SwitchToIeee802154(void); - - /* BLE thread entry */ - static void BleEntry(void *, void *, void *); }; /** @@ -184,7 +181,7 @@ inline BLEManager & BLEMgr(void) * Returns the platform-specific implementation of the BLEManager singleton object. * * Internal components can use this to gain access to features of the BLEManager - * that are specific to the platform. + * that are specific to the Zephyr platforms. */ inline BLEManagerImpl & BLEMgrImpl(void) { diff --git a/src/platform/telink/BUILD.gn b/src/platform/telink/BUILD.gn index 1a4c90395dbe7c..da7e1f39e57d0d 100644 --- a/src/platform/telink/BUILD.gn +++ b/src/platform/telink/BUILD.gn @@ -13,7 +13,6 @@ # limitations under the License. import("//build_overrides/chip.gni") -import("//build_overrides/telink.gni") import("${chip_root}/src/platform/device.gni") import("${chip_root}/src/platform/telink/args.gni") @@ -48,18 +47,13 @@ static_library("telink") { "SystemPlatformConfig.h", ] - deps = [] - public = [ "${chip_root}/src/credentials/CHIPCert.h", "${chip_root}/src/credentials/CertificationDeclaration.h", "${chip_root}/src/credentials/DeviceAttestationCredsProvider.h", ] - public_deps = [ - "${chip_root}/src/platform:platform_base", - "${telink_sdk_build_root}", - ] + public_deps = [ "${chip_root}/src/platform:platform_base" ] if (chip_enable_factory_data) { sources += [ diff --git a/src/platform/telink/BlePlatformConfig.h b/src/platform/telink/BlePlatformConfig.h index 6b451d7b88c1ca..8667470deffb68 100644 --- a/src/platform/telink/BlePlatformConfig.h +++ b/src/platform/telink/BlePlatformConfig.h @@ -1,6 +1,6 @@ /* * - * Copyright (c) 2021 Project CHIP Authors + * Copyright (c) 2022 Project CHIP Authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -24,10 +24,12 @@ #pragma once +#include + // ==================== Platform Adaptations ==================== -#define BLE_CONNECTION_OBJECT uint16_t -#define BLE_CONNECTION_UNINITIALIZED ((uint16_t) 0xFFFF) +#define BLE_CONNECTION_OBJECT bt_conn * +#define BLE_CONNECTION_UNINITIALIZED nullptr #define BLE_MAX_RECEIVE_WINDOW_SIZE 5 // ========== Platform-specific Configuration Overrides ========= diff --git a/src/platform/telink/CHIPDevicePlatformConfig.h b/src/platform/telink/CHIPDevicePlatformConfig.h index 6af8812f70d5a8..28c93f1d4e6ee9 100644 --- a/src/platform/telink/CHIPDevicePlatformConfig.h +++ b/src/platform/telink/CHIPDevicePlatformConfig.h @@ -92,6 +92,8 @@ #define CHIP_DEVICE_CONFIG_ENABLE_THREAD CONFIG_NET_L2_OPENTHREAD +#define CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE CONFIG_BT + // ========== Platform-specific Configuration ========= // These are configuration options that are unique to Zephyr platforms. @@ -175,7 +177,7 @@ // ========== Platform-specific Configuration Overrides ========= #ifndef CHIP_DEVICE_CONFIG_CHIP_TASK_PRIORITY -#define CHIP_DEVICE_CONFIG_CHIP_TASK_PRIORITY (K_PRIO_COOP(CONFIG_NUM_COOP_PRIORITIES - 1)) +#define CHIP_DEVICE_CONFIG_CHIP_TASK_PRIORITY (K_PRIO_PREEMPT(1)) #endif // CHIP_DEVICE_CONFIG_CHIP_TASK_PRIORITY #ifndef CHIP_DEVICE_CONFIG_CHIP_TASK_STACK_SIZE @@ -195,15 +197,17 @@ #endif // CONFIG_CHIP_ENABLE_PAIRING_AUTOSTART #ifdef CONFIG_CHIP_ENABLE_DNSSD_SRP -#define CHIP_DEVICE_CONFIG_ENABLE_MDNS 1 #define CHIP_DEVICE_CONFIG_ENABLE_THREAD_SRP_CLIENT 1 -#define CHIP_DEVICE_CONFIG_ENABLE_COMMISSIONABLE_DISCOVERY 1 #ifdef CONFIG_CHIP_ENABLE_DNS_CLIENT #define CHIP_DEVICE_CONFIG_ENABLE_THREAD_DNS_CLIENT 1 #define CHIP_DEVICE_CONFIG_ENABLE_THREAD_COMMISSIONABLE_DISCOVERY 1 #endif // CONFIG_CHIP_ENABLE_DNS_CLIENT #endif // CONFIG_CHIP_ENABLE_DNSSD_SRP +#ifdef CONFIG_CHIP_COMMISSIONABLE_DEVICE_TYPE +#define CHIP_DEVICE_CONFIG_ENABLE_COMMISSIONABLE_DEVICE_TYPE 1 +#endif // CONFIG_CHIP_COMMISSIONABLE_DEVICE_TYPE + #ifdef CONFIG_CHIP_DEVICE_TYPE #define CHIP_DEVICE_CONFIG_DEVICE_TYPE CONFIG_CHIP_DEVICE_TYPE #endif // CONFIG_CHIP_DEVICE_TYPE diff --git a/src/platform/telink/CHIPDevicePlatformEvent.h b/src/platform/telink/CHIPDevicePlatformEvent.h index b04059508c1bf6..a1f53347bc9c5a 100644 --- a/src/platform/telink/CHIPDevicePlatformEvent.h +++ b/src/platform/telink/CHIPDevicePlatformEvent.h @@ -1,6 +1,6 @@ /* * - * Copyright (c) 2021 Project CHIP Authors + * Copyright (c) 2022 Project CHIP Authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -24,76 +24,4 @@ #pragma once -#include - -#include - -namespace chip { -namespace DeviceLayer { - -namespace DeviceEventType { - -/** - * Enumerates Telink platform-specific event types that are visible to the application. - */ -enum PublicPlatformSpecificEventTypes -{ - /* None currently defined */ -}; - -/** - * Enumerates Telink platform-specific event types that are internal to the chip Device Layer. - */ -enum InternalPlatformSpecificEventTypes -{ - kPlatformTelinkEvent = kRange_InternalPlatformSpecific, - kPlatformTelinkBleConnected, - kPlatformTelinkBleDisconnected, - kPlatformTelinkBleDisconnectRequest, - kPlatformTelinkBleCCCWrite, - kPlatformTelinkBleRXWrite, - kPlatformTelinkBleTXComplete, - kPlatformTelinkBleOutOfBuffersEvent, -}; - -} // namespace DeviceEventType - -struct BleConnEventType -{ - uint16_t connHandle; - uint8_t HciResult; -}; - -struct BleCCCWriteEventType -{ - uint16_t connHandle; - uint16_t Value; -}; - -struct BleRXWriteEventType -{ - uint16_t connHandle; - ::chip::System::PacketBuffer * Data; -}; - -struct BleTXCompleteEventType -{ - uint16_t connHandle; -}; - -/** - * Represents platform-specific event information for Zephyr platforms. - */ -struct ChipDevicePlatformEvent final -{ - union - { - BleConnEventType BleConnEvent; - BleCCCWriteEventType BleCCCWriteEvent; - BleRXWriteEventType BleRXWriteEvent; - BleTXCompleteEventType BleTXCompleteEvent; - }; -}; - -} // namespace DeviceLayer -} // namespace chip +#include diff --git a/src/platform/telink/CHIPPlatformConfig.h b/src/platform/telink/CHIPPlatformConfig.h index 85cc1c85736c75..f78ab8791d1253 100644 --- a/src/platform/telink/CHIPPlatformConfig.h +++ b/src/platform/telink/CHIPPlatformConfig.h @@ -30,24 +30,24 @@ #define CHIP_CONFIG_PERSISTED_STORAGE_KEY_TYPE const char * #define CHIP_CONFIG_PERSISTED_STORAGE_MAX_KEY_LENGTH 2 -/** - * @def CHIP_CONFIG_MAX_FABRICS - * - * @brief - * Maximum number of fabrics the device can participate in. Each fabric can - * provision the device with its unique operational credentials and manage - * its own access control lists. - */ -#ifndef CHIP_CONFIG_MAX_FABRICS -#define CHIP_CONFIG_MAX_FABRICS 5 // 4 fabrics + 1 for rotation slack -#endif +#define CHIP_CONFIG_LIFETIIME_PERSISTED_COUNTER_KEY "rc" // ==================== Security Adaptations ==================== +#ifdef CONFIG_CHIP_CRYPTO_PSA +#define CHIP_CONFIG_SHA256_CONTEXT_SIZE sizeof(psa_hash_operation_t) +#elif defined(CONFIG_CC3XX_BACKEND) +// Size of the statically allocated context for SHA256 operations in CryptoPAL +// determined empirically. +#define CHIP_CONFIG_SHA256_CONTEXT_SIZE 244 +#else +#define CHIP_CONFIG_SHA256_CONTEXT_SIZE 208 +#endif + // ==================== General Configuration Overrides ==================== #ifndef CHIP_CONFIG_MAX_UNSOLICITED_MESSAGE_HANDLERS -#define CHIP_CONFIG_MAX_UNSOLICITED_MESSAGE_HANDLERS 16 +#define CHIP_CONFIG_MAX_UNSOLICITED_MESSAGE_HANDLERS 8 #endif // CHIP_CONFIG_MAX_UNSOLICITED_MESSAGE_HANDLERS #ifndef CHIP_CONFIG_MAX_EXCHANGE_CONTEXTS @@ -61,3 +61,7 @@ #ifndef CHIP_CONFIG_BDX_MAX_NUM_TRANSFERS #define CHIP_CONFIG_BDX_MAX_NUM_TRANSFERS 1 #endif // CHIP_CONFIG_BDX_MAX_NUM_TRANSFERS + +#ifndef CHIP_CONFIG_MAX_FABRICS +#define CHIP_CONFIG_MAX_FABRICS 5 +#endif diff --git a/src/platform/telink/FactoryDataProvider.h b/src/platform/telink/FactoryDataProvider.h index 040a0d44ca9ba8..829831e554aa33 100644 --- a/src/platform/telink/FactoryDataProvider.h +++ b/src/platform/telink/FactoryDataProvider.h @@ -34,8 +34,8 @@ struct InternalFlashFactoryData { CHIP_ERROR GetFactoryDataPartition(uint8_t *& data, size_t & dataSize) { - data = reinterpret_cast(FLASH_AREA_OFFSET(factory_data)); - dataSize = FLASH_AREA_SIZE(factory_data); + data = reinterpret_cast(FIXED_PARTITION_OFFSET(factory_partition)); + dataSize = FIXED_PARTITION_SIZE(factory_partition); return CHIP_NO_ERROR; } @@ -46,7 +46,8 @@ struct ExternalFlashFactoryData { CHIP_ERROR GetFactoryDataPartition(uint8_t *& data, size_t & dataSize) { - int ret = flash_read(mFlashDevice, FLASH_AREA_OFFSET(factory_data), mFactoryDataBuffer, FLASH_AREA_SIZE(factory_data)); + int ret = flash_read(mFlashDevice, FIXED_PARTITION_OFFSET(factory_partition), mFactoryDataBuffer, + FIXED_PARTITION_SIZE(factory_partition)); if (ret != 0) { @@ -54,7 +55,7 @@ struct ExternalFlashFactoryData } data = mFactoryDataBuffer; - dataSize = FLASH_AREA_SIZE(factory_data); + dataSize = FIXED_PARTITION_SIZE(factory_partition); return CHIP_NO_ERROR; } @@ -62,7 +63,7 @@ struct ExternalFlashFactoryData CHIP_ERROR ProtectFactoryDataPartitionAgainstWrite() { return CHIP_ERROR_NOT_IMPLEMENTED; } const struct device * mFlashDevice = DEVICE_DT_GET(DT_CHOSEN(zephyr_flash_controller)); - uint8_t mFactoryDataBuffer[FLASH_AREA_SIZE(factory_data)]; + uint8_t mFactoryDataBuffer[FIXED_PARTITION_SIZE(factory_partition)]; }; template @@ -107,8 +108,8 @@ class FactoryDataProvider : public chip::Credentials::DeviceAttestationCredentia CHIP_ERROR GetEnableKey(MutableByteSpan & enableKey); private: - static constexpr uint16_t kFactoryDataPartitionSize = FLASH_AREA_SIZE(factory_data); - static constexpr uint32_t kFactoryDataPartitionAddress = FLASH_AREA_OFFSET(factory_data); + static constexpr uint16_t kFactoryDataPartitionSize = FIXED_PARTITION_SIZE(factory_partition); + static constexpr uint32_t kFactoryDataPartitionAddress = FIXED_PARTITION_OFFSET(factory_partition); static constexpr uint8_t kDACPrivateKeyLength = 32; static constexpr uint8_t kDACPublicKeyLength = 65; diff --git a/src/platform/telink/OTAImageProcessorImpl.cpp b/src/platform/telink/OTAImageProcessorImpl.cpp index f0c3c4de5cdd35..b5649820dace72 100644 --- a/src/platform/telink/OTAImageProcessorImpl.cpp +++ b/src/platform/telink/OTAImageProcessorImpl.cpp @@ -52,8 +52,8 @@ CHIP_ERROR OTAImageProcessorImpl::PrepareDownloadImpl() return System::MapErrorZephyr(-EFAULT); } - int err = - stream_flash_init(&stream, flash_dev, mBuffer, sizeof(mBuffer), FLASH_AREA_OFFSET(image_1), FLASH_AREA_SIZE(image_1), NULL); + int err = stream_flash_init(&stream, flash_dev, mBuffer, sizeof(mBuffer), FIXED_PARTITION_OFFSET(slot1_partition), + FIXED_PARTITION_SIZE(slot1_partition), NULL); if (err) { diff --git a/src/platform/tests/BUILD.gn b/src/platform/tests/BUILD.gn index d34c8b00c88ce4..1de55b7be409ce 100644 --- a/src/platform/tests/BUILD.gn +++ b/src/platform/tests/BUILD.gn @@ -83,7 +83,7 @@ if (chip_device_platform != "none" && chip_device_platform != "fake") { } if (current_os == "zephyr" || current_os == "android" || - current_os == "mbed") { + current_os == "mbed" || current_os == "cmsis-rtos") { test_sources += [ "TestKeyValueStoreMgr.cpp" ] } diff --git a/src/platform/webos/BLEManagerImpl.cpp b/src/platform/webos/BLEManagerImpl.cpp index ad8aec549d0f00..4aef02746ebc5a 100644 --- a/src/platform/webos/BLEManagerImpl.cpp +++ b/src/platform/webos/BLEManagerImpl.cpp @@ -72,7 +72,7 @@ void HandleIncomingBleConnection(BLEEndPoint * bleEP) ChipLogProgress(DeviceLayer, "con rcvd"); } -void BLEManagerImpl::InitConnectionData(void) +void BLEManagerImpl::InitConnectionData() { /* Initialize Hashmap */ if (!mConnectionMap) @@ -917,7 +917,7 @@ void BLEManagerImpl::NotifyBLEPeripheralAdvStopComplete(bool aIsSuccess, void * PlatformMgr().PostEventOrDie(&event); } -void BLEManagerImpl::OnChipScanComplete(void) +void BLEManagerImpl::OnChipScanComplete() { if (mBLEScanConfig.mBleScanState != BleScanState::kScanForDiscriminator && mBLEScanConfig.mBleScanState != BleScanState::kScanForAddress) diff --git a/src/platform/webos/ChipDeviceScanner.cpp b/src/platform/webos/ChipDeviceScanner.cpp index d75723efbf5521..7e3a4b71b9f0a9 100644 --- a/src/platform/webos/ChipDeviceScanner.cpp +++ b/src/platform/webos/ChipDeviceScanner.cpp @@ -322,7 +322,7 @@ bool ChipDeviceScanner::cancelDiscoveryCb(LSHandle * sh, LSMessage * message, vo return true; } -CHIP_ERROR ChipDeviceScanner::StopChipScan(void) +CHIP_ERROR ChipDeviceScanner::StopChipScan() { int ret = 0; ReturnErrorCodeIf(!mIsScanning, CHIP_ERROR_INCORRECT_STATE); diff --git a/src/platform/webos/ConfigurationManagerImpl.cpp b/src/platform/webos/ConfigurationManagerImpl.cpp index aaad2515f963d5..a7815277a215fd 100644 --- a/src/platform/webos/ConfigurationManagerImpl.cpp +++ b/src/platform/webos/ConfigurationManagerImpl.cpp @@ -285,7 +285,7 @@ CHIP_ERROR ConfigurationManagerImpl::WriteConfigValueBin(Key key, const uint8_t return PosixConfig::WriteConfigValueBin(key, data, dataLen); } -void ConfigurationManagerImpl::RunConfigUnitTest(void) +void ConfigurationManagerImpl::RunConfigUnitTest() { PosixConfig::RunConfigUnitTest(); } diff --git a/src/platform/webos/MainLoop.cpp b/src/platform/webos/MainLoop.cpp index 52f4a95f5f2956..3f55eccf0a7d7b 100644 --- a/src/platform/webos/MainLoop.cpp +++ b/src/platform/webos/MainLoop.cpp @@ -140,7 +140,7 @@ void MainLoop::DeleteData(LoopData * loopData) chip::Platform::Delete(loopData); } -void MainLoop::Deinit(void) +void MainLoop::Deinit() { std::vector::const_iterator iter = mLoopData.cbegin(); while (iter != mLoopData.cend()) @@ -203,7 +203,7 @@ gpointer MainLoop::ThreadStartLSMainLoopHandler(gpointer data) return NULL; } -bool MainLoop::StartLSMainLoop(void) +bool MainLoop::StartLSMainLoop() { bool result = true; LSError lserror; @@ -238,7 +238,7 @@ bool MainLoop::StartLSMainLoop(void) return result; } -MainLoop & MainLoop::Instance(void) +MainLoop & MainLoop::Instance() { static MainLoop sMainLoop; return sMainLoop; diff --git a/src/protocols/secure_channel/CASESession.cpp b/src/protocols/secure_channel/CASESession.cpp index 3c4d2572fb926b..67351f96c0903a 100644 --- a/src/protocols/secure_channel/CASESession.cpp +++ b/src/protocols/secure_channel/CASESession.cpp @@ -628,6 +628,7 @@ CHIP_ERROR CASESession::HandleSigma1(System::PacketBufferHandle && msg) ChipLogError(SecureChannel, "CASE failed to match destination ID with local fabrics"); ChipLogByteSpan(SecureChannel, destinationIdentifier); } + SuccessOrExit(err); // ParseSigma1 ensures that: // mRemotePubKey.Length() == initiatorPubKey.size() == kP256_PublicKey_Length. @@ -1041,7 +1042,7 @@ CHIP_ERROR CASESession::HandleSigma2(System::PacketBufferHandle && msg) // Verify that responderNodeId (from responderNOC) matches one that was included // in the computation of the Destination Identifier when generating Sigma1. - VerifyOrReturnError(mPeerNodeId == responderNodeId, CHIP_ERROR_INVALID_CASE_PARAMETER); + VerifyOrExit(mPeerNodeId == responderNodeId, err = CHIP_ERROR_INVALID_CASE_PARAMETER); // Construct msg_R2_Signed and validate the signature in msg_r2_encrypted msg_r2_signed_len = TLV::EstimateStructOverhead(sizeof(uint16_t), responderNOC.size(), responderICAC.size(), diff --git a/src/protocols/secure_channel/tests/TestCASESession.cpp b/src/protocols/secure_channel/tests/TestCASESession.cpp index 9c62a48e046908..8af555796e5bec 100644 --- a/src/protocols/secure_channel/tests/TestCASESession.cpp +++ b/src/protocols/secure_channel/tests/TestCASESession.cpp @@ -310,6 +310,7 @@ class TestCASESession #if CONFIG_BUILD_FOR_HOST_UNIT_TEST static void SimulateUpdateNOCInvalidatePendingEstablishment(nlTestSuite * inSuite, void * inContext); #endif // CONFIG_BUILD_FOR_HOST_UNIT_TEST + static void Sigma1BadDestinationIdTest(nlTestSuite * inSuite, void * inContext); }; void TestCASESession::SecurePairingWaitTest(nlTestSuite * inSuite, void * inContext) @@ -1005,6 +1006,88 @@ void TestCASESession::SimulateUpdateNOCInvalidatePendingEstablishment(nlTestSuit } #endif // CONFIG_BUILD_FOR_HOST_UNIT_TEST +namespace { +class ExpectErrorExchangeDelegate : public ExchangeDelegate +{ +public: + ExpectErrorExchangeDelegate(nlTestSuite * suite, uint16_t expectedProtocolCode) : + mSuite(suite), mExpectedProtocolCode(expectedProtocolCode) + {} + +private: + CHIP_ERROR OnMessageReceived(ExchangeContext * ec, const PayloadHeader & payloadHeader, + System::PacketBufferHandle && buf) override + { + using namespace SecureChannel; + + NL_TEST_ASSERT(mSuite, payloadHeader.HasMessageType(MsgType::StatusReport)); + + SecureChannel::StatusReport statusReport; + CHIP_ERROR err = statusReport.Parse(std::move(buf)); + NL_TEST_ASSERT(mSuite, err == CHIP_NO_ERROR); + + NL_TEST_ASSERT(mSuite, statusReport.GetProtocolId() == SecureChannel::Id); + NL_TEST_ASSERT(mSuite, statusReport.GetGeneralCode() == GeneralStatusCode::kFailure); + NL_TEST_ASSERT(mSuite, statusReport.GetProtocolCode() == mExpectedProtocolCode); + return CHIP_NO_ERROR; + } + + void OnResponseTimeout(ExchangeContext * ec) override {} + + Messaging::ExchangeMessageDispatch & GetMessageDispatch() override { return SessionEstablishmentExchangeDispatch::Instance(); } + + nlTestSuite * mSuite; + uint16_t mExpectedProtocolCode; +}; +} // anonymous namespace + +void TestCASESession::Sigma1BadDestinationIdTest(nlTestSuite * inSuite, void * inContext) +{ + using SecureChannel::MsgType; + + TestContext & ctx = *reinterpret_cast(inContext); + + SessionManager & sessionManager = ctx.GetSecureSessionManager(); + + constexpr size_t bufferSize = 600; + System::PacketBufferHandle data = chip::System::PacketBufferHandle::New(bufferSize); + NL_TEST_ASSERT(inSuite, !data.IsNull()); + + MutableByteSpan buf(data->Start(), data->AvailableDataLength()); + // This uses a bogus destination id that is not going to match anything in practice. + CHIP_ERROR err = EncodeSigma1(buf); + NL_TEST_ASSERT(inSuite, err == CHIP_NO_ERROR); + data->SetDataLength(static_cast(buf.size())); + + Optional session = sessionManager.CreateUnauthenticatedSession(ctx.GetAliceAddress(), GetDefaultMRPConfig()); + NL_TEST_ASSERT(inSuite, session.HasValue()); + + TestCASESecurePairingDelegate caseDelegate; + CASESession caseSession; + caseSession.SetGroupDataProvider(&gDeviceGroupDataProvider); + err = caseSession.PrepareForSessionEstablishment(sessionManager, &gDeviceFabrics, nullptr, nullptr, &caseDelegate, + ScopedNodeId(), NullOptional); + NL_TEST_ASSERT(inSuite, err == CHIP_NO_ERROR); + + err = ctx.GetExchangeManager().RegisterUnsolicitedMessageHandlerForType(MsgType::CASE_Sigma1, &caseSession); + NL_TEST_ASSERT(inSuite, err == CHIP_NO_ERROR); + + ExpectErrorExchangeDelegate delegate(inSuite, SecureChannel::kProtocolCodeNoSharedRoot); + ExchangeContext * exchange = ctx.GetExchangeManager().NewContext(session.Value(), &delegate); + NL_TEST_ASSERT(inSuite, exchange != nullptr); + + err = exchange->SendMessage(MsgType::CASE_Sigma1, std::move(data), SendMessageFlags::kExpectResponse); + NL_TEST_ASSERT(inSuite, err == CHIP_NO_ERROR); + + ctx.DrainAndServiceIO(); + + NL_TEST_ASSERT(inSuite, caseDelegate.mNumPairingErrors == 1); + NL_TEST_ASSERT(inSuite, caseDelegate.mNumPairingComplete == 0); + + ctx.GetExchangeManager().UnregisterUnsolicitedMessageHandlerForType(MsgType::CASE_Sigma1); + caseSession.Clear(); +} + } // namespace chip // Test Suite @@ -1027,6 +1110,7 @@ static const nlTest sTests[] = // CASESession that are in the process of establishing. NL_TEST_DEF("InvalidatePendingSessionEstablishment", chip::TestCASESession::SimulateUpdateNOCInvalidatePendingEstablishment), #endif // CONFIG_BUILD_FOR_HOST_UNIT_TEST + NL_TEST_DEF("Sigma1BadDestinationId", chip::TestCASESession::Sigma1BadDestinationIdTest), NL_TEST_SENTINEL() }; diff --git a/src/pybindings/pycontroller/BUILD.gn b/src/pybindings/pycontroller/BUILD.gn index c4dce518c4e622..b15e424098a9b4 100644 --- a/src/pybindings/pycontroller/BUILD.gn +++ b/src/pybindings/pycontroller/BUILD.gn @@ -50,7 +50,7 @@ shared_library("CHIPController") { } else if (current_os == "linux") { include_dirs += [ "/usr/include/python3.9" ] } else { - assert(false, "OS not supprted.") + assert(false, "OS not supported.") } sources = [ diff --git a/src/setup_payload/QRCodeSetupPayloadGenerator.cpp b/src/setup_payload/QRCodeSetupPayloadGenerator.cpp index c6531482a56344..386000ba452a35 100644 --- a/src/setup_payload/QRCodeSetupPayloadGenerator.cpp +++ b/src/setup_payload/QRCodeSetupPayloadGenerator.cpp @@ -53,7 +53,8 @@ static CHIP_ERROR populateBits(uint8_t * bits, size_t & offset, uint64_t input, { if (input & 1) { - bits[index / 8] |= static_cast(1 << index % 8); + const uint8_t mask = static_cast(1 << index % 8); + bits[index / 8] = static_cast(bits[index / 8] | mask); } index++; input >>= 1; diff --git a/src/system/BUILD.gn b/src/system/BUILD.gn index 76d64235fd0389..348e3af0ebf5f1 100644 --- a/src/system/BUILD.gn +++ b/src/system/BUILD.gn @@ -65,6 +65,8 @@ buildconfig_header("system_buildconfig") { chip_system_config_posix_locking = chip_system_config_locking == "posix" chip_system_config_freertos_locking = chip_system_config_locking == "freertos" chip_system_config_mbed_locking = chip_system_config_locking == "mbed" + chip_system_config_cmsis_rtos_locking = + chip_system_config_locking == "cmsis-rtos" chip_system_config_no_locking = chip_system_config_locking == "none" have_clock_gettime = chip_system_config_clock == "clock_gettime" have_clock_settime = have_clock_gettime @@ -82,6 +84,7 @@ buildconfig_header("system_buildconfig") { "CHIP_SYSTEM_CONFIG_POSIX_LOCKING=${chip_system_config_posix_locking}", "CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING=${chip_system_config_freertos_locking}", "CHIP_SYSTEM_CONFIG_MBED_LOCKING=${chip_system_config_mbed_locking}", + "CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING=${chip_system_config_cmsis_rtos_locking}", "CHIP_SYSTEM_CONFIG_NO_LOCKING=${chip_system_config_no_locking}", "CHIP_SYSTEM_CONFIG_PROVIDE_STATISTICS=${chip_system_config_provide_statistics}", "HAVE_CLOCK_GETTIME=${have_clock_gettime}", diff --git a/src/system/SystemConfig.h b/src/system/SystemConfig.h index 87171af3352059..c214e922ca84f8 100644 --- a/src/system/SystemConfig.h +++ b/src/system/SystemConfig.h @@ -155,6 +155,10 @@ #define CHIP_SYSTEM_CONFIG_MBED_LOCKING INET_CONFIG_MBED_LOCKING #endif // !defined(CHIP_SYSTEM_CONFIG_MBED_LOCKING) && defined(INET_CONFIG_MBED_LOCKING) +#if !defined(CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING) && defined(INET_CONFIG_CMSIS_RTOS_LOCKING) +#define CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING INET_CONFIG_CMSIS_RTOS_LOCKING +#endif // !defined(CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING) && defined(INET_CONFIG_CMSIS_RTOS_LOCKING) + #if !defined(CHIP_SYSTEM_CONFIG_PACKETBUFFER_POOL_SIZE) && defined(INET_CONFIG_NUM_BUFS) #define CHIP_SYSTEM_CONFIG_PACKETBUFFER_POOL_SIZE INET_CONFIG_NUM_BUFS #endif // !defined(CHIP_SYSTEM_CONFIG_PACKETBUFFER_POOL_SIZE) && defined(INET_CONFIG_NUM_BUFS) @@ -174,18 +178,6 @@ /* Configuration option variables defined below */ -/** - * @def CHIP_SYSTEM_CONFIG_NO_LOCKING - * - * @brief - * Disable the use of locking within the system layer. - * - * Unless you are simulating an LwIP-based system on a Unix-style host, this value should be left at its default. - */ -#ifndef CHIP_SYSTEM_CONFIG_NO_LOCKING -#define CHIP_SYSTEM_CONFIG_NO_LOCKING 0 -#endif /* CHIP_SYSTEM_CONFIG_NO_LOCKING */ - /** * @def CHIP_SYSTEM_CONFIG_POSIX_LOCKING * @@ -226,6 +218,20 @@ #define CHIP_SYSTEM_CONFIG_MBED_LOCKING 0 #endif /* CHIP_SYSTEM_CONFIG_MBED_LOCKING */ +/** + * @def CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING + * + * @brief + * Use CMSIS-RTOS locking. + * + * This should be generally asserted (1) for CMSIS-RTOS. + * + * However, if you are simulating an LwIP-based system atop POSIX threads and BSD sockets, this should also be deasserted (0). + */ +#ifndef CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING +#define CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING 0 +#endif /* CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING */ + /** * @def CHIP_SYSTEM_CONFIG_POOL_USE_HEAP * @@ -248,13 +254,13 @@ #define CHIP_SYSTEM_CONFIG_NO_LOCKING 0 #endif /* CHIP_SYSTEM_CONFIG_NO_LOCKING */ -#if !(CHIP_SYSTEM_CONFIG_POSIX_LOCKING || CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING || CHIP_SYSTEM_CONFIG_MBED_LOCKING || CHIP_SYSTEM_CONFIG_NO_LOCKING) -#error "REQUIRED: CHIP_SYSTEM_CONFIG_POSIX_LOCKING || CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING || CHIP_SYSTEM_CONFIG_MBED_LOCKING || CHIP_SYSTEM_CONFIG_NO_LOCKING" -#endif // !(CHIP_SYSTEM_CONFIG_POSIX_LOCKING || CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING || CHIP_SYSTEM_CONFIG_MBED_LOCKING || CHIP_SYSTEM_CONFIG_NO_LOCKING) +#if !(CHIP_SYSTEM_CONFIG_POSIX_LOCKING || CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING || CHIP_SYSTEM_CONFIG_MBED_LOCKING || CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING ||CHIP_SYSTEM_CONFIG_NO_LOCKING) +#error "REQUIRED: CHIP_SYSTEM_CONFIG_POSIX_LOCKING || CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING || CHIP_SYSTEM_CONFIG_MBED_LOCKING || CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING || CHIP_SYSTEM_CONFIG_NO_LOCKING" +#endif // !(CHIP_SYSTEM_CONFIG_POSIX_LOCKING || CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING || CHIP_SYSTEM_CONFIG_MBED_LOCKING || CHIP_SYSTEM_CONFIG_NO_LOCKING || CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING) -#if CHIP_SYSTEM_CONFIG_NO_LOCKING && (CHIP_SYSTEM_CONFIG_POSIX_LOCKING || CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING || CHIP_SYSTEM_CONFIG_MBED_LOCKING) -#error "FORBIDDEN: CHIP_SYSTEM_CONFIG_NO_LOCKING && (CHIP_SYSTEM_CONFIG_POSIX_LOCKING || CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING || CHIP_SYSTEM_CONFIG_MBED_LOCKING)" -#endif // CHIP_SYSTEM_CONFIG_NO_LOCKING && (CHIP_SYSTEM_CONFIG_POSIX_LOCKING || CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING || CHIP_SYSTEM_CONFIG_MBED_LOCKING) +#if CHIP_SYSTEM_CONFIG_NO_LOCKING && (CHIP_SYSTEM_CONFIG_POSIX_LOCKING || CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING || CHIP_SYSTEM_CONFIG_MBED_LOCKING || CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING) +#error "FORBIDDEN: CHIP_SYSTEM_CONFIG_NO_LOCKING && (CHIP_SYSTEM_CONFIG_POSIX_LOCKING || CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING || CHIP_SYSTEM_CONFIG_MBED_LOCKING || CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING)" +#endif // CHIP_SYSTEM_CONFIG_NO_LOCKING && (CHIP_SYSTEM_CONFIG_POSIX_LOCKING || CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING || CHIP_SYSTEM_CONFIG_MBED_LOCKING || CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING) #if CHIP_SYSTEM_CONFIG_POSIX_LOCKING && CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING #error "FORBIDDEN: CHIP_SYSTEM_CONFIG_POSIX_LOCKING && CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING" @@ -268,6 +274,18 @@ #error "FORBIDDEN: CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING && CHIP_SYSTEM_CONFIG_MBED_LOCKING" #endif // CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING && CHIP_SYSTEM_CONFIG_MBED_LOCKING +#if CHIP_SYSTEM_CONFIG_POSIX_LOCKING && CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING +#error "FORBIDDEN: CHIP_SYSTEM_CONFIG_POSIX_LOCKING && CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING" +#endif // CHIP_SYSTEM_CONFIG_POSIX_LOCKING && CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING + +#if CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING && CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING +#error "FORBIDDEN: CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING && CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING" +#endif // CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING && CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING + +#if CHIP_SYSTEM_CONFIG_MBED_LOCKING && CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING +#error "FORBIDDEN: CHIP_SYSTEM_CONFIG_MBED_LOCKING && CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING" +#endif // CHIP_SYSTEM_CONFIG_MBED_LOCKING && CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING + /** * @def CHIP_SYSTEM_HEADER_RESERVE_SIZE * @@ -505,6 +523,18 @@ struct LwIPEvent; #endif /* !CHIP_SYSTEM_CONFIG_USE_LWIP */ #endif /* CHIP_SYSTEM_CONFIG_HEADER_RESERVE_SIZE */ +/** + * @def CHIP_SYSTEM_CONFIG_PLATFORM_LOG + * + * @brief + * Defines whether (1) or not (0) the system uses a platform-specific logging implementation. + * + * See CHIPLogging.h for details. + */ +#ifndef CHIP_SYSTEM_CONFIG_PLATFORM_LOG +#define CHIP_SYSTEM_CONFIG_PLATFORM_LOG 0 +#endif // CHIP_SYSTEM_CONFIG_PLATFORM_LOG + /** * @def CHIP_SYSTEM_CONFIG_PLATFORM_PROVIDES_TIME * diff --git a/src/system/SystemMutex.cpp b/src/system/SystemMutex.cpp index 878a1dda9b1983..ca6283ccd000aa 100644 --- a/src/system/SystemMutex.cpp +++ b/src/system/SystemMutex.cpp @@ -25,6 +25,8 @@ // Include module header #include +#include + #if !CHIP_SYSTEM_CONFIG_NO_LOCKING // Include system headers @@ -108,6 +110,35 @@ DLL_EXPORT void Mutex::Lock(void) } #endif // CHIP_SYSTEM_CONFIG_FREERTOS_LOCKING +#if CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING +DLL_EXPORT CHIP_ERROR Mutex::Init(Mutex & aThis) +{ + aThis.mCmsisRTOSMutex = osMutexNew(NULL); + if (aThis.mCmsisRTOSMutex == NULL) + { + ChipLogError(chipSystemLayer, "osMutexNew failed"); + return CHIP_ERROR_NO_MEMORY; + } + return CHIP_NO_ERROR; +} + +DLL_EXPORT void Mutex::Lock(void) +{ + if (mCmsisRTOSMutex && osMutexAcquire(mCmsisRTOSMutex, osWaitForever) != osOK) + { + ChipLogError(chipSystemLayer, "osMutexAcquire failed"); + } +} + +DLL_EXPORT void Mutex::Unlock(void) +{ + if (mCmsisRTOSMutex && osMutexRelease(mCmsisRTOSMutex) != osOK) + { + ChipLogError(chipSystemLayer, "osMutexRelease failed"); + } +} +#endif // CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING + } // namespace System } // namespace chip diff --git a/src/system/SystemMutex.h b/src/system/SystemMutex.h index 09470b4d66df8b..13c8337c6c7ffb 100644 --- a/src/system/SystemMutex.h +++ b/src/system/SystemMutex.h @@ -52,6 +52,10 @@ #include #endif // CHIP_SYSTEM_CONFIG_MBED_LOCKING +#if CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING +#include +#endif // CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING + namespace chip { namespace System { @@ -101,6 +105,10 @@ class DLL_EXPORT Mutex rtos::Mutex mMbedMutex; #endif // CHIP_SYSTEM_CONFIG_MBED_LOCKING +#if CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING + osMutexId_t mCmsisRTOSMutex; +#endif // CHIP_SYSTEM_CONFIG_CMSIS_RTOS_LOCKING + Mutex(const Mutex &) = delete; Mutex & operator=(const Mutex &) = delete; }; diff --git a/src/system/system.gni b/src/system/system.gni index 0a27615c40a577..f65a610bd88161 100644 --- a/src/system/system.gni +++ b/src/system/system.gni @@ -57,6 +57,8 @@ if (chip_system_config_locking == "") { chip_system_config_locking = "freertos" } else if (current_os == "mbed") { chip_system_config_locking = "mbed" + } else if (current_os == "cmsis-rtos") { + chip_system_config_locking = "cmsis-rtos" } else if (chip_system_config_use_dispatch == false) { chip_system_config_locking = "posix" } else { @@ -68,8 +70,9 @@ assert( chip_system_config_locking == "posix" || chip_system_config_locking == "freertos" || chip_system_config_locking == "none" || - chip_system_config_locking == "mbed", - "Please select a valid mutex implementation: posix, freertos, mbed, none") + chip_system_config_locking == "mbed" || + chip_system_config_locking == "cmsis-rtos", + "Please select a valid mutex implementation: posix, freertos, mbed, cmsis-rtos, none") assert( chip_system_config_clock == "clock_gettime" || diff --git a/src/system/tests/TestSystemClock.cpp b/src/system/tests/TestSystemClock.cpp index 1ac5b994a2edb2..d0bd76e08ec010 100644 --- a/src/system/tests/TestSystemClock.cpp +++ b/src/system/tests/TestSystemClock.cpp @@ -115,7 +115,7 @@ static const nlTest sTests[] = }; // clang-format on -int TestSystemClock(void) +int TestSystemClock() { nlTestSuite theSuite = { "chip-systemclock", &sTests[0], nullptr /* setup */, nullptr /* teardown */ diff --git a/src/system/tests/TestSystemErrorStr.cpp b/src/system/tests/TestSystemErrorStr.cpp index 2cd02610bc9df1..437d5fc1a69ca8 100644 --- a/src/system/tests/TestSystemErrorStr.cpp +++ b/src/system/tests/TestSystemErrorStr.cpp @@ -97,7 +97,7 @@ static const nlTest sTests[] = }; // clang-format on -int TestSystemErrorStr(void) +int TestSystemErrorStr() { // clang-format off nlTestSuite theSuite = diff --git a/src/system/tests/TestSystemPacketBuffer.cpp b/src/system/tests/TestSystemPacketBuffer.cpp index f1f584e26f31f1..0cec7450efc565 100644 --- a/src/system/tests/TestSystemPacketBuffer.cpp +++ b/src/system/tests/TestSystemPacketBuffer.cpp @@ -2008,7 +2008,7 @@ const nlTest sTests[] = }; // clang-format on -int TestSystemPacketBuffer(void) +int TestSystemPacketBuffer() { // clang-format off nlTestSuite theSuite = { diff --git a/src/system/tests/TestSystemScheduleLambda.cpp b/src/system/tests/TestSystemScheduleLambda.cpp index db43fcf36a78e7..9dd78829bb4ff5 100644 --- a/src/system/tests/TestSystemScheduleLambda.cpp +++ b/src/system/tests/TestSystemScheduleLambda.cpp @@ -83,7 +83,7 @@ static int TestTeardown(void * aContext) return (SUCCESS); } -int TestSystemScheduleLambda(void) +int TestSystemScheduleLambda() { // Run test suit againt one lContext. nlTestRunner(&kTheSuite, nullptr); diff --git a/src/system/tests/TestSystemScheduleWork.cpp b/src/system/tests/TestSystemScheduleWork.cpp index 6c858905f50b76..05b047997f9311 100644 --- a/src/system/tests/TestSystemScheduleWork.cpp +++ b/src/system/tests/TestSystemScheduleWork.cpp @@ -96,7 +96,7 @@ static int TestTeardown(void * aContext) return (SUCCESS); } -int TestSystemScheduleWork(void) +int TestSystemScheduleWork() { // Run test suit againt one lContext. nlTestRunner(&kTheSuite, nullptr); diff --git a/src/system/tests/TestSystemTimer.cpp b/src/system/tests/TestSystemTimer.cpp index 1ad153369a13c2..9188d63656a06a 100644 --- a/src/system/tests/TestSystemTimer.cpp +++ b/src/system/tests/TestSystemTimer.cpp @@ -625,12 +625,14 @@ static int TestSetup(void * aContext) return FAILURE; } +#if !defined(CHIP_DEVICE_LAYER_TARGET_OPEN_IOT_SDK) #if CHIP_SYSTEM_CONFIG_USE_LWIP && LWIP_VERSION_MAJOR == 2 && LWIP_VERSION_MINOR == 0 static sys_mbox_t * sLwIPEventQueue = NULL; sys_mbox_new(sLwIPEventQueue, 100); tcpip_init(NULL, NULL); #endif // CHIP_SYSTEM_CONFIG_USE_LWIP && LWIP_VERSION_MAJOR == 2 && LWIP_VERSION_MINOR == 0 +#endif // !defined(CHIP_DEVICE_LAYER_TARGET_OPEN_IOT_SDK) sLayer.Init(); @@ -650,15 +652,17 @@ static int TestTeardown(void * aContext) lContext.mLayer->Shutdown(); +#if !defined(CHIP_DEVICE_LAYER_TARGET_OPEN_IOT_SDK) #if CHIP_SYSTEM_CONFIG_USE_LWIP && (LWIP_VERSION_MAJOR == 2) && (LWIP_VERSION_MINOR == 0) tcpip_finish(NULL, NULL); #endif // CHIP_SYSTEM_CONFIG_USE_LWIP && (LWIP_VERSION_MAJOR == 2) && (LWIP_VERSION_MINOR == 0) +#endif // !defined(CHIP_DEVICE_LAYER_TARGET_OPEN_IOT_SDK) ::chip::Platform::MemoryShutdown(); return (SUCCESS); } -int TestSystemTimer(void) +int TestSystemTimer() { return chip::ExecuteTestsWithContext(&kTheSuite); } diff --git a/src/system/tests/TestSystemWakeEvent.cpp b/src/system/tests/TestSystemWakeEvent.cpp index 2c77f7d9d7bf0f..e311f75f642ce3 100644 --- a/src/system/tests/TestSystemWakeEvent.cpp +++ b/src/system/tests/TestSystemWakeEvent.cpp @@ -182,7 +182,7 @@ static const nlTest sTests[] = static nlTestSuite kTheSuite = { "chip-system-wake-event", sTests }; -int TestSystemWakeEvent(void) +int TestSystemWakeEvent() { return chip::ExecuteTestsWithContext(&kTheSuite); } diff --git a/src/system/tests/TestTimeSource.cpp b/src/system/tests/TestTimeSource.cpp index 89ce5b6bad57e4..59a15e57d5d345 100644 --- a/src/system/tests/TestTimeSource.cpp +++ b/src/system/tests/TestTimeSource.cpp @@ -78,7 +78,7 @@ static const nlTest sTests[] = }; // clang-format on -int TestTimeSource(void) +int TestTimeSource() { nlTestSuite theSuite = { "chip-timesource", &sTests[0], nullptr /* setup */, nullptr /* teardown */ diff --git a/src/test_driver/efr32/include/CHIPProjectConfig.h b/src/test_driver/efr32/include/CHIPProjectConfig.h index 04b0577e94ced3..451292ff519b7b 100644 --- a/src/test_driver/efr32/include/CHIPProjectConfig.h +++ b/src/test_driver/efr32/include/CHIPProjectConfig.h @@ -65,16 +65,6 @@ */ #define CHIP_DEVICE_CONFIG_DEVICE_HARDWARE_VERSION 1 -/** - * CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING - * - * A string identifying the software version running on the device. - * CHIP service currently expects the software version to be in the format - * {MAJOR_VERSION}.0d{MINOR_VERSION} - */ -#ifndef CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING -#define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING "0.1ALPHA" -#endif /** * CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE * diff --git a/src/test_driver/nrfconnect/CMakeLists.txt b/src/test_driver/nrfconnect/CMakeLists.txt index 7d145d6df9e0ed..39648928a5dde2 100644 --- a/src/test_driver/nrfconnect/CMakeLists.txt +++ b/src/test_driver/nrfconnect/CMakeLists.txt @@ -47,15 +47,6 @@ set(CHIP_CFLAGS -isystem$ENV{ZEPHYR_BASE}/../mbedtls/include ) -set(CHIP_TESTS - -lCHIP_tests -) - -set(CHIP_LIBRARIES - -lCHIP - ${CHIP_TESTS} -) - # Load NCS/Zephyr build system list(APPEND ZEPHYR_EXTRA_MODULES ${CHIP_ROOT}/config/nrfconnect/chip-module) find_package(Zephyr HINTS $ENV{ZEPHYR_BASE}) @@ -68,7 +59,6 @@ project(AllChipTests) enable_testing() target_sources(app PRIVATE main/runner.cpp) -target_link_options(app PUBLIC -Wl,--whole-archive ${CHIP_TESTS} -Wl,--no-whole-archive) target_link_libraries(app PUBLIC chip $) target_compile_definitions(app PUBLIC CHIP_HAVE_CONFIG_H) diff --git a/src/test_driver/openiotsdk/integration-tests/.gitignore b/src/test_driver/openiotsdk/integration-tests/.gitignore new file mode 100644 index 00000000000000..9e76edca71065a --- /dev/null +++ b/src/test_driver/openiotsdk/integration-tests/.gitignore @@ -0,0 +1 @@ +/**/test_report.json diff --git a/src/test_driver/openiotsdk/integration-tests/common/__init__.py b/src/test_driver/openiotsdk/integration-tests/common/__init__.py new file mode 100644 index 00000000000000..e69de29bb2d1d6 diff --git a/src/test_driver/openiotsdk/integration-tests/common/device.py b/src/test_driver/openiotsdk/integration-tests/common/device.py new file mode 100644 index 00000000000000..eff76e1c5ad413 --- /dev/null +++ b/src/test_driver/openiotsdk/integration-tests/common/device.py @@ -0,0 +1,120 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# All rights reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +import logging +import queue +from time import sleep, time +from typing import Optional + +log = logging.getLogger(__name__) + + +class Device: + + def __init__(self, name: Optional[str] = None): + """ + Base Device runner class containing device handling functions and logging + :param name: Logging name for the client + """ + self.iq = queue.Queue() + self.oq = queue.Queue() + if name is None: + self.name = str(hex(id(self))) + else: + self.name = name + + def send(self, command, expected_output=None, wait_before_read=None, wait_for_response=10, assert_output=True): + """ + Send command for client + :param command: Command + :param expected_output: Reply to wait from the client + :param wait_before_read: Timeout after write + :param wait_for_response: Timeout waiting the response + :param assert_output: Assert the fail situations to end the test run + :return: If there's expected output then the response line is returned + """ + log.debug('{}: Sending command to client: "{}"'.format( + self.name, command)) + self.flush(0) + self._write(command) + if expected_output is not None: + if wait_before_read is not None: + sleep(wait_before_read) + return self.wait_for_output(expected_output, wait_for_response, assert_output) + + def flush(self, timeout: float = 0) -> [str]: + """ + Flush the lines in the input queue + :param timeout: The timeout before flushing starts + :type timeout: float + :return: The lines removed from the input queue + :rtype: list of str + """ + sleep(timeout) + lines = [] + while True: + try: + lines.append(self._read_line(0)) + except queue.Empty: + return lines + + def wait_for_output(self, search: str, timeout: float = 10, assert_timeout: bool = True) -> [str]: + """ + Wait for expected output response + :param search: Expected response string + :type search: str + :param timeout: Response waiting time + :type timeout: float + :param assert_timeout: Assert on timeout situations + :type assert_timeout: bool + :return: Line received before a match + :rtype: list of str + """ + lines = [] + start = time() + now = 0 + timeout_error_msg = '{}: Didn\'t find {} in {} s'.format( + self.name, search, timeout) + + while time() - start <= timeout: + try: + line = self._read_line(1) + if line: + lines.append(line) + if search in line: + end = time() + return lines + + except queue.Empty: + last = now + now = time() + if now - start >= timeout: + if assert_timeout: + log.error(timeout_error_msg) + assert False, timeout_error_msg + else: + log.warning(timeout_error_msg) + return [] + if now - last > 1: + log.info('{}: Waiting for "{}" string... Timeout in {:.0f} s'.format(self.name, search, + abs(now - start - timeout))) + + def _write(self, data): + self.oq.put(data) + + def _read_line(self, timeout): + return self.iq.get(timeout=timeout) diff --git a/src/test_driver/openiotsdk/integration-tests/common/fixtures.py b/src/test_driver/openiotsdk/integration-tests/common/fixtures.py new file mode 100644 index 00000000000000..2613b196567c00 --- /dev/null +++ b/src/test_driver/openiotsdk/integration-tests/common/fixtures.py @@ -0,0 +1,122 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# All rights reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +import pytest +import os +import pathlib +from time import sleep +import shutil + +from .telnet_connection import TelnetConnection +from .fvp_device import FvpDevice + +from chip import exceptions + +from chip import ChipDeviceCtrl +from chip.ChipStack import * +import chip.native +import chip.CertificateAuthority + +import logging +log = logging.getLogger(__name__) + + +@pytest.fixture(scope="session") +def rootDir(): + return pathlib.Path(__file__).parents[5].absolute() + + +@pytest.fixture(scope="session") +def fvp(request): + if request.config.getoption('fvp'): + return request.config.getoption('fvp') + else: + return shutil.which('FVP_Corstone_SSE-300_Ethos-U55') + + +@pytest.fixture(scope="session") +def fvpConfig(request, rootDir): + if request.config.getoption('fvpConfig'): + return request.config.getoption('fvpConfig') + else: + return os.path.join(rootDir, 'config/openiotsdk/fvp/cs300.conf') + + +@pytest.fixture(scope="session") +def telnetPort(request): + return request.config.getoption('telnetPort') + + +@pytest.fixture(scope="session") +def networkInterface(request): + if request.config.getoption('networkInterface'): + return request.config.getoption('networkInterface') + else: + return None + + +@pytest.fixture(scope="function") +def device(fvp, fvpConfig, binaryPath, telnetPort, networkInterface): + connection = TelnetConnection('localhost', telnetPort) + device = FvpDevice(fvp, fvpConfig, binaryPath, connection, networkInterface, "FVPdev") + device.start() + yield device + device.stop() + + +@pytest.fixture(scope="session") +def vendor_id(): + return 0xFFF1 + + +@pytest.fixture(scope="session") +def fabric_id(): + return 1 + + +@pytest.fixture(scope="session") +def node_id(): + return 1 + + +@pytest.fixture(scope="function") +def controller(vendor_id, fabric_id, node_id): + try: + chip.native.Init() + chipStack = chip.ChipStack.ChipStack( + persistentStoragePath='/tmp/openiotsdk-test-storage.json', enableServerInteractions=False) + certificateAuthorityManager = chip.CertificateAuthority.CertificateAuthorityManager( + chipStack, chipStack.GetStorageManager()) + certificateAuthorityManager.LoadAuthoritiesFromStorage() + if (len(certificateAuthorityManager.activeCaList) == 0): + ca = certificateAuthorityManager.NewCertificateAuthority() + ca.NewFabricAdmin(vendorId=vendor_id, fabricId=fabric_id) + elif (len(certificateAuthorityManager.activeCaList[0].adminList) == 0): + certificateAuthorityManager.activeCaList[0].NewFabricAdmin(vendorId=vendor_id, fabricId=fabric_id) + + caList = certificateAuthorityManager.activeCaList + + devCtrl = caList[0].adminList[0].NewController() + + except exceptions.ChipStackException as ex: + log.error("Controller initialization failed {}".format(ex)) + return None + except: + log.error("Controller initialization failed") + return None + + yield devCtrl diff --git a/src/test_driver/openiotsdk/integration-tests/common/fvp_device.py b/src/test_driver/openiotsdk/integration-tests/common/fvp_device.py new file mode 100644 index 00000000000000..3255e6a42eaf48 --- /dev/null +++ b/src/test_driver/openiotsdk/integration-tests/common/fvp_device.py @@ -0,0 +1,102 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# All rights reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +import logging +import threading +import os +import subprocess +from time import sleep + +from .device import Device + +log = logging.getLogger(__name__) + + +class FvpDevice(Device): + + def __init__(self, fvp, fvp_config, binary_file, connection_channel, network_interface, name=None): + + self.run = False + self.connection_channel = connection_channel + super(FvpDevice, self).__init__(name) + + input_thread_name = '<-- {}'.format(self.name) + output_thread_name = '--> {}'.format(self.name) + + self.fvp_cmd = [ + fvp, + '-f', f'{fvp_config}', + '--application', f'{binary_file}', + '--quantum=25', + '-C', 'mps3_board.telnetterminal0.start_port={}'.format(self.connection_channel.get_port()) + ] + + if network_interface != None: + self.fvp_cmd.extend(['-C', 'mps3_board.hostbridge.interfaceName={}'.format(network_interface), ]) + else: + self.fvp_cmd.extend(['-C', 'mps3_board.hostbridge.userNetworking=1']) + + self.it = threading.Thread( + target=self._input_thread, name=input_thread_name) + self.ot = threading.Thread( + target=self._output_thread, name=output_thread_name) + + def start(self): + """ + Start the FVP and connection channel with device + """ + log.info('Starting "{}" runner...'.format(self.name)) + + self.proc = subprocess.Popen(self.fvp_cmd) + sleep(3) + self.connection_channel.open() + self.run = True + self.it.start() + self.ot.start() + log.info('"{}" runner started'.format(self.name)) + + def stop(self): + """ + Stop the FVP and connection channel + """ + log.info('Stopping "{}" runner...'.format(self.name)) + self.run = False + self.connection_channel.close() + self.oq.put(None) + self.it.join() + self.ot.join() + self.proc.terminate() + self.proc.wait() + log.info('"{}" runner stoped'.format(self.name)) + + def _input_thread(self): + while self.run: + line = self.connection_channel.readline() + if line: + log.info('<--|{}| {}'.format(self.name, line.strip())) + self.iq.put(line) + else: + pass + + def _output_thread(self): + while self.run: + line = self.oq.get() + if line: + log.info('-->|{}| {}'.format(self.name, line.strip())) + self.connection_channel.write(line) + else: + log.debug('Nothing sent') diff --git a/src/test_driver/openiotsdk/integration-tests/common/telnet_connection.py b/src/test_driver/openiotsdk/integration-tests/common/telnet_connection.py new file mode 100644 index 00000000000000..b5367ed5747387 --- /dev/null +++ b/src/test_driver/openiotsdk/integration-tests/common/telnet_connection.py @@ -0,0 +1,123 @@ +# Copyright (c) 2009-2021 Arm Limited +# SPDX-License-Identifier: Apache-2.0 +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import logging +from time import sleep +import re + +from telnetlib import Telnet + +log = logging.getLogger(__name__) + + +class TelnetConnection: + """ + Telnet Connection class containing telnet connection handling functions + :param host: host name + :param port: prot number + """ + + def __init__(self, host=None, port=0): + self.telnet = Telnet() + self.host = host + self.port = port + self.is_open = False + + def open(self): + """ + Open telnet connection + """ + try: + self.telnet.open(self.host, self.port) + except Exception as e: + log.error('Open telnet connection to {}:{} failed {}'.format(self.host, self.port, e)) + return None + + self.is_open = True + + def __strip_escape(self, string_to_escape) -> str: + """ + Strip escape characters from string. + :param string_to_escape: string to work on + :return: stripped string + """ + raw_ansi_pattern = r'\033\[((?:\d|;)*)([a-zA-Z])' + ansi_pattern = raw_ansi_pattern.encode() + ansi_eng = re.compile(ansi_pattern) + matches = [] + for match in ansi_eng.finditer(string_to_escape): + matches.append(match) + matches.reverse() + for match in matches: + start = match.start() + end = match.end() + string_to_escape = string_to_escape[0:start] + string_to_escape[end:] + return string_to_escape + + def __formatline(self, line) -> str: + output_line = self.__strip_escape(line) + # Testapp uses \r to print characters to the same line, strip those and return only the last part + # If there is only one \r, don't remove anything. + if b'\r' in line and line.count(b'\r') > 1: + output_line = output_line.split(b'\r')[-2] + # Debug traces use tabulator characters, change those to spaces for readability + output_line = output_line.replace(b'\t', b' ') + output_line = output_line.decode('utf-8', 'ignore') + output_line.rstrip() + return output_line + + def readline(self): + """ + Read line from telnet session + :return: One line from telnet stream + """ + if not self.is_open: + return None + try: + output = self.telnet.read_until(b"\n", 1) + return self.__formatline(output) + except Exception as e: + log.error('Telnet read failed {}'.format(e)) + return None + + def write(self, data): + """ + Write data to telnet input + :param data: Data to send [bytes array] + """ + if not self.is_open: + return None + try: + data = data + '\n' + for item in data: + self.telnet.write(item.encode('utf-8')) + sleep(0.03) + except Exception as e: + log.error('Telnet write failed {}'.format(e)) + return None + + def close(self): + """ + Close telnet connection + """ + self.telnet.close() + self.is_open = False + + def get_port(self): + """ + Get port number of telnet connection + :return: Port Nnumber + """ + return self.port diff --git a/src/test_driver/openiotsdk/integration-tests/common/utils.py b/src/test_driver/openiotsdk/integration-tests/common/utils.py new file mode 100644 index 00000000000000..04d463d8558d38 --- /dev/null +++ b/src/test_driver/openiotsdk/integration-tests/common/utils.py @@ -0,0 +1,249 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# All rights reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +import os +import random +import shlex +import re +import ctypes +import asyncio +from time import sleep + +from chip.setup_payload import SetupPayload +from chip import exceptions + +from chip.clusters import Objects as GeneratedObjects +from chip import discovery + +import logging +log = logging.getLogger(__name__) + +IP_ADDRESS_BUFFER_LEN = 100 + + +def get_setup_payload(device): + """ + Get device setup payload from logs + :param device: serial device instance + :return: setup payload or None + """ + ret = device.wait_for_output("SetupQRCode") + if ret == None or len(ret) < 2: + return None + + qr_code = re.sub( + r"[\[\]]", "", ret[-1].partition("SetupQRCode:")[2]).strip() + try: + setup_payload = SetupPayload().ParseQrCode( + "VP:vendorpayload%{}".format(qr_code)) + except exceptions.ChipStackError as ex: + log.error("SetupPayload failed {}".format(str(ex))) + return None + + return setup_payload + + +def discover_device(devCtrl, setupPayload): + """ + Discover specific device in network. + Search by device discriminator from setup payload + :param devCtrl: device controller instance + :param setupPayload: device setup payload + :return: CommissionableNode object if node device discovered or None if failed + """ + log.info("Attempting to find device on network") + longDiscriminator = int(setupPayload.attributes['Long discriminator']) + try: + res = devCtrl.DiscoverCommissionableNodes( + discovery.FilterType.LONG_DISCRIMINATOR, longDiscriminator, stopOnFirst=True, timeoutSecond=5) + except exceptions.ChipStackError as ex: + log.error("DiscoverCommissionableNodes failed {}".format(str(ex))) + return None + if not res: + log.info("Device not found") + return None + return res[0] + + +def connect_device(setupPayload, commissionableDevice, nodeId=None): + """ + Connect to Matter discovered device on network + :param setupPayload: device setup payload + :param commissionableDevice: CommissionableNode object with discovered device + :param nodeId: device node ID + :return: node ID if connection successful or None if failed + """ + if nodeId == None: + nodeId = random.randint(1, 1000000) + + pincode = int(setupPayload.attributes['SetUpPINCode']) + try: + commissionableDevice.Commission(nodeId, pincode) + except exceptions.ChipStackError as ex: + log.error("Commission discovered device failed {}".format(str(ex))) + return None + return nodeId + + +def disconnect_device(devCtrl, nodeId): + """ + Disconnect Matter device + :param devCtrl: device controller instance + :param nodeId: device node ID + :return: node ID if connection successful or None if failed + """ + try: + devCtrl.CloseSession(nodeId) + except exceptions.ChipStackException as ex: + log.error("CloseSession failed {}".format(str(ex))) + return False + return True + + +class ParsingError(exceptions.ChipStackException): + def __init__(self, msg=None): + self.msg = "Parsing Error: " + msg + + def __str__(self): + return self.msg + + +def ParseEncodedString(value): + if value.find(":") < 0: + raise ParsingError( + "Value should be encoded in encoding:encodedvalue format") + enc, encValue = value.split(":", 1) + if enc == "str": + return encValue.encode("utf-8") + b'\x00' + elif enc == "hex": + return bytes.fromhex(encValue) + raise ParsingError("Only str and hex encoding is supported") + + +def ParseValueWithType(value, type): + if type == 'int': + return int(value) + elif type == 'str': + return value + elif type == 'bytes': + return ParseEncodedString(value) + elif type == 'bool': + return (value.upper() not in ['F', 'FALSE', '0']) + else: + raise ParsingError('Cannot recognize type: {}'.format(type)) + + +def ParseValueWithStruct(value, cluster): + return eval(f"GeneratedObjects.{cluster}.Structs.{value}") + + +def ParseValue(value, valueType, cluster): + if valueType: + return ParseValueWithType(value, valueType) + elif value.find(":") > 0 and value.split(":", 1)[0] == "struct": + return ParseValueWithStruct(value.split(":", 1)[1], cluster) + else: + raise ParsingError('Cannot parse value: {}'.format(value)) + + +def FormatZCLArguments(cluster, args, cmdArgsWithType): + cmdArgsDict = {} + for kvPair in args: + if kvPair.find("=") < 0: + raise ParsingError("Argument should in key=value format") + key, value = kvPair.split("=", 1) + valueType = cmdArgsWithType.get(key, None) + cmdArgsDict[key] = ParseValue(value, valueType, cluster) + return cmdArgsDict + + +def send_zcl_command(devCtrl, line, requestTimeoutMs: int = None): + """ + Format and send ZCL message to device. + :param devCtrl: device controller instance + :param line: command line + :param requestTimeoutMs: command request timeout in ms + :return: error code and command response + """ + res = None + err = 0 + try: + args = shlex.split(line) + if len(args) < 4: + raise exceptions.InvalidArgumentCount(4, len(args)) + + cluster, command, nodeId, endpoint = args[0:4] + cmdArgsLine = args[4:] + allCommands = devCtrl.ZCLCommandList() + if cluster not in allCommands: + raise exceptions.UnknownCluster(cluster) + cmdArgsWithType = allCommands.get(cluster).get(command, None) + # When command takes no arguments, (not command) is True + if command == None: + raise exceptions.UnknownCommand(cluster, command) + + args = FormatZCLArguments(cluster, cmdArgsLine, cmdArgsWithType) + clusterObj = getattr(GeneratedObjects, cluster) + commandObj = getattr(clusterObj.Commands, command) + req = commandObj(**args) + + res = asyncio.run(devCtrl.SendCommand(int(nodeId), int(endpoint), req, timedRequestTimeoutMs=requestTimeoutMs)) + + except exceptions.ChipStackException as ex: + log.error("An exception occurred during processing ZCL command: {}".format(str(ex))) + err = -1 + except Exception as ex: + log.error("An exception occurred during processing input: {}".format(str(ex))) + err = -1 + + return (err, res) + + +def read_zcl_attribute(devCtrl, line): + """ + Read ZCL attribute from device: + + :param devCtrl: device controller instance + :param line: command line + :return: error code and attribute response + """ + res = None + err = 0 + try: + args = shlex.split(line) + if len(args) < 4: + raise exceptions.InvalidArgumentCount(4, len(args)) + + cluster, attribute, nodeId, endpoint = args[0:4] + allAttrs = devCtrl.ZCLAttributeList() + if cluster not in allAttrs: + raise exceptions.UnknownCluster(cluster) + + attrDetails = allAttrs.get(cluster).get(attribute, None) + if attrDetails == None: + raise exceptions.UnknownAttribute(cluster, attribute) + + res = devCtrl.ZCLReadAttribute(cluster, attribute, int( + nodeId), int(endpoint), 0) + except exceptions.ChipStackException as ex: + log.error("An exception occurred during processing ZCL attribute: {}".format(str(ex))) + err = -1 + except Exception as ex: + log.error("An exception occurred during processing input: {}".format(str(ex))) + err = -1 + + return (err, res) diff --git a/src/test_driver/openiotsdk/integration-tests/conftest.py b/src/test_driver/openiotsdk/integration-tests/conftest.py new file mode 100644 index 00000000000000..90116956e55dec --- /dev/null +++ b/src/test_driver/openiotsdk/integration-tests/conftest.py @@ -0,0 +1,38 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# All rights reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +import pytest + +pytest_plugins = ['common.fixtures'] + + +def pytest_addoption(parser): + """ + Function for pytest to enable own custom commandline arguments + :param parser: argparser + :return: + """ + parser.addoption('--binaryPath', action='store', + help='Application binary path') + parser.addoption('--fvp', action='store', + help='FVP instance path') + parser.addoption('--fvpConfig', action='store', + help='FVP configuration file path') + parser.addoption('--telnetPort', action='store', + help='Telnet terminal port number.', default="5000") + parser.addoption('--networkInterface', action='store', + help='FVP network interface name') diff --git a/src/test_driver/openiotsdk/integration-tests/lock-app/__init__.py b/src/test_driver/openiotsdk/integration-tests/lock-app/__init__.py new file mode 100644 index 00000000000000..e69de29bb2d1d6 diff --git a/src/test_driver/openiotsdk/integration-tests/lock-app/test_app.py b/src/test_driver/openiotsdk/integration-tests/lock-app/test_app.py new file mode 100644 index 00000000000000..d89d26dc32d698 --- /dev/null +++ b/src/test_driver/openiotsdk/integration-tests/lock-app/test_app.py @@ -0,0 +1,176 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# All rights reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +import pytest +from time import sleep + +from common.utils import * + +from chip.clusters.Objects import DoorLock + +import logging +log = logging.getLogger(__name__) + + +@pytest.fixture(scope="session") +def binaryPath(request, rootDir): + if request.config.getoption('binaryPath'): + return request.config.getoption('binaryPath') + else: + return os.path.join(rootDir, 'examples/lock-app/openiotsdk/build/chip-openiotsdk-lock-app-example.elf') + + +@pytest.mark.smoketest +def test_smoke_test(device): + ret = device.wait_for_output("Open IoT SDK lock-app example application start") + assert ret != None and len(ret) > 0 + ret = device.wait_for_output("Open IoT SDK lock-app example application run") + assert ret != None and len(ret) > 0 + + +@pytest.mark.commissioningtest +def test_commissioning(device, controller): + assert controller != None + devCtrl = controller + + setupPayload = get_setup_payload(device) + assert setupPayload != None + + commissionable_device = discover_device(devCtrl, setupPayload) + assert commissionable_device != None + + assert commissionable_device.vendorId == int(setupPayload.attributes['VendorID']) + assert commissionable_device.productId == int(setupPayload.attributes['ProductID']) + assert commissionable_device.addresses[0] != None + + nodeId = connect_device(setupPayload, commissionable_device) + assert nodeId != None + log.info("Device {} connected".format(commissionable_device.addresses[0])) + + ret = device.wait_for_output("Commissioning completed successfully", timeout=30) + assert ret != None and len(ret) > 0 + + assert disconnect_device(devCtrl, nodeId) + + +LOCK_CTRL_TEST_PIN_CODE = 12345 +LOCK_CTRL_TEST_USER_INDEX = 1 +LOCK_CTRL_TEST_ENDPOINT_ID = 1 +LOCK_CTRL_TEST_USER_NAME = 'testUser' +LOCK_CTRL_TEST_CREDENTIAL_INDEX = 1 + + +@pytest.mark.ctrltest +def test_lock_ctrl(device, controller): + assert controller != None + devCtrl = controller + + setupPayload = get_setup_payload(device) + assert setupPayload != None + + commissionable_device = discover_device(devCtrl, setupPayload) + assert commissionable_device != None + + nodeId = connect_device(setupPayload, commissionable_device) + assert nodeId != None + + ret = device.wait_for_output("Commissioning completed successfully", timeout=30) + assert ret != None and len(ret) > 0 + + err, res = send_zcl_command( + devCtrl, "DoorLock SetUser {} {} operationType={} userIndex={} userName={} userUniqueId={} " + "userStatus={} userType={} credentialRule={}".format(nodeId, LOCK_CTRL_TEST_ENDPOINT_ID, + DoorLock.Enums.DlDataOperationType.kAdd, + LOCK_CTRL_TEST_USER_INDEX, + LOCK_CTRL_TEST_USER_NAME, + LOCK_CTRL_TEST_USER_INDEX, + DoorLock.Enums.DlUserStatus.kOccupiedEnabled, + DoorLock.Enums.DlUserType.kUnrestrictedUser, + DoorLock.Enums.DlCredentialRule.kSingle), requestTimeoutMs=1000) + assert err == 0 + + ret = device.wait_for_output("Successfully set the user [mEndpointId={},index={},adjustedIndex=0]".format( + LOCK_CTRL_TEST_ENDPOINT_ID, + LOCK_CTRL_TEST_USER_INDEX)) + assert ret != None and len(ret) > 0 + + err, res = send_zcl_command( + devCtrl, "DoorLock GetUser {} {} userIndex={}".format(nodeId, LOCK_CTRL_TEST_ENDPOINT_ID, + LOCK_CTRL_TEST_USER_INDEX)) + assert err == 0 + assert res.userIndex == LOCK_CTRL_TEST_USER_INDEX + assert res.userName == LOCK_CTRL_TEST_USER_NAME + assert res.userUniqueId == LOCK_CTRL_TEST_USER_INDEX + assert res.userStatus == DoorLock.Enums.DlUserStatus.kOccupiedEnabled + assert res.userType == DoorLock.Enums.DlUserType.kUnrestrictedUser + assert res.credentialRule == DoorLock.Enums.DlCredentialRule.kSingle + + err, res = send_zcl_command( + devCtrl, "DoorLock SetCredential {} {} operationType={} " + "credential=struct:DlCredential(credentialType={},credentialIndex={}) credentialData=str:{} " + "userIndex={} userStatus={} userType={}".format(nodeId, LOCK_CTRL_TEST_ENDPOINT_ID, + DoorLock.Enums.DlDataOperationType.kAdd, + DoorLock.Enums.DlCredentialType.kPin, + LOCK_CTRL_TEST_CREDENTIAL_INDEX, + LOCK_CTRL_TEST_PIN_CODE, + LOCK_CTRL_TEST_USER_INDEX, + DoorLock.Enums.DlUserStatus.kOccupiedEnabled, + DoorLock.Enums.DlUserType.kUnrestrictedUser), requestTimeoutMs=1000) + assert err == 0 + assert res.status == DoorLock.Enums.DlStatus.kSuccess + + ret = device.wait_for_output("Successfully set the credential [mEndpointId={},index={}," + "credentialType={},creator=1,modifier=1]".format(LOCK_CTRL_TEST_ENDPOINT_ID, + LOCK_CTRL_TEST_USER_INDEX, DoorLock.Enums.DlCredentialType.kPin)) + assert ret != None and len(ret) > 0 + + err, res = send_zcl_command( + devCtrl, "DoorLock GetCredentialStatus {} {} credential=struct:DlCredential(credentialType={}," + "credentialIndex={})".format(nodeId, LOCK_CTRL_TEST_ENDPOINT_ID, + DoorLock.Enums.DlCredentialType.kPin, + LOCK_CTRL_TEST_CREDENTIAL_INDEX), requestTimeoutMs=1000) + assert err == 0 + assert res.credentialExists + assert res.userIndex == LOCK_CTRL_TEST_USER_INDEX + + err, res = send_zcl_command( + devCtrl, "DoorLock LockDoor {} {} pinCode=str:{}".format(nodeId, LOCK_CTRL_TEST_ENDPOINT_ID, + LOCK_CTRL_TEST_PIN_CODE), requestTimeoutMs=1000) + assert err == 0 + + ret = device.wait_for_output("Setting door lock state to \"Locked\" [endpointId={}]".format(LOCK_CTRL_TEST_ENDPOINT_ID)) + assert ret != None and len(ret) > 0 + + err, res = read_zcl_attribute( + devCtrl, "DoorLock LockState {} {}".format(nodeId, LOCK_CTRL_TEST_ENDPOINT_ID)) + assert err == 0 + assert res.value == DoorLock.Enums.DlLockState.kLocked + + err, res = send_zcl_command( + devCtrl, "DoorLock UnlockDoor {} {} pinCode=str:{}".format(nodeId, LOCK_CTRL_TEST_ENDPOINT_ID, + LOCK_CTRL_TEST_PIN_CODE), requestTimeoutMs=1000) + assert err == 0 + + ret = device.wait_for_output("Setting door lock state to \"Unlocked\" [endpointId={}]".format(LOCK_CTRL_TEST_ENDPOINT_ID)) + assert ret != None and len(ret) > 0 + + err, res = read_zcl_attribute( + devCtrl, "DoorLock LockState {} {}".format(nodeId, LOCK_CTRL_TEST_ENDPOINT_ID)) + assert err == 0 + assert res.value == DoorLock.Enums.DlLockState.kUnlocked + + assert disconnect_device(devCtrl, nodeId) diff --git a/src/test_driver/openiotsdk/integration-tests/pytest.ini b/src/test_driver/openiotsdk/integration-tests/pytest.ini new file mode 100644 index 00000000000000..78c8ab6382ffa5 --- /dev/null +++ b/src/test_driver/openiotsdk/integration-tests/pytest.ini @@ -0,0 +1,9 @@ +[pytest] +log_cli = true +log_level = INFO +log_format = %(asctime)s.%(msecs)03d %(levelname)s %(message)s +log_cli_format = %(asctime)s.%(msecs)03d %(levelname)s %(message)s +markers = + smoketest: A simple test to verify that the application is properly launched + commissioningtest: Test to validate the commissionign process + ctrltest: Test checking the operation of the application through integration with it diff --git a/src/test_driver/openiotsdk/integration-tests/shell/__init__.py b/src/test_driver/openiotsdk/integration-tests/shell/__init__.py new file mode 100644 index 00000000000000..e69de29bb2d1d6 diff --git a/src/test_driver/openiotsdk/integration-tests/shell/test_app.py b/src/test_driver/openiotsdk/integration-tests/shell/test_app.py new file mode 100644 index 00000000000000..72cd8d0166c50f --- /dev/null +++ b/src/test_driver/openiotsdk/integration-tests/shell/test_app.py @@ -0,0 +1,191 @@ +# Copyright (c) 2009-2021 Arm Limited +# SPDX-License-Identifier: Apache-2.0 +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import pytest +import re +from packaging import version +from time import sleep + +from chip.setup_payload import SetupPayload +from chip import exceptions +import chip.native + +from common.utils import * + +import logging +log = logging.getLogger(__name__) + + +@pytest.fixture(scope="session") +def binaryPath(request, rootDir): + if request.config.getoption('binaryPath'): + return request.config.getoption('binaryPath') + else: + return os.path.join(rootDir, 'examples/shell/openiotsdk/build/chip-openiotsdk-shell-example.elf') + + +SHELL_COMMAND_NAME = ["base64", "exit", "help", "version", + "config", "device", "onboardingcodes", "dns", + "echo", "log", "rand"] + + +def get_shell_command(response): + return [line.split()[0].strip() for line in response] + + +def parse_config_response(response): + config = {} + for param in response: + param_name = param.split(":")[0].lower() + if "discriminator" in param_name: + value = int(param.split(":")[1].strip(), 16) + elif "pincode" in param_name: + value = int(param.split(":")[1].strip()) + else: + value = int(param.split(":")[1].split()[0].strip()) + + if "hardwareversion" in param_name: + param_name = "hardwarever" + + config[param_name] = value + return config + + +def parse_boarding_codes_response(response): + codes = {} + for param in response: + codes[param.split(":")[0].lower()] = param.split()[1].strip() + return codes + + +@pytest.mark.smoketest +def test_smoke_test(device): + ret = device.wait_for_output("Open IoT SDK shell example application start") + assert ret != None and len(ret) > 0 + ret = device.wait_for_output("Open IoT SDK shell example application run") + assert ret != None and len(ret) > 0 + + +@pytest.mark.ctrltest +def test_command_check(device): + try: + chip.native.Init() + except exceptions.ChipStackException as ex: + log.error("CHIP initialization failed {}".format(ex)) + assert False + except: + log.error("CHIP initialization failed") + assert False + + ret = device.wait_for_output("Open IoT SDK shell example application start") + assert ret != None and len(ret) > 0 + ret = device.wait_for_output("Open IoT SDK shell example application run") + assert ret != None and len(ret) > 0 + + # Help + ret = device.send(command="help", expected_output="Done") + assert ret != None and len(ret) > 1 + shell_commands = get_shell_command(ret[1:-1]) + assert set(SHELL_COMMAND_NAME) == set(shell_commands) + + # Echo + ret = device.send(command="echo Hello", expected_output="Done") + assert ret != None and len(ret) > 1 + assert "Hello" in ret[-2] + + # Log + ret = device.send(command="log Hello", expected_output="Done") + assert ret != None and len(ret) > 1 + assert "[INF] [TOO] Hello" in ret[-2] + + # Rand + ret = device.send(command="rand", expected_output="Done") + assert ret != None and len(ret) > 1 + assert ret[-2].rstrip().isdigit() + + # Base64 + hex_string = "1234" + ret = device.send(command="base64 encode {}".format( + hex_string), expected_output="Done") + assert ret != None and len(ret) > 1 + base64code = ret[-2] + ret = device.send(command="base64 decode {}".format( + base64code), expected_output="Done") + assert ret != None and len(ret) > 1 + assert ret[-2].rstrip() == hex_string + + # Version + ret = device.send(command="version", expected_output="Done") + assert ret != None and len(ret) > 1 + assert "CHIP" in ret[-2].split()[0] + app_version = ret[-2].split()[1] + assert isinstance(version.parse(app_version), version.Version) + + # Config + ret = device.send(command="config", expected_output="Done") + assert ret != None and len(ret) > 2 + + config = parse_config_response(ret[1:-1]) + + for param_name, value in config.items(): + ret = device.send(command="config {}".format( + param_name), expected_output="Done") + assert ret != None and len(ret) > 1 + if "discriminator" in param_name: + assert int(ret[-2].split()[0], 16) == value + else: + assert int(ret[-2].split()[0]) == value + + new_value = int(config['discriminator']) + 1 + ret = device.send(command="config discriminator {}".format( + new_value), expected_output="Done") + assert ret != None and len(ret) > 1 + assert "Setup discriminator set to: {}".format(new_value) in ret[-2] + + ret = device.send(command="config discriminator", expected_output="Done") + assert ret != None and len(ret) > 1 + assert int(ret[-2].split()[0], 16) == new_value + + # Onboardingcodes + ret = device.send(command="onboardingcodes none", expected_output="Done") + assert ret != None and len(ret) > 2 + + boarding_codes = parse_boarding_codes_response(ret[1:-1]) + + for param, value in boarding_codes.items(): + ret = device.send(command="onboardingcodes none {}".format( + param), expected_output="Done") + assert ret != None and len(ret) > 1 + assert value == ret[-2].strip() + + try: + device_details = dict(SetupPayload().ParseQrCode( + "VP:vendorpayload%{}".format(boarding_codes['qrcode'])).attributes) + except exceptions.ChipStackError as ex: + log.error(ex.msg) + assert False + assert device_details != None and len(device_details) != 0 + + try: + device_details = dict(SetupPayload().ParseManualPairingCode( + boarding_codes['manualpairingcode']).attributes) + except exceptions.ChipStackError as ex: + log.error(ex.msg) + assert False + assert device_details != None and len(device_details) != 0 + + # Exit - should be the last check + ret = device.send(command="exit", expected_output="Goodbye") + assert ret != None and len(ret) > 0 diff --git a/src/test_driver/openiotsdk/unit-tests/.gitignore b/src/test_driver/openiotsdk/unit-tests/.gitignore new file mode 100644 index 00000000000000..bcd261e241a6c2 --- /dev/null +++ b/src/test_driver/openiotsdk/unit-tests/.gitignore @@ -0,0 +1,2 @@ +build/ +test_report.json diff --git a/src/test_driver/openiotsdk/unit-tests/CMakeLists.txt b/src/test_driver/openiotsdk/unit-tests/CMakeLists.txt new file mode 100644 index 00000000000000..15470ba12589f8 --- /dev/null +++ b/src/test_driver/openiotsdk/unit-tests/CMakeLists.txt @@ -0,0 +1,83 @@ +# +# Copyright (c) 2022 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +cmake_minimum_required(VERSION 3.21) + +get_filename_component(CHIP_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/../../../.. REALPATH) +get_filename_component(OPEN_IOT_SDK_CONFIG ${CHIP_ROOT}/config/openiotsdk REALPATH) +get_filename_component(OPEN_IOT_SDK_EXAMPLE_COMMON ${CHIP_ROOT}/examples/platform/openiotsdk REALPATH) + +list(APPEND CMAKE_MODULE_PATH ${OPEN_IOT_SDK_CONFIG}/cmake) + +# Toolchain files need to exist before first call to project +include(toolchain) + +project(chip-open-iot-sdk-unit-tests LANGUAGES C CXX ASM) + +include(sdk) +include(linker) + +# LwIP configuration +if(TARGET lwip-cmsis-port) + # lwip requires user_lwipopts.h, we use the custom settings + target_include_directories(lwipopts + INTERFACE + lwip-config + ) +endif() + +# Application CHIP build configuration +set(CONFIG_CHIP_LIB_TESTS YES) +set(CONFIG_CHIP_DETAIL_LOGGING NO) +set(CONFIG_CHIP_PROGRESS_LOGGING NO) +set(CONFIG_CHIP_AUTOMATION_LOGGING YES) +set(CONFIG_CHIP_ERROR_LOGGING NO) + +include(chip) + +add_subdirectory(${OPEN_IOT_SDK_EXAMPLE_COMMON}/app ./app_build) + +file(STRINGS testnames.txt TEST_NAMES_FROM_FILE) +STRING(REGEX REPLACE "\n" ";" TEST_NAMES_FROM_FILE "${TEST_NAMES_FROM_FILE}") + +foreach(TEST_NAME IN LISTS TEST_NAMES_FROM_FILE) + add_executable(${TEST_NAME}) + target_include_directories(${TEST_NAME} + PRIVATE + main/include + ${CHIP_ROOT}/third_party/nlunit-test/repo/src + ) + + target_sources(${TEST_NAME} + PRIVATE + main/main.cpp + ) + + target_link_libraries(${TEST_NAME} + openiotsdk-app + ) + + # Link the *whole-archives* to keep the static test objects. + target_link_options(${TEST_NAME} + PUBLIC + -Wl,--whole-archive "${CMAKE_CURRENT_BINARY_DIR}/chip_build/lib/lib${TEST_NAME}.a" + -Wl,--no-whole-archive "${CMAKE_CURRENT_BINARY_DIR}/chip_build/lib/libCHIP_tests.a" + -Wl,--no-whole-archive) + + # set_target_link requires APP_TARGET to be defined + set(APP_TARGET ${TEST_NAME}) + set_target_link(${TEST_NAME}) +endforeach() diff --git a/src/test_driver/openiotsdk/unit-tests/README.md b/src/test_driver/openiotsdk/unit-tests/README.md new file mode 100644 index 00000000000000..584f31aea71e0d --- /dev/null +++ b/src/test_driver/openiotsdk/unit-tests/README.md @@ -0,0 +1,86 @@ +# Matter Open IoT Unit Tests Application + +The Open IoT SDK Unit Tests Application executes all supported unit tests on the +target. + +The Matter unit tests are included in a set of libraries and allow to validate +most of the components used by Matter examples applications. The main goal of +this application is to run registered tests on Open IoT SDK target and check the +results. The final result is the number of tests that failed. + +## Environment setup + +The required environment is the same as for the Matter examples. For information +on how to setup it see +[Open IoT SDK examples](../../../../docs/examples/openiotsdk_examples.md#Environment-setup). + +## Building + +The build process means creating separate executable file for each Matter tested +component. It assumes the use of all supported test libraries and creating +independent applications from them. + +You build using a vscode task or call the script directly from the command line. + +### Building using vscode task + +``` +Command Palette (F1) => Run Task... => Build Open IoT SDK unit-tests => (debug on/off) +``` + +This will call the scripts with the selected parameters. + +### Building using CLI + +You can call the script directly yourself. + +``` +${MATTER_ROOT}/scripts/examples/openiotsdk_example.sh unit-tests +``` + +Use `--help` to get more information about the script options. + +## Running + +Unit-tests applications can be run independently or as an entire set. It runs in +the background and opens a telnet session. The script will open telnet for you +and connect to the port used by the `FVP`. When the telnet process is terminated +it will also terminate the `FVP` instance. + +You can run the application script from a vscode task or call the script +directly. + +Expected output of each executed test: + +``` + [ATM] Open IoT SDK unit-tests start + [ATM] Open IoT SDK unit-tests run... + ... + [ATM] Test status: 0 +``` + +### Running using vscode task + +``` +Command Palette (F1) => Run Task... => Run Open IoT SDK unit-tests => or all (to run all tests) +``` + +### Running using CLI + +You can call the script directly yourself. + +``` +${MATTER_ROOT}/scripts/examples/openiotsdk_example.sh -C run unit-tests (optional to run specific test) +``` + +## Debugging + +Debugging can be started using a VS code launch task: + +``` +Run and Debug (Ctrl+Shift+D) => Debug Open IoT SDK unit-tests application => Start Debugging (F5) => => +``` + +As you can see above, you will need to select the name of the test twice. This +is because the debug task needs to launch the run task and currently VS code has +no way of passing parameters between tasks. diff --git a/src/test_driver/openiotsdk/unit-tests/cmsis-config/RTE_Components.h b/src/test_driver/openiotsdk/unit-tests/cmsis-config/RTE_Components.h new file mode 100644 index 00000000000000..e86df2b4e44e06 --- /dev/null +++ b/src/test_driver/openiotsdk/unit-tests/cmsis-config/RTE_Components.h @@ -0,0 +1,22 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef RTE_COMPONENTS_H +#define RTE_COMPONENTS_H + +#endif // RTE_COMPONENTS_H diff --git a/src/test_driver/openiotsdk/unit-tests/freertos-config/FreeRTOSConfig.h b/src/test_driver/openiotsdk/unit-tests/freertos-config/FreeRTOSConfig.h new file mode 100644 index 00000000000000..6011c1e9d6bf79 --- /dev/null +++ b/src/test_driver/openiotsdk/unit-tests/freertos-config/FreeRTOSConfig.h @@ -0,0 +1,257 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef FREERTOS_CONFIG_H +#define FREERTOS_CONFIG_H + +/*----------------------------------------------------------- + * Application specific definitions. + * + * These definitions should be adjusted for your particular hardware and + * application requirements. + * + * THESE PARAMETERS ARE DESCRIBED WITHIN THE 'CONFIGURATION' SECTION OF THE + * FreeRTOS API DOCUMENTATION AVAILABLE ON THE FreeRTOS.org WEB SITE. + * + * See http://www.freertos.org/a00110.html + *----------------------------------------------------------*/ + +#if (defined(__ARMCC_VERSION) || defined(__GNUC__) || defined(__ICCARM__)) +#include + +extern uint32_t SystemCoreClock; +#endif + +// Minimal stack size [words] <0-65535> +// Stack for idle task and default task stack in words. +// Default: 128 +#define configMINIMAL_STACK_SIZE ((uint16_t)(4 * 1024)) + +// Total heap size [bytes] <0-0xFFFFFFFF> +// Heap memory size in bytes. +// Default: 8192 +#define configTOTAL_HEAP_SIZE ((size_t) 8192) + +// Kernel tick frequency [Hz] <0-0xFFFFFFFF> +// Kernel tick rate in Hz. +// Default: 1000 +#define configTICK_RATE_HZ ((TickType_t) 1000) + +// Timer task stack depth [words] <0-65535> +// Stack for timer task in words. +// Default: 80 +#define configTIMER_TASK_STACK_DEPTH configMINIMAL_STACK_SIZE + +// Timer task priority <0-56> +// Timer task priority. +// Default: 40 (High) +#define configTIMER_TASK_PRIORITY 40 + +// Timer queue length <0-1024> +// Timer command queue length. +// Default: 5 +#define configTIMER_QUEUE_LENGTH 5 + +// Preemption interrupt priority +// Maximum priority of interrupts that are safe to call FreeRTOS API. +// Default: 16 +#define configMAX_SYSCALL_INTERRUPT_PRIORITY (5 << (8 - configPRIO_BITS)) + +// Use time slicing +// Enable setting to use timeslicing. +// Default: 1 +#define configUSE_TIME_SLICING 1 + +// Idle should yield +// Control Yield behaviour of the idle task. +// Default: 1 +#define configIDLE_SHOULD_YIELD 1 + +// Check for stack overflow +// <0=>Disable <1=>Method one <2=>Method two +// Enable or disable stack overflow checking. +// Callback function vApplicationStackOverflowHook implementation is required when stack checking is enabled. +// Default: 0 +#define configCHECK_FOR_STACK_OVERFLOW 2 + +// Use idle hook +// Enable callback function call on each idle task iteration. +// Callback function vApplicationIdleHook implementation is required when idle hook is enabled. +// Default: 0 +#define configUSE_IDLE_HOOK 0 + +// Use tick hook +// Enable callback function call during each tick interrupt. +// Callback function vApplicationTickHook implementation is required when tick hook is enabled. +// Default: 0 +#define configUSE_TICK_HOOK 0 + +// Use deamon task startup hook +// Enable callback function call when timer service starts. +// Callback function vApplicationDaemonTaskStartupHook implementation is required when deamon task startup hook is +// enabled. Default: 0 +#define configUSE_DAEMON_TASK_STARTUP_HOOK 0 + +// Use malloc failed hook +// Enable callback function call when out of dynamic memory. +// Callback function vApplicationMallocFailedHook implementation is required when malloc failed hook is enabled. +// Default: 0 +#define configUSE_MALLOC_FAILED_HOOK 0 + +// Queue registry size +// Define maximum number of queue objects registered for debug purposes. +// The queue registry is used by kernel aware debuggers to locate queue and semaphore structures and display +// associated text names. Default: 0 +#define configQUEUE_REGISTRY_SIZE 0 + +// Event Recorder configuration +// Initialize and setup Event Recorder level filtering. +// Settings have no effect when Event Recorder is not present. + +// Initialize Event Recorder +// Initialize Event Recorder before FreeRTOS kernel start. +// Default: 1 +#define configEVR_INITIALIZE 1 + +// Setup recording level filter +// Enable configuration of FreeRTOS events recording level +// Default: 1 +#define configEVR_SETUP_LEVEL 1 + +// Tasks functions +// Define event recording level bitmask for events generated from Tasks functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_TASKS 0x05 + +// Queue functions +// Define event recording level bitmask for events generated from Queue functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_QUEUE 0x05 + +// Timer functions +// Define event recording level bitmask for events generated from Timer functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_TIMERS 0x05 + +// Event Groups functions +// Define event recording level bitmask for events generated from Event Groups functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_EVENTGROUPS 0x05 + +// Heap functions +// Define event recording level bitmask for events generated from Heap functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_HEAP 0x05 + +// Stream Buffer functions +// Define event recording level bitmask for events generated from Stream Buffer functions. +// Default: 0x05 +// <0x00=>Off <0x01=>Errors <0x05=>Errors + Operation <0x0F=>All +#define configEVR_LEVEL_STREAMBUFFER 0x05 +// +// + +// Port Specific Features +// Enable and configure port specific features. +// Check FreeRTOS documentation for definitions that apply for the used port. + +// Use Floating Point Unit +// Using Floating Point Unit (FPU) affects context handling. +// Enable FPU when application uses floating point operations. +// Default: 1 +#define configENABLE_FPU 1 + +// Use Memory Protection Unit +// Using Memory Protection Unit (MPU) requires detailed memory map definition. +// This setting is only releavant for MPU enabled ports. +// Default: 0 +#define configENABLE_MPU 0 + +// Use TrustZone Secure Side Only +// This settings prevents FreeRTOS contex switch to Non-Secure side. +// Enable this setting when FreeRTOS runs on the Secure side only. +#define configRUN_FREERTOS_SECURE_ONLY 1 + +// Use TrustZone Security Extension +// Using TrustZone affects context handling. +// Enable TrustZone when FreeRTOS runs on the Non-Secure side and calls functions from the Secure side. +// Default: 1 +#define configENABLE_TRUSTZONE 0 + +// Minimal secure stack size [words] <0-65535> +// Stack for idle task Secure side context in words. +// This setting is only relevant when TrustZone extension is enabled. +// Default: 128 +#define configMINIMAL_SECURE_STACK_SIZE ((uint32_t) 128) +// + +#ifdef __NVIC_PRIO_BITS +#define configPRIO_BITS __NVIC_PRIO_BITS +#else +#define configPRIO_BITS 4 +#endif + +//------------- <<< end of configuration section >>> --------------------------- + +/* Defines needed by FreeRTOS to implement CMSIS RTOS2 API. Do not change! */ +#define configCPU_CLOCK_HZ (SystemCoreClock) +#define configSUPPORT_STATIC_ALLOCATION 1 +#define configSUPPORT_DYNAMIC_ALLOCATION 1 +#define configUSE_PREEMPTION 1 +#define configUSE_TIMERS 1 +#define configUSE_MUTEXES 1 +#define configUSE_RECURSIVE_MUTEXES 1 +#define configUSE_COUNTING_SEMAPHORES 1 +#define configUSE_TASK_NOTIFICATIONS 1 +#define configUSE_TRACE_FACILITY 1 +#define configUSE_16_BIT_TICKS 0 +#define configUSE_PORT_OPTIMISED_TASK_SELECTION 0 +#define configMAX_PRIORITIES 56 +#define configKERNEL_INTERRUPT_PRIORITY (0x07 << (8 - configPRIO_BITS)) + +/* Defines that include FreeRTOS functions which implement CMSIS RTOS2 API. Do not change! */ +#define INCLUDE_xEventGroupSetBitsFromISR 1 +#define INCLUDE_xSemaphoreGetMutexHolder 1 +#define INCLUDE_vTaskDelay 1 +#define INCLUDE_xTaskDelayUntil 1 +#define INCLUDE_vTaskDelete 1 +#define INCLUDE_xTaskGetCurrentTaskHandle 1 +#define INCLUDE_xTaskGetSchedulerState 1 +#define INCLUDE_uxTaskGetStackHighWaterMark 1 +#define INCLUDE_uxTaskPriorityGet 1 +#define INCLUDE_vTaskPrioritySet 1 +#define INCLUDE_eTaskGetState 1 +#define INCLUDE_vTaskSuspend 1 +#define INCLUDE_xTimerPendFunctionCall 1 + +/* Map the FreeRTOS port interrupt handlers to their CMSIS standard names. */ +#define xPortPendSVHandler PendSV_Handler +#define vPortSVCHandler SVC_Handler + +/* Ensure Cortex-M port compatibility. */ +#define SysTick_Handler xPortSysTickHandler + +#include "RTE_Components.h" +#include CMSIS_device_header + +#endif /* FREERTOS_CONFIG_H */ diff --git a/src/test_driver/openiotsdk/unit-tests/lwip-config/user_lwipopts.h b/src/test_driver/openiotsdk/unit-tests/lwip-config/user_lwipopts.h new file mode 100644 index 00000000000000..59ed1720c7e36c --- /dev/null +++ b/src/test_driver/openiotsdk/unit-tests/lwip-config/user_lwipopts.h @@ -0,0 +1,25 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef USER_LWIPOPTS_H +#define USER_LWIPOPTS_H + +#define LWIP_STATS (0) +#define PBUF_POOL_SIZE (1001) + +#endif /* USER_LWIPOPTS_H */ diff --git a/src/test_driver/openiotsdk/unit-tests/main/include/CHIPProjectConfig.h b/src/test_driver/openiotsdk/unit-tests/main/include/CHIPProjectConfig.h new file mode 100644 index 00000000000000..bb2c4755245f95 --- /dev/null +++ b/src/test_driver/openiotsdk/unit-tests/main/include/CHIPProjectConfig.h @@ -0,0 +1,44 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Example project configuration file for CHIP. + * + * This is a place to put application or project-specific overrides + * to the default configuration values for general CHIP features. + * + */ + +#pragma once + +// Enable support functions for parsing command-line arguments +#define CHIP_CONFIG_ENABLE_ARG_PARSER 1 +#define CHIP_CONFIG_NON_POSIX_LONG_OPT 1 + +#define CHIP_SYSTEM_CONFIG_NUM_TIMERS 32 +#define CHIP_DEVICE_CONFIG_ENABLE_BOTH_COMMISSIONER_AND_COMMISSIONEE 1 + +#define CONFIG_BUILD_FOR_HOST_UNIT_TEST 1 + +#define CONFIG_IM_BUILD_FOR_UNIT_TEST 1 +#define CHIP_DEVICE_CONFIG_DYNAMIC_ENDPOINT_COUNT 64 +#define CHIP_CONFIG_MAX_FABRICS 16 +#define CHIP_DEVICE_CONFIG_MAX_EVENT_QUEUE_SIZE 500 + +#define CHIP_SYSTEM_CONFIG_POOL_USE_HEAP 1 diff --git a/src/test_driver/openiotsdk/unit-tests/main/include/NlTestLogger.h b/src/test_driver/openiotsdk/unit-tests/main/include/NlTestLogger.h new file mode 100644 index 00000000000000..f43e3e19081fc2 --- /dev/null +++ b/src/test_driver/openiotsdk/unit-tests/main/include/NlTestLogger.h @@ -0,0 +1,72 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Custom NL test logger implementation + * + */ + +#include +#include + +class NlTestLogger +{ + static void def_log_name(struct _nlTestSuite * inSuite) { printf("[ %s ]\r\n", inSuite->name); } + + static void def_log_initialize(struct _nlTestSuite * inSuite, int inResult, int inWidth) + { + printf("[ %s : %-*s ] : %s\r\n", inSuite->name, inWidth, "Initialize", inResult == FAILURE ? "FAILED" : "PASSED"); + } + static void def_log_terminate(struct _nlTestSuite * inSuite, int inResult, int inWidth) + { + printf("[ %s : %-*s ] : %s\r\n", inSuite->name, inWidth, "Terminate", inResult == FAILURE ? "FAILED" : "PASSED"); + } + + static void def_log_setup(struct _nlTestSuite * inSuite, int inResult, int inWidth) + { + printf("[ %s : %-*s ] : %s\r\n", inSuite->name, inWidth, "Setup", inResult == FAILURE ? "FAILED" : "PASSED"); + } + + static void def_log_test(struct _nlTestSuite * inSuite, int inWidth, int inIndex) + { + printf("[ %s : %-*s ] : %s\r\n", inSuite->name, inWidth, inSuite->tests[inIndex].name, + inSuite->flagError ? "FAILED" : "PASSED"); + } + + static void def_log_teardown(struct _nlTestSuite * inSuite, int inResult, int inWidth) + { + printf("[ %s : %-*s ] : %s\r\n", inSuite->name, inWidth, "TearDown", inResult == FAILURE ? "FAILED" : "PASSED"); + } + + static void def_log_statTest(struct _nlTestSuite * inSuite) + { + printf("Failed Tests: %d / %d\r\n", inSuite->failedTests, inSuite->runTests); + } + + static void def_log_statAssert(struct _nlTestSuite * inSuite) + { + printf("Failed Asserts: %d / %d\r\n", inSuite->failedAssertions, inSuite->performedAssertions); + } + +public: + static constexpr nl_test_output_logger_t nl_test_logger = { + def_log_name, def_log_initialize, def_log_terminate, def_log_setup, + def_log_test, def_log_teardown, def_log_statTest, def_log_statAssert, + }; +}; diff --git a/src/test_driver/openiotsdk/unit-tests/main/main.cpp b/src/test_driver/openiotsdk/unit-tests/main/main.cpp new file mode 100644 index 00000000000000..8c41fd04d68593 --- /dev/null +++ b/src/test_driver/openiotsdk/unit-tests/main/main.cpp @@ -0,0 +1,90 @@ +/* + * + * Copyright (c) 2021 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 +#include + +#include +#include + +#include + +#include "cmsis_os2.h" +#include "openiotsdk_platform.h" + +constexpr nl_test_output_logger_t NlTestLogger::nl_test_logger; + +using namespace ::chip; + +static void test_thread(void * argument) +{ + int status; + CHIP_ERROR err; + + if (openiotsdk_network_init(true)) + { + ChipLogAutomation("ERROR: Network initialization failed"); + goto exit; + } + + err = DeviceLayer::PlatformMgr().InitChipStack(); + if (err != CHIP_NO_ERROR) + { + ChipLogAutomation("Chip stack initialization failed: %s", err.AsString()); + goto exit; + } + + ChipLogAutomation("Open IoT SDK unit-tests run..."); + status = RunRegisteredUnitTests(); + ChipLogAutomation("Test status: %d", status); + ChipLogAutomation("Open IoT SDK unit-tests completed"); +exit: + osThreadTerminate(osThreadGetId()); +} + +int main() +{ + ChipLogAutomation("Open IoT SDK unit-tests start"); + + if (openiotsdk_platform_init()) + { + ChipLogAutomation("ERROR: Open IoT SDK platform initialization failed"); + return EXIT_FAILURE; + } + + nlTestSetLogger(&NlTestLogger::nl_test_logger); + + static const osThreadAttr_t thread_attr = { + .stack_size = 20 * 1024 // Allocate enough stack for app thread + }; + + osThreadId_t testThread = osThreadNew(test_thread, NULL, &thread_attr); + if (testThread == NULL) + { + ChipLogAutomation("ERROR: Failed to create app thread"); + return EXIT_FAILURE; + } + + if (openiotsdk_platform_run()) + { + ChipLogAutomation("ERROR: Open IoT SDK platform run failed"); + return EXIT_FAILURE; + } + + return EXIT_SUCCESS; +} diff --git a/src/test_driver/openiotsdk/unit-tests/testnames.txt b/src/test_driver/openiotsdk/unit-tests/testnames.txt new file mode 100644 index 00000000000000..03fa4aee9b70f4 --- /dev/null +++ b/src/test_driver/openiotsdk/unit-tests/testnames.txt @@ -0,0 +1,24 @@ +accesstest +AppTests +ASN1Tests +BDXTests +ChipCryptoTests +CoreTests +CredentialsTest +DataModelTests +InetLayerTests +MdnsTests +MessagingLayerTests +MinimalMdnsCoreTests +MinimalMdnsRecordsTests +MinimalMdnsRespondersTests +PlatformTests +RawTransportTests +RetransmitTests +SecureChannelTests +SetupPayloadTests +SupportTests +SystemLayerTests +TestShell +TransportLayerTests +UserDirectedCommissioningTests diff --git a/src/tools/chip-cert/chip-cert.cpp b/src/tools/chip-cert/chip-cert.cpp index 8bc63a011e53d0..571a00421f2569 100644 --- a/src/tools/chip-cert/chip-cert.cpp +++ b/src/tools/chip-cert/chip-cert.cpp @@ -76,7 +76,7 @@ const char * const sHelp = * @return Unconditionally returns true. * */ -bool PrintVersion(void) +bool PrintVersion() { printf("chip " CHIP_VERSION_STRING "\n" COPYRIGHT_STRING); diff --git a/src/tools/spake2p/spake2p.cpp b/src/tools/spake2p/spake2p.cpp index 2f4890352add4e..45f5cc9d7c4323 100644 --- a/src/tools/spake2p/spake2p.cpp +++ b/src/tools/spake2p/spake2p.cpp @@ -53,7 +53,7 @@ const char * const sHelp = * @return Unconditionally returns true. * */ -bool PrintVersion(void) +bool PrintVersion() { printf("chip " CHIP_VERSION_STRING "\n" COPYRIGHT_STRING); diff --git a/src/transport/raw/tests/TestMessageHeader.cpp b/src/transport/raw/tests/TestMessageHeader.cpp index dc15dc894b0f49..15a845c8a6be9b 100644 --- a/src/transport/raw/tests/TestMessageHeader.cpp +++ b/src/transport/raw/tests/TestMessageHeader.cpp @@ -548,7 +548,7 @@ static const nlTest sTests[] = }; // clang-format on -int TestMessageHeader(void) +int TestMessageHeader() { nlTestSuite theSuite = { "Transport-MessageHeader", &sTests[0], nullptr, nullptr }; nlTestRunner(&theSuite, nullptr); diff --git a/src/transport/raw/tests/TestPeerAddress.cpp b/src/transport/raw/tests/TestPeerAddress.cpp index 617d18b037debc..262dab991fb554 100644 --- a/src/transport/raw/tests/TestPeerAddress.cpp +++ b/src/transport/raw/tests/TestPeerAddress.cpp @@ -124,7 +124,7 @@ const nlTest sTests[] = } // namespace -int TestPeerAddress(void) +int TestPeerAddress() { // clang-format off nlTestSuite theSuite = diff --git a/src/transport/tests/TestPeerConnections.cpp b/src/transport/tests/TestPeerConnections.cpp index 2e03347aa0f60b..b7de7c546e6965 100644 --- a/src/transport/tests/TestPeerConnections.cpp +++ b/src/transport/tests/TestPeerConnections.cpp @@ -162,7 +162,7 @@ static const nlTest sTests[] = }; // clang-format on -int TestPeerConnectionsFn(void) +int TestPeerConnectionsFn() { nlTestSuite theSuite = { "Transport-SecureSessionTable", &sTests[0], Initialize, Finalize }; nlTestRunner(&theSuite, nullptr); diff --git a/third_party/bouffalolab/bl602/bl602_executable.gni b/third_party/bouffalolab/bl602/bl602_executable.gni index b2e6ae85485ae4..5c327b0f913540 100644 --- a/third_party/bouffalolab/bl602/bl602_executable.gni +++ b/third_party/bouffalolab/bl602/bl602_executable.gni @@ -26,11 +26,9 @@ template("bl602_executable") { objcopy = "riscv64-unknown-elf-objcopy" if ("linux" == host_os) { - objcopy = - "../../${bouffalolab_toolchain}/Linux/bin/riscv64-unknown-elf-objcopy" + objcopy = "${bouffalolab_sdk_root}/toolchain/riscv/Linux/bin/riscv64-unknown-elf-objcopy" } else if ("mac" == host_os || "darwin" == host_os) { - objcopy = - "../../${bouffalolab_toolchain}/Darwin/bin/riscv64-unknown-elf-objcopy" + objcopy = "${bouffalolab_sdk_root}/toolchain/riscv/Darwin/bin/riscv64-unknown-elf-objcopy" } # Copy flashing dependencies to the output directory so that the output diff --git a/third_party/bouffalolab/bl602/bl602_sdk.gni b/third_party/bouffalolab/bl602/bl602_sdk.gni index 7c21ecdc63830d..fb8a661ef263ae 100644 --- a/third_party/bouffalolab/bl602/bl602_sdk.gni +++ b/third_party/bouffalolab/bl602/bl602_sdk.gni @@ -129,6 +129,7 @@ template("bl602_sdk") { "${bl602_sdk_root}/components/network/wifi_manager/bl60x_wifi_driver/include", "${bl602_sdk_root}/components/network/wifi_manager/bl60x_wifi_driver", "${bl602_sdk_root}/components/network/dns_server/include", + "${bl602_sdk_root}/components/network/rfparam_adapter_tmp/rftlv", "${bl602_sdk_root}/components/platform/soc/bl602/bl602_std/bl602_std/StdDriver/Inc", "${bl602_sdk_root}/components/security/blcrypto_suite/inc/blcrypto_suite", @@ -259,6 +260,7 @@ template("bl602_sdk") { #include defines "OS_USING_FREERTOS", "BL602_MATTER_SUPPORT", + "PBUF_POOL_SIZE=20", "TD_DIAGNOSIS_STA", "CONFIG_ENABLE_IPV6_ADDR_CALLBACK", "CONFIG_LWIP_HOOK_IP6_ROUTE_DEFAULT", @@ -320,6 +322,7 @@ template("bl602_sdk") { "${bl602_sdk_root}/components/stage/easyflash4/src/ef_utils.c", "${bl602_sdk_root}/components/sys/blmtd/bl_mtd.c", "${bl602_sdk_root}/components/sys/blota/bl_sys_ota_cli.c", + "${bl602_sdk_root}/components/utils/src/utils_hex.c", "${bl602_sdk_root}/components/utils/src/utils_hexdump.c", "${bl602_sdk_root}/components/utils/src/utils_sha256.c", "${chip_root}/third_party/mbedtls/repo/library/aes.c", @@ -548,6 +551,7 @@ template("bl602_sdk") { "${bl602_sdk_root}/components/utils/src/utils_rbtree.c", #rebase add + "${bl602_sdk_root}/components/network/rfparam_adapter_tmp/rftlv/phy_rftlv.c", "${bl602_sdk_root}/components/network/wifi_hosal/port/wifi_hosal_bl602.c", "${bl602_sdk_root}/components/network/wifi_hosal/wifi_hosal.c", "${bl602_sdk_root}/components/os/bl_os_adapter/bl_os_adapter/bl_os_hal.c", diff --git a/third_party/bouffalolab/bl702/bl702_executable.gni b/third_party/bouffalolab/bl702/bl702_executable.gni index 8d72c59b48acf7..e50120b0255f24 100644 --- a/third_party/bouffalolab/bl702/bl702_executable.gni +++ b/third_party/bouffalolab/bl702/bl702_executable.gni @@ -26,11 +26,9 @@ template("bl702_executable") { objcopy = "riscv64-unknown-elf-objcopy" if ("linux" == host_os) { - objcopy = - "../../${bouffalolab_toolchain}/Linux/bin/riscv64-unknown-elf-objcopy" + objcopy = "${bouffalolab_sdk_root}/toolchain/riscv/Linux/bin/riscv64-unknown-elf-objcopy" } else if ("mac" == host_os || "darwin" == host_os) { - objcopy = - "../../${bouffalolab_toolchain}/Darwin/bin/riscv64-unknown-elf-objcopy" + objcopy = "${bouffalolab_sdk_root}/toolchain/riscv/Darwin/bin/riscv64-unknown-elf-objcopy" } # Copy flashing dependencies to the output directory so that the output diff --git a/third_party/bouffalolab/repo b/third_party/bouffalolab/repo index dc526317d2903c..ae0622d85476ed 160000 --- a/third_party/bouffalolab/repo +++ b/third_party/bouffalolab/repo @@ -1 +1 @@ -Subproject commit dc526317d2903c4d3a8466226983ce34dc8f23d1 +Subproject commit ae0622d85476ed838ebc3efde9743c376bc9f96d diff --git a/third_party/mbedtls/repo b/third_party/mbedtls/repo index ed179db976fb1e..3917028ab75c58 160000 --- a/third_party/mbedtls/repo +++ b/third_party/mbedtls/repo @@ -1 +1 @@ -Subproject commit ed179db976fb1e9351795986cddac86a67aae08b +Subproject commit 3917028ab75c58e4f052f1fccd8370593b936573 diff --git a/third_party/openthread/platforms/BUILD.gn b/third_party/openthread/platforms/BUILD.gn index 3e0e4d2da2dfc7..7445a6407ab63e 100644 --- a/third_party/openthread/platforms/BUILD.gn +++ b/third_party/openthread/platforms/BUILD.gn @@ -12,8 +12,10 @@ # See the License for the specific language governing permissions and # limitations under the License. +import("//build_overrides/chip.gni") import("//build_overrides/jlink.gni") import("//build_overrides/openthread.gni") +import("${chip_root}/src/platform/device.gni") config("libopenthread-platform_config") { include_dirs = [ "${openthread_root}/examples/platforms" ] @@ -45,8 +47,6 @@ static_library("libopenthread-platform-utils") { "${openthread_root}/examples/platforms/utils/code_utils.h", "${openthread_root}/examples/platforms/utils/debug_uart.c", "${openthread_root}/examples/platforms/utils/encoding.h", - "${openthread_root}/examples/platforms/utils/logging_rtt.c", - "${openthread_root}/examples/platforms/utils/logging_rtt.h", "${openthread_root}/examples/platforms/utils/mac_frame.cpp", "${openthread_root}/examples/platforms/utils/mac_frame.h", "${openthread_root}/examples/platforms/utils/settings.h", @@ -54,10 +54,17 @@ static_library("libopenthread-platform-utils") { "${openthread_root}/examples/platforms/utils/soft_source_match_table.c", "${openthread_root}/examples/platforms/utils/soft_source_match_table.h", ] - public_deps = [ - "${openthread_root}/src/core:libopenthread_core_headers", - "${segger_rtt_root}:segger_rtt", - ] + + public_deps = [ "${openthread_root}/src/core:libopenthread_core_headers" ] + + if (chip_enable_segger_rtt) { + sources += [ + "${openthread_root}/examples/platforms/utils/logging_rtt.c", + "${openthread_root}/examples/platforms/utils/logging_rtt.h", + ] + + public_deps += [ "${segger_rtt_root}:segger_rtt" ] + } public_configs = [ ":libopenthread-platform_config" ] } diff --git a/third_party/openthread/repo b/third_party/openthread/repo index faeea3d2b9df48..27b43146a931f2 160000 --- a/third_party/openthread/repo +++ b/third_party/openthread/repo @@ -1 +1 @@ -Subproject commit faeea3d2b9df48dd769592b7c5a85609c0c48389 +Subproject commit 27b43146a931f2d53380f9e895223ce18e5a83d3 diff --git a/third_party/pigweed/repo b/third_party/pigweed/repo index 9264e6862cc408..4b50d0eac2fe6b 160000 --- a/third_party/pigweed/repo +++ b/third_party/pigweed/repo @@ -1 +1 @@ -Subproject commit 9264e6862cc40868a902e5e4ac4e43e2f7eb040d +Subproject commit 4b50d0eac2fe6bc14ec46b51cd8519ca8c042e92 diff --git a/third_party/qpg_sdk/BUILD.gn b/third_party/qpg_sdk/BUILD.gn index 88263ed5a4ebfe..d1c60542365ae9 100755 --- a/third_party/qpg_sdk/BUILD.gn +++ b/third_party/qpg_sdk/BUILD.gn @@ -160,10 +160,10 @@ static_library("qpg_bootloader_lib") { qpg_make_build("qpg_openthread_glue") { make_sources = [ "${qpg_sdk_root}/Components/Qorvo/Matter" ] - make_output = [ "${target_gen_dir}/${qpg_sdk_lib_dir}/OpenThreadQorvoGlue_qpg6105_mtd/libOpenThreadQorvoGlue_${qpg_target_ic}_mtd.a" ] + make_output = [ "${target_gen_dir}/${qpg_sdk_lib_dir}/OpenThreadQorvoGlue_qpg6105_ftd/libOpenThreadQorvoGlue_${qpg_target_ic}_ftd.a" ] make_args = [ "-f", - rebase_path(qpg_sdk_root, root_build_dir) + "/Libraries/Qorvo/OpenThreadQorvoGlue/Makefile.OpenThreadQorvoGlue_${qpg_target_ic}_mtd", + rebase_path(qpg_sdk_root, root_build_dir) + "/Libraries/Qorvo/OpenThreadQorvoGlue/Makefile.OpenThreadQorvoGlue_${qpg_target_ic}_ftd", "FREERTOS_REPO_DIR=" + rebase_path(chip_root, root_build_dir) + "/third_party/freertos/repo", "MBEDTLS_REPO_DIR=" + rebase_path(chip_root, root_build_dir) + @@ -171,10 +171,10 @@ qpg_make_build("qpg_openthread_glue") { "OPENTHREAD_REPO_DIR =" + rebase_path(chip_root, root_build_dir) + "/third_party/openthread/repo", "WORKDIR=" + rebase_path(target_gen_dir, root_build_dir) + - "/${qpg_sdk_lib_dir}/OpenThreadQorvoGlue_${qpg_target_ic}_mtd", + "/${qpg_sdk_lib_dir}/OpenThreadQorvoGlue_${qpg_target_ic}_ftd", ] } static_library("qpg_openthread_glue_lib") { deps = [ "${chip_root}/third_party/qpg_sdk:qpg_openthread_glue" ] - libs = [ "${target_gen_dir}/${qpg_sdk_lib_dir}/OpenThreadQorvoGlue_qpg6105_mtd/libOpenThreadQorvoGlue_${qpg_target_ic}_mtd.a" ] + libs = [ "${target_gen_dir}/${qpg_sdk_lib_dir}/OpenThreadQorvoGlue_qpg6105_ftd/libOpenThreadQorvoGlue_${qpg_target_ic}_ftd.a" ] } diff --git a/third_party/qpg_sdk/repo b/third_party/qpg_sdk/repo index 617a0b065592c0..eb198408bc8581 160000 --- a/third_party/qpg_sdk/repo +++ b/third_party/qpg_sdk/repo @@ -1 +1 @@ -Subproject commit 617a0b065592c0bd298d28e4b275c830b91b3d7b +Subproject commit eb198408bc8581702fc0fccd2e05345a1491b558 diff --git a/third_party/silabs/BUILD.gn b/third_party/silabs/BUILD.gn index f968d3dc38f13c..9ef1251fd88f31 100644 --- a/third_party/silabs/BUILD.gn +++ b/third_party/silabs/BUILD.gn @@ -16,7 +16,13 @@ import("//build_overrides/chip.gni") import("//build_overrides/efr32_sdk.gni") import("//build_overrides/jlink.gni") import("${chip_root}/src/platform/device.gni") -import("${efr32_sdk_build_root}/efr32_sdk.gni") +import("${efr32_sdk_build_root}/silabs_board.gni") + +if (silabs_board == "BRD4325A") { # CCP board + import("${efr32_sdk_build_root}/SiWx917_sdk.gni") +} else { + import("${efr32_sdk_build_root}/efr32_sdk.gni") +} declare_args() { # Build target to use for efr32 SDK. Use this to set global SDK defines. @@ -24,10 +30,17 @@ declare_args() { sl_ot_efr32_root = "${chip_root}/third_party/openthread/ot-efr32" sl_openthread_root = "${chip_root}/third_party/openthread/ot-efr32/openthread" use_thread_coap_lib = false + sl_matter_version_str = "" } assert(efr32_sdk_target != "", "efr32_sdk_target must be specified") +config("silabs_config") { + if (sl_matter_version_str != "") { + defines = [ "SL_MATTER_VERSION_STRING=\"${sl_matter_version_str}\"" ] + } +} + group("efr32_sdk") { public_deps = [ efr32_sdk_target ] } diff --git a/third_party/silabs/SiWx917_sdk.gni b/third_party/silabs/SiWx917_sdk.gni new file mode 100644 index 00000000000000..a60d443f7ed2c0 --- /dev/null +++ b/third_party/silabs/SiWx917_sdk.gni @@ -0,0 +1,340 @@ +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/chip.gni") +import("//build_overrides/efr32_sdk.gni") +import("//build_overrides/jlink.gni") +import("//build_overrides/mbedtls.gni") + +import("${chip_root}/src/lib/lib.gni") +import("silabs_board.gni") + +declare_args() { + # Location of the efr32 SDK. + efr32_sdk_root = "${chip_root}/third_party/silabs/gecko_sdk" + sdk_support_root = "${chip_root}/third_party/silabs/matter_support" + wiseconnect_sdk_root = "${chip_root}/third_party/silabs/wisemcu-wifi-bt-sdk" + examples_plat_dir = "${chip_root}/examples/platform/silabs/SiWx917" + + # Build openthread with prebuilt silabs lib + use_silabs_thread_lib = false + enable_openthread_cli = true + + kvs_max_entries = 75 + use_external_flash = true + + # Use Silabs factory data provider example. + # Users can implement their own. + use_efr32_factory_data_provider = true + + # Enable Segger System View + use_system_view = false +} + +# Explorer Kit and MGM240L do not have external flash +if (silabs_board == "BRD2703A" || silabs_board == "BRD4319A") { + use_external_flash = false +} + +# Enable LEDs by default +use_wstk_leds = true + +# Board does not support LEDs and Buttons at the same time +if (silabs_board == "BRD4317A" || silabs_board == "BRD4316A" || + silabs_board == "BRD4319A") { + use_wstk_leds = false +} + +assert(efr32_sdk_root != "", "efr32_sdk_root must be specified") + +# Defines an efr32 SDK build target. +# +# Parameters: +# efr32_sdk_root - The location of the erf32 SDK. +# sources - The sources files to build. +template("efr32_sdk") { + if (defined(invoker.efr32_sdk_root)) { + efr32_sdk_root = invoker.efr32_sdk_root + } + + assert(efr32_sdk_root != "", "efr32_sdk_root must be specified") + + sdk_target_name = target_name + + config("${sdk_target_name}_config") { + include_dirs = [] + libs = [] + if (defined(invoker.include_dirs)) { + include_dirs += invoker.include_dirs + } + + # Treat these includes as system includes, so warnings in them are not fatal. + _include_dirs = [ + "${sdk_support_root}/platform/emdrv/nvm3/inc", + + "${chip_root}/third_party/mbedtls/repo/include", + + ### CCP includes ### + "${wiseconnect_sdk_root}/platforms/si91x/drivers/peripheral_drivers/inc", + "${wiseconnect_sdk_root}/platforms/si91x/core/chip/inc", + "${wiseconnect_sdk_root}/platforms/si91x/core/config", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/cmsis_driver/config", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/rom_driver/inc", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/systemlevel/inc", + + "${wiseconnect_sdk_root}/platforms/si91x/drivers/cmsis_driver", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/cmsis_driver/CMSIS/Driver/Include", + "${wiseconnect_sdk_root}/platforms/si91x/boards/brd4325a/inc", + "${wiseconnect_sdk_root}/platforms/si91x/core/cmsis", + "${wiseconnect_sdk_root}/third_party/freertos/include", + "${wiseconnect_sdk_root}/third_party/freertos/portable/GCC/ARM_CM4F", + "${examples_plat_dir}/device/inc", + + "${wiseconnect_sdk_root}/sapi/include", + + "${chip_root}/examples/platform/SiWx917/SiWx917", + "${chip_root}/examples/platform/SiWx917/SiWx917/hal", + ] + + # Note that we're setting the mbedTLS and PSA configuration files through a + # define. This means the build system by default does not pick up changes in + # the content of these, only when changing the filename itself. + # To fix this, these files are also manually depended upon in the source set + # declared in efr32_mbedtls_config further down this file. + defines = [ + "MBEDTLS_CONFIG_FILE=\"siwx917-chip-mbedtls-config.h\"", + "__STARTUP_CLEAR_BSS", + "HARD_FAULT_LOG_ENABLE", + "CORTEXM3_EFM32_MICRO", + "SILABS_LOG_ENABLED=1", + + #Matter required at least 40960 but SiWx917 SoC requires an extra 20k to resolve nvm3_open() error, Need to be checked. + "NVM3_DEFAULT_NVM_SIZE=73728", + "NVM3_DEFAULT_MAX_OBJECT_SIZE=4092", + "KVS_MAX_ENTRIES=${kvs_max_entries}", + "EFR32_OPENTHREAD_API", + "PHY=EMBER_PHY_RAIL", + "CORTEXM3", + "MICRO=EMBER_MICRO_CORTEXM3_EFR32", + "PLAT=EMBER_PLATFORM_CORTEXM3", + "${silabs_mcu}=1", + "${silabs_board}=1", + "__HEAP_SIZE=0", + "SL_COMPONENT_CATALOG_PRESENT", + "PLATFORM_HEADER=\"platform-header.h\"", + "USE_NVM3=1", + "RSI_ARM_CM4F", + "RSI_BLE_ENABLE=1", + "BRD4325A", + "CHIP_9117", + "RS91X_BLE_ENABLE=1", + ] + + if (use_system_view) { + _include_dirs += [ + "${efr32_sdk_root}/util/third_party/segger/systemview/SEGGER", + "${efr32_sdk_root}/util/third_party/segger/systemview/Sample/FreeRTOSV10/Config/Cortex-M", + "${efr32_sdk_root}/util/third_party/segger/systemview/Sample/FreeRTOSV10", + "${efr32_sdk_root}/util/third_party/segger/systemview/Config/", + ] + + defines += [ "SL_SYSTEM_VIEW=1" ] + } + + defines += board_defines + + if (defined(invoker.enable_sleepy_device)) { + if (invoker.enable_sleepy_device) { + defines += [ + "CHIP_DEVICE_CONFIG_ENABLE_SED=1", + "SL_CATALOG_POWER_MANAGER_PRESENT", + "SL_CATALOG_SLEEPTIMER_PRESENT", + ] + } + } + + if (chip_build_libshell) { # matter shell + defines += [ + "ENABLE_CHIP_SHELL", + "OPENTHREAD_CONFIG_CLI_TRANSPORT=OT_CLI_TRANSPORT_CONSOLE", + "CHIP_DEVICE_CONFIG_THREAD_ENABLE_CLI=1", + ] + } else { + if (enable_openthread_cli) { # ot-cli only + defines += [ "CHIP_DEVICE_CONFIG_THREAD_ENABLE_CLI=1" ] + } + } + + # USART include files + if ((defined(invoker.chip_enable_pw_rpc) && invoker.chip_enable_pw_rpc) || + chip_build_libshell || enable_openthread_cli || + (defined(invoker.chip_enable_wifi) && invoker.chip_enable_wifi) || + (defined(invoker.show_qr_code) && invoker.show_qr_code) || + (defined(invoker.disable_lcd) && !invoker.disable_lcd) || + (defined(invoker.use_external_flash) && use_external_flash)) { + defines += [ "CONFIG_ENABLE_UART" ] + + if (defined(invoker.use_external_flash) && use_external_flash) { + defines += [ "CONFIG_USE_EXTERNAL_FLASH" ] + + _include_dirs += [ "${efr32_sdk_root}/hardware/driver/mx25_flash_shutdown/inc/sl_mx25_flash_shutdown_usart" ] + } + + _include_dirs += [ + "${efr32_sdk_root}/platform/emdrv/uartdrv/inc", + "${efr32_sdk_root}/platform/emdrv/uartdrv/config", + "${efr32_sdk_root}/hardware/driver/memlcd/inc/memlcd_usart", + "${efr32_sdk_root}/platform/common/errno/inc", + ] + } + + libs += [ "${sdk_support_root}/platform/emdrv/nvm3/lib/libnvm3_CM4_gcc.a" ] + + cflags = [] + foreach(include_dir, _include_dirs) { + cflags += [ "-isystem" + rebase_path(include_dir, root_build_dir) ] + } + + cflags += [ + "-Wno-maybe-uninitialized", + "-Wno-shadow", + ] + + if (silabs_family == "efr32mg24" || silabs_family == "mgm24") { + cflags += [ "-mcmse" ] + } + + if (defined(invoker.use_rs911x)) { + if (invoker.use_rs911x == true) { + #add compilation flags for rs991x build. This will be addressed directly in wiseconnect sdk in the next version release of that sdk + cflags += invoker.rs911x_cflags + } + } + + if (defined(invoker.defines)) { + defines += invoker.defines + } + } + + source_set("si917_mbedtls_config") { + # We're setting the mbedTLS config flags here as the efr32_sdk target + # acts as the mbedTLS target for EFR32 builds. We need this for the build + # system to recompile mbedTLS (= the SDK) when the mbedTLS config gets + # edited. + sources = [ + "${chip_root}/src/platform/silabs/SiWx917/siwx917-chip-mbedtls-config.h", + ] + + public_deps = [ "${chip_root}/src/crypto:crypto_buildconfig" ] + } + + source_set(sdk_target_name) { + sources = [ + "${examples_plat_dir}/device/src/startup_RS1xxxx.c", + "${sdk_support_root}/platform/emdrv/nvm3/src/ccp_flash_dev.c", + "${sdk_support_root}/platform/emdrv/nvm3/src/ccp_flash_intf.c", + "${sdk_support_root}/platform/emdrv/nvm3/src/ccp_flash_prg.c", + "${sdk_support_root}/platform/emdrv/nvm3/src/nvm3_default.c", + + ### nvm3 for ccp platform ### + "${sdk_support_root}/platform/emdrv/nvm3/src/nvm3_hal_flash_ccp.c", + "${sdk_support_root}/platform/emdrv/nvm3/src/nvm3_lock.c", + + ######## CCP Platform ######### + "${wiseconnect_sdk_root}/platforms/si91x/boards/brd4325a/src/rsi_board.c", + + #"${wiseconnect_sdk_root}/platforms/si91x/boards/brd4325a/src/syscalls.c", + "${wiseconnect_sdk_root}/platforms/si91x/core/chip/src/rsi_deepsleep_commonflash.c", + "${wiseconnect_sdk_root}/platforms/si91x/core/chip/src/rsi_ps_ram_func.c", + "${wiseconnect_sdk_root}/platforms/si91x/core/chip/src/rsi_system_config.c", + "${wiseconnect_sdk_root}/platforms/si91x/core/chip/src/system_RS1xxxx.c", + + #"${wiseconnect_sdk_root}/platforms/si91x/drivers/cmsis_driver/UDMA.c", + #"${wiseconnect_sdk_root}/platforms/si91x/drivers/cmsis_driver/USART.c", + + "${wiseconnect_sdk_root}/platforms/si91x/drivers/peripheral_drivers/src/clock_update.c", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/peripheral_drivers/src/rsi_comparator.c", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/peripheral_drivers/src/rsi_egpio.c", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/peripheral_drivers/src/rsi_udma.c", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/peripheral_drivers/src/rsi_udma_wrapper.c", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/peripheral_drivers/src/rsi_usart.c", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/systemlevel/src/rsi_ipmu.c", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/systemlevel/src/rsi_pll.c", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/systemlevel/src/rsi_power_save.c", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/systemlevel/src/rsi_processor_sensor.c", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/systemlevel/src/rsi_rtc.c", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/systemlevel/src/rsi_temp_sensor.c", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/systemlevel/src/rsi_time_period.c", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/systemlevel/src/rsi_ulpss_clk.c", + "${wiseconnect_sdk_root}/platforms/si91x/drivers/systemlevel/src/rsi_wwdt.c", + "${wiseconnect_sdk_root}/third_party/freertos/croutine.c", + "${wiseconnect_sdk_root}/third_party/freertos/event_groups.c", + "${wiseconnect_sdk_root}/third_party/freertos/list.c", + "${wiseconnect_sdk_root}/third_party/freertos/portable/GCC/ARM_CM4F/port.c", + "${wiseconnect_sdk_root}/third_party/freertos/queue.c", + "${wiseconnect_sdk_root}/third_party/freertos/stream_buffer.c", + "${wiseconnect_sdk_root}/third_party/freertos/tasks.c", + "${wiseconnect_sdk_root}/third_party/freertos/timers.c", + + # Bluetooth + "${wiseconnect_sdk_root}/sapi/bluetooth/rsi_ble_gap_apis.c", + "${wiseconnect_sdk_root}/sapi/bluetooth/rsi_ble_gatt_apis.c", + "${wiseconnect_sdk_root}/sapi/bluetooth/rsi_bt_common_apis.c", + "${wiseconnect_sdk_root}/sapi/driver/rsi_bt_ble.c", + + # mbedtls + "${chip_root}/third_party/mbedtls/repo/library/aes.c", + "${chip_root}/third_party/mbedtls/repo/library/asn1parse.c", + "${chip_root}/third_party/mbedtls/repo/library/asn1write.c", + "${chip_root}/third_party/mbedtls/repo/library/bignum.c", + "${chip_root}/third_party/mbedtls/repo/library/ccm.c", + "${chip_root}/third_party/mbedtls/repo/library/cipher.c", + "${chip_root}/third_party/mbedtls/repo/library/cipher_wrap.c", + "${chip_root}/third_party/mbedtls/repo/library/constant_time.c", + "${chip_root}/third_party/mbedtls/repo/library/ctr_drbg.c", + "${chip_root}/third_party/mbedtls/repo/library/ecdh.c", + "${chip_root}/third_party/mbedtls/repo/library/ecdsa.c", + "${chip_root}/third_party/mbedtls/repo/library/ecp.c", + "${chip_root}/third_party/mbedtls/repo/library/ecp_curves.c", + "${chip_root}/third_party/mbedtls/repo/library/entropy.c", + "${chip_root}/third_party/mbedtls/repo/library/hkdf.c", + "${chip_root}/third_party/mbedtls/repo/library/hmac_drbg.c", + "${chip_root}/third_party/mbedtls/repo/library/md.c", + "${chip_root}/third_party/mbedtls/repo/library/oid.c", + "${chip_root}/third_party/mbedtls/repo/library/pk.c", + "${chip_root}/third_party/mbedtls/repo/library/pk_wrap.c", + "${chip_root}/third_party/mbedtls/repo/library/pkcs5.c", + "${chip_root}/third_party/mbedtls/repo/library/pkwrite.c", + "${chip_root}/third_party/mbedtls/repo/library/platform.c", + "${chip_root}/third_party/mbedtls/repo/library/platform_util.c", + "${chip_root}/third_party/mbedtls/repo/library/sha256.c", + "${chip_root}/third_party/mbedtls/repo/library/sha512.c", + "${chip_root}/third_party/mbedtls/repo/library/x509_create.c", + "${chip_root}/third_party/mbedtls/repo/library/x509write_csr.c", + ] + + public_deps = [ + ":si917_mbedtls_config", + "${segger_rtt_root}:segger_rtt", + "${segger_rtt_root}:segger_rtt_printf", + "${segger_rtt_root}:segger_rtt_syscalls", + ] + + if (defined(invoker.sources)) { + sources += invoker.sources + } + + public_configs = [ ":${sdk_target_name}_config" ] + } +} diff --git a/third_party/silabs/efr32_arm.gni b/third_party/silabs/efr32_arm.gni index e1696309677ae2..68126f50843c8d 100644 --- a/third_party/silabs/efr32_arm.gni +++ b/third_party/silabs/efr32_arm.gni @@ -14,7 +14,7 @@ import("silabs_board.gni") -if (silabs_family == "efr32mg12") { +if (silabs_family == "efr32mg12" || silabs_family == "SiWx917") { arm_arch = "armv7e-m" arm_abi = "aapcs" arm_cpu = "cortex-m4" diff --git a/third_party/silabs/efr32_sdk.gni b/third_party/silabs/efr32_sdk.gni index 39d6e5d7161ce4..c6aa9d95a4fdb0 100644 --- a/third_party/silabs/efr32_sdk.gni +++ b/third_party/silabs/efr32_sdk.gni @@ -38,6 +38,8 @@ declare_args() { # Enable Segger System View use_system_view = false + + sleep_time_ms = 3300000 # 55 mins sleep } # Explorer Kit and MGM240L do not have external flash @@ -223,6 +225,7 @@ template("efr32_sdk") { "CHIP_DEVICE_CONFIG_ENABLE_SED=1", "SL_CATALOG_POWER_MANAGER_PRESENT", "SL_CATALOG_SLEEPTIMER_PRESENT", + "SL_SLEEP_TIME_MS=${sleep_time_ms}", ] } } diff --git a/third_party/silabs/silabs_board.gni b/third_party/silabs/silabs_board.gni index b5fe904a1e9561..1e638c9351a2b6 100644 --- a/third_party/silabs/silabs_board.gni +++ b/third_party/silabs/silabs_board.gni @@ -59,6 +59,9 @@ if (silabs_board == "BRD4304A") { } else if (silabs_board == "BRD4170A") { silabs_family = "efr32mg12" silabs_mcu = "EFR32MG12P433F1024GM68" +} else if (silabs_board == "BRD4325A") { + silabs_family = "SiWx917" + silabs_mcu = "EFR32MG12P432F1024GL125" } else if (silabs_board == "BRD4180A") { assert( false, diff --git a/third_party/telink_sdk/BUILD.gn b/third_party/telink_sdk/BUILD.gn deleted file mode 100644 index ac8b84a8177e0a..00000000000000 --- a/third_party/telink_sdk/BUILD.gn +++ /dev/null @@ -1,47 +0,0 @@ -# Copyright (c) 2020 Project CHIP Authors -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import("//build_overrides/telink.gni") - -config("telink_sdk_config") { - include_dirs = [ - "${telink_sdk_build_root}/repo/eagle_ble_sdk", - "${telink_sdk_build_root}/repo/eagle_ble_sdk/drivers/B91", - "${telink_sdk_build_root}/repo/eagle_ble_sdk/stack/ble", - "${telink_sdk_build_root}/repo/eagle_ble_sdk/stack/ble/controller", - "${telink_sdk_build_root}/repo/eagle_ble_sdk/vendor/common", - ] - - libs = [ - "${telink_sdk_build_root}/repo/eagle_ble_sdk/proj_lib/libB91_ble_lib.a", - ] - - defines = [ - "USE_ZEPHYR_HAL_HEADERS", - "MCU_CORE_TYPE = MCU_CORE_9518", - ] - - cflags = [] -} - -source_set("telink_sdk") { - sources = [ - "${telink_sdk_build_root}/repo/eagle_ble_sdk/common/utility.c", - "${telink_sdk_build_root}/repo/eagle_ble_sdk/drivers/B91/aes.c", - "${telink_sdk_build_root}/repo/eagle_ble_sdk/drivers/B91/ext_driver/software_pa.c", - "${telink_sdk_build_root}/repo/eagle_ble_sdk/vendor/common/blt_common.c", - ] - - public_configs = [ ":telink_sdk_config" ] -} diff --git a/third_party/telink_sdk/repo b/third_party/telink_sdk/repo deleted file mode 160000 index 6a3cb0a3615cf7..00000000000000 --- a/third_party/telink_sdk/repo +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 6a3cb0a3615cf7f2f0418440d3ae9d93f6f3e595 diff --git a/zzz_generated/app-common/app-common/zap-generated/af-structs.h b/zzz_generated/app-common/app-common/zap-generated/af-structs.h index 3c1d5866c587f0..504c6d137296ba 100644 --- a/zzz_generated/app-common/app-common/zap-generated/af-structs.h +++ b/zzz_generated/app-common/app-common/zap-generated/af-structs.h @@ -368,6 +368,14 @@ typedef struct _LineupInfo uint8_t lineupInfoType; } LineupInfo; +// Struct for MonitoringRegistration +typedef struct _MonitoringRegistration +{ + chip::NodeId ClientNodeId; + uint64_t ICid; + chip::FabricIndex FabricIndex; +} MonitoringRegistration; + // Struct for NOCStruct typedef struct _NOCStruct { diff --git a/zzz_generated/app-common/app-common/zap-generated/attribute-id.h b/zzz_generated/app-common/app-common/zap-generated/attribute-id.h index ae5e84a0245133..db53fc67718181 100644 --- a/zzz_generated/app-common/app-common/zap-generated/attribute-id.h +++ b/zzz_generated/app-common/app-common/zap-generated/attribute-id.h @@ -1133,6 +1133,16 @@ #define ZCL_RMS_VOLTAGE_SAG_PERIOD_PHASE_C_ATTRIBUTE_ID (0x0A16) #define ZCL_RMS_VOLTAGE_SWELL_PERIOD_PHASE_C_ATTRIBUTE_ID (0x0A17) +// Attribute ids for cluster: Client Monitoring + +// Client attributes + +// Server attributes +#define ZCL_IDLE_MODE_INTERVAL_ATTRIBUTE_ID (0x0000) +#define ZCL_ACTIVE_MODE_INTERVAL_ATTRIBUTE_ID (0x0001) +#define ZCL_ACTIVE_MODE_THRESHOLD_ATTRIBUTE_ID (0x0002) +#define ZCL_EXPECTED_CLIENTS_ATTRIBUTE_ID (0x0003) + // Attribute ids for cluster: Unit Testing // Client attributes diff --git a/zzz_generated/app-common/app-common/zap-generated/attribute-size.h b/zzz_generated/app-common/app-common/zap-generated/attribute-size.h index 1dd48e3117cf14..1c8dc9b444bb1e 100644 --- a/zzz_generated/app-common/app-common/zap-generated/attribute-size.h +++ b/zzz_generated/app-common/app-common/zap-generated/attribute-size.h @@ -28,10 +28,10 @@ ZCL_BOOLEAN_ATTRIBUTE_TYPE, 1, ZCL_BITMAP8_ATTRIBUTE_TYPE, 1, ZCL_BITMAP16_ATTRI ZCL_INT24S_ATTRIBUTE_TYPE, 3, ZCL_INT32S_ATTRIBUTE_TYPE, 4, ZCL_INT40S_ATTRIBUTE_TYPE, 5, ZCL_INT48S_ATTRIBUTE_TYPE, 6, ZCL_INT56S_ATTRIBUTE_TYPE, 7, ZCL_INT64S_ATTRIBUTE_TYPE, 8, ZCL_ENUM8_ATTRIBUTE_TYPE, 1, ZCL_ENUM16_ATTRIBUTE_TYPE, 2, ZCL_SINGLE_ATTRIBUTE_TYPE, 4, ZCL_DOUBLE_ATTRIBUTE_TYPE, 8, ZCL_TOD_ATTRIBUTE_TYPE, 4, ZCL_DATE_ATTRIBUTE_TYPE, 4, - ZCL_UTC_ATTRIBUTE_TYPE, 4, ZCL_EPOCH_US_ATTRIBUTE_TYPE, 8, ZCL_EPOCH_S_ATTRIBUTE_TYPE, 4, ZCL_SYSTIME_US_ATTRIBUTE_TYPE, 8, - ZCL_PERCENT_ATTRIBUTE_TYPE, 1, ZCL_PERCENT100THS_ATTRIBUTE_TYPE, 2, ZCL_CLUSTER_ID_ATTRIBUTE_TYPE, 4, - ZCL_ATTRIB_ID_ATTRIBUTE_TYPE, 4, ZCL_FIELD_ID_ATTRIBUTE_TYPE, 4, ZCL_EVENT_ID_ATTRIBUTE_TYPE, 4, ZCL_COMMAND_ID_ATTRIBUTE_TYPE, - 4, ZCL_ACTION_ID_ATTRIBUTE_TYPE, 1, ZCL_TRANS_ID_ATTRIBUTE_TYPE, 4, ZCL_NODE_ID_ATTRIBUTE_TYPE, 8, ZCL_VENDOR_ID_ATTRIBUTE_TYPE, - 2, ZCL_DEVTYPE_ID_ATTRIBUTE_TYPE, 4, ZCL_FABRIC_ID_ATTRIBUTE_TYPE, 8, ZCL_GROUP_ID_ATTRIBUTE_TYPE, 2, ZCL_STATUS_ATTRIBUTE_TYPE, - 2, ZCL_DATA_VER_ATTRIBUTE_TYPE, 4, ZCL_EVENT_NO_ATTRIBUTE_TYPE, 8, ZCL_ENDPOINT_NO_ATTRIBUTE_TYPE, 2, + ZCL_EPOCH_US_ATTRIBUTE_TYPE, 8, ZCL_EPOCH_S_ATTRIBUTE_TYPE, 4, ZCL_SYSTIME_US_ATTRIBUTE_TYPE, 8, ZCL_PERCENT_ATTRIBUTE_TYPE, 1, + ZCL_PERCENT100THS_ATTRIBUTE_TYPE, 2, ZCL_CLUSTER_ID_ATTRIBUTE_TYPE, 4, ZCL_ATTRIB_ID_ATTRIBUTE_TYPE, 4, + ZCL_FIELD_ID_ATTRIBUTE_TYPE, 4, ZCL_EVENT_ID_ATTRIBUTE_TYPE, 4, ZCL_COMMAND_ID_ATTRIBUTE_TYPE, 4, ZCL_ACTION_ID_ATTRIBUTE_TYPE, + 1, ZCL_TRANS_ID_ATTRIBUTE_TYPE, 4, ZCL_NODE_ID_ATTRIBUTE_TYPE, 8, ZCL_VENDOR_ID_ATTRIBUTE_TYPE, 2, + ZCL_DEVTYPE_ID_ATTRIBUTE_TYPE, 4, ZCL_FABRIC_ID_ATTRIBUTE_TYPE, 8, ZCL_GROUP_ID_ATTRIBUTE_TYPE, 2, ZCL_STATUS_ATTRIBUTE_TYPE, 2, + ZCL_DATA_VER_ATTRIBUTE_TYPE, 4, ZCL_EVENT_NO_ATTRIBUTE_TYPE, 8, ZCL_ENDPOINT_NO_ATTRIBUTE_TYPE, 2, ZCL_FABRIC_IDX_ATTRIBUTE_TYPE, 1, ZCL_IPV4ADR_ATTRIBUTE_TYPE, 4, ZCL_IPV6ADR_ATTRIBUTE_TYPE, 16, diff --git a/zzz_generated/app-common/app-common/zap-generated/attribute-type.h b/zzz_generated/app-common/app-common/zap-generated/attribute-type.h index c99ef54ed32359..b53b87637673c2 100644 --- a/zzz_generated/app-common/app-common/zap-generated/attribute-type.h +++ b/zzz_generated/app-common/app-common/zap-generated/attribute-type.h @@ -58,7 +58,6 @@ enum ZCL_STRUCT_ATTRIBUTE_TYPE = 0x4C, // Structure ZCL_TOD_ATTRIBUTE_TYPE = 0xE0, // Time of day ZCL_DATE_ATTRIBUTE_TYPE = 0xE1, // Date - ZCL_UTC_ATTRIBUTE_TYPE = 0xE2, // UTC Time ZCL_EPOCH_US_ATTRIBUTE_TYPE = 0xE3, // Epoch Microseconds ZCL_EPOCH_S_ATTRIBUTE_TYPE = 0xE4, // Epoch Seconds ZCL_SYSTIME_US_ATTRIBUTE_TYPE = 0xE5, // System Time Microseconds diff --git a/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.cpp b/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.cpp index aba2445a5cba5d..5a41eed51bbc3f 100644 --- a/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.cpp +++ b/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.cpp @@ -16399,7 +16399,7 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint32_t value) Traits::StorageType storageValue; Traits::WorkingToStorage(value, storageValue); uint8_t * writable = Traits::ToAttributeStoreRepresentation(storageValue); - return emberAfWriteServerAttribute(endpoint, Clusters::Thermostat::Id, Id, writable, ZCL_UTC_ATTRIBUTE_TYPE); + return emberAfWriteServerAttribute(endpoint, Clusters::Thermostat::Id, Id, writable, ZCL_EPOCH_S_ATTRIBUTE_TYPE); } } // namespace SetpointChangeSourceTimestamp @@ -27727,6 +27727,167 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) } // namespace Attributes } // namespace ElectricalMeasurement +namespace ClientMonitoring { +namespace Attributes { + +namespace IdleModeInterval { + +EmberAfStatus Get(chip::EndpointId endpoint, uint32_t * value) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType temp; + uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); + EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::ClientMonitoring::Id, Id, readable, sizeof(temp)); + VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); + if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + { + return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + } + *value = Traits::StorageToWorking(temp); + return status; +} +EmberAfStatus Set(chip::EndpointId endpoint, uint32_t value) +{ + using Traits = NumericAttributeTraits; + if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + { + return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + } + Traits::StorageType storageValue; + Traits::WorkingToStorage(value, storageValue); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(storageValue); + return emberAfWriteServerAttribute(endpoint, Clusters::ClientMonitoring::Id, Id, writable, ZCL_INT32U_ATTRIBUTE_TYPE); +} + +} // namespace IdleModeInterval + +namespace ActiveModeInterval { + +EmberAfStatus Get(chip::EndpointId endpoint, uint32_t * value) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType temp; + uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); + EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::ClientMonitoring::Id, Id, readable, sizeof(temp)); + VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); + if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + { + return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + } + *value = Traits::StorageToWorking(temp); + return status; +} +EmberAfStatus Set(chip::EndpointId endpoint, uint32_t value) +{ + using Traits = NumericAttributeTraits; + if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + { + return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + } + Traits::StorageType storageValue; + Traits::WorkingToStorage(value, storageValue); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(storageValue); + return emberAfWriteServerAttribute(endpoint, Clusters::ClientMonitoring::Id, Id, writable, ZCL_INT32U_ATTRIBUTE_TYPE); +} + +} // namespace ActiveModeInterval + +namespace ActiveModeThreshold { + +EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType temp; + uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); + EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::ClientMonitoring::Id, Id, readable, sizeof(temp)); + VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); + if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + { + return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + } + *value = Traits::StorageToWorking(temp); + return status; +} +EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) +{ + using Traits = NumericAttributeTraits; + if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + { + return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + } + Traits::StorageType storageValue; + Traits::WorkingToStorage(value, storageValue); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(storageValue); + return emberAfWriteServerAttribute(endpoint, Clusters::ClientMonitoring::Id, Id, writable, ZCL_INT16U_ATTRIBUTE_TYPE); +} + +} // namespace ActiveModeThreshold + +namespace FeatureMap { + +EmberAfStatus Get(chip::EndpointId endpoint, uint32_t * value) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType temp; + uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); + EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::ClientMonitoring::Id, Id, readable, sizeof(temp)); + VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); + if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + { + return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + } + *value = Traits::StorageToWorking(temp); + return status; +} +EmberAfStatus Set(chip::EndpointId endpoint, uint32_t value) +{ + using Traits = NumericAttributeTraits; + if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + { + return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + } + Traits::StorageType storageValue; + Traits::WorkingToStorage(value, storageValue); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(storageValue); + return emberAfWriteServerAttribute(endpoint, Clusters::ClientMonitoring::Id, Id, writable, ZCL_BITMAP32_ATTRIBUTE_TYPE); +} + +} // namespace FeatureMap + +namespace ClusterRevision { + +EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType temp; + uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); + EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::ClientMonitoring::Id, Id, readable, sizeof(temp)); + VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); + if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + { + return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + } + *value = Traits::StorageToWorking(temp); + return status; +} +EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) +{ + using Traits = NumericAttributeTraits; + if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + { + return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + } + Traits::StorageType storageValue; + Traits::WorkingToStorage(value, storageValue); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(storageValue); + return emberAfWriteServerAttribute(endpoint, Clusters::ClientMonitoring::Id, Id, writable, ZCL_INT16U_ATTRIBUTE_TYPE); +} + +} // namespace ClusterRevision + +} // namespace Attributes +} // namespace ClientMonitoring + namespace UnitTesting { namespace Attributes { diff --git a/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.h b/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.h index e1e6b3dd21d05d..1f9b95358053f6 100644 --- a/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.h +++ b/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.h @@ -2780,7 +2780,7 @@ EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullabl } // namespace SetpointChangeAmount namespace SetpointChangeSourceTimestamp { -EmberAfStatus Get(chip::EndpointId endpoint, uint32_t * value); // utc +EmberAfStatus Get(chip::EndpointId endpoint, uint32_t * value); // epoch_s EmberAfStatus Set(chip::EndpointId endpoint, uint32_t value); } // namespace SetpointChangeSourceTimestamp @@ -4652,6 +4652,37 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); } // namespace Attributes } // namespace ElectricalMeasurement +namespace ClientMonitoring { +namespace Attributes { + +namespace IdleModeInterval { +EmberAfStatus Get(chip::EndpointId endpoint, uint32_t * value); // int32u +EmberAfStatus Set(chip::EndpointId endpoint, uint32_t value); +} // namespace IdleModeInterval + +namespace ActiveModeInterval { +EmberAfStatus Get(chip::EndpointId endpoint, uint32_t * value); // int32u +EmberAfStatus Set(chip::EndpointId endpoint, uint32_t value); +} // namespace ActiveModeInterval + +namespace ActiveModeThreshold { +EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // int16u +EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +} // namespace ActiveModeThreshold + +namespace FeatureMap { +EmberAfStatus Get(chip::EndpointId endpoint, uint32_t * value); // bitmap32 +EmberAfStatus Set(chip::EndpointId endpoint, uint32_t value); +} // namespace FeatureMap + +namespace ClusterRevision { +EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // int16u +EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +} // namespace ClusterRevision + +} // namespace Attributes +} // namespace ClientMonitoring + namespace UnitTesting { namespace Attributes { diff --git a/zzz_generated/app-common/app-common/zap-generated/callback.h b/zzz_generated/app-common/app-common/zap-generated/callback.h index 6669d106cd3da8..8c82bc550c2a7e 100644 --- a/zzz_generated/app-common/app-common/zap-generated/callback.h +++ b/zzz_generated/app-common/app-common/zap-generated/callback.h @@ -586,6 +586,14 @@ void emberAfAccountLoginClusterInitCallback(chip::EndpointId endpoint); */ void emberAfElectricalMeasurementClusterInitCallback(chip::EndpointId endpoint); +/** @brief Client Monitoring Cluster Init + * + * Cluster Init + * + * @param endpoint Endpoint that is being initialized + */ +void emberAfClientMonitoringClusterInitCallback(chip::EndpointId endpoint); + /** @brief Unit Testing Cluster Init * * Cluster Init @@ -7255,6 +7263,104 @@ void emberAfElectricalMeasurementClusterServerTickCallback(chip::EndpointId endp */ void emberAfElectricalMeasurementClusterClientTickCallback(chip::EndpointId endpoint); +// +// Client Monitoring Cluster +// + +/** @brief Client Monitoring Cluster Server Init + * + * Server Init + * + * @param endpoint Endpoint that is being initialized + */ +void emberAfClientMonitoringClusterServerInitCallback(chip::EndpointId endpoint); + +/** @brief Client Monitoring Cluster Client Init + * + * Client Init + * + * @param endpoint Endpoint that is being initialized + */ +void emberAfClientMonitoringClusterClientInitCallback(chip::EndpointId endpoint); + +/** @brief Client Monitoring Cluster Server Attribute Changed + * + * Server Attribute Changed + * + * @param attributePath Concrete attribute path that changed + */ +void MatterClientMonitoringClusterServerAttributeChangedCallback(const chip::app::ConcreteAttributePath & attributePath); + +/** @brief Client Monitoring Cluster Server Message Sent + * + * Server Message Sent + * + * @param destination The destination to which the message was sent + * @param apsFrame The APS frame for the message + * @param msgLen The length of the message + * @param message The message that was sent + * @param status The status of the sent message + */ +void emberAfClientMonitoringClusterServerMessageSentCallback(const chip::MessageSendDestination & destination, + EmberApsFrame * apsFrame, uint16_t msgLen, uint8_t * message, + EmberStatus status); + +/** @brief Client Monitoring Cluster Client Message Sent + * + * Client Message Sent + * + * @param destination The destination to which the message was sent + * @param apsFrame The APS frame for the message + * @param msgLen The length of the message + * @param message The message that was sent + * @param status The status of the sent message + */ +void emberAfClientMonitoringClusterClientMessageSentCallback(const chip::MessageSendDestination & destination, + EmberApsFrame * apsFrame, uint16_t msgLen, uint8_t * message, + EmberStatus status); + +/** @brief Client Monitoring Cluster Server Pre Attribute Changed + * + * Server Pre Attribute Changed + * + * @param attributePath Concrete attribute path to be changed + * @param attributeType Attribute type + * @param size Attribute size + * @param value Attribute value + */ +chip::Protocols::InteractionModel::Status +MatterClientMonitoringClusterServerPreAttributeChangedCallback(const chip::app::ConcreteAttributePath & attributePath, + EmberAfAttributeType attributeType, uint16_t size, uint8_t * value); + +/** @brief Client Monitoring Cluster Client Pre Attribute Changed + * + * Client Pre Attribute Changed + * + * @param attributePath Concrete attribute path to be changed + * @param attributeType Attribute type + * @param size Attribute size + * @param value Attribute value + */ +chip::Protocols::InteractionModel::Status +MatterClientMonitoringClusterClientPreAttributeChangedCallback(const chip::app::ConcreteAttributePath & attributePath, + EmberAfAttributeType attributeType, uint16_t size, uint8_t * value); + +/** @brief Client Monitoring Cluster Server Tick + * + * Server Tick + * + * @param endpoint Endpoint that is being served + */ +void emberAfClientMonitoringClusterServerTickCallback(chip::EndpointId endpoint); + +/** @brief Client Monitoring Cluster Client Tick + * + * Client Tick + * + * @param endpoint Endpoint that is being served + */ +void emberAfClientMonitoringClusterClientTickCallback(chip::EndpointId endpoint); + // // Unit Testing Cluster // @@ -8695,6 +8801,18 @@ bool emberAfElectricalMeasurementClusterGetMeasurementProfileResponseCommandCall bool emberAfElectricalMeasurementClusterGetMeasurementProfileCommandCallback( chip::app::CommandHandler * commandObj, const chip::app::ConcreteCommandPath & commandPath, const chip::app::Clusters::ElectricalMeasurement::Commands::GetMeasurementProfileCommand::DecodableType & commandData); +/** + * @brief Client Monitoring Cluster RegisterClientMonitoring Command callback (from client) + */ +bool emberAfClientMonitoringClusterRegisterClientMonitoringCallback( + chip::app::CommandHandler * commandObj, const chip::app::ConcreteCommandPath & commandPath, + const chip::app::Clusters::ClientMonitoring::Commands::RegisterClientMonitoring::DecodableType & commandData); +/** + * @brief Client Monitoring Cluster StayAwakeRequest Command callback (from client) + */ +bool emberAfClientMonitoringClusterStayAwakeRequestCallback( + chip::app::CommandHandler * commandObj, const chip::app::ConcreteCommandPath & commandPath, + const chip::app::Clusters::ClientMonitoring::Commands::StayAwakeRequest::DecodableType & commandData); /** * @brief Unit Testing Cluster Test Command callback (from client) */ diff --git a/zzz_generated/app-common/app-common/zap-generated/cluster-enums.h b/zzz_generated/app-common/app-common/zap-generated/cluster-enums.h index b71d81dba7eaaf..12cb3de9b1caaf 100644 --- a/zzz_generated/app-common/app-common/zap-generated/cluster-enums.h +++ b/zzz_generated/app-common/app-common/zap-generated/cluster-enums.h @@ -2273,6 +2273,9 @@ namespace AccountLogin { namespace ElectricalMeasurement { } // namespace ElectricalMeasurement +namespace ClientMonitoring { +} // namespace ClientMonitoring + namespace UnitTesting { // Enum for SimpleEnum diff --git a/zzz_generated/app-common/app-common/zap-generated/cluster-id.h b/zzz_generated/app-common/app-common/zap-generated/cluster-id.h index 5833b9fadd0453..087eb6fd1ae65c 100644 --- a/zzz_generated/app-common/app-common/zap-generated/cluster-id.h +++ b/zzz_generated/app-common/app-common/zap-generated/cluster-id.h @@ -142,6 +142,9 @@ static constexpr chip::ClusterId ZCL_PROXY_VALID_CLUSTER_ID = 0x0044; // Definitions for cluster: Boolean State static constexpr chip::ClusterId ZCL_BOOLEAN_STATE_CLUSTER_ID = 0x0045; +// Definitions for cluster: Client Monitoring +static constexpr chip::ClusterId ZCL_CLIENT_MONITORING_CLUSTER_ID = 0x0046; + // Definitions for cluster: Mode Select static constexpr chip::ClusterId ZCL_MODE_SELECT_CLUSTER_ID = 0x0050; diff --git a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp index 37fdb4628962f7..b3eec2ebadbf02 100644 --- a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp +++ b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp @@ -8542,7 +8542,7 @@ CHIP_ERROR Type::Encode(TLV::TLVWriter & writer, TLV::Tag tag) const { TLV::TLVType outer; ReturnErrorOnFailure(writer.StartContainer(tag, TLV::kTLVType_Structure, outer)); - ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kNewPosition)), newPosition)); + ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kPreviousPosition)), previousPosition)); ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kTotalNumberOfPressesCounted)), totalNumberOfPressesCounted)); ReturnErrorOnFailure(writer.EndContainer(outer)); @@ -8563,8 +8563,8 @@ CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader) } switch (TLV::TagNumFromTag(reader.GetTag())) { - case to_underlying(Fields::kNewPosition): - ReturnErrorOnFailure(DataModel::Decode(reader, newPosition)); + case to_underlying(Fields::kPreviousPosition): + ReturnErrorOnFailure(DataModel::Decode(reader, previousPosition)); break; case to_underlying(Fields::kTotalNumberOfPressesCounted): ReturnErrorOnFailure(DataModel::Decode(reader, totalNumberOfPressesCounted)); @@ -18554,6 +18554,192 @@ namespace Events { } // namespace Events } // namespace ElectricalMeasurement +namespace ClientMonitoring { +namespace Structs { +namespace MonitoringRegistration { +CHIP_ERROR Type::EncodeForWrite(TLV::TLVWriter & writer, TLV::Tag tag) const +{ + return DoEncode(writer, tag, NullOptional); +} + +CHIP_ERROR Type::EncodeForRead(TLV::TLVWriter & writer, TLV::Tag tag, FabricIndex accessingFabricIndex) const +{ + return DoEncode(writer, tag, MakeOptional(accessingFabricIndex)); +} + +CHIP_ERROR Type::DoEncode(TLV::TLVWriter & writer, TLV::Tag tag, const Optional & accessingFabricIndex) const +{ + TLV::TLVType outer; + ReturnErrorOnFailure(writer.StartContainer(tag, TLV::kTLVType_Structure, outer)); + ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kClientNodeId)), clientNodeId)); + ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kICid)), ICid)); + if (accessingFabricIndex.HasValue()) + { + ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kFabricIndex)), fabricIndex)); + } + ReturnErrorOnFailure(writer.EndContainer(outer)); + return CHIP_NO_ERROR; +} + +CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader) +{ + CHIP_ERROR err = CHIP_NO_ERROR; + TLV::TLVType outer; + VerifyOrReturnError(TLV::kTLVType_Structure == reader.GetType(), CHIP_ERROR_WRONG_TLV_TYPE); + err = reader.EnterContainer(outer); + ReturnErrorOnFailure(err); + while ((err = reader.Next()) == CHIP_NO_ERROR) + { + if (!TLV::IsContextTag(reader.GetTag())) + { + continue; + } + switch (TLV::TagNumFromTag(reader.GetTag())) + { + case to_underlying(Fields::kClientNodeId): + ReturnErrorOnFailure(DataModel::Decode(reader, clientNodeId)); + break; + case to_underlying(Fields::kICid): + ReturnErrorOnFailure(DataModel::Decode(reader, ICid)); + break; + case to_underlying(Fields::kFabricIndex): + ReturnErrorOnFailure(DataModel::Decode(reader, fabricIndex)); + break; + default: + break; + } + } + + VerifyOrReturnError(err == CHIP_END_OF_TLV, err); + ReturnErrorOnFailure(reader.ExitContainer(outer)); + + return CHIP_NO_ERROR; +} + +} // namespace MonitoringRegistration +} // namespace Structs + +namespace Commands { +namespace RegisterClientMonitoring { +CHIP_ERROR Type::Encode(TLV::TLVWriter & writer, TLV::Tag tag) const +{ + TLV::TLVType outer; + ReturnErrorOnFailure(writer.StartContainer(tag, TLV::kTLVType_Structure, outer)); + ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kClientNodeId)), clientNodeId)); + ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kICid)), ICid)); + ReturnErrorOnFailure(writer.EndContainer(outer)); + return CHIP_NO_ERROR; +} + +CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader) +{ + CHIP_ERROR err = CHIP_NO_ERROR; + TLV::TLVType outer; + VerifyOrReturnError(TLV::kTLVType_Structure == reader.GetType(), CHIP_ERROR_WRONG_TLV_TYPE); + ReturnErrorOnFailure(reader.EnterContainer(outer)); + while ((err = reader.Next()) == CHIP_NO_ERROR) + { + if (!TLV::IsContextTag(reader.GetTag())) + { + continue; + } + switch (TLV::TagNumFromTag(reader.GetTag())) + { + case to_underlying(Fields::kClientNodeId): + ReturnErrorOnFailure(DataModel::Decode(reader, clientNodeId)); + break; + case to_underlying(Fields::kICid): + ReturnErrorOnFailure(DataModel::Decode(reader, ICid)); + break; + default: + break; + } + } + + VerifyOrReturnError(err == CHIP_END_OF_TLV, err); + ReturnErrorOnFailure(reader.ExitContainer(outer)); + return CHIP_NO_ERROR; +} +} // namespace RegisterClientMonitoring. +namespace StayAwakeRequest { +CHIP_ERROR Type::Encode(TLV::TLVWriter & writer, TLV::Tag tag) const +{ + TLV::TLVType outer; + ReturnErrorOnFailure(writer.StartContainer(tag, TLV::kTLVType_Structure, outer)); + ReturnErrorOnFailure(writer.EndContainer(outer)); + return CHIP_NO_ERROR; +} + +CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader) +{ + CHIP_ERROR err = CHIP_NO_ERROR; + TLV::TLVType outer; + VerifyOrReturnError(TLV::kTLVType_Structure == reader.GetType(), CHIP_ERROR_WRONG_TLV_TYPE); + ReturnErrorOnFailure(reader.EnterContainer(outer)); + while ((err = reader.Next()) == CHIP_NO_ERROR) + { + if (!TLV::IsContextTag(reader.GetTag())) + { + continue; + } + switch (TLV::TagNumFromTag(reader.GetTag())) + { + default: + break; + } + } + + VerifyOrReturnError(err == CHIP_END_OF_TLV, err); + ReturnErrorOnFailure(reader.ExitContainer(outer)); + return CHIP_NO_ERROR; +} +} // namespace StayAwakeRequest. +} // namespace Commands + +namespace Attributes { +CHIP_ERROR TypeInfo::DecodableType::Decode(TLV::TLVReader & reader, const ConcreteAttributePath & path) +{ + switch (path.mAttributeId) + { + case Attributes::IdleModeInterval::TypeInfo::GetAttributeId(): + ReturnErrorOnFailure(DataModel::Decode(reader, idleModeInterval)); + break; + case Attributes::ActiveModeInterval::TypeInfo::GetAttributeId(): + ReturnErrorOnFailure(DataModel::Decode(reader, activeModeInterval)); + break; + case Attributes::ActiveModeThreshold::TypeInfo::GetAttributeId(): + ReturnErrorOnFailure(DataModel::Decode(reader, activeModeThreshold)); + break; + case Attributes::ExpectedClients::TypeInfo::GetAttributeId(): + ReturnErrorOnFailure(DataModel::Decode(reader, expectedClients)); + break; + case Attributes::GeneratedCommandList::TypeInfo::GetAttributeId(): + ReturnErrorOnFailure(DataModel::Decode(reader, generatedCommandList)); + break; + case Attributes::AcceptedCommandList::TypeInfo::GetAttributeId(): + ReturnErrorOnFailure(DataModel::Decode(reader, acceptedCommandList)); + break; + case Attributes::AttributeList::TypeInfo::GetAttributeId(): + ReturnErrorOnFailure(DataModel::Decode(reader, attributeList)); + break; + case Attributes::FeatureMap::TypeInfo::GetAttributeId(): + ReturnErrorOnFailure(DataModel::Decode(reader, featureMap)); + break; + case Attributes::ClusterRevision::TypeInfo::GetAttributeId(): + ReturnErrorOnFailure(DataModel::Decode(reader, clusterRevision)); + break; + default: + break; + } + + return CHIP_NO_ERROR; +} +} // namespace Attributes + +namespace Events { +} // namespace Events + +} // namespace ClientMonitoring namespace UnitTesting { namespace Structs { namespace SimpleStruct { @@ -21401,6 +21587,13 @@ bool CommandIsFabricScoped(ClusterId aCluster, CommandId aCommand) return false; } } + case Clusters::ClientMonitoring::Id: { + switch (aCommand) + { + default: + return false; + } + } case Clusters::UnitTesting::Id: { switch (aCommand) { diff --git a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h index 4fadf5d916bf8c..61e97cfdc8e3b2 100644 --- a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h +++ b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h @@ -10880,7 +10880,7 @@ static constexpr PriorityLevel kPriorityLevel = PriorityLevel::Info; enum class Fields { - kNewPosition = 0, + kPreviousPosition = 0, kTotalNumberOfPressesCounted = 1, }; @@ -10892,7 +10892,7 @@ struct Type static constexpr ClusterId GetClusterId() { return Clusters::Switch::Id; } static constexpr bool kIsFabricScoped = false; - uint8_t newPosition = static_cast(0); + uint8_t previousPosition = static_cast(0); uint8_t totalNumberOfPressesCounted = static_cast(0); CHIP_ERROR Encode(TLV::TLVWriter & writer, TLV::Tag tag) const; @@ -10905,7 +10905,7 @@ struct DecodableType static constexpr EventId GetEventId() { return Events::MultiPressComplete::Id; } static constexpr ClusterId GetClusterId() { return Clusters::Switch::Id; } - uint8_t newPosition = static_cast(0); + uint8_t previousPosition = static_cast(0); uint8_t totalNumberOfPressesCounted = static_cast(0); CHIP_ERROR Decode(TLV::TLVReader & reader); @@ -25185,6 +25185,228 @@ struct TypeInfo }; } // namespace Attributes } // namespace ElectricalMeasurement +namespace ClientMonitoring { +namespace Structs { +namespace MonitoringRegistration { +enum class Fields +{ + kClientNodeId = 1, + kICid = 2, + kFabricIndex = 254, +}; + +struct Type +{ +public: + chip::NodeId clientNodeId = static_cast(0); + uint64_t ICid = static_cast(0); + chip::FabricIndex fabricIndex = static_cast(0); + + CHIP_ERROR Decode(TLV::TLVReader & reader); + + static constexpr bool kIsFabricScoped = true; + + auto GetFabricIndex() const { return fabricIndex; } + + void SetFabricIndex(chip::FabricIndex fabricIndex_) { fabricIndex = fabricIndex_; } + + CHIP_ERROR EncodeForWrite(TLV::TLVWriter & writer, TLV::Tag tag) const; + CHIP_ERROR EncodeForRead(TLV::TLVWriter & writer, TLV::Tag tag, FabricIndex accessingFabricIndex) const; + +private: + CHIP_ERROR DoEncode(TLV::TLVWriter & writer, TLV::Tag tag, const Optional & accessingFabricIndex) const; +}; + +using DecodableType = Type; + +} // namespace MonitoringRegistration +} // namespace Structs + +namespace Commands { +// Forward-declarations so we can reference these later. + +namespace RegisterClientMonitoring { +struct Type; +struct DecodableType; +} // namespace RegisterClientMonitoring + +namespace StayAwakeRequest { +struct Type; +struct DecodableType; +} // namespace StayAwakeRequest + +} // namespace Commands + +namespace Commands { +namespace RegisterClientMonitoring { +enum class Fields +{ + kClientNodeId = 0, + kICid = 1, +}; + +struct Type +{ +public: + // Use GetCommandId instead of commandId directly to avoid naming conflict with CommandIdentification in ExecutionOfACommand + static constexpr CommandId GetCommandId() { return Commands::RegisterClientMonitoring::Id; } + static constexpr ClusterId GetClusterId() { return Clusters::ClientMonitoring::Id; } + + chip::NodeId clientNodeId = static_cast(0); + uint64_t ICid = static_cast(0); + + CHIP_ERROR Encode(TLV::TLVWriter & writer, TLV::Tag tag) const; + + using ResponseType = DataModel::NullObjectType; + + static constexpr bool MustUseTimedInvoke() { return false; } +}; + +struct DecodableType +{ +public: + static constexpr CommandId GetCommandId() { return Commands::RegisterClientMonitoring::Id; } + static constexpr ClusterId GetClusterId() { return Clusters::ClientMonitoring::Id; } + + chip::NodeId clientNodeId = static_cast(0); + uint64_t ICid = static_cast(0); + CHIP_ERROR Decode(TLV::TLVReader & reader); +}; +}; // namespace RegisterClientMonitoring +namespace StayAwakeRequest { +enum class Fields +{ +}; + +struct Type +{ +public: + // Use GetCommandId instead of commandId directly to avoid naming conflict with CommandIdentification in ExecutionOfACommand + static constexpr CommandId GetCommandId() { return Commands::StayAwakeRequest::Id; } + static constexpr ClusterId GetClusterId() { return Clusters::ClientMonitoring::Id; } + + CHIP_ERROR Encode(TLV::TLVWriter & writer, TLV::Tag tag) const; + + using ResponseType = DataModel::NullObjectType; + + static constexpr bool MustUseTimedInvoke() { return false; } +}; + +struct DecodableType +{ +public: + static constexpr CommandId GetCommandId() { return Commands::StayAwakeRequest::Id; } + static constexpr ClusterId GetClusterId() { return Clusters::ClientMonitoring::Id; } + + CHIP_ERROR Decode(TLV::TLVReader & reader); +}; +}; // namespace StayAwakeRequest +} // namespace Commands + +namespace Attributes { + +namespace IdleModeInterval { +struct TypeInfo +{ + using Type = uint32_t; + using DecodableType = uint32_t; + using DecodableArgType = uint32_t; + + static constexpr ClusterId GetClusterId() { return Clusters::ClientMonitoring::Id; } + static constexpr AttributeId GetAttributeId() { return Attributes::IdleModeInterval::Id; } + static constexpr bool MustUseTimedWrite() { return false; } +}; +} // namespace IdleModeInterval +namespace ActiveModeInterval { +struct TypeInfo +{ + using Type = uint32_t; + using DecodableType = uint32_t; + using DecodableArgType = uint32_t; + + static constexpr ClusterId GetClusterId() { return Clusters::ClientMonitoring::Id; } + static constexpr AttributeId GetAttributeId() { return Attributes::ActiveModeInterval::Id; } + static constexpr bool MustUseTimedWrite() { return false; } +}; +} // namespace ActiveModeInterval +namespace ActiveModeThreshold { +struct TypeInfo +{ + using Type = uint16_t; + using DecodableType = uint16_t; + using DecodableArgType = uint16_t; + + static constexpr ClusterId GetClusterId() { return Clusters::ClientMonitoring::Id; } + static constexpr AttributeId GetAttributeId() { return Attributes::ActiveModeThreshold::Id; } + static constexpr bool MustUseTimedWrite() { return false; } +}; +} // namespace ActiveModeThreshold +namespace ExpectedClients { +struct TypeInfo +{ + using Type = chip::app::DataModel::List; + using DecodableType = + chip::app::DataModel::DecodableList; + using DecodableArgType = const chip::app::DataModel::DecodableList< + chip::app::Clusters::ClientMonitoring::Structs::MonitoringRegistration::DecodableType> &; + + static constexpr ClusterId GetClusterId() { return Clusters::ClientMonitoring::Id; } + static constexpr AttributeId GetAttributeId() { return Attributes::ExpectedClients::Id; } + static constexpr bool MustUseTimedWrite() { return false; } +}; +} // namespace ExpectedClients +namespace GeneratedCommandList { +struct TypeInfo : public Clusters::Globals::Attributes::GeneratedCommandList::TypeInfo +{ + static constexpr ClusterId GetClusterId() { return Clusters::ClientMonitoring::Id; } +}; +} // namespace GeneratedCommandList +namespace AcceptedCommandList { +struct TypeInfo : public Clusters::Globals::Attributes::AcceptedCommandList::TypeInfo +{ + static constexpr ClusterId GetClusterId() { return Clusters::ClientMonitoring::Id; } +}; +} // namespace AcceptedCommandList +namespace AttributeList { +struct TypeInfo : public Clusters::Globals::Attributes::AttributeList::TypeInfo +{ + static constexpr ClusterId GetClusterId() { return Clusters::ClientMonitoring::Id; } +}; +} // namespace AttributeList +namespace FeatureMap { +struct TypeInfo : public Clusters::Globals::Attributes::FeatureMap::TypeInfo +{ + static constexpr ClusterId GetClusterId() { return Clusters::ClientMonitoring::Id; } +}; +} // namespace FeatureMap +namespace ClusterRevision { +struct TypeInfo : public Clusters::Globals::Attributes::ClusterRevision::TypeInfo +{ + static constexpr ClusterId GetClusterId() { return Clusters::ClientMonitoring::Id; } +}; +} // namespace ClusterRevision + +struct TypeInfo +{ + struct DecodableType + { + static constexpr ClusterId GetClusterId() { return Clusters::ClientMonitoring::Id; } + + CHIP_ERROR Decode(TLV::TLVReader & reader, const ConcreteAttributePath & path); + + Attributes::IdleModeInterval::TypeInfo::DecodableType idleModeInterval = static_cast(0); + Attributes::ActiveModeInterval::TypeInfo::DecodableType activeModeInterval = static_cast(0); + Attributes::ActiveModeThreshold::TypeInfo::DecodableType activeModeThreshold = static_cast(0); + Attributes::ExpectedClients::TypeInfo::DecodableType expectedClients; + Attributes::GeneratedCommandList::TypeInfo::DecodableType generatedCommandList; + Attributes::AcceptedCommandList::TypeInfo::DecodableType acceptedCommandList; + Attributes::AttributeList::TypeInfo::DecodableType attributeList; + Attributes::FeatureMap::TypeInfo::DecodableType featureMap = static_cast(0); + Attributes::ClusterRevision::TypeInfo::DecodableType clusterRevision = static_cast(0); + }; +}; +} // namespace Attributes +} // namespace ClientMonitoring namespace UnitTesting { namespace Structs { namespace SimpleStruct { diff --git a/zzz_generated/app-common/app-common/zap-generated/command-id.h b/zzz_generated/app-common/app-common/zap-generated/command-id.h index 45c8decb6fdc72..b443dfc0199f10 100644 --- a/zzz_generated/app-common/app-common/zap-generated/command-id.h +++ b/zzz_generated/app-common/app-common/zap-generated/command-id.h @@ -317,6 +317,10 @@ #define ZCL_GET_MEASUREMENT_PROFILE_RESPONSE_COMMAND_COMMAND_ID (0x01) #define ZCL_GET_MEASUREMENT_PROFILE_COMMAND_COMMAND_ID (0x01) +// Commands for cluster: Client Monitoring +#define ZCL_REGISTER_CLIENT_MONITORING_COMMAND_ID (0x00) +#define ZCL_STAY_AWAKE_REQUEST_COMMAND_ID (0x01) + // Commands for cluster: Unit Testing #define ZCL_TEST_COMMAND_ID (0x00) #define ZCL_TEST_SPECIFIC_RESPONSE_COMMAND_ID (0x00) diff --git a/zzz_generated/app-common/app-common/zap-generated/ids/Attributes.h b/zzz_generated/app-common/app-common/zap-generated/ids/Attributes.h index c7dce39a648afe..78fed4d2e9636f 100644 --- a/zzz_generated/app-common/app-common/zap-generated/ids/Attributes.h +++ b/zzz_generated/app-common/app-common/zap-generated/ids/Attributes.h @@ -4605,6 +4605,48 @@ static constexpr AttributeId Id = Globals::Attributes::ClusterRevision::Id; } // namespace Attributes } // namespace ElectricalMeasurement +namespace ClientMonitoring { +namespace Attributes { + +namespace IdleModeInterval { +static constexpr AttributeId Id = 0x00000000; +} // namespace IdleModeInterval + +namespace ActiveModeInterval { +static constexpr AttributeId Id = 0x00000001; +} // namespace ActiveModeInterval + +namespace ActiveModeThreshold { +static constexpr AttributeId Id = 0x00000002; +} // namespace ActiveModeThreshold + +namespace ExpectedClients { +static constexpr AttributeId Id = 0x00000003; +} // namespace ExpectedClients + +namespace GeneratedCommandList { +static constexpr AttributeId Id = Globals::Attributes::GeneratedCommandList::Id; +} // namespace GeneratedCommandList + +namespace AcceptedCommandList { +static constexpr AttributeId Id = Globals::Attributes::AcceptedCommandList::Id; +} // namespace AcceptedCommandList + +namespace AttributeList { +static constexpr AttributeId Id = Globals::Attributes::AttributeList::Id; +} // namespace AttributeList + +namespace FeatureMap { +static constexpr AttributeId Id = Globals::Attributes::FeatureMap::Id; +} // namespace FeatureMap + +namespace ClusterRevision { +static constexpr AttributeId Id = Globals::Attributes::ClusterRevision::Id; +} // namespace ClusterRevision + +} // namespace Attributes +} // namespace ClientMonitoring + namespace UnitTesting { namespace Attributes { diff --git a/zzz_generated/app-common/app-common/zap-generated/ids/Clusters.h b/zzz_generated/app-common/app-common/zap-generated/ids/Clusters.h index a5d2738c08311f..6d9fe6fbd0cfdd 100644 --- a/zzz_generated/app-common/app-common/zap-generated/ids/Clusters.h +++ b/zzz_generated/app-common/app-common/zap-generated/ids/Clusters.h @@ -232,6 +232,9 @@ static constexpr ClusterId Id = 0x0000050E; namespace ElectricalMeasurement { static constexpr ClusterId Id = 0x00000B04; } // namespace ElectricalMeasurement +namespace ClientMonitoring { +static constexpr ClusterId Id = 0x00001046; +} // namespace ClientMonitoring namespace UnitTesting { static constexpr ClusterId Id = 0xFFF1FC05; } // namespace UnitTesting diff --git a/zzz_generated/app-common/app-common/zap-generated/ids/Commands.h b/zzz_generated/app-common/app-common/zap-generated/ids/Commands.h index d7430e8e41f21b..1da2e63b9e3996 100644 --- a/zzz_generated/app-common/app-common/zap-generated/ids/Commands.h +++ b/zzz_generated/app-common/app-common/zap-generated/ids/Commands.h @@ -1091,6 +1091,20 @@ static constexpr CommandId Id = 0x00000001; } // namespace Commands } // namespace ElectricalMeasurement +namespace ClientMonitoring { +namespace Commands { + +namespace RegisterClientMonitoring { +static constexpr CommandId Id = 0x00000000; +} // namespace RegisterClientMonitoring + +namespace StayAwakeRequest { +static constexpr CommandId Id = 0x00000001; +} // namespace StayAwakeRequest + +} // namespace Commands +} // namespace ClientMonitoring + namespace UnitTesting { namespace Commands { diff --git a/zzz_generated/app-common/app-common/zap-generated/print-cluster.h b/zzz_generated/app-common/app-common/zap-generated/print-cluster.h index 4ab05c73ae61de..9b315e279a7397 100644 --- a/zzz_generated/app-common/app-common/zap-generated/print-cluster.h +++ b/zzz_generated/app-common/app-common/zap-generated/print-cluster.h @@ -20,92 +20,94 @@ // Prevent multiple inclusion #pragma once +#include + // This is the mapping of IDs to cluster names assuming a format according // to the "EmberAfClusterName" defined in the ZCL header. // The names of clusters that are not present, are removed. #if defined(ZCL_USING_IDENTIFY_CLUSTER_SERVER) || defined(ZCL_USING_IDENTIFY_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_IDENTIFY_CLUSTER { ZCL_IDENTIFY_CLUSTER_ID, "Identify" }, +#define CHIP_PRINTCLUSTER_IDENTIFY_CLUSTER { chip::app::Clusters::Identify::Id, "Identify" }, #else #define CHIP_PRINTCLUSTER_IDENTIFY_CLUSTER #endif #if defined(ZCL_USING_GROUPS_CLUSTER_SERVER) || defined(ZCL_USING_GROUPS_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_GROUPS_CLUSTER { ZCL_GROUPS_CLUSTER_ID, "Groups" }, +#define CHIP_PRINTCLUSTER_GROUPS_CLUSTER { chip::app::Clusters::Groups::Id, "Groups" }, #else #define CHIP_PRINTCLUSTER_GROUPS_CLUSTER #endif #if defined(ZCL_USING_SCENES_CLUSTER_SERVER) || defined(ZCL_USING_SCENES_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_SCENES_CLUSTER { ZCL_SCENES_CLUSTER_ID, "Scenes" }, +#define CHIP_PRINTCLUSTER_SCENES_CLUSTER { chip::app::Clusters::Scenes::Id, "Scenes" }, #else #define CHIP_PRINTCLUSTER_SCENES_CLUSTER #endif #if defined(ZCL_USING_ON_OFF_CLUSTER_SERVER) || defined(ZCL_USING_ON_OFF_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_ON_OFF_CLUSTER { ZCL_ON_OFF_CLUSTER_ID, "On/Off" }, +#define CHIP_PRINTCLUSTER_ON_OFF_CLUSTER { chip::app::Clusters::OnOff::Id, "On/Off" }, #else #define CHIP_PRINTCLUSTER_ON_OFF_CLUSTER #endif #if defined(ZCL_USING_ON_OFF_SWITCH_CONFIGURATION_CLUSTER_SERVER) || defined(ZCL_USING_ON_OFF_SWITCH_CONFIGURATION_CLUSTER_CLIENT) #define CHIP_PRINTCLUSTER_ON_OFF_SWITCH_CONFIGURATION_CLUSTER \ - { ZCL_ON_OFF_SWITCH_CONFIGURATION_CLUSTER_ID, "On/off Switch Configuration" }, + { chip::app::Clusters::OnOffSwitchConfiguration::Id, "On/off Switch Configuration" }, #else #define CHIP_PRINTCLUSTER_ON_OFF_SWITCH_CONFIGURATION_CLUSTER #endif #if defined(ZCL_USING_LEVEL_CONTROL_CLUSTER_SERVER) || defined(ZCL_USING_LEVEL_CONTROL_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_LEVEL_CONTROL_CLUSTER { ZCL_LEVEL_CONTROL_CLUSTER_ID, "Level Control" }, +#define CHIP_PRINTCLUSTER_LEVEL_CONTROL_CLUSTER { chip::app::Clusters::LevelControl::Id, "Level Control" }, #else #define CHIP_PRINTCLUSTER_LEVEL_CONTROL_CLUSTER #endif #if defined(ZCL_USING_BINARY_INPUT_BASIC_CLUSTER_SERVER) || defined(ZCL_USING_BINARY_INPUT_BASIC_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_BINARY_INPUT_BASIC_CLUSTER { ZCL_BINARY_INPUT_BASIC_CLUSTER_ID, "Binary Input (Basic)" }, +#define CHIP_PRINTCLUSTER_BINARY_INPUT_BASIC_CLUSTER { chip::app::Clusters::BinaryInputBasic::Id, "Binary Input (Basic)" }, #else #define CHIP_PRINTCLUSTER_BINARY_INPUT_BASIC_CLUSTER #endif #if defined(ZCL_USING_PWM_CLUSTER_SERVER) || defined(ZCL_USING_PWM_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_PWM_CLUSTER { ZCL_PWM_CLUSTER_ID, "Pulse Width Modulation" }, +#define CHIP_PRINTCLUSTER_PWM_CLUSTER { chip::app::Clusters::PulseWidthModulation::Id, "Pulse Width Modulation" }, #else #define CHIP_PRINTCLUSTER_PWM_CLUSTER #endif #if defined(ZCL_USING_DESCRIPTOR_CLUSTER_SERVER) || defined(ZCL_USING_DESCRIPTOR_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_DESCRIPTOR_CLUSTER { ZCL_DESCRIPTOR_CLUSTER_ID, "Descriptor" }, +#define CHIP_PRINTCLUSTER_DESCRIPTOR_CLUSTER { chip::app::Clusters::Descriptor::Id, "Descriptor" }, #else #define CHIP_PRINTCLUSTER_DESCRIPTOR_CLUSTER #endif #if defined(ZCL_USING_BINDING_CLUSTER_SERVER) || defined(ZCL_USING_BINDING_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_BINDING_CLUSTER { ZCL_BINDING_CLUSTER_ID, "Binding" }, +#define CHIP_PRINTCLUSTER_BINDING_CLUSTER { chip::app::Clusters::Binding::Id, "Binding" }, #else #define CHIP_PRINTCLUSTER_BINDING_CLUSTER #endif #if defined(ZCL_USING_ACCESS_CONTROL_CLUSTER_SERVER) || defined(ZCL_USING_ACCESS_CONTROL_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_ACCESS_CONTROL_CLUSTER { ZCL_ACCESS_CONTROL_CLUSTER_ID, "Access Control" }, +#define CHIP_PRINTCLUSTER_ACCESS_CONTROL_CLUSTER { chip::app::Clusters::AccessControl::Id, "Access Control" }, #else #define CHIP_PRINTCLUSTER_ACCESS_CONTROL_CLUSTER #endif #if defined(ZCL_USING_ACTIONS_CLUSTER_SERVER) || defined(ZCL_USING_ACTIONS_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_ACTIONS_CLUSTER { ZCL_ACTIONS_CLUSTER_ID, "Actions" }, +#define CHIP_PRINTCLUSTER_ACTIONS_CLUSTER { chip::app::Clusters::Actions::Id, "Actions" }, #else #define CHIP_PRINTCLUSTER_ACTIONS_CLUSTER #endif #if defined(ZCL_USING_BASIC_CLUSTER_SERVER) || defined(ZCL_USING_BASIC_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_BASIC_CLUSTER { ZCL_BASIC_CLUSTER_ID, "Basic" }, +#define CHIP_PRINTCLUSTER_BASIC_CLUSTER { chip::app::Clusters::Basic::Id, "Basic" }, #else #define CHIP_PRINTCLUSTER_BASIC_CLUSTER #endif #if defined(ZCL_USING_OTA_SOFTWARE_UPDATE_PROVIDER_CLUSTER_SERVER) || defined(ZCL_USING_OTA_SOFTWARE_UPDATE_PROVIDER_CLUSTER_CLIENT) #define CHIP_PRINTCLUSTER_OTA_SOFTWARE_UPDATE_PROVIDER_CLUSTER \ - { ZCL_OTA_SOFTWARE_UPDATE_PROVIDER_CLUSTER_ID, "OTA Software Update Provider" }, + { chip::app::Clusters::OtaSoftwareUpdateProvider::Id, "OTA Software Update Provider" }, #else #define CHIP_PRINTCLUSTER_OTA_SOFTWARE_UPDATE_PROVIDER_CLUSTER #endif @@ -113,186 +115,189 @@ #if defined(ZCL_USING_OTA_SOFTWARE_UPDATE_REQUESTOR_CLUSTER_SERVER) || \ defined(ZCL_USING_OTA_SOFTWARE_UPDATE_REQUESTOR_CLUSTER_CLIENT) #define CHIP_PRINTCLUSTER_OTA_SOFTWARE_UPDATE_REQUESTOR_CLUSTER \ - { ZCL_OTA_SOFTWARE_UPDATE_REQUESTOR_CLUSTER_ID, "OTA Software Update Requestor" }, + { chip::app::Clusters::OtaSoftwareUpdateRequestor::Id, "OTA Software Update Requestor" }, #else #define CHIP_PRINTCLUSTER_OTA_SOFTWARE_UPDATE_REQUESTOR_CLUSTER #endif #if defined(ZCL_USING_LOCALIZATION_CONFIGURATION_CLUSTER_SERVER) || defined(ZCL_USING_LOCALIZATION_CONFIGURATION_CLUSTER_CLIENT) #define CHIP_PRINTCLUSTER_LOCALIZATION_CONFIGURATION_CLUSTER \ - { ZCL_LOCALIZATION_CONFIGURATION_CLUSTER_ID, "Localization Configuration" }, + { chip::app::Clusters::LocalizationConfiguration::Id, "Localization Configuration" }, #else #define CHIP_PRINTCLUSTER_LOCALIZATION_CONFIGURATION_CLUSTER #endif #if defined(ZCL_USING_TIME_FORMAT_LOCALIZATION_CLUSTER_SERVER) || defined(ZCL_USING_TIME_FORMAT_LOCALIZATION_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_TIME_FORMAT_LOCALIZATION_CLUSTER { ZCL_TIME_FORMAT_LOCALIZATION_CLUSTER_ID, "Time Format Localization" }, +#define CHIP_PRINTCLUSTER_TIME_FORMAT_LOCALIZATION_CLUSTER \ + { chip::app::Clusters::TimeFormatLocalization::Id, "Time Format Localization" }, #else #define CHIP_PRINTCLUSTER_TIME_FORMAT_LOCALIZATION_CLUSTER #endif #if defined(ZCL_USING_UNIT_LOCALIZATION_CLUSTER_SERVER) || defined(ZCL_USING_UNIT_LOCALIZATION_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_UNIT_LOCALIZATION_CLUSTER { ZCL_UNIT_LOCALIZATION_CLUSTER_ID, "Unit Localization" }, +#define CHIP_PRINTCLUSTER_UNIT_LOCALIZATION_CLUSTER { chip::app::Clusters::UnitLocalization::Id, "Unit Localization" }, #else #define CHIP_PRINTCLUSTER_UNIT_LOCALIZATION_CLUSTER #endif #if defined(ZCL_USING_POWER_SOURCE_CONFIGURATION_CLUSTER_SERVER) || defined(ZCL_USING_POWER_SOURCE_CONFIGURATION_CLUSTER_CLIENT) #define CHIP_PRINTCLUSTER_POWER_SOURCE_CONFIGURATION_CLUSTER \ - { ZCL_POWER_SOURCE_CONFIGURATION_CLUSTER_ID, "Power Source Configuration" }, + { chip::app::Clusters::PowerSourceConfiguration::Id, "Power Source Configuration" }, #else #define CHIP_PRINTCLUSTER_POWER_SOURCE_CONFIGURATION_CLUSTER #endif #if defined(ZCL_USING_POWER_SOURCE_CLUSTER_SERVER) || defined(ZCL_USING_POWER_SOURCE_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_POWER_SOURCE_CLUSTER { ZCL_POWER_SOURCE_CLUSTER_ID, "Power Source" }, +#define CHIP_PRINTCLUSTER_POWER_SOURCE_CLUSTER { chip::app::Clusters::PowerSource::Id, "Power Source" }, #else #define CHIP_PRINTCLUSTER_POWER_SOURCE_CLUSTER #endif #if defined(ZCL_USING_GENERAL_COMMISSIONING_CLUSTER_SERVER) || defined(ZCL_USING_GENERAL_COMMISSIONING_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_GENERAL_COMMISSIONING_CLUSTER { ZCL_GENERAL_COMMISSIONING_CLUSTER_ID, "General Commissioning" }, +#define CHIP_PRINTCLUSTER_GENERAL_COMMISSIONING_CLUSTER { chip::app::Clusters::GeneralCommissioning::Id, "General Commissioning" }, #else #define CHIP_PRINTCLUSTER_GENERAL_COMMISSIONING_CLUSTER #endif #if defined(ZCL_USING_NETWORK_COMMISSIONING_CLUSTER_SERVER) || defined(ZCL_USING_NETWORK_COMMISSIONING_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_NETWORK_COMMISSIONING_CLUSTER { ZCL_NETWORK_COMMISSIONING_CLUSTER_ID, "Network Commissioning" }, +#define CHIP_PRINTCLUSTER_NETWORK_COMMISSIONING_CLUSTER { chip::app::Clusters::NetworkCommissioning::Id, "Network Commissioning" }, #else #define CHIP_PRINTCLUSTER_NETWORK_COMMISSIONING_CLUSTER #endif #if defined(ZCL_USING_DIAGNOSTIC_LOGS_CLUSTER_SERVER) || defined(ZCL_USING_DIAGNOSTIC_LOGS_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_DIAGNOSTIC_LOGS_CLUSTER { ZCL_DIAGNOSTIC_LOGS_CLUSTER_ID, "Diagnostic Logs" }, +#define CHIP_PRINTCLUSTER_DIAGNOSTIC_LOGS_CLUSTER { chip::app::Clusters::DiagnosticLogs::Id, "Diagnostic Logs" }, #else #define CHIP_PRINTCLUSTER_DIAGNOSTIC_LOGS_CLUSTER #endif #if defined(ZCL_USING_GENERAL_DIAGNOSTICS_CLUSTER_SERVER) || defined(ZCL_USING_GENERAL_DIAGNOSTICS_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_GENERAL_DIAGNOSTICS_CLUSTER { ZCL_GENERAL_DIAGNOSTICS_CLUSTER_ID, "General Diagnostics" }, +#define CHIP_PRINTCLUSTER_GENERAL_DIAGNOSTICS_CLUSTER { chip::app::Clusters::GeneralDiagnostics::Id, "General Diagnostics" }, #else #define CHIP_PRINTCLUSTER_GENERAL_DIAGNOSTICS_CLUSTER #endif #if defined(ZCL_USING_SOFTWARE_DIAGNOSTICS_CLUSTER_SERVER) || defined(ZCL_USING_SOFTWARE_DIAGNOSTICS_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_SOFTWARE_DIAGNOSTICS_CLUSTER { ZCL_SOFTWARE_DIAGNOSTICS_CLUSTER_ID, "Software Diagnostics" }, +#define CHIP_PRINTCLUSTER_SOFTWARE_DIAGNOSTICS_CLUSTER { chip::app::Clusters::SoftwareDiagnostics::Id, "Software Diagnostics" }, #else #define CHIP_PRINTCLUSTER_SOFTWARE_DIAGNOSTICS_CLUSTER #endif #if defined(ZCL_USING_THREAD_NETWORK_DIAGNOSTICS_CLUSTER_SERVER) || defined(ZCL_USING_THREAD_NETWORK_DIAGNOSTICS_CLUSTER_CLIENT) #define CHIP_PRINTCLUSTER_THREAD_NETWORK_DIAGNOSTICS_CLUSTER \ - { ZCL_THREAD_NETWORK_DIAGNOSTICS_CLUSTER_ID, "Thread Network Diagnostics" }, + { chip::app::Clusters::ThreadNetworkDiagnostics::Id, "Thread Network Diagnostics" }, #else #define CHIP_PRINTCLUSTER_THREAD_NETWORK_DIAGNOSTICS_CLUSTER #endif #if defined(ZCL_USING_WIFI_NETWORK_DIAGNOSTICS_CLUSTER_SERVER) || defined(ZCL_USING_WIFI_NETWORK_DIAGNOSTICS_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_WIFI_NETWORK_DIAGNOSTICS_CLUSTER { ZCL_WIFI_NETWORK_DIAGNOSTICS_CLUSTER_ID, "WiFi Network Diagnostics" }, +#define CHIP_PRINTCLUSTER_WIFI_NETWORK_DIAGNOSTICS_CLUSTER \ + { chip::app::Clusters::WiFiNetworkDiagnostics::Id, "WiFi Network Diagnostics" }, #else #define CHIP_PRINTCLUSTER_WIFI_NETWORK_DIAGNOSTICS_CLUSTER #endif #if defined(ZCL_USING_ETHERNET_NETWORK_DIAGNOSTICS_CLUSTER_SERVER) || defined(ZCL_USING_ETHERNET_NETWORK_DIAGNOSTICS_CLUSTER_CLIENT) #define CHIP_PRINTCLUSTER_ETHERNET_NETWORK_DIAGNOSTICS_CLUSTER \ - { ZCL_ETHERNET_NETWORK_DIAGNOSTICS_CLUSTER_ID, "Ethernet Network Diagnostics" }, + { chip::app::Clusters::EthernetNetworkDiagnostics::Id, "Ethernet Network Diagnostics" }, #else #define CHIP_PRINTCLUSTER_ETHERNET_NETWORK_DIAGNOSTICS_CLUSTER #endif #if defined(ZCL_USING_TIME_SYNCHRONIZATION_CLUSTER_SERVER) || defined(ZCL_USING_TIME_SYNCHRONIZATION_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_TIME_SYNCHRONIZATION_CLUSTER { ZCL_TIME_SYNCHRONIZATION_CLUSTER_ID, "Time Synchronization" }, +#define CHIP_PRINTCLUSTER_TIME_SYNCHRONIZATION_CLUSTER { chip::app::Clusters::TimeSynchronization::Id, "Time Synchronization" }, #else #define CHIP_PRINTCLUSTER_TIME_SYNCHRONIZATION_CLUSTER #endif #if defined(ZCL_USING_BRIDGED_DEVICE_BASIC_CLUSTER_SERVER) || defined(ZCL_USING_BRIDGED_DEVICE_BASIC_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_BRIDGED_DEVICE_BASIC_CLUSTER { ZCL_BRIDGED_DEVICE_BASIC_CLUSTER_ID, "Bridged Device Basic" }, +#define CHIP_PRINTCLUSTER_BRIDGED_DEVICE_BASIC_CLUSTER { chip::app::Clusters::BridgedDeviceBasic::Id, "Bridged Device Basic" }, #else #define CHIP_PRINTCLUSTER_BRIDGED_DEVICE_BASIC_CLUSTER #endif #if defined(ZCL_USING_SWITCH_CLUSTER_SERVER) || defined(ZCL_USING_SWITCH_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_SWITCH_CLUSTER { ZCL_SWITCH_CLUSTER_ID, "Switch" }, +#define CHIP_PRINTCLUSTER_SWITCH_CLUSTER { chip::app::Clusters::Switch::Id, "Switch" }, #else #define CHIP_PRINTCLUSTER_SWITCH_CLUSTER #endif #if defined(ZCL_USING_ADMINISTRATOR_COMMISSIONING_CLUSTER_SERVER) || defined(ZCL_USING_ADMINISTRATOR_COMMISSIONING_CLUSTER_CLIENT) #define CHIP_PRINTCLUSTER_ADMINISTRATOR_COMMISSIONING_CLUSTER \ - { ZCL_ADMINISTRATOR_COMMISSIONING_CLUSTER_ID, "AdministratorCommissioning" }, + { chip::app::Clusters::AdministratorCommissioning::Id, "AdministratorCommissioning" }, #else #define CHIP_PRINTCLUSTER_ADMINISTRATOR_COMMISSIONING_CLUSTER #endif #if defined(ZCL_USING_OPERATIONAL_CREDENTIALS_CLUSTER_SERVER) || defined(ZCL_USING_OPERATIONAL_CREDENTIALS_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_OPERATIONAL_CREDENTIALS_CLUSTER { ZCL_OPERATIONAL_CREDENTIALS_CLUSTER_ID, "Operational Credentials" }, +#define CHIP_PRINTCLUSTER_OPERATIONAL_CREDENTIALS_CLUSTER \ + { chip::app::Clusters::OperationalCredentials::Id, "Operational Credentials" }, #else #define CHIP_PRINTCLUSTER_OPERATIONAL_CREDENTIALS_CLUSTER #endif #if defined(ZCL_USING_GROUP_KEY_MANAGEMENT_CLUSTER_SERVER) || defined(ZCL_USING_GROUP_KEY_MANAGEMENT_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_GROUP_KEY_MANAGEMENT_CLUSTER { ZCL_GROUP_KEY_MANAGEMENT_CLUSTER_ID, "Group Key Management" }, +#define CHIP_PRINTCLUSTER_GROUP_KEY_MANAGEMENT_CLUSTER { chip::app::Clusters::GroupKeyManagement::Id, "Group Key Management" }, #else #define CHIP_PRINTCLUSTER_GROUP_KEY_MANAGEMENT_CLUSTER #endif #if defined(ZCL_USING_FIXED_LABEL_CLUSTER_SERVER) || defined(ZCL_USING_FIXED_LABEL_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_FIXED_LABEL_CLUSTER { ZCL_FIXED_LABEL_CLUSTER_ID, "Fixed Label" }, +#define CHIP_PRINTCLUSTER_FIXED_LABEL_CLUSTER { chip::app::Clusters::FixedLabel::Id, "Fixed Label" }, #else #define CHIP_PRINTCLUSTER_FIXED_LABEL_CLUSTER #endif #if defined(ZCL_USING_USER_LABEL_CLUSTER_SERVER) || defined(ZCL_USING_USER_LABEL_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_USER_LABEL_CLUSTER { ZCL_USER_LABEL_CLUSTER_ID, "User Label" }, +#define CHIP_PRINTCLUSTER_USER_LABEL_CLUSTER { chip::app::Clusters::UserLabel::Id, "User Label" }, #else #define CHIP_PRINTCLUSTER_USER_LABEL_CLUSTER #endif #if defined(ZCL_USING_PROXY_CONFIGURATION_CLUSTER_SERVER) || defined(ZCL_USING_PROXY_CONFIGURATION_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_PROXY_CONFIGURATION_CLUSTER { ZCL_PROXY_CONFIGURATION_CLUSTER_ID, "Proxy Configuration" }, +#define CHIP_PRINTCLUSTER_PROXY_CONFIGURATION_CLUSTER { chip::app::Clusters::ProxyConfiguration::Id, "Proxy Configuration" }, #else #define CHIP_PRINTCLUSTER_PROXY_CONFIGURATION_CLUSTER #endif #if defined(ZCL_USING_PROXY_DISCOVERY_CLUSTER_SERVER) || defined(ZCL_USING_PROXY_DISCOVERY_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_PROXY_DISCOVERY_CLUSTER { ZCL_PROXY_DISCOVERY_CLUSTER_ID, "Proxy Discovery" }, +#define CHIP_PRINTCLUSTER_PROXY_DISCOVERY_CLUSTER { chip::app::Clusters::ProxyDiscovery::Id, "Proxy Discovery" }, #else #define CHIP_PRINTCLUSTER_PROXY_DISCOVERY_CLUSTER #endif #if defined(ZCL_USING_PROXY_VALID_CLUSTER_SERVER) || defined(ZCL_USING_PROXY_VALID_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_PROXY_VALID_CLUSTER { ZCL_PROXY_VALID_CLUSTER_ID, "Proxy Valid" }, +#define CHIP_PRINTCLUSTER_PROXY_VALID_CLUSTER { chip::app::Clusters::ProxyValid::Id, "Proxy Valid" }, #else #define CHIP_PRINTCLUSTER_PROXY_VALID_CLUSTER #endif #if defined(ZCL_USING_BOOLEAN_STATE_CLUSTER_SERVER) || defined(ZCL_USING_BOOLEAN_STATE_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_BOOLEAN_STATE_CLUSTER { ZCL_BOOLEAN_STATE_CLUSTER_ID, "Boolean State" }, +#define CHIP_PRINTCLUSTER_BOOLEAN_STATE_CLUSTER { chip::app::Clusters::BooleanState::Id, "Boolean State" }, #else #define CHIP_PRINTCLUSTER_BOOLEAN_STATE_CLUSTER #endif #if defined(ZCL_USING_MODE_SELECT_CLUSTER_SERVER) || defined(ZCL_USING_MODE_SELECT_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_MODE_SELECT_CLUSTER { ZCL_MODE_SELECT_CLUSTER_ID, "Mode Select" }, +#define CHIP_PRINTCLUSTER_MODE_SELECT_CLUSTER { chip::app::Clusters::ModeSelect::Id, "Mode Select" }, #else #define CHIP_PRINTCLUSTER_MODE_SELECT_CLUSTER #endif #if defined(ZCL_USING_DOOR_LOCK_CLUSTER_SERVER) || defined(ZCL_USING_DOOR_LOCK_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_DOOR_LOCK_CLUSTER { ZCL_DOOR_LOCK_CLUSTER_ID, "Door Lock" }, +#define CHIP_PRINTCLUSTER_DOOR_LOCK_CLUSTER { chip::app::Clusters::DoorLock::Id, "Door Lock" }, #else #define CHIP_PRINTCLUSTER_DOOR_LOCK_CLUSTER #endif #if defined(ZCL_USING_WINDOW_COVERING_CLUSTER_SERVER) || defined(ZCL_USING_WINDOW_COVERING_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_WINDOW_COVERING_CLUSTER { ZCL_WINDOW_COVERING_CLUSTER_ID, "Window Covering" }, +#define CHIP_PRINTCLUSTER_WINDOW_COVERING_CLUSTER { chip::app::Clusters::WindowCovering::Id, "Window Covering" }, #else #define CHIP_PRINTCLUSTER_WINDOW_COVERING_CLUSTER #endif #if defined(ZCL_USING_BARRIER_CONTROL_CLUSTER_SERVER) || defined(ZCL_USING_BARRIER_CONTROL_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_BARRIER_CONTROL_CLUSTER { ZCL_BARRIER_CONTROL_CLUSTER_ID, "Barrier Control" }, +#define CHIP_PRINTCLUSTER_BARRIER_CONTROL_CLUSTER { chip::app::Clusters::BarrierControl::Id, "Barrier Control" }, #else #define CHIP_PRINTCLUSTER_BARRIER_CONTROL_CLUSTER #endif @@ -300,19 +305,19 @@ #if defined(ZCL_USING_PUMP_CONFIGURATION_AND_CONTROL_CLUSTER_SERVER) || \ defined(ZCL_USING_PUMP_CONFIGURATION_AND_CONTROL_CLUSTER_CLIENT) #define CHIP_PRINTCLUSTER_PUMP_CONFIGURATION_AND_CONTROL_CLUSTER \ - { ZCL_PUMP_CONFIGURATION_AND_CONTROL_CLUSTER_ID, "Pump Configuration and Control" }, + { chip::app::Clusters::PumpConfigurationAndControl::Id, "Pump Configuration and Control" }, #else #define CHIP_PRINTCLUSTER_PUMP_CONFIGURATION_AND_CONTROL_CLUSTER #endif #if defined(ZCL_USING_THERMOSTAT_CLUSTER_SERVER) || defined(ZCL_USING_THERMOSTAT_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_THERMOSTAT_CLUSTER { ZCL_THERMOSTAT_CLUSTER_ID, "Thermostat" }, +#define CHIP_PRINTCLUSTER_THERMOSTAT_CLUSTER { chip::app::Clusters::Thermostat::Id, "Thermostat" }, #else #define CHIP_PRINTCLUSTER_THERMOSTAT_CLUSTER #endif #if defined(ZCL_USING_FAN_CONTROL_CLUSTER_SERVER) || defined(ZCL_USING_FAN_CONTROL_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_FAN_CONTROL_CLUSTER { ZCL_FAN_CONTROL_CLUSTER_ID, "Fan Control" }, +#define CHIP_PRINTCLUSTER_FAN_CONTROL_CLUSTER { chip::app::Clusters::FanControl::Id, "Fan Control" }, #else #define CHIP_PRINTCLUSTER_FAN_CONTROL_CLUSTER #endif @@ -320,43 +325,45 @@ #if defined(ZCL_USING_THERMOSTAT_USER_INTERFACE_CONFIGURATION_CLUSTER_SERVER) || \ defined(ZCL_USING_THERMOSTAT_USER_INTERFACE_CONFIGURATION_CLUSTER_CLIENT) #define CHIP_PRINTCLUSTER_THERMOSTAT_USER_INTERFACE_CONFIGURATION_CLUSTER \ - { ZCL_THERMOSTAT_USER_INTERFACE_CONFIGURATION_CLUSTER_ID, "Thermostat User Interface Configuration" }, + { chip::app::Clusters::ThermostatUserInterfaceConfiguration::Id, "Thermostat User Interface Configuration" }, #else #define CHIP_PRINTCLUSTER_THERMOSTAT_USER_INTERFACE_CONFIGURATION_CLUSTER #endif #if defined(ZCL_USING_COLOR_CONTROL_CLUSTER_SERVER) || defined(ZCL_USING_COLOR_CONTROL_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_COLOR_CONTROL_CLUSTER { ZCL_COLOR_CONTROL_CLUSTER_ID, "Color Control" }, +#define CHIP_PRINTCLUSTER_COLOR_CONTROL_CLUSTER { chip::app::Clusters::ColorControl::Id, "Color Control" }, #else #define CHIP_PRINTCLUSTER_COLOR_CONTROL_CLUSTER #endif #if defined(ZCL_USING_BALLAST_CONFIGURATION_CLUSTER_SERVER) || defined(ZCL_USING_BALLAST_CONFIGURATION_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_BALLAST_CONFIGURATION_CLUSTER { ZCL_BALLAST_CONFIGURATION_CLUSTER_ID, "Ballast Configuration" }, +#define CHIP_PRINTCLUSTER_BALLAST_CONFIGURATION_CLUSTER { chip::app::Clusters::BallastConfiguration::Id, "Ballast Configuration" }, #else #define CHIP_PRINTCLUSTER_BALLAST_CONFIGURATION_CLUSTER #endif #if defined(ZCL_USING_ILLUMINANCE_MEASUREMENT_CLUSTER_SERVER) || defined(ZCL_USING_ILLUMINANCE_MEASUREMENT_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_ILLUMINANCE_MEASUREMENT_CLUSTER { ZCL_ILLUMINANCE_MEASUREMENT_CLUSTER_ID, "Illuminance Measurement" }, +#define CHIP_PRINTCLUSTER_ILLUMINANCE_MEASUREMENT_CLUSTER \ + { chip::app::Clusters::IlluminanceMeasurement::Id, "Illuminance Measurement" }, #else #define CHIP_PRINTCLUSTER_ILLUMINANCE_MEASUREMENT_CLUSTER #endif #if defined(ZCL_USING_TEMPERATURE_MEASUREMENT_CLUSTER_SERVER) || defined(ZCL_USING_TEMPERATURE_MEASUREMENT_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_TEMPERATURE_MEASUREMENT_CLUSTER { ZCL_TEMPERATURE_MEASUREMENT_CLUSTER_ID, "Temperature Measurement" }, +#define CHIP_PRINTCLUSTER_TEMPERATURE_MEASUREMENT_CLUSTER \ + { chip::app::Clusters::TemperatureMeasurement::Id, "Temperature Measurement" }, #else #define CHIP_PRINTCLUSTER_TEMPERATURE_MEASUREMENT_CLUSTER #endif #if defined(ZCL_USING_PRESSURE_MEASUREMENT_CLUSTER_SERVER) || defined(ZCL_USING_PRESSURE_MEASUREMENT_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_PRESSURE_MEASUREMENT_CLUSTER { ZCL_PRESSURE_MEASUREMENT_CLUSTER_ID, "Pressure Measurement" }, +#define CHIP_PRINTCLUSTER_PRESSURE_MEASUREMENT_CLUSTER { chip::app::Clusters::PressureMeasurement::Id, "Pressure Measurement" }, #else #define CHIP_PRINTCLUSTER_PRESSURE_MEASUREMENT_CLUSTER #endif #if defined(ZCL_USING_FLOW_MEASUREMENT_CLUSTER_SERVER) || defined(ZCL_USING_FLOW_MEASUREMENT_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_FLOW_MEASUREMENT_CLUSTER { ZCL_FLOW_MEASUREMENT_CLUSTER_ID, "Flow Measurement" }, +#define CHIP_PRINTCLUSTER_FLOW_MEASUREMENT_CLUSTER { chip::app::Clusters::FlowMeasurement::Id, "Flow Measurement" }, #else #define CHIP_PRINTCLUSTER_FLOW_MEASUREMENT_CLUSTER #endif @@ -364,103 +371,110 @@ #if defined(ZCL_USING_RELATIVE_HUMIDITY_MEASUREMENT_CLUSTER_SERVER) || \ defined(ZCL_USING_RELATIVE_HUMIDITY_MEASUREMENT_CLUSTER_CLIENT) #define CHIP_PRINTCLUSTER_RELATIVE_HUMIDITY_MEASUREMENT_CLUSTER \ - { ZCL_RELATIVE_HUMIDITY_MEASUREMENT_CLUSTER_ID, "Relative Humidity Measurement" }, + { chip::app::Clusters::RelativeHumidityMeasurement::Id, "Relative Humidity Measurement" }, #else #define CHIP_PRINTCLUSTER_RELATIVE_HUMIDITY_MEASUREMENT_CLUSTER #endif #if defined(ZCL_USING_OCCUPANCY_SENSING_CLUSTER_SERVER) || defined(ZCL_USING_OCCUPANCY_SENSING_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_OCCUPANCY_SENSING_CLUSTER { ZCL_OCCUPANCY_SENSING_CLUSTER_ID, "Occupancy Sensing" }, +#define CHIP_PRINTCLUSTER_OCCUPANCY_SENSING_CLUSTER { chip::app::Clusters::OccupancySensing::Id, "Occupancy Sensing" }, #else #define CHIP_PRINTCLUSTER_OCCUPANCY_SENSING_CLUSTER #endif #if defined(ZCL_USING_WAKE_ON_LAN_CLUSTER_SERVER) || defined(ZCL_USING_WAKE_ON_LAN_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_WAKE_ON_LAN_CLUSTER { ZCL_WAKE_ON_LAN_CLUSTER_ID, "Wake on LAN" }, +#define CHIP_PRINTCLUSTER_WAKE_ON_LAN_CLUSTER { chip::app::Clusters::WakeOnLan::Id, "Wake on LAN" }, #else #define CHIP_PRINTCLUSTER_WAKE_ON_LAN_CLUSTER #endif #if defined(ZCL_USING_CHANNEL_CLUSTER_SERVER) || defined(ZCL_USING_CHANNEL_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_CHANNEL_CLUSTER { ZCL_CHANNEL_CLUSTER_ID, "Channel" }, +#define CHIP_PRINTCLUSTER_CHANNEL_CLUSTER { chip::app::Clusters::Channel::Id, "Channel" }, #else #define CHIP_PRINTCLUSTER_CHANNEL_CLUSTER #endif #if defined(ZCL_USING_TARGET_NAVIGATOR_CLUSTER_SERVER) || defined(ZCL_USING_TARGET_NAVIGATOR_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_TARGET_NAVIGATOR_CLUSTER { ZCL_TARGET_NAVIGATOR_CLUSTER_ID, "Target Navigator" }, +#define CHIP_PRINTCLUSTER_TARGET_NAVIGATOR_CLUSTER { chip::app::Clusters::TargetNavigator::Id, "Target Navigator" }, #else #define CHIP_PRINTCLUSTER_TARGET_NAVIGATOR_CLUSTER #endif #if defined(ZCL_USING_MEDIA_PLAYBACK_CLUSTER_SERVER) || defined(ZCL_USING_MEDIA_PLAYBACK_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_MEDIA_PLAYBACK_CLUSTER { ZCL_MEDIA_PLAYBACK_CLUSTER_ID, "Media Playback" }, +#define CHIP_PRINTCLUSTER_MEDIA_PLAYBACK_CLUSTER { chip::app::Clusters::MediaPlayback::Id, "Media Playback" }, #else #define CHIP_PRINTCLUSTER_MEDIA_PLAYBACK_CLUSTER #endif #if defined(ZCL_USING_MEDIA_INPUT_CLUSTER_SERVER) || defined(ZCL_USING_MEDIA_INPUT_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_MEDIA_INPUT_CLUSTER { ZCL_MEDIA_INPUT_CLUSTER_ID, "Media Input" }, +#define CHIP_PRINTCLUSTER_MEDIA_INPUT_CLUSTER { chip::app::Clusters::MediaInput::Id, "Media Input" }, #else #define CHIP_PRINTCLUSTER_MEDIA_INPUT_CLUSTER #endif #if defined(ZCL_USING_LOW_POWER_CLUSTER_SERVER) || defined(ZCL_USING_LOW_POWER_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_LOW_POWER_CLUSTER { ZCL_LOW_POWER_CLUSTER_ID, "Low Power" }, +#define CHIP_PRINTCLUSTER_LOW_POWER_CLUSTER { chip::app::Clusters::LowPower::Id, "Low Power" }, #else #define CHIP_PRINTCLUSTER_LOW_POWER_CLUSTER #endif #if defined(ZCL_USING_KEYPAD_INPUT_CLUSTER_SERVER) || defined(ZCL_USING_KEYPAD_INPUT_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_KEYPAD_INPUT_CLUSTER { ZCL_KEYPAD_INPUT_CLUSTER_ID, "Keypad Input" }, +#define CHIP_PRINTCLUSTER_KEYPAD_INPUT_CLUSTER { chip::app::Clusters::KeypadInput::Id, "Keypad Input" }, #else #define CHIP_PRINTCLUSTER_KEYPAD_INPUT_CLUSTER #endif #if defined(ZCL_USING_CONTENT_LAUNCHER_CLUSTER_SERVER) || defined(ZCL_USING_CONTENT_LAUNCHER_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_CONTENT_LAUNCHER_CLUSTER { ZCL_CONTENT_LAUNCHER_CLUSTER_ID, "Content Launcher" }, +#define CHIP_PRINTCLUSTER_CONTENT_LAUNCHER_CLUSTER { chip::app::Clusters::ContentLauncher::Id, "Content Launcher" }, #else #define CHIP_PRINTCLUSTER_CONTENT_LAUNCHER_CLUSTER #endif #if defined(ZCL_USING_AUDIO_OUTPUT_CLUSTER_SERVER) || defined(ZCL_USING_AUDIO_OUTPUT_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_AUDIO_OUTPUT_CLUSTER { ZCL_AUDIO_OUTPUT_CLUSTER_ID, "Audio Output" }, +#define CHIP_PRINTCLUSTER_AUDIO_OUTPUT_CLUSTER { chip::app::Clusters::AudioOutput::Id, "Audio Output" }, #else #define CHIP_PRINTCLUSTER_AUDIO_OUTPUT_CLUSTER #endif #if defined(ZCL_USING_APPLICATION_LAUNCHER_CLUSTER_SERVER) || defined(ZCL_USING_APPLICATION_LAUNCHER_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_APPLICATION_LAUNCHER_CLUSTER { ZCL_APPLICATION_LAUNCHER_CLUSTER_ID, "Application Launcher" }, +#define CHIP_PRINTCLUSTER_APPLICATION_LAUNCHER_CLUSTER { chip::app::Clusters::ApplicationLauncher::Id, "Application Launcher" }, #else #define CHIP_PRINTCLUSTER_APPLICATION_LAUNCHER_CLUSTER #endif #if defined(ZCL_USING_APPLICATION_BASIC_CLUSTER_SERVER) || defined(ZCL_USING_APPLICATION_BASIC_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_APPLICATION_BASIC_CLUSTER { ZCL_APPLICATION_BASIC_CLUSTER_ID, "Application Basic" }, +#define CHIP_PRINTCLUSTER_APPLICATION_BASIC_CLUSTER { chip::app::Clusters::ApplicationBasic::Id, "Application Basic" }, #else #define CHIP_PRINTCLUSTER_APPLICATION_BASIC_CLUSTER #endif #if defined(ZCL_USING_ACCOUNT_LOGIN_CLUSTER_SERVER) || defined(ZCL_USING_ACCOUNT_LOGIN_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_ACCOUNT_LOGIN_CLUSTER { ZCL_ACCOUNT_LOGIN_CLUSTER_ID, "Account Login" }, +#define CHIP_PRINTCLUSTER_ACCOUNT_LOGIN_CLUSTER { chip::app::Clusters::AccountLogin::Id, "Account Login" }, #else #define CHIP_PRINTCLUSTER_ACCOUNT_LOGIN_CLUSTER #endif #if defined(ZCL_USING_ELECTRICAL_MEASUREMENT_CLUSTER_SERVER) || defined(ZCL_USING_ELECTRICAL_MEASUREMENT_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_ELECTRICAL_MEASUREMENT_CLUSTER { ZCL_ELECTRICAL_MEASUREMENT_CLUSTER_ID, "Electrical Measurement" }, +#define CHIP_PRINTCLUSTER_ELECTRICAL_MEASUREMENT_CLUSTER \ + { chip::app::Clusters::ElectricalMeasurement::Id, "Electrical Measurement" }, #else #define CHIP_PRINTCLUSTER_ELECTRICAL_MEASUREMENT_CLUSTER #endif +#if defined(ZCL_USING_CLIENT_MONITORING_CLUSTER_SERVER) || defined(ZCL_USING_CLIENT_MONITORING_CLUSTER_CLIENT) +#define CHIP_PRINTCLUSTER_CLIENT_MONITORING_CLUSTER { chip::app::Clusters::ClientMonitoring::Id, "Client Monitoring" }, +#else +#define CHIP_PRINTCLUSTER_CLIENT_MONITORING_CLUSTER +#endif + #if defined(ZCL_USING_UNIT_TESTING_CLUSTER_SERVER) || defined(ZCL_USING_UNIT_TESTING_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_UNIT_TESTING_CLUSTER { ZCL_UNIT_TESTING_CLUSTER_ID, "Unit Testing" }, +#define CHIP_PRINTCLUSTER_UNIT_TESTING_CLUSTER { chip::app::Clusters::UnitTesting::Id, "Unit Testing" }, #else #define CHIP_PRINTCLUSTER_UNIT_TESTING_CLUSTER #endif #if defined(ZCL_USING_FAULT_INJECTION_CLUSTER_SERVER) || defined(ZCL_USING_FAULT_INJECTION_CLUSTER_CLIENT) -#define CHIP_PRINTCLUSTER_FAULT_INJECTION_CLUSTER { ZCL_FAULT_INJECTION_CLUSTER_ID, "Fault Injection" }, +#define CHIP_PRINTCLUSTER_FAULT_INJECTION_CLUSTER { chip::app::Clusters::FaultInjection::Id, "Fault Injection" }, #else #define CHIP_PRINTCLUSTER_FAULT_INJECTION_CLUSTER #endif @@ -535,6 +549,7 @@ CHIP_PRINTCLUSTER_APPLICATION_BASIC_CLUSTER \ CHIP_PRINTCLUSTER_ACCOUNT_LOGIN_CLUSTER \ CHIP_PRINTCLUSTER_ELECTRICAL_MEASUREMENT_CLUSTER \ + CHIP_PRINTCLUSTER_CLIENT_MONITORING_CLUSTER \ CHIP_PRINTCLUSTER_UNIT_TESTING_CLUSTER \ CHIP_PRINTCLUSTER_FAULT_INJECTION_CLUSTER diff --git a/zzz_generated/chef-rootnode_doorlock_aNKYAreMXE/zap-generated/endpoint_config.h b/zzz_generated/chef-rootnode_doorlock_aNKYAreMXE/zap-generated/endpoint_config.h index 44c5ef3598be90..ef5ccb21301250 100644 --- a/zzz_generated/chef-rootnode_doorlock_aNKYAreMXE/zap-generated/endpoint_config.h +++ b/zzz_generated/chef-rootnode_doorlock_aNKYAreMXE/zap-generated/endpoint_config.h @@ -309,8 +309,8 @@ ZAP_MIN_MAX_DEFAULTS_INDEX(3) }, /* UserCodeTemporaryDisableTime */ \ { 0x00000032, ZAP_TYPE(BOOLEAN), 1, ZAP_ATTRIBUTE_MASK(WRITABLE), ZAP_SIMPLE_DEFAULT(0) }, /* SendPINOverTheAir */ \ { 0x00000033, ZAP_TYPE(BOOLEAN), 1, ZAP_ATTRIBUTE_MASK(WRITABLE), \ - ZAP_SIMPLE_DEFAULT(0) }, /* RequirePINforRemoteOperation */ \ - { 0x0000FFFC, ZAP_TYPE(BITMAP32), 4, 0, ZAP_SIMPLE_DEFAULT(0x0001) }, /* FeatureMap */ \ + ZAP_SIMPLE_DEFAULT(1) }, /* RequirePINforRemoteOperation */ \ + { 0x0000FFFC, ZAP_TYPE(BITMAP32), 4, 0, ZAP_SIMPLE_DEFAULT(0x0081) }, /* FeatureMap */ \ { 0x0000FFFD, ZAP_TYPE(INT16U), 2, 0, ZAP_SIMPLE_DEFAULT(6) }, /* ClusterRevision */ \ } diff --git a/zzz_generated/chip-tool/zap-generated/cluster/Commands.h b/zzz_generated/chip-tool/zap-generated/cluster/Commands.h index 852804cdd7daff..aafc35794b3bf4 100644 --- a/zzz_generated/chip-tool/zap-generated/cluster/Commands.h +++ b/zzz_generated/chip-tool/zap-generated/cluster/Commands.h @@ -102,6 +102,7 @@ | ApplicationBasic | 0x050D | | AccountLogin | 0x050E | | ElectricalMeasurement | 0x0B04 | +| ClientMonitoring | 0x1046 | | UnitTesting | 0xFFF1FC05| | FaultInjection | 0xFFF1FC06| \*----------------------------------------------------------------------------*/ @@ -7296,6 +7297,89 @@ class ElectricalMeasurementGetMeasurementProfileCommand : public ClusterCommand chip::app::Clusters::ElectricalMeasurement::Commands::GetMeasurementProfileCommand::Type mRequest; }; +/*----------------------------------------------------------------------------*\ +| Cluster ClientMonitoring | 0x1046 | +|------------------------------------------------------------------------------| +| Commands: | | +| * RegisterClientMonitoring | 0x00 | +| * StayAwakeRequest | 0x01 | +|------------------------------------------------------------------------------| +| Attributes: | | +| * IdleModeInterval | 0x0000 | +| * ActiveModeInterval | 0x0001 | +| * ActiveModeThreshold | 0x0002 | +| * ExpectedClients | 0x0003 | +| * GeneratedCommandList | 0xFFF8 | +| * AcceptedCommandList | 0xFFF9 | +| * AttributeList | 0xFFFB | +| * FeatureMap | 0xFFFC | +| * ClusterRevision | 0xFFFD | +|------------------------------------------------------------------------------| +| Events: | | +\*----------------------------------------------------------------------------*/ + +/* + * Command RegisterClientMonitoring + */ +class ClientMonitoringRegisterClientMonitoring : public ClusterCommand +{ +public: + ClientMonitoringRegisterClientMonitoring(CredentialIssuerCommands * credsIssuerConfig) : + ClusterCommand("register-client-monitoring", credsIssuerConfig) + { + AddArgument("ClientNodeId", 0, UINT64_MAX, &mRequest.clientNodeId); + AddArgument("ICid", 0, UINT64_MAX, &mRequest.ICid); + ClusterCommand::AddArguments(); + } + + CHIP_ERROR SendCommand(chip::DeviceProxy * device, std::vector endpointIds) override + { + ChipLogProgress(chipTool, "Sending cluster (0x00001046) command (0x00000000) on endpoint %u", endpointIds.at(0)); + + return ClusterCommand::SendCommand(device, endpointIds.at(0), 0x00001046, 0x00000000, mRequest); + } + + CHIP_ERROR SendGroupCommand(chip::GroupId groupId, chip::FabricIndex fabricIndex) override + { + ChipLogProgress(chipTool, "Sending cluster (0x00001046) command (0x00000000) on Group %u", groupId); + + return ClusterCommand::SendGroupCommand(groupId, fabricIndex, 0x00001046, 0x00000000, mRequest); + } + +private: + chip::app::Clusters::ClientMonitoring::Commands::RegisterClientMonitoring::Type mRequest; +}; + +/* + * Command StayAwakeRequest + */ +class ClientMonitoringStayAwakeRequest : public ClusterCommand +{ +public: + ClientMonitoringStayAwakeRequest(CredentialIssuerCommands * credsIssuerConfig) : + ClusterCommand("stay-awake-request", credsIssuerConfig) + { + ClusterCommand::AddArguments(); + } + + CHIP_ERROR SendCommand(chip::DeviceProxy * device, std::vector endpointIds) override + { + ChipLogProgress(chipTool, "Sending cluster (0x00001046) command (0x00000001) on endpoint %u", endpointIds.at(0)); + + return ClusterCommand::SendCommand(device, endpointIds.at(0), 0x00001046, 0x00000001, mRequest); + } + + CHIP_ERROR SendGroupCommand(chip::GroupId groupId, chip::FabricIndex fabricIndex) override + { + ChipLogProgress(chipTool, "Sending cluster (0x00001046) command (0x00000001) on Group %u", groupId); + + return ClusterCommand::SendGroupCommand(groupId, fabricIndex, 0x00001046, 0x00000001, mRequest); + } + +private: + chip::app::Clusters::ClientMonitoring::Commands::StayAwakeRequest::Type mRequest; +}; + /*----------------------------------------------------------------------------*\ | Cluster UnitTesting | 0xFFF1FC05| |------------------------------------------------------------------------------| @@ -12909,6 +12993,52 @@ void registerClusterElectricalMeasurement(Commands & commands, CredentialIssuerC commands.Register(clusterName, clusterCommands); } +void registerClusterClientMonitoring(Commands & commands, CredentialIssuerCommands * credsIssuerConfig) +{ + using namespace chip::app::Clusters::ClientMonitoring; + + const char * clusterName = "ClientMonitoring"; + + commands_list clusterCommands = { + // + // Commands + // + make_unique(Id, credsIssuerConfig), // + make_unique(credsIssuerConfig), // + make_unique(credsIssuerConfig), // + // + // Attributes + // + make_unique(Id, credsIssuerConfig), // + make_unique(Id, "idle-mode-interval", Attributes::IdleModeInterval::Id, credsIssuerConfig), // + make_unique(Id, "active-mode-interval", Attributes::ActiveModeInterval::Id, credsIssuerConfig), // + make_unique(Id, "active-mode-threshold", Attributes::ActiveModeThreshold::Id, credsIssuerConfig), // + make_unique(Id, "expected-clients", Attributes::ExpectedClients::Id, credsIssuerConfig), // + make_unique(Id, "generated-command-list", Attributes::GeneratedCommandList::Id, credsIssuerConfig), // + make_unique(Id, "accepted-command-list", Attributes::AcceptedCommandList::Id, credsIssuerConfig), // + make_unique(Id, "attribute-list", Attributes::AttributeList::Id, credsIssuerConfig), // + make_unique(Id, "feature-map", Attributes::FeatureMap::Id, credsIssuerConfig), // + make_unique(Id, "cluster-revision", Attributes::ClusterRevision::Id, credsIssuerConfig), // + make_unique>(Id, credsIssuerConfig), // + make_unique(Id, credsIssuerConfig), // + make_unique(Id, "idle-mode-interval", Attributes::IdleModeInterval::Id, credsIssuerConfig), // + make_unique(Id, "active-mode-interval", Attributes::ActiveModeInterval::Id, credsIssuerConfig), // + make_unique(Id, "active-mode-threshold", Attributes::ActiveModeThreshold::Id, credsIssuerConfig), // + make_unique(Id, "expected-clients", Attributes::ExpectedClients::Id, credsIssuerConfig), // + make_unique(Id, "generated-command-list", Attributes::GeneratedCommandList::Id, credsIssuerConfig), // + make_unique(Id, "accepted-command-list", Attributes::AcceptedCommandList::Id, credsIssuerConfig), // + make_unique(Id, "attribute-list", Attributes::AttributeList::Id, credsIssuerConfig), // + make_unique(Id, "feature-map", Attributes::FeatureMap::Id, credsIssuerConfig), // + make_unique(Id, "cluster-revision", Attributes::ClusterRevision::Id, credsIssuerConfig), // + // + // Events + // + make_unique(Id, credsIssuerConfig), // + make_unique(Id, credsIssuerConfig), // + }; + + commands.Register(clusterName, clusterCommands); +} void registerClusterUnitTesting(Commands & commands, CredentialIssuerCommands * credsIssuerConfig) { using namespace chip::app::Clusters::UnitTesting; @@ -13427,6 +13557,7 @@ void registerClusters(Commands & commands, CredentialIssuerCommands * credsIssue registerClusterApplicationBasic(commands, credsIssuerConfig); registerClusterAccountLogin(commands, credsIssuerConfig); registerClusterElectricalMeasurement(commands, credsIssuerConfig); + registerClusterClientMonitoring(commands, credsIssuerConfig); registerClusterUnitTesting(commands, credsIssuerConfig); registerClusterFaultInjection(commands, credsIssuerConfig); registerClusterSubscriptions(commands, credsIssuerConfig); diff --git a/zzz_generated/chip-tool/zap-generated/cluster/ComplexArgumentParser.cpp b/zzz_generated/chip-tool/zap-generated/cluster/ComplexArgumentParser.cpp index 5fec5e0a074e79..ac4bcac9fc2dd7 100644 --- a/zzz_generated/chip-tool/zap-generated/cluster/ComplexArgumentParser.cpp +++ b/zzz_generated/chip-tool/zap-generated/cluster/ComplexArgumentParser.cpp @@ -997,6 +997,38 @@ void ComplexArgumentParser::Finalize(chip::app::Clusters::ModeSelect::Structs::M ComplexArgumentParser::Finalize(request.mode); ComplexArgumentParser::Finalize(request.semanticTags); } +CHIP_ERROR ComplexArgumentParser::Setup(const char * label, + chip::app::Clusters::ClientMonitoring::Structs::MonitoringRegistration::Type & request, + Json::Value & value) +{ + VerifyOrReturnError(value.isObject(), CHIP_ERROR_INVALID_ARGUMENT); + + ReturnErrorOnFailure(ComplexArgumentParser::EnsureMemberExist("MonitoringRegistration.clientNodeId", "clientNodeId", + value.isMember("clientNodeId"))); + ReturnErrorOnFailure(ComplexArgumentParser::EnsureMemberExist("MonitoringRegistration.ICid", "ICid", value.isMember("ICid"))); + + char labelWithMember[kMaxLabelLength]; + snprintf(labelWithMember, sizeof(labelWithMember), "%s.%s", label, "clientNodeId"); + ReturnErrorOnFailure(ComplexArgumentParser::Setup(labelWithMember, request.clientNodeId, value["clientNodeId"])); + + snprintf(labelWithMember, sizeof(labelWithMember), "%s.%s", label, "ICid"); + ReturnErrorOnFailure(ComplexArgumentParser::Setup(labelWithMember, request.ICid, value["ICid"])); + + if (value.isMember("fabricIndex")) + { + snprintf(labelWithMember, sizeof(labelWithMember), "%s.%s", label, "fabricIndex"); + ReturnErrorOnFailure(ComplexArgumentParser::Setup(labelWithMember, request.fabricIndex, value["fabricIndex"])); + } + + return CHIP_NO_ERROR; +} + +void ComplexArgumentParser::Finalize(chip::app::Clusters::ClientMonitoring::Structs::MonitoringRegistration::Type & request) +{ + ComplexArgumentParser::Finalize(request.clientNodeId); + ComplexArgumentParser::Finalize(request.ICid); + ComplexArgumentParser::Finalize(request.fabricIndex); +} CHIP_ERROR ComplexArgumentParser::Setup(const char * label, chip::app::Clusters::OperationalCredentials::Structs::NOCStruct::Type & request, Json::Value & value) diff --git a/zzz_generated/chip-tool/zap-generated/cluster/ComplexArgumentParser.h b/zzz_generated/chip-tool/zap-generated/cluster/ComplexArgumentParser.h index 7a69b9477b2d65..dacf0f20365f4d 100644 --- a/zzz_generated/chip-tool/zap-generated/cluster/ComplexArgumentParser.h +++ b/zzz_generated/chip-tool/zap-generated/cluster/ComplexArgumentParser.h @@ -142,6 +142,10 @@ static CHIP_ERROR Setup(const char * label, chip::app::Clusters::ModeSelect::Str Json::Value & value); static void Finalize(chip::app::Clusters::ModeSelect::Structs::ModeOptionStruct::Type & request); +static CHIP_ERROR Setup(const char * label, chip::app::Clusters::ClientMonitoring::Structs::MonitoringRegistration::Type & request, + Json::Value & value); + +static void Finalize(chip::app::Clusters::ClientMonitoring::Structs::MonitoringRegistration::Type & request); static CHIP_ERROR Setup(const char * label, chip::app::Clusters::OperationalCredentials::Structs::NOCStruct::Type & request, Json::Value & value); diff --git a/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp b/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp index c9f8748cdbe4da..5f6b65a2f5543b 100644 --- a/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp +++ b/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp @@ -1021,6 +1021,39 @@ CHIP_ERROR DataModelLogger::LogValue(const char * label, size_t indent, return CHIP_NO_ERROR; } +CHIP_ERROR +DataModelLogger::LogValue(const char * label, size_t indent, + const chip::app::Clusters::ClientMonitoring::Structs::MonitoringRegistration::DecodableType & value) +{ + DataModelLogger::LogString(label, indent, "{"); + { + CHIP_ERROR err = LogValue("ClientNodeId", indent + 1, value.clientNodeId); + if (err != CHIP_NO_ERROR) + { + DataModelLogger::LogString(indent + 1, "Struct truncated due to invalid value for 'ClientNodeId'"); + return err; + } + } + { + CHIP_ERROR err = LogValue("ICid", indent + 1, value.ICid); + if (err != CHIP_NO_ERROR) + { + DataModelLogger::LogString(indent + 1, "Struct truncated due to invalid value for 'ICid'"); + return err; + } + } + { + CHIP_ERROR err = LogValue("FabricIndex", indent + 1, value.fabricIndex); + if (err != CHIP_NO_ERROR) + { + DataModelLogger::LogString(indent + 1, "Struct truncated due to invalid value for 'FabricIndex'"); + return err; + } + } + DataModelLogger::LogString(indent, "}"); + + return CHIP_NO_ERROR; +} CHIP_ERROR DataModelLogger::LogValue(const char * label, size_t indent, const chip::app::Clusters::OperationalCredentials::Structs::NOCStruct::DecodableType & value) { @@ -3101,10 +3134,10 @@ CHIP_ERROR DataModelLogger::LogValue(const char * label, size_t indent, { DataModelLogger::LogString(label, indent, "{"); { - CHIP_ERROR err = DataModelLogger::LogValue("NewPosition", indent + 1, value.newPosition); + CHIP_ERROR err = DataModelLogger::LogValue("PreviousPosition", indent + 1, value.previousPosition); if (err != CHIP_NO_ERROR) { - DataModelLogger::LogString(indent + 1, "Event truncated due to invalid value for 'NewPosition'"); + DataModelLogger::LogString(indent + 1, "Event truncated due to invalid value for 'PreviousPosition'"); return err; } } diff --git a/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.h b/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.h index c9b823373808fc..a0b5f9a78388a2 100644 --- a/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.h +++ b/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.h @@ -81,6 +81,8 @@ static CHIP_ERROR LogValue(const char * label, size_t indent, const chip::app::Clusters::Channel::Structs::LineupInfo::DecodableType & value); static CHIP_ERROR LogValue(const char * label, size_t indent, const chip::app::Clusters::ModeSelect::Structs::ModeOptionStruct::DecodableType & value); +static CHIP_ERROR LogValue(const char * label, size_t indent, + const chip::app::Clusters::ClientMonitoring::Structs::MonitoringRegistration::DecodableType & value); static CHIP_ERROR LogValue(const char * label, size_t indent, const chip::app::Clusters::OperationalCredentials::Structs::NOCStruct::DecodableType & value); static CHIP_ERROR LogValue(const char * label, size_t indent, diff --git a/zzz_generated/chip-tool/zap-generated/test/Commands.h b/zzz_generated/chip-tool/zap-generated/test/Commands.h index 796a968a9bbed7..f0469227c5e774 100644 --- a/zzz_generated/chip-tool/zap-generated/test/Commands.h +++ b/zzz_generated/chip-tool/zap-generated/test/Commands.h @@ -39,8 +39,11 @@ class TestList : public Command printf("Test_TC_ACL_1_1\n"); printf("Test_TC_ACL_2_1\n"); printf("Test_TC_ACL_2_2\n"); + printf("Test_TC_ACL_2_3\n"); printf("Test_TC_BOOL_1_1\n"); printf("Test_TC_BOOL_2_1\n"); + printf("Test_TC_BRBINFO_1_1\n"); + printf("Test_TC_BRBINFO_2_1\n"); printf("Test_TC_ACT_1_1\n"); printf("Test_TC_BIND_1_1\n"); printf("Test_TC_CC_1_1\n"); @@ -108,6 +111,7 @@ class TestList : public Command printf("Test_TC_APBSC_1_10\n"); printf("Test_TC_CONTENTLAUNCHER_1_11\n"); printf("Test_TC_ALOGIN_1_12\n"); + printf("Test_TC_ALOGIN_12_1\n"); printf("Test_TC_LOWPOWER_2_1\n"); printf("Test_TC_KEYPADINPUT_3_2\n"); printf("Test_TC_KEYPADINPUT_3_3\n"); @@ -120,6 +124,7 @@ class TestList : public Command printf("Test_TC_MEDIAINPUT_3_11\n"); printf("Test_TC_MEDIAINPUT_3_12\n"); printf("Test_TC_MEDIAINPUT_3_13\n"); + printf("Test_TC_WAKEONLAN_4_1\n"); printf("Test_TC_CHANNEL_5_1\n"); printf("Test_TC_CHANNEL_5_2\n"); printf("Test_TC_CHANNEL_5_3\n"); @@ -244,6 +249,7 @@ class TestList : public Command printf("Test_TC_DRLK_2_3\n"); printf("Test_TC_DRLK_2_4\n"); printf("Test_TC_DRLK_2_5\n"); + printf("Test_TC_DRLK_2_6\n"); printf("Test_TC_DRLK_2_7\n"); printf("Test_TC_DRLK_2_9\n"); printf("TestGroupMessaging\n"); @@ -390,7 +396,6 @@ class ManualTestList : public Command printf("Test_TC_MEDIAINPUT_3_15\n"); printf("Test_TC_MEDIAINPUT_3_16\n"); printf("Test_TC_MEDIAINPUT_3_17\n"); - printf("Test_TC_WAKEONLAN_4_1\n"); printf("Test_TC_CHANNEL_5_4\n"); printf("Test_TC_CHANNEL_5_5\n"); printf("Test_TC_CHANNEL_5_6\n"); @@ -405,7 +410,6 @@ class ManualTestList : public Command printf("Test_TC_CONTENTLAUNCHER_10_7\n"); printf("Test_TC_MC_11_1\n"); printf("Test_TC_MC_11_2\n"); - printf("Test_TC_ALOGIN_12_1\n"); printf("Test_TC_ALOGIN_12_2\n"); printf("Test_TC_CADMIN_1_1\n"); printf("Test_TC_CADMIN_1_2\n"); @@ -517,7 +521,6 @@ class ManualTestList : public Command printf("Test_TC_CC_9_2\n"); printf("Test_TC_CC_9_3\n"); printf("Test_TC_DRLK_2_1\n"); - printf("Test_TC_DRLK_2_6\n"); printf("Test_TC_DRLK_2_8\n"); printf("Test_TC_DRLK_2_10\n"); printf("Test_TC_DRLK_3_1\n"); @@ -567,7 +570,6 @@ class ManualTestList : public Command printf("Test_TC_S_2_3\n"); printf("Test_TC_S_3_1\n"); printf("Test_TC_PCC_3_1\n"); - printf("Test_TC_ACL_2_3\n"); printf("Test_TC_ACL_2_4\n"); printf("Test_TC_ACL_2_5\n"); printf("Test_TC_ACL_2_6\n"); @@ -576,8 +578,6 @@ class ManualTestList : public Command printf("Test_TC_ACL_2_9\n"); printf("Test_TC_ACL_2_10\n"); printf("Test_TC_ULABEL_3_1\n"); - printf("Test_TC_BRBINFO_1_1\n"); - printf("Test_TC_BRBINFO_2_1\n"); printf("Test_TC_BRBINFO_2_2\n"); printf("Test_TC_BRBINFO_2_3\n"); printf("Test_TC_ACE_1_1\n"); @@ -2264,18 +2264,28 @@ class Test_TC_ACL_2_2Suite : public TestCommand } }; -class Test_TC_BOOL_1_1Suite : public TestCommand +class Test_TC_ACL_2_3Suite : public TestCommand { public: - Test_TC_BOOL_1_1Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_BOOL_1_1", 6, credsIssuerConfig) + Test_TC_ACL_2_3Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_ACL_2_3", 20, credsIssuerConfig) { AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); AddArgument("cluster", &mCluster); AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("D_OK_EMPTY", &mDOkEmpty); + AddArgument("D_OK_SINGLE", &mDOkSingle); + AddArgument("D_OK_FULL", &mDOkFull); + AddArgument("D_BAD_LENGTH", &mDBadLength); + AddArgument("D_BAD_STRUCT", &mDBadStruct); + AddArgument("D_BAD_LIST", &mDBadList); + AddArgument("D_BAD_ELEM", &mDBadElem); + AddArgument("D_BAD_OVERFLOW", &mDBadOverflow); + AddArgument("D_BAD_UNDERFLOW", &mDBadUnderflow); + AddArgument("D_BAD_NONE", &mDBadNone); AddArgument("timeout", 0, UINT16_MAX, &mTimeout); } - ~Test_TC_BOOL_1_1Suite() {} + ~Test_TC_ACL_2_3Suite() {} chip::System::Clock::Timeout GetWaitDuration() const override { @@ -2286,8 +2296,20 @@ class Test_TC_BOOL_1_1Suite : public TestCommand chip::Optional mNodeId; chip::Optional mCluster; chip::Optional mEndpoint; + chip::Optional mDOkEmpty; + chip::Optional mDOkSingle; + chip::Optional mDOkFull; + chip::Optional mDBadLength; + chip::Optional mDBadStruct; + chip::Optional mDBadList; + chip::Optional mDBadElem; + chip::Optional mDBadOverflow; + chip::Optional mDBadUnderflow; + chip::Optional mDBadNone; chip::Optional mTimeout; + uint8_t CurrentFabricIndex; + chip::EndpointId GetEndpoint(chip::EndpointId endpoint) { return mEndpoint.HasValue() ? mEndpoint.Value() : endpoint; } // @@ -2307,57 +2329,154 @@ class Test_TC_BOOL_1_1Suite : public TestCommand case 1: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { - uint16_t value; + uint8_t value; VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); - VerifyOrReturn(CheckValue("clusterRevision", value, 1U)); - VerifyOrReturn(CheckConstraintType("value", "int16u", "int16u")); + CurrentFabricIndex = value; } break; case 2: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { - uint32_t value; + chip::app::DataModel::DecodableList + value; VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); - VerifyOrReturn(CheckValue("featureMap", value, 0UL)); - VerifyOrReturn(CheckConstraintType("value", "bitmap32", "bitmap32")); + { + auto iter_0 = value.begin(); + VerifyOrReturn(CheckNoMoreListItems("extension", iter_0, 0)); + } } break; case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 4: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { - chip::app::DataModel::DecodableList value; + chip::app::DataModel::DecodableList + value; VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); - VerifyOrReturn(CheckConstraintType("value", "list", "list")); - VerifyOrReturn(CheckConstraintContains("value", value, 0UL)); - VerifyOrReturn(CheckConstraintContains("value", value, 65528UL)); - VerifyOrReturn(CheckConstraintContains("value", value, 65529UL)); - VerifyOrReturn(CheckConstraintContains("value", value, 65531UL)); - VerifyOrReturn(CheckConstraintContains("value", value, 65532UL)); - VerifyOrReturn(CheckConstraintContains("value", value, 65533UL)); + { + auto iter_0 = value.begin(); + VerifyOrReturn(CheckNextListItemDecodes("extension", iter_0, 0)); + VerifyOrReturn(CheckValueAsString( + "extension[0].data", iter_0.GetValue().data, + mDOkEmpty.HasValue() ? mDOkEmpty.Value() : chip::ByteSpan(chip::Uint8::from_const_char("\x17\x18"), 2))); + VerifyOrReturn(CheckValue("extension[0].fabricIndex", iter_0.GetValue().fabricIndex, CurrentFabricIndex)); + VerifyOrReturn(CheckNoMoreListItems("extension", iter_0, 1)); + } } break; - case 4: + case 5: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 6: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { - chip::app::DataModel::DecodableList value; + chip::app::DataModel::DecodableList + value; VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); { auto iter_0 = value.begin(); - VerifyOrReturn(CheckNoMoreListItems("acceptedCommandList", iter_0, 0)); + VerifyOrReturn(CheckNextListItemDecodes("extension", iter_0, 0)); + VerifyOrReturn(CheckValueAsString( + "extension[0].data", iter_0.GetValue().data, + mDOkSingle.HasValue() + ? mDOkSingle.Value() + : chip::ByteSpan(chip::Uint8::from_const_char( + "\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64" + "\x2E\x20\x54\x68\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65" + "\x6C\x65\x6D\x65\x6E\x74\x20\x6C\x69\x76\x69\x6E\x67\x20\x61\x73\x20\x61\x20\x63" + "\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00\x18"), + 71))); + VerifyOrReturn(CheckValue("extension[0].fabricIndex", iter_0.GetValue().fabricIndex, CurrentFabricIndex)); + VerifyOrReturn(CheckNoMoreListItems("extension", iter_0, 1)); } - VerifyOrReturn(CheckConstraintType("value", "list", "list")); } break; - case 5: + case 7: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 8: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { - chip::app::DataModel::DecodableList value; + chip::app::DataModel::DecodableList + value; VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); { auto iter_0 = value.begin(); - VerifyOrReturn(CheckNoMoreListItems("generatedCommandList", iter_0, 0)); + VerifyOrReturn(CheckNextListItemDecodes("extension", iter_0, 0)); + VerifyOrReturn(CheckValueAsString( + "extension[0].data", iter_0.GetValue().data, + mDOkFull.HasValue() + ? mDOkFull.Value() + : chip::ByteSpan( + chip::Uint8::from_const_char( + "\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54" + "\x68\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74" + "\x20\x6C\x69\x76\x69\x6E\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67" + "\x00\xD0\x00\x00\xF1\xFF\x02\x00\x31\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54" + "\x68\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74" + "\x20\x61\x67\x61\x69\x6E\x2E\x2E\x2E\x2E\x2E\x00\x18"), + 128))); + VerifyOrReturn(CheckValue("extension[0].fabricIndex", iter_0.GetValue().fabricIndex, CurrentFabricIndex)); + VerifyOrReturn(CheckNoMoreListItems("extension", iter_0, 1)); + } + } + break; + case 9: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 10: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 11: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 12: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 13: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 14: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 15: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 16: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 17: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList + value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + { + auto iter_0 = value.begin(); + VerifyOrReturn(CheckNextListItemDecodes("extension", iter_0, 0)); + VerifyOrReturn(CheckValueAsString( + "extension[0].data", iter_0.GetValue().data, + mDOkEmpty.HasValue() ? mDOkEmpty.Value() : chip::ByteSpan(chip::Uint8::from_const_char("\x17\x18"), 2))); + VerifyOrReturn(CheckValue("extension[0].fabricIndex", iter_0.GetValue().fabricIndex, CurrentFabricIndex)); + VerifyOrReturn(CheckNoMoreListItems("extension", iter_0, 1)); + } + } + break; + case 18: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 19: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList + value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + { + auto iter_0 = value.begin(); + VerifyOrReturn(CheckNoMoreListItems("extension", iter_0, 0)); } - VerifyOrReturn(CheckConstraintType("value", "list", "list")); } break; default: @@ -2383,39 +2502,382 @@ class Test_TC_BOOL_1_1Suite : public TestCommand return WaitForCommissionee(kIdentityAlpha, value); } case 1: { - LogStep(1, "read the global attribute: ClusterRevision"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), BooleanState::Id, BooleanState::Attributes::ClusterRevision::Id, - true, chip::NullOptional); + LogStep(1, "TH1 reads DUT Endpoint 0 OperationalCredentials cluster CurrentFabricIndex attribute"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), OperationalCredentials::Id, + OperationalCredentials::Attributes::CurrentFabricIndex::Id, true, chip::NullOptional); } case 2: { - LogStep(2, "Read the global attribute: FeatureMap"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), BooleanState::Id, BooleanState::Attributes::FeatureMap::Id, true, + LogStep(2, "TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, true, chip::NullOptional); } case 3: { - LogStep(3, "Read the global attribute: AttributeList"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), BooleanState::Id, BooleanState::Attributes::AttributeList::Id, - true, chip::NullOptional); + LogStep(3, + "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1. struct: Data field: D_OK_EMPTY : 1718"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::DataModel::List value; + + { + auto * listHolder_0 = new ListHolder(1); + listFreer.add(listHolder_0); + + listHolder_0->mList[0].data = + mDOkEmpty.HasValue() ? mDOkEmpty.Value() : chip::ByteSpan(chip::Uint8::from_const_char("\x17\x18"), 2); + listHolder_0->mList[0].fabricIndex = CurrentFabricIndex; + + value = chip::app::DataModel::List( + listHolder_0->mList, 1); + } + return WriteAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, + value, chip::NullOptional, chip::NullOptional); } case 4: { - LogStep(4, "Read the global attribute: AcceptedCommandList"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), BooleanState::Id, - BooleanState::Attributes::AcceptedCommandList::Id, true, chip::NullOptional); + LogStep(4, "TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, true, + chip::NullOptional); } case 5: { - LogStep(5, "Read the global attribute: GeneratedCommandList"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), BooleanState::Id, - BooleanState::Attributes::GeneratedCommandList::Id, true, chip::NullOptional); + LogStep(5, + "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1.struct Data field: D_OK_SINGLE " + ":17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E67206" + "17320612063686172737472696E670018"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::DataModel::List value; + + { + auto * listHolder_0 = new ListHolder(1); + listFreer.add(listHolder_0); + + listHolder_0->mList[0].data = mDOkSingle.HasValue() + ? mDOkSingle.Value() + : chip::ByteSpan( + chip::Uint8::from_const_char( + "\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54\x68\x69" + "\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x6C\x69\x76" + "\x69\x6E\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00\x18"), + 71); + listHolder_0->mList[0].fabricIndex = CurrentFabricIndex; + + value = chip::app::DataModel::List( + listHolder_0->mList, 1); + } + return WriteAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, + value, chip::NullOptional, chip::NullOptional); + } + case 6: { + LogStep(6, "TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, true, + chip::NullOptional); + } + case 7: { + LogStep(7, + "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1.struct Data field: D_OK_FULL " + ":17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E67206" + "17320612063686172737472696E6700D00000F1FF02003148656C6C6F20576F726C642E205468697320697320612073696E676C6520656" + "C656D656E7420616761696E2E2E2E2E2E0018"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::DataModel::List value; + + { + auto * listHolder_0 = new ListHolder(1); + listFreer.add(listHolder_0); + + listHolder_0->mList[0].data = mDOkFull.HasValue() + ? mDOkFull.Value() + : chip::ByteSpan(chip::Uint8::from_const_char( + "\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20" + "\x54\x68\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65" + "\x6E\x74\x20\x6C\x69\x76\x69\x6E\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72" + "\x69\x6E\x67\x00\xD0\x00\x00\xF1\xFF\x02\x00\x31\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C" + "\x64\x2E\x20\x54\x68\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C" + "\x65\x6D\x65\x6E\x74\x20\x61\x67\x61\x69\x6E\x2E\x2E\x2E\x2E\x2E\x00\x18"), + 128); + listHolder_0->mList[0].fabricIndex = CurrentFabricIndex; + + value = chip::app::DataModel::List( + listHolder_0->mList, 1); + } + return WriteAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, + value, chip::NullOptional, chip::NullOptional); + } + case 8: { + LogStep(8, "TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, true, + chip::NullOptional); + } + case 9: { + LogStep(9, + "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1 .struct Data field: D_BAD_LENGTH " + ":17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E67206" + "17320612063686172737472696E6700D00000F1FF02003248656C6C6F20576F726C642E205468697320697320612073696E676C6520656" + "C656D656E7420616761696E2E2E2E2E2E2E0018"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::DataModel::List value; + + { + auto * listHolder_0 = new ListHolder(1); + listFreer.add(listHolder_0); + + listHolder_0->mList[0].data = mDBadLength.HasValue() + ? mDBadLength.Value() + : chip::ByteSpan(chip::Uint8::from_const_char( + "\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20" + "\x54\x68\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65" + "\x6E\x74\x20\x6C\x69\x76\x69\x6E\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72" + "\x69\x6E\x67\x00\xD0\x00\x00\xF1\xFF\x02\x00\x32\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C" + "\x64\x2E\x20\x54\x68\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C" + "\x65\x6D\x65\x6E\x74\x20\x61\x67\x61\x69\x6E\x2E\x2E\x2E\x2E\x2E\x2E\x00\x18"), + 129); + listHolder_0->mList[0].fabricIndex = CurrentFabricIndex; + + value = chip::app::DataModel::List( + listHolder_0->mList, 1); + } + return WriteAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, + value, chip::NullOptional, chip::NullOptional); + } + case 10: { + LogStep(10, + "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1. struct Data field: D_BAD_STRUCT : 1518"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::DataModel::List value; + + { + auto * listHolder_0 = new ListHolder(1); + listFreer.add(listHolder_0); + + listHolder_0->mList[0].data = + mDBadStruct.HasValue() ? mDBadStruct.Value() : chip::ByteSpan(chip::Uint8::from_const_char("\x15\x18"), 2); + listHolder_0->mList[0].fabricIndex = CurrentFabricIndex; + + value = chip::app::DataModel::List( + listHolder_0->mList, 1); + } + return WriteAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, + value, chip::NullOptional, chip::NullOptional); + } + case 11: { + LogStep(11, + "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1. struct Data field: D_BAD_LIST " + ":3701D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E672" + "0617320612063686172737472696E670018"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::DataModel::List value; + + { + auto * listHolder_0 = new ListHolder(1); + listFreer.add(listHolder_0); + + listHolder_0->mList[0].data = mDBadList.HasValue() + ? mDBadList.Value() + : chip::ByteSpan( + chip::Uint8::from_const_char( + "\x37\x01\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54\x68" + "\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x6C\x69" + "\x76\x69\x6E\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00\x18"), + 72); + listHolder_0->mList[0].fabricIndex = CurrentFabricIndex; + + value = chip::app::DataModel::List( + listHolder_0->mList, 1); + } + return WriteAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, + value, chip::NullOptional, chip::NullOptional); + } + case 12: { + LogStep(12, + "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1. struct Data field: D_BAD_ELEM " + ":17103D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E67206173206120636" + "86172737472696E670018"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::DataModel::List value; + + { + auto * listHolder_0 = new ListHolder(1); + listFreer.add(listHolder_0); + + listHolder_0->mList[0].data = mDBadElem.HasValue() + ? mDBadElem.Value() + : chip::ByteSpan(chip::Uint8::from_const_char( + "\x17\x10\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54\x68\x69\x73\x20\x69" + "\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x6C\x69\x76" + "\x69\x6E\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00\x18"), + 65); + listHolder_0->mList[0].fabricIndex = CurrentFabricIndex; + + value = chip::app::DataModel::List( + listHolder_0->mList, 1); + } + return WriteAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, + value, chip::NullOptional, chip::NullOptional); + } + case 13: { + LogStep(13, + "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1 .struct Data field: D_BAD_OVERFLOW : " + "17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E672061" + "7320612063686172737472696E670018FF"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::DataModel::List value; + + { + auto * listHolder_0 = new ListHolder(1); + listFreer.add(listHolder_0); + + listHolder_0->mList[0].data = mDBadOverflow.HasValue() + ? mDBadOverflow.Value() + : chip::ByteSpan( + chip::Uint8::from_const_char( + "\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54\x68\x69" + "\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x6C\x69\x76" + "\x69\x6E\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00\x18\xFF"), + 72); + listHolder_0->mList[0].fabricIndex = CurrentFabricIndex; + + value = chip::app::DataModel::List( + listHolder_0->mList, 1); + } + return WriteAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, + value, chip::NullOptional, chip::NullOptional); + } + case 14: { + LogStep(14, + "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1. struct Data field: D_BAD_UNDERFLOW " + ":17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E67206" + "17320612063686172737472696E6700"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::DataModel::List value; + + { + auto * listHolder_0 = new ListHolder(1); + listFreer.add(listHolder_0); + + listHolder_0->mList[0].data = mDBadUnderflow.HasValue() + ? mDBadUnderflow.Value() + : chip::ByteSpan( + chip::Uint8::from_const_char( + "\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54\x68\x69" + "\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x6C\x69\x76" + "\x69\x6E\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00"), + 70); + listHolder_0->mList[0].fabricIndex = CurrentFabricIndex; + + value = chip::app::DataModel::List( + listHolder_0->mList, 1); + } + return WriteAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, + value, chip::NullOptional, chip::NullOptional); + } + case 15: { + LogStep(15, + "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1.struct Data field: D_BAD_NONE"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::DataModel::List value; + + { + auto * listHolder_0 = new ListHolder(1); + listFreer.add(listHolder_0); + + listHolder_0->mList[0].data = + mDBadNone.HasValue() ? mDBadNone.Value() : chip::ByteSpan(chip::Uint8::from_const_char(""), 0); + listHolder_0->mList[0].fabricIndex = CurrentFabricIndex; + + value = chip::app::DataModel::List( + listHolder_0->mList, 1); + } + return WriteAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, + value, chip::NullOptional, chip::NullOptional); + } + case 16: { + LogStep( + 16, + "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 2 elements . value is list of AccessControlExtensionStruct containing 2 " + "elements . first element contains Data field: D_OK_EMPTY 1718 . second element contains Data field: D_OK_SINGLE " + "17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320" + "612063686172737472696E670018"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::DataModel::List value; + + { + auto * listHolder_0 = new ListHolder(2); + listFreer.add(listHolder_0); + + listHolder_0->mList[0].data = + mDOkEmpty.HasValue() ? mDOkEmpty.Value() : chip::ByteSpan(chip::Uint8::from_const_char("\x17\x18"), 2); + listHolder_0->mList[0].fabricIndex = CurrentFabricIndex; + + listHolder_0->mList[1].data = mDOkSingle.HasValue() + ? mDOkSingle.Value() + : chip::ByteSpan( + chip::Uint8::from_const_char( + "\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54\x68\x69" + "\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x6C\x69\x76" + "\x69\x6E\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00\x18"), + 71); + listHolder_0->mList[1].fabricIndex = CurrentFabricIndex; + + value = chip::app::DataModel::List( + listHolder_0->mList, 2); + } + return WriteAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, + value, chip::NullOptional, chip::NullOptional); + } + case 17: { + LogStep(17, "TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, true, + chip::NullOptional); + } + case 18: { + LogStep(18, "TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is an empty list"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::DataModel::List value; + + value = chip::app::DataModel::List(); + return WriteAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, + value, chip::NullOptional, chip::NullOptional); + } + case 19: { + LogStep(19, "TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute"); + VerifyOrDo(!ShouldSkip("ACL.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), AccessControl::Id, AccessControl::Attributes::Extension::Id, true, + chip::NullOptional); } } return CHIP_NO_ERROR; } }; -class Test_TC_BOOL_2_1Suite : public TestCommand +class Test_TC_BOOL_1_1Suite : public TestCommand { public: - Test_TC_BOOL_2_1Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_BOOL_2_1", 2, credsIssuerConfig) + Test_TC_BOOL_1_1Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_BOOL_1_1", 6, credsIssuerConfig) { AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); AddArgument("cluster", &mCluster); @@ -2423,7 +2885,155 @@ class Test_TC_BOOL_2_1Suite : public TestCommand AddArgument("timeout", 0, UINT16_MAX, &mTimeout); } - ~Test_TC_BOOL_2_1Suite() {} + ~Test_TC_BOOL_1_1Suite() {} + + chip::System::Clock::Timeout GetWaitDuration() const override + { + return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); + } + +private: + chip::Optional mNodeId; + chip::Optional mCluster; + chip::Optional mEndpoint; + chip::Optional mTimeout; + + chip::EndpointId GetEndpoint(chip::EndpointId endpoint) { return mEndpoint.HasValue() ? mEndpoint.Value() : endpoint; } + + // + // Tests methods + // + + void OnResponse(const chip::app::StatusIB & status, chip::TLV::TLVReader * data) override + { + bool shouldContinue = false; + + switch (mTestIndex - 1) + { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + shouldContinue = true; + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint16_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("clusterRevision", value, 1U)); + VerifyOrReturn(CheckConstraintType("value", "int16u", "int16u")); + } + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint32_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("featureMap", value, 0UL)); + VerifyOrReturn(CheckConstraintType("value", "bitmap32", "bitmap32")); + } + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 0UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 65528UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 65529UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 65531UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 65532UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 65533UL)); + } + break; + case 4: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + { + auto iter_0 = value.begin(); + VerifyOrReturn(CheckNoMoreListItems("acceptedCommandList", iter_0, 0)); + } + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + } + break; + case 5: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + { + auto iter_0 = value.begin(); + VerifyOrReturn(CheckNoMoreListItems("generatedCommandList", iter_0, 0)); + } + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + } + break; + default: + LogErrorOnFailure(ContinueOnChipMainThread(CHIP_ERROR_INVALID_ARGUMENT)); + } + + if (shouldContinue) + { + ContinueOnChipMainThread(CHIP_NO_ERROR); + } + } + + CHIP_ERROR DoTestStep(uint16_t testIndex) override + { + using namespace chip::app::Clusters; + switch (testIndex) + { + case 0: { + LogStep(0, "Wait for the commissioned device to be retrieved"); + ListFreer listFreer; + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee(kIdentityAlpha, value); + } + case 1: { + LogStep(1, "read the global attribute: ClusterRevision"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), BooleanState::Id, BooleanState::Attributes::ClusterRevision::Id, + true, chip::NullOptional); + } + case 2: { + LogStep(2, "Read the global attribute: FeatureMap"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), BooleanState::Id, BooleanState::Attributes::FeatureMap::Id, true, + chip::NullOptional); + } + case 3: { + LogStep(3, "Read the global attribute: AttributeList"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), BooleanState::Id, BooleanState::Attributes::AttributeList::Id, + true, chip::NullOptional); + } + case 4: { + LogStep(4, "Read the global attribute: AcceptedCommandList"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), BooleanState::Id, + BooleanState::Attributes::AcceptedCommandList::Id, true, chip::NullOptional); + } + case 5: { + LogStep(5, "Read the global attribute: GeneratedCommandList"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), BooleanState::Id, + BooleanState::Attributes::GeneratedCommandList::Id, true, chip::NullOptional); + } + } + return CHIP_NO_ERROR; + } +}; + +class Test_TC_BOOL_2_1Suite : public TestCommand +{ +public: + Test_TC_BOOL_2_1Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_BOOL_2_1", 2, credsIssuerConfig) + { + AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); + AddArgument("cluster", &mCluster); + AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("timeout", 0, UINT16_MAX, &mTimeout); + } + + ~Test_TC_BOOL_2_1Suite() {} chip::System::Clock::Timeout GetWaitDuration() const override { @@ -2493,6 +3103,1281 @@ class Test_TC_BOOL_2_1Suite : public TestCommand } }; +class Test_TC_BRBINFO_1_1Suite : public TestCommand +{ +public: + Test_TC_BRBINFO_1_1Suite(CredentialIssuerCommands * credsIssuerConfig) : + TestCommand("Test_TC_BRBINFO_1_1", 20, credsIssuerConfig) + { + AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); + AddArgument("cluster", &mCluster); + AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("timeout", 0, UINT16_MAX, &mTimeout); + } + + ~Test_TC_BRBINFO_1_1Suite() {} + + chip::System::Clock::Timeout GetWaitDuration() const override + { + return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); + } + +private: + chip::Optional mNodeId; + chip::Optional mCluster; + chip::Optional mEndpoint; + chip::Optional mTimeout; + + chip::EndpointId GetEndpoint(chip::EndpointId endpoint) { return mEndpoint.HasValue() ? mEndpoint.Value() : endpoint; } + + // + // Tests methods + // + + void OnResponse(const chip::app::StatusIB & status, chip::TLV::TLVReader * data) override + { + bool shouldContinue = false; + + switch (mTestIndex - 1) + { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + shouldContinue = true; + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint16_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("clusterRevision", value, 1U)); + VerifyOrReturn(CheckConstraintType("value", "int16u", "int16u")); + } + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint32_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("featureMap", value, 0UL)); + VerifyOrReturn(CheckConstraintType("value", "bitmap32", "bitmap32")); + } + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 17UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 65528UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 65529UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 65531UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 65532UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 65533UL)); + } + break; + case 4: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 1UL)); + } + break; + case 5: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 2UL)); + } + break; + case 6: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 3UL)); + } + break; + case 7: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 5UL)); + } + break; + case 8: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 7UL)); + } + break; + case 9: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 8UL)); + } + break; + case 10: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 9UL)); + } + break; + case 11: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 10UL)); + } + break; + case 12: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 11UL)); + } + break; + case 13: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 12UL)); + } + break; + case 14: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 13UL)); + } + break; + case 15: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 14UL)); + } + break; + case 16: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 15UL)); + } + break; + case 17: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 18UL)); + } + break; + case 18: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + { + auto iter_0 = value.begin(); + VerifyOrReturn(CheckNoMoreListItems("acceptedCommandList", iter_0, 0)); + } + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + } + break; + case 19: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + { + auto iter_0 = value.begin(); + VerifyOrReturn(CheckNoMoreListItems("generatedCommandList", iter_0, 0)); + } + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + } + break; + default: + LogErrorOnFailure(ContinueOnChipMainThread(CHIP_ERROR_INVALID_ARGUMENT)); + } + + if (shouldContinue) + { + ContinueOnChipMainThread(CHIP_NO_ERROR); + } + } + + CHIP_ERROR DoTestStep(uint16_t testIndex) override + { + using namespace chip::app::Clusters; + switch (testIndex) + { + case 0: { + LogStep(0, "Wait for the commissioned device to be retrieved"); + ListFreer listFreer; + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee(kIdentityAlpha, value); + } + case 1: { + LogStep(1, "TH reads the ClusterRevision from DUT"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::ClusterRevision::Id, true, chip::NullOptional); + } + case 2: { + LogStep(2, "TH reads the FeatureMap from DUT"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::FeatureMap::Id, true, chip::NullOptional); + } + case 3: { + LogStep(3, "TH reads AttributeList from DUT"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 4: { + LogStep(4, "TH reads optional attribute(VendorName) in AttributeList"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 5: { + LogStep(5, "TH reads optional attribute(VendorID) in AttributeList"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0002"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 6: { + LogStep(6, "TH reads optional attribute(ProductName) in AttributeList"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0003"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 7: { + LogStep(7, "TH reads optional attribute(NodeLabel) in AttributeList"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0005"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 8: { + LogStep(8, "TH reads optional attribute(HardwareVersion) in AttributeList"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0007"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 9: { + LogStep(9, "TH reads optional attribute(HardwareVersionString) in AttributeList"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0008"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 10: { + LogStep(10, "TH reads optional attribute(SoftwareVersion) in AttributeList"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0009"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 11: { + LogStep(11, "TH reads optional attribute(SoftwareVersionString) in AttributeList"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000a"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 12: { + LogStep(12, "TH reads optional attribute(ManufacturingDate) in AttributeList"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000b"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 13: { + LogStep(13, "TH reads optional attribute(PartNumber) in AttributeList"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000c"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 14: { + LogStep(14, "TH reads optional attribute(ProductURL) in AttributeList"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000d"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 15: { + LogStep(15, "TH reads optional attribute(ProductLabel) in AttributeList"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000e"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 16: { + LogStep(16, "TH reads optional attribute(SerialNumber) in AttributeList"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000f"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 17: { + LogStep(17, "TH reads optional attribute(UniqueID) in AttributeList"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0012"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 18: { + LogStep(18, "TH1 reads AcceptedCommandList from DUT"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::AcceptedCommandList::Id, true, chip::NullOptional); + } + case 19: { + LogStep(19, "TH1 reads GeneratedCommandList from DUT"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::GeneratedCommandList::Id, true, chip::NullOptional); + } + } + return CHIP_NO_ERROR; + } +}; + +class Test_TC_BRBINFO_2_1Suite : public TestCommand +{ +public: + Test_TC_BRBINFO_2_1Suite(CredentialIssuerCommands * credsIssuerConfig) : + TestCommand("Test_TC_BRBINFO_2_1", 50, credsIssuerConfig) + { + AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); + AddArgument("cluster", &mCluster); + AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("timeout", 0, UINT16_MAX, &mTimeout); + } + + ~Test_TC_BRBINFO_2_1Suite() + { + if (VendorNameValueBuffer != nullptr) + { + chip::Platform::MemoryFree(VendorNameValueBuffer); + VendorNameValueBuffer = nullptr; + } + if (ProductNameValueBuffer != nullptr) + { + chip::Platform::MemoryFree(ProductNameValueBuffer); + ProductNameValueBuffer = nullptr; + } + if (NodeLabelValueBuffer != nullptr) + { + chip::Platform::MemoryFree(NodeLabelValueBuffer); + NodeLabelValueBuffer = nullptr; + } + if (HardwareVersionStringValueBuffer != nullptr) + { + chip::Platform::MemoryFree(HardwareVersionStringValueBuffer); + HardwareVersionStringValueBuffer = nullptr; + } + if (SoftwareVersionStringValueBuffer != nullptr) + { + chip::Platform::MemoryFree(SoftwareVersionStringValueBuffer); + SoftwareVersionStringValueBuffer = nullptr; + } + if (ManufacturingDateValueBuffer != nullptr) + { + chip::Platform::MemoryFree(ManufacturingDateValueBuffer); + ManufacturingDateValueBuffer = nullptr; + } + if (PartNumberValueBuffer != nullptr) + { + chip::Platform::MemoryFree(PartNumberValueBuffer); + PartNumberValueBuffer = nullptr; + } + if (ProductURLValueBuffer != nullptr) + { + chip::Platform::MemoryFree(ProductURLValueBuffer); + ProductURLValueBuffer = nullptr; + } + if (ProductLabelValueBuffer != nullptr) + { + chip::Platform::MemoryFree(ProductLabelValueBuffer); + ProductLabelValueBuffer = nullptr; + } + if (SerialNumberValueBuffer != nullptr) + { + chip::Platform::MemoryFree(SerialNumberValueBuffer); + SerialNumberValueBuffer = nullptr; + } + if (UniqueIDValueBuffer != nullptr) + { + chip::Platform::MemoryFree(UniqueIDValueBuffer); + UniqueIDValueBuffer = nullptr; + } + } + + chip::System::Clock::Timeout GetWaitDuration() const override + { + return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); + } + +private: + chip::Optional mNodeId; + chip::Optional mCluster; + chip::Optional mEndpoint; + chip::Optional mTimeout; + + char * VendorNameValueBuffer = nullptr; + chip::CharSpan VendorNameValue; + chip::VendorId VendorIDValue; + char * ProductNameValueBuffer = nullptr; + chip::CharSpan ProductNameValue; + char * NodeLabelValueBuffer = nullptr; + chip::CharSpan NodeLabelValue; + uint16_t HardwareVersionValue; + char * HardwareVersionStringValueBuffer = nullptr; + chip::CharSpan HardwareVersionStringValue; + uint32_t SoftwareVersionValue; + char * SoftwareVersionStringValueBuffer = nullptr; + chip::CharSpan SoftwareVersionStringValue; + char * ManufacturingDateValueBuffer = nullptr; + chip::CharSpan ManufacturingDateValue; + char * PartNumberValueBuffer = nullptr; + chip::CharSpan PartNumberValue; + char * ProductURLValueBuffer = nullptr; + chip::CharSpan ProductURLValue; + char * ProductLabelValueBuffer = nullptr; + chip::CharSpan ProductLabelValue; + char * SerialNumberValueBuffer = nullptr; + chip::CharSpan SerialNumberValue; + char * UniqueIDValueBuffer = nullptr; + chip::CharSpan UniqueIDValue; + + chip::EndpointId GetEndpoint(chip::EndpointId endpoint) { return mEndpoint.HasValue() ? mEndpoint.Value() : endpoint; } + + // + // Tests methods + // + + void OnResponse(const chip::app::StatusIB & status, chip::TLV::TLVReader * data) override + { + bool shouldContinue = false; + + switch (mTestIndex - 1) + { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + shouldContinue = true; + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "char_string", "char_string")); + VerifyOrReturn(CheckConstraintMaxLength("value", value, 32)); + if (VendorNameValueBuffer != nullptr) + { + chip::Platform::MemoryFree(VendorNameValueBuffer); + } + VendorNameValueBuffer = static_cast(chip::Platform::MemoryAlloc(value.size())); + memcpy(VendorNameValueBuffer, value.data(), value.size()); + VendorNameValue = chip::CharSpan(VendorNameValueBuffer, value.size()); + } + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_WRITE)); + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValueAsString("vendorName", value, VendorNameValue)); + } + break; + case 4: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::VendorId value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "vendor_id", "vendor_id")); + VerifyOrReturn(CheckConstraintMinValue("value", value, 1U)); + VerifyOrReturn(CheckConstraintMaxValue("value", value, 65521U)); + VendorIDValue = value; + } + break; + case 5: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + shouldContinue = true; + break; + case 6: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_WRITE)); + break; + case 7: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::VendorId value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("vendorID", value, VendorIDValue)); + } + break; + case 8: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "char_string", "char_string")); + VerifyOrReturn(CheckConstraintMaxLength("value", value, 32)); + if (ProductNameValueBuffer != nullptr) + { + chip::Platform::MemoryFree(ProductNameValueBuffer); + } + ProductNameValueBuffer = static_cast(chip::Platform::MemoryAlloc(value.size())); + memcpy(ProductNameValueBuffer, value.data(), value.size()); + ProductNameValue = chip::CharSpan(ProductNameValueBuffer, value.size()); + } + break; + case 9: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_WRITE)); + break; + case 10: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValueAsString("productName", value, ProductNameValue)); + } + break; + case 11: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "char_string", "char_string")); + VerifyOrReturn(CheckConstraintMaxLength("value", value, 32)); + if (NodeLabelValueBuffer != nullptr) + { + chip::Platform::MemoryFree(NodeLabelValueBuffer); + } + NodeLabelValueBuffer = static_cast(chip::Platform::MemoryAlloc(value.size())); + memcpy(NodeLabelValueBuffer, value.data(), value.size()); + NodeLabelValue = chip::CharSpan(NodeLabelValueBuffer, value.size()); + } + break; + case 12: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + shouldContinue = true; + break; + case 13: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + shouldContinue = true; + break; + case 14: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint16_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "int16u", "int16u")); + VerifyOrReturn(CheckConstraintMinValue("value", value, 0U)); + VerifyOrReturn(CheckConstraintMaxValue("value", value, 65534U)); + HardwareVersionValue = value; + } + break; + case 15: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_WRITE)); + break; + case 16: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint16_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("hardwareVersion", value, HardwareVersionValue)); + } + break; + case 17: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "char_string", "char_string")); + VerifyOrReturn(CheckConstraintMinLength("value", value, 1)); + VerifyOrReturn(CheckConstraintMaxLength("value", value, 64)); + if (HardwareVersionStringValueBuffer != nullptr) + { + chip::Platform::MemoryFree(HardwareVersionStringValueBuffer); + } + HardwareVersionStringValueBuffer = static_cast(chip::Platform::MemoryAlloc(value.size())); + memcpy(HardwareVersionStringValueBuffer, value.data(), value.size()); + HardwareVersionStringValue = chip::CharSpan(HardwareVersionStringValueBuffer, value.size()); + } + break; + case 18: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_WRITE)); + break; + case 19: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValueAsString("hardwareVersionString", value, HardwareVersionStringValue)); + } + break; + case 20: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint32_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintMinValue("value", value, 0UL)); + VerifyOrReturn(CheckConstraintMaxValue("value", value, 4294967294UL)); + SoftwareVersionValue = value; + } + break; + case 21: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_WRITE)); + break; + case 22: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint32_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("softwareVersion", value, SoftwareVersionValue)); + } + break; + case 23: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintMinLength("value", value, 1)); + VerifyOrReturn(CheckConstraintMaxLength("value", value, 64)); + if (SoftwareVersionStringValueBuffer != nullptr) + { + chip::Platform::MemoryFree(SoftwareVersionStringValueBuffer); + } + SoftwareVersionStringValueBuffer = static_cast(chip::Platform::MemoryAlloc(value.size())); + memcpy(SoftwareVersionStringValueBuffer, value.data(), value.size()); + SoftwareVersionStringValue = chip::CharSpan(SoftwareVersionStringValueBuffer, value.size()); + } + break; + case 24: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_WRITE)); + break; + case 25: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValueAsString("softwareVersionString", value, SoftwareVersionStringValue)); + } + break; + case 26: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "char_string", "char_string")); + VerifyOrReturn(CheckConstraintMinLength("value", value, 8)); + VerifyOrReturn(CheckConstraintMaxLength("value", value, 16)); + if (ManufacturingDateValueBuffer != nullptr) + { + chip::Platform::MemoryFree(ManufacturingDateValueBuffer); + } + ManufacturingDateValueBuffer = static_cast(chip::Platform::MemoryAlloc(value.size())); + memcpy(ManufacturingDateValueBuffer, value.data(), value.size()); + ManufacturingDateValue = chip::CharSpan(ManufacturingDateValueBuffer, value.size()); + } + break; + case 27: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + shouldContinue = true; + break; + case 28: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_WRITE)); + break; + case 29: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValueAsString("manufacturingDate", value, ManufacturingDateValue)); + } + break; + case 30: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "char_string", "char_string")); + VerifyOrReturn(CheckConstraintMaxLength("value", value, 32)); + if (PartNumberValueBuffer != nullptr) + { + chip::Platform::MemoryFree(PartNumberValueBuffer); + } + PartNumberValueBuffer = static_cast(chip::Platform::MemoryAlloc(value.size())); + memcpy(PartNumberValueBuffer, value.data(), value.size()); + PartNumberValue = chip::CharSpan(PartNumberValueBuffer, value.size()); + } + break; + case 31: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_WRITE)); + break; + case 32: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValueAsString("partNumber", value, PartNumberValue)); + } + break; + case 33: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "long_char_string", "long_char_string")); + VerifyOrReturn(CheckConstraintMaxLength("value", value, 256)); + if (ProductURLValueBuffer != nullptr) + { + chip::Platform::MemoryFree(ProductURLValueBuffer); + } + ProductURLValueBuffer = static_cast(chip::Platform::MemoryAlloc(value.size())); + memcpy(ProductURLValueBuffer, value.data(), value.size()); + ProductURLValue = chip::CharSpan(ProductURLValueBuffer, value.size()); + } + break; + case 34: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + shouldContinue = true; + break; + case 35: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_WRITE)); + break; + case 36: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValueAsString("productURL", value, ProductURLValue)); + } + break; + case 37: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "char_string", "char_string")); + VerifyOrReturn(CheckConstraintMaxLength("value", value, 64)); + if (ProductLabelValueBuffer != nullptr) + { + chip::Platform::MemoryFree(ProductLabelValueBuffer); + } + ProductLabelValueBuffer = static_cast(chip::Platform::MemoryAlloc(value.size())); + memcpy(ProductLabelValueBuffer, value.data(), value.size()); + ProductLabelValue = chip::CharSpan(ProductLabelValueBuffer, value.size()); + } + break; + case 38: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + shouldContinue = true; + break; + case 39: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_WRITE)); + break; + case 40: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValueAsString("productLabel", value, ProductLabelValue)); + } + break; + case 41: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "char_string", "char_string")); + VerifyOrReturn(CheckConstraintMaxLength("value", value, 32)); + if (SerialNumberValueBuffer != nullptr) + { + chip::Platform::MemoryFree(SerialNumberValueBuffer); + } + SerialNumberValueBuffer = static_cast(chip::Platform::MemoryAlloc(value.size())); + memcpy(SerialNumberValueBuffer, value.data(), value.size()); + SerialNumberValue = chip::CharSpan(SerialNumberValueBuffer, value.size()); + } + break; + case 42: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_WRITE)); + break; + case 43: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValueAsString("serialNumber", value, SerialNumberValue)); + } + break; + case 44: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + bool value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("reachable", value, true)); + VerifyOrReturn(CheckConstraintType("value", "boolean", "boolean")); + } + break; + case 45: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_WRITE)); + break; + case 46: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + bool value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("reachable", value, true)); + VerifyOrReturn(CheckConstraintType("value", "boolean", "boolean")); + } + break; + case 47: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "char_string", "char_string")); + VerifyOrReturn(CheckConstraintMaxLength("value", value, 32)); + if (UniqueIDValueBuffer != nullptr) + { + chip::Platform::MemoryFree(UniqueIDValueBuffer); + } + UniqueIDValueBuffer = static_cast(chip::Platform::MemoryAlloc(value.size())); + memcpy(UniqueIDValueBuffer, value.data(), value.size()); + UniqueIDValue = chip::CharSpan(UniqueIDValueBuffer, value.size()); + } + break; + case 48: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_WRITE)); + break; + case 49: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::CharSpan value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValueAsString("uniqueID", value, UniqueIDValue)); + } + break; + default: + LogErrorOnFailure(ContinueOnChipMainThread(CHIP_ERROR_INVALID_ARGUMENT)); + } + + if (shouldContinue) + { + ContinueOnChipMainThread(CHIP_NO_ERROR); + } + } + + CHIP_ERROR DoTestStep(uint16_t testIndex) override + { + using namespace chip::app::Clusters; + switch (testIndex) + { + case 0: { + LogStep(0, "Wait for the commissioned device to be retrieved"); + ListFreer listFreer; + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee(kIdentityAlpha, value); + } + case 1: { + LogStep(1, "TH reads VendorName from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::VendorName::Id, true, chip::NullOptional); + } + case 2: { + LogStep(2, "TH writes VendorName from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::CharSpan value; + value = chip::Span("samplegarbage: not in length on purpose", 6); + return WriteAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::VendorName::Id, value, chip::NullOptional, chip::NullOptional); + } + case 3: { + LogStep(3, "TH reads VendorName from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0001"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::VendorName::Id, true, chip::NullOptional); + } + case 4: { + LogStep(4, "TH reads VendorID from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0002"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::VendorID::Id, true, chip::NullOptional); + } + case 5: { + LogStep(5, "Verify that VendorID matches the value assigned to this manufacturer"); + VerifyOrDo(!ShouldSkip("PICS_USER_PROMPT && BRBINFO.S.A0002"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; + value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); + value.expectedValue.Emplace(); + value.expectedValue.Value() = chip::Span("ygarbage: not in length on purpose", 1); + return UserPrompt(kIdentityAlpha, value); + } + case 6: { + LogStep(6, "TH writes VendorID from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0002"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::VendorId value; + value = static_cast(17); + return WriteAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::VendorID::Id, value, chip::NullOptional, chip::NullOptional); + } + case 7: { + LogStep(7, "TH reads VendorID from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0002"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::VendorID::Id, true, chip::NullOptional); + } + case 8: { + LogStep(8, "TH reads ProductName from the DUT"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0003"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::ProductName::Id, true, chip::NullOptional); + } + case 9: { + LogStep(9, "TH writes ProductName from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0003"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::CharSpan value; + value = chip::Span("newproductgarbage: not in length on purpose", 10); + return WriteAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::ProductName::Id, value, chip::NullOptional, chip::NullOptional); + } + case 10: { + LogStep(10, "TH reads ProductName from the DUT"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0003"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::ProductName::Id, true, chip::NullOptional); + } + case 11: { + LogStep(11, "TH reads NodeLabel from the DUT"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0005"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::NodeLabel::Id, true, chip::NullOptional); + } + case 12: { + LogStep(12, "TH writes NodeLabel from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0005 && PICS_USER_PROMPT"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; + value.message = chip::Span("Please enter 'y' after successgarbage: not in length on purpose", 30); + value.expectedValue.Emplace(); + value.expectedValue.Value() = chip::Span("ygarbage: not in length on purpose", 1); + return UserPrompt(kIdentityAlpha, value); + } + case 13: { + LogStep(13, "TH reads NodeLabel from the DUT"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0005 && PICS_USER_PROMPT"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; + value.message = chip::Span("Please enter 'y' after successgarbage: not in length on purpose", 30); + value.expectedValue.Emplace(); + value.expectedValue.Value() = chip::Span("ygarbage: not in length on purpose", 1); + return UserPrompt(kIdentityAlpha, value); + } + case 14: { + LogStep(14, "TH reads HardwareVersion from the DUT"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0007"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::HardwareVersion::Id, true, chip::NullOptional); + } + case 15: { + LogStep(15, "TH writes HardwareVersion from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0007"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + uint16_t value; + value = 17713U; + return WriteAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::HardwareVersion::Id, value, chip::NullOptional, + chip::NullOptional); + } + case 16: { + LogStep(16, "TH reads HardwareVersion from the DUT"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0007"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::HardwareVersion::Id, true, chip::NullOptional); + } + case 17: { + LogStep(17, "TH reads HardwareVersionString from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0008"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::HardwareVersionString::Id, true, chip::NullOptional); + } + case 18: { + LogStep(18, "TH writes HardwareVersionString from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0008"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::CharSpan value; + value = chip::Span("newhardwareversiongarbage: not in length on purpose", 18); + return WriteAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::HardwareVersionString::Id, value, chip::NullOptional, + chip::NullOptional); + } + case 19: { + LogStep(19, "TH reads HardwareVersionString from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0008"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::HardwareVersionString::Id, true, chip::NullOptional); + } + case 20: { + LogStep(20, "TH reads SoftwareVersion from the DUT"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0009"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::SoftwareVersion::Id, true, chip::NullOptional); + } + case 21: { + LogStep(21, "TH writes SoftwareVersion from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0009"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + uint32_t value; + value = 33299UL; + return WriteAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::SoftwareVersion::Id, value, chip::NullOptional, + chip::NullOptional); + } + case 22: { + LogStep(22, "TH reads SoftwareVersion from the DUT"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0009"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::SoftwareVersion::Id, true, chip::NullOptional); + } + case 23: { + LogStep(23, "TH reads SoftwareVersionString from the DUT"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000a"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::SoftwareVersionString::Id, true, chip::NullOptional); + } + case 24: { + LogStep(24, "TH writes SoftwareVersionString from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000a"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::CharSpan value; + value = chip::Span("1.0garbage: not in length on purpose", 3); + return WriteAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::SoftwareVersionString::Id, value, chip::NullOptional, + chip::NullOptional); + } + case 25: { + LogStep(25, "TH reads SoftwareVersionString from the DUT"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000a"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::SoftwareVersionString::Id, true, chip::NullOptional); + } + case 26: { + LogStep(26, "TH reads ManufacturingDate from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000b"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::ManufacturingDate::Id, true, chip::NullOptional); + } + case 27: { + LogStep(27, "Verify if the first 8 characters specify date according to ISO 8601, i.e, YYYYMMDD."); + VerifyOrDo(!ShouldSkip("PICS_USER_PROMPT && BRBINFO.S.A000b"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; + value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); + value.expectedValue.Emplace(); + value.expectedValue.Value() = chip::Span("ygarbage: not in length on purpose", 1); + return UserPrompt(kIdentityAlpha, value); + } + case 28: { + LogStep(28, "TH writes ManufacturingDate from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000b"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::CharSpan value; + value = chip::Span("20210814789452INgarbage: not in length on purpose", 16); + return WriteAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::ManufacturingDate::Id, value, chip::NullOptional, + chip::NullOptional); + } + case 29: { + LogStep(29, "TH reads ManufacturingDate from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000b"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::ManufacturingDate::Id, true, chip::NullOptional); + } + case 30: { + LogStep(30, "TH reads PartNumber from the DUT"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000c"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::PartNumber::Id, true, chip::NullOptional); + } + case 31: { + LogStep(31, "TH writes PartNumber from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000c"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::CharSpan value; + value = chip::Span("newpartgarbage: not in length on purpose", 7); + return WriteAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::PartNumber::Id, value, chip::NullOptional, chip::NullOptional); + } + case 32: { + LogStep(32, "TH reads PartNumber from the DUT"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000c"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::PartNumber::Id, true, chip::NullOptional); + } + case 33: { + LogStep(33, "TH reads ProductURL from the DUT"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000d"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::ProductURL::Id, true, chip::NullOptional); + } + case 34: { + LogStep(34, + "Verify that it specifies a link to a specific web page, Verify that it follows the syntax rules specified in " + "RFC 3986."); + VerifyOrDo(!ShouldSkip("PICS_USER_PROMPT && BRBINFO.S.A000d"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; + value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); + value.expectedValue.Emplace(); + value.expectedValue.Value() = chip::Span("ygarbage: not in length on purpose", 1); + return UserPrompt(kIdentityAlpha, value); + } + case 35: { + LogStep(35, "TH writes ProductURL from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000d"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::CharSpan value; + value = chip::Span("https://www.example.comgarbage: not in length on purpose", 23); + return WriteAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::ProductURL::Id, value, chip::NullOptional, chip::NullOptional); + } + case 36: { + LogStep(36, "TH reads ProductURL from the DUT"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000d"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::ProductURL::Id, true, chip::NullOptional); + } + case 37: { + LogStep(37, "TH reads ProductLabel from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000e"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::ProductLabel::Id, true, chip::NullOptional); + } + case 38: { + LogStep(38, "Verify that it does not include the name of the vendor as defined within the VendorName attribute"); + VerifyOrDo(!ShouldSkip("PICS_USER_PROMPT && BRBINFO.S.A000e"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; + value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); + value.expectedValue.Emplace(); + value.expectedValue.Value() = chip::Span("ygarbage: not in length on purpose", 1); + return UserPrompt(kIdentityAlpha, value); + } + case 39: { + LogStep(39, "TH writes ProductLabel from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000e"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::CharSpan value; + value = chip::Span("newproductlabelgarbage: not in length on purpose", 15); + return WriteAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::ProductLabel::Id, value, chip::NullOptional, chip::NullOptional); + } + case 40: { + LogStep(40, "TH reads ProductLabel from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000e"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::ProductLabel::Id, true, chip::NullOptional); + } + case 41: { + LogStep(41, "TH reads SerialNumber from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000f"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::SerialNumber::Id, true, chip::NullOptional); + } + case 42: { + LogStep(42, "TH writes SerialNumber from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000f"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::CharSpan value; + value = chip::Span("newserialnumbergarbage: not in length on purpose", 15); + return WriteAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::SerialNumber::Id, value, chip::NullOptional, chip::NullOptional); + } + case 43: { + LogStep(43, "TH reads SerialNumber from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A000f"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::SerialNumber::Id, true, chip::NullOptional); + } + case 44: { + LogStep(44, "TH reads Reachable from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0011"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::Reachable::Id, true, chip::NullOptional); + } + case 45: { + LogStep(45, "TH sends Write request message to DUT to change value of Reachable to false"); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0011"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + bool value; + value = false; + return WriteAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::Reachable::Id, value, chip::NullOptional, chip::NullOptional); + } + case 46: { + LogStep(46, "TH reads Reachable from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0011"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::Reachable::Id, true, chip::NullOptional); + } + case 47: { + LogStep(47, "TH reads UniqueID from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0012"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::UniqueID::Id, true, chip::NullOptional); + } + case 48: { + LogStep(48, "TH writes UniqueID from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0012"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::CharSpan value; + value = chip::Span("newidgarbage: not in length on purpose", 5); + return WriteAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::UniqueID::Id, value, chip::NullOptional, chip::NullOptional); + } + case 49: { + LogStep(49, "TH reads UniqueID from the DUT."); + VerifyOrDo(!ShouldSkip("BRBINFO.S.A0012"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), BridgedDeviceBasic::Id, + BridgedDeviceBasic::Attributes::UniqueID::Id, true, chip::NullOptional); + } + } + return CHIP_NO_ERROR; + } +}; + class Test_TC_ACT_1_1Suite : public TestCommand { public: @@ -13446,7 +15331,7 @@ class Test_TC_BINFO_2_1Suite : public TestCommand class Test_TC_CNET_1_3Suite : public TestCommand { public: - Test_TC_CNET_1_3Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_CNET_1_3", 0, credsIssuerConfig) + Test_TC_CNET_1_3Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_CNET_1_3", 16, credsIssuerConfig) { AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); AddArgument("cluster", &mCluster); @@ -13479,6 +15364,159 @@ class Test_TC_CNET_1_3Suite : public TestCommand switch (mTestIndex - 1) { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + shouldContinue = true; + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint16_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("clusterRevision", value, 1U)); + VerifyOrReturn(CheckConstraintType("value", "int16u", "int16u")); + } + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint32_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("featureMap", value, 0UL)); + } + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint32_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("featureMap", value, 1UL)); + } + break; + case 4: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint32_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("featureMap", value, 2UL)); + } + break; + case 5: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint32_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("featureMap", value, 4UL)); + } + break; + case 6: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 65528UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 65529UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 65531UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 65532UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 65533UL)); + } + break; + case 7: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 0UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 1UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 4UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 5UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 6UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 7UL)); + } + break; + case 8: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 2UL)); + } + break; + case 9: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 3UL)); + } + break; + case 10: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 0UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 4UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 6UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 8UL)); + } + break; + case 11: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 2UL)); + } + break; + case 12: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 3UL)); + } + break; + case 13: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + { + auto iter_0 = value.begin(); + VerifyOrReturn(CheckNoMoreListItems("acceptedCommandList", iter_0, 0)); + } + } + break; + case 14: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "list", "list")); + VerifyOrReturn(CheckConstraintContains("value", value, 1UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 5UL)); + VerifyOrReturn(CheckConstraintContains("value", value, 7UL)); + } + break; + case 15: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + { + auto iter_0 = value.begin(); + VerifyOrReturn(CheckNoMoreListItems("generatedCommandList", iter_0, 0)); + } + } + break; default: LogErrorOnFailure(ContinueOnChipMainThread(CHIP_ERROR_INVALID_ARGUMENT)); } @@ -13494,6 +15532,103 @@ class Test_TC_CNET_1_3Suite : public TestCommand using namespace chip::app::Clusters; switch (testIndex) { + case 0: { + LogStep(0, "Wait for the commissioned device to be retrieved"); + ListFreer listFreer; + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee(kIdentityAlpha, value); + } + case 1: { + LogStep(1, "Read the global attribute: ClusterRevision"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), NetworkCommissioning::Id, + NetworkCommissioning::Attributes::ClusterRevision::Id, true, chip::NullOptional); + } + case 2: { + LogStep(2, "Read the global attribute: FeatureMap"); + VerifyOrDo(!ShouldSkip(" !CNET.S.F00 && !CNET.S.F01 && !CNET.S.F02 "), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), NetworkCommissioning::Id, + NetworkCommissioning::Attributes::FeatureMap::Id, true, chip::NullOptional); + } + case 3: { + LogStep(3, "Read the global attribute: FeatureMap when CNET.S.F00 is set"); + VerifyOrDo(!ShouldSkip("CNET.S.F00"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), NetworkCommissioning::Id, + NetworkCommissioning::Attributes::FeatureMap::Id, true, chip::NullOptional); + } + case 4: { + LogStep(4, "Read the global attribute: FeatureMap when CNET.S.F01 is set"); + VerifyOrDo(!ShouldSkip("CNET.S.F01"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), NetworkCommissioning::Id, + NetworkCommissioning::Attributes::FeatureMap::Id, true, chip::NullOptional); + } + case 5: { + LogStep(5, "Read the global attribute: FeatureMap when CNET.S.F02 is set"); + VerifyOrDo(!ShouldSkip("CNET.S.F02"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), NetworkCommissioning::Id, + NetworkCommissioning::Attributes::FeatureMap::Id, true, chip::NullOptional); + } + case 6: { + LogStep(6, "Read the global attribute: AttributeList"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), NetworkCommissioning::Id, + NetworkCommissioning::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 7: { + LogStep(7, "Read mandatory attributes in AttributeList if CNET.S.F00(WI)/CNET.S.F01(TH)/CNET.S.F02(ET) is true"); + VerifyOrDo(!ShouldSkip("CNET.S.F00 || CNET.S.F01 || CNET.S.F02"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), NetworkCommissioning::Id, + NetworkCommissioning::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 8: { + LogStep(8, "Read the optional attribute(ScanMaxTimeSeconds): AttributeList"); + VerifyOrDo(!ShouldSkip("CNET.S.A0002"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), NetworkCommissioning::Id, + NetworkCommissioning::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 9: { + LogStep(9, "Reading optional attribute(ConnectMaxTimeSeconds) in AttributeList"); + VerifyOrDo(!ShouldSkip("CNET.S.A0003"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), NetworkCommissioning::Id, + NetworkCommissioning::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 10: { + LogStep(10, "Read AcceptedCommandList If DUT supports Wi-Fi/Thread related features CNET.S.F00(WI),CNET.S.F01(TH)"); + VerifyOrDo(!ShouldSkip("CNET.S.F00 || CNET.S.F01"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), NetworkCommissioning::Id, + NetworkCommissioning::Attributes::AcceptedCommandList::Id, true, chip::NullOptional); + } + case 11: { + LogStep(11, "Read AcceptedCommandList If DUT supports Wi-Fi related features (CNET.S.F00(WI) is true)"); + VerifyOrDo(!ShouldSkip("CNET.S.F00"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), NetworkCommissioning::Id, + NetworkCommissioning::Attributes::AcceptedCommandList::Id, true, chip::NullOptional); + } + case 12: { + LogStep(12, "Read AcceptedCommandList If DUT supports Thread related features(CNET.S.F01(TH) is true)"); + VerifyOrDo(!ShouldSkip("CNET.S.F01"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), NetworkCommissioning::Id, + NetworkCommissioning::Attributes::AcceptedCommandList::Id, true, chip::NullOptional); + } + case 13: { + LogStep(13, "Read AcceptedCommandList If DUT supports Ethernet related features(CNET.S.F02(TH) is true)"); + VerifyOrDo(!ShouldSkip("CNET.S.F02"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), NetworkCommissioning::Id, + NetworkCommissioning::Attributes::AcceptedCommandList::Id, true, chip::NullOptional); + } + case 14: { + LogStep(14, + "Read the GeneratedCommandList If DUT supports Wi-Fi/Thread related features(CNET.S.F00(WI) or CNET.S.F01(TH) " + "is true)"); + VerifyOrDo(!ShouldSkip("CNET.S.F00 || CNET.S.F01"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), NetworkCommissioning::Id, + NetworkCommissioning::Attributes::GeneratedCommandList::Id, true, chip::NullOptional); + } + case 15: { + LogStep(15, "Read the GeneratedCommandList If DUT supports Ethernet related features(CNET.S.F02(ET) must be true)"); + VerifyOrDo(!ShouldSkip("CNET.S.F02"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(0), NetworkCommissioning::Id, + NetworkCommissioning::Attributes::GeneratedCommandList::Id, true, chip::NullOptional); + } } return CHIP_NO_ERROR; } @@ -23484,29 +25619,193 @@ class Test_TC_ALOGIN_1_12Suite : public TestCommand return WaitForCommissionee(kIdentityAlpha, value); } case 1: { - LogStep(1, "Read the global attribute: ClusterRevision"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(3), AccountLogin::Id, AccountLogin::Attributes::ClusterRevision::Id, - true, chip::NullOptional); + LogStep(1, "Read the global attribute: ClusterRevision"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), AccountLogin::Id, AccountLogin::Attributes::ClusterRevision::Id, + true, chip::NullOptional); + } + case 2: { + LogStep(2, "Read the global attribute: FeatureMap"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), AccountLogin::Id, AccountLogin::Attributes::FeatureMap::Id, true, + chip::NullOptional); + } + case 3: { + LogStep(3, "Read the global attribute: AttributeList"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), AccountLogin::Id, AccountLogin::Attributes::AttributeList::Id, + true, chip::NullOptional); + } + case 4: { + LogStep(4, "Read the global attribute: AcceptedCommandList"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), AccountLogin::Id, + AccountLogin::Attributes::AcceptedCommandList::Id, true, chip::NullOptional); + } + case 5: { + LogStep(5, "Read the global attribute: GeneratedCommandList"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(3), AccountLogin::Id, + AccountLogin::Attributes::GeneratedCommandList::Id, true, chip::NullOptional); + } + } + return CHIP_NO_ERROR; + } +}; + +class Test_TC_ALOGIN_12_1Suite : public TestCommand +{ +public: + Test_TC_ALOGIN_12_1Suite(CredentialIssuerCommands * credsIssuerConfig) : + TestCommand("Test_TC_ALOGIN_12_1", 5, credsIssuerConfig) + { + AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); + AddArgument("cluster", &mCluster); + AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("TempAccountIdentifier", &mTempAccountIdentifier); + AddArgument("catalogVendorId", 0, UINT16_MAX, &mCatalogVendorId); + AddArgument("applicationId", &mApplicationId); + AddArgument("timeout", 0, UINT16_MAX, &mTimeout); + } + + ~Test_TC_ALOGIN_12_1Suite() + { + if (setupPINBuffer != nullptr) + { + chip::Platform::MemoryFree(setupPINBuffer); + setupPINBuffer = nullptr; + } + } + + chip::System::Clock::Timeout GetWaitDuration() const override + { + return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); + } + +private: + chip::Optional mNodeId; + chip::Optional mCluster; + chip::Optional mEndpoint; + chip::Optional mTempAccountIdentifier; + chip::Optional mCatalogVendorId; + chip::Optional mApplicationId; + chip::Optional mTimeout; + + char * setupPINBuffer = nullptr; + chip::CharSpan setupPIN; + + chip::EndpointId GetEndpoint(chip::EndpointId endpoint) { return mEndpoint.HasValue() ? mEndpoint.Value() : endpoint; } + + // + // Tests methods + // + + void OnResponse(const chip::app::StatusIB & status, chip::TLV::TLVReader * data) override + { + bool shouldContinue = false; + + switch (mTestIndex - 1) + { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + shouldContinue = true; + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::Clusters::ApplicationLauncher::Commands::LauncherResponse::DecodableType value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("status", value.status, 0U)); + } + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::Clusters::AccountLogin::Commands::GetSetupPINResponse::DecodableType value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + if (setupPINBuffer != nullptr) + { + chip::Platform::MemoryFree(setupPINBuffer); + } + setupPINBuffer = static_cast(chip::Platform::MemoryAlloc(value.setupPIN.size())); + memcpy(setupPINBuffer, value.setupPIN.data(), value.setupPIN.size()); + setupPIN = chip::CharSpan(setupPINBuffer, value.setupPIN.size()); + } + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 4: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + default: + LogErrorOnFailure(ContinueOnChipMainThread(CHIP_ERROR_INVALID_ARGUMENT)); + } + + if (shouldContinue) + { + ContinueOnChipMainThread(CHIP_NO_ERROR); + } + } + + CHIP_ERROR DoTestStep(uint16_t testIndex) override + { + using namespace chip::app::Clusters; + switch (testIndex) + { + case 0: { + LogStep(0, "Wait for the commissioned device to be retrieved"); + ListFreer listFreer; + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee(kIdentityAlpha, value); + } + case 1: { + LogStep(1, "Launch an app with the provided a application ID"); + VerifyOrDo(!ShouldSkip("APPLAUNCHER.S.C00.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::ApplicationLauncher::Commands::LaunchApp::Type value; + + value.application.catalogVendorId = mCatalogVendorId.HasValue() ? mCatalogVendorId.Value() : 123U; + value.application.applicationId = + mApplicationId.HasValue() ? mApplicationId.Value() : chip::Span("exampleid", 9); + + value.data.Emplace(); + value.data.Value() = chip::ByteSpan(chip::Uint8::from_const_char("Hello Worldgarbage: not in length on purpose"), 11); + return SendCommand(kIdentityAlpha, GetEndpoint(3), ApplicationLauncher::Id, + ApplicationLauncher::Commands::LaunchApp::Id, value, chip::NullOptional + + ); } case 2: { - LogStep(2, "Read the global attribute: FeatureMap"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(3), AccountLogin::Id, AccountLogin::Attributes::FeatureMap::Id, true, - chip::NullOptional); + LogStep(2, "TH sends a GetSetupPIN command to the DUT with test values provided by the product maker."); + VerifyOrDo(!ShouldSkip("ALOGIN.S.C00.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::AccountLogin::Commands::GetSetupPIN::Type value; + value.tempAccountIdentifier = + mTempAccountIdentifier.HasValue() ? mTempAccountIdentifier.Value() : chip::Span("1111", 4); + return SendCommand(kIdentityAlpha, GetEndpoint(3), AccountLogin::Id, AccountLogin::Commands::GetSetupPIN::Id, value, + chip::Optional(10000), chip::NullOptional + + ); } case 3: { - LogStep(3, "Read the global attribute: AttributeList"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(3), AccountLogin::Id, AccountLogin::Attributes::AttributeList::Id, - true, chip::NullOptional); + LogStep(3, "TH sends a Login command to the DUT with test values provided by the product maker."); + VerifyOrDo(!ShouldSkip("ALOGIN.S.C02.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::AccountLogin::Commands::Login::Type value; + value.tempAccountIdentifier = + mTempAccountIdentifier.HasValue() ? mTempAccountIdentifier.Value() : chip::Span("1111", 4); + value.setupPIN = setupPIN; + return SendCommand(kIdentityAlpha, GetEndpoint(3), AccountLogin::Id, AccountLogin::Commands::Login::Id, value, + chip::Optional(10000), chip::NullOptional + + ); } case 4: { - LogStep(4, "Read the global attribute: AcceptedCommandList"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(3), AccountLogin::Id, - AccountLogin::Attributes::AcceptedCommandList::Id, true, chip::NullOptional); - } - case 5: { - LogStep(5, "Read the global attribute: GeneratedCommandList"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(3), AccountLogin::Id, - AccountLogin::Attributes::GeneratedCommandList::Id, true, chip::NullOptional); + LogStep(4, "TH sends a Logout command to the DUT with test values provided by the product maker."); + VerifyOrDo(!ShouldSkip("ALOGIN.S.C03.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::AccountLogin::Commands::Logout::Type value; + return SendCommand(kIdentityAlpha, GetEndpoint(3), AccountLogin::Id, AccountLogin::Commands::Logout::Id, value, + chip::Optional(10000), chip::NullOptional + + ); } } return CHIP_NO_ERROR; @@ -24611,151 +26910,262 @@ class Test_TC_MEDIAINPUT_3_11Suite : public TestCommand return WaitForCommissionee(kIdentityAlpha, value); } case 1: { - LogStep(1, - "TH reads the InputList attribute from the DUT to show list of Inputs available and Verify list of available " - "inputs supported by the device is provided, where each entry in the list contains an index(type:uint 8), " - "InputType (InputType Enums), Name (type: Strings), and Description(Type:String)"); + LogStep(1, + "TH reads the InputList attribute from the DUT to show list of Inputs available and Verify list of available " + "inputs supported by the device is provided, where each entry in the list contains an index(type:uint 8), " + "InputType (InputType Enums), Name (type: Strings), and Description(Type:String)"); + VerifyOrDo(!ShouldSkip("MEDIAINPUT.S.A0000"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), MediaInput::Id, MediaInput::Attributes::InputList::Id, true, + chip::NullOptional); + } + case 2: { + LogStep(2, "Select Input Command"); + VerifyOrDo(!ShouldSkip("MEDIAINPUT.S.C00.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::MediaInput::Commands::SelectInput::Type value; + value.index = 1U; + return SendCommand(kIdentityAlpha, GetEndpoint(1), MediaInput::Id, MediaInput::Commands::SelectInput::Id, value, + chip::NullOptional + + ); + } + case 3: { + LogStep(3, "Read current input list"); + VerifyOrDo(!ShouldSkip("MEDIAINPUT.S.A0001 && MEDIAINPUT.S.C00.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), MediaInput::Id, MediaInput::Attributes::CurrentInput::Id, true, + chip::NullOptional); + } + } + return CHIP_NO_ERROR; + } +}; + +class Test_TC_MEDIAINPUT_3_12Suite : public TestCommand +{ +public: + Test_TC_MEDIAINPUT_3_12Suite(CredentialIssuerCommands * credsIssuerConfig) : + TestCommand("Test_TC_MEDIAINPUT_3_12", 4, credsIssuerConfig) + { + AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); + AddArgument("cluster", &mCluster); + AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("timeout", 0, UINT16_MAX, &mTimeout); + } + + ~Test_TC_MEDIAINPUT_3_12Suite() {} + + chip::System::Clock::Timeout GetWaitDuration() const override + { + return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); + } + +private: + chip::Optional mNodeId; + chip::Optional mCluster; + chip::Optional mEndpoint; + chip::Optional mTimeout; + + chip::EndpointId GetEndpoint(chip::EndpointId endpoint) { return mEndpoint.HasValue() ? mEndpoint.Value() : endpoint; } + + // + // Tests methods + // + + void OnResponse(const chip::app::StatusIB & status, chip::TLV::TLVReader * data) override + { + bool shouldContinue = false; + + switch (mTestIndex - 1) + { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + shouldContinue = true; + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + } + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + default: + LogErrorOnFailure(ContinueOnChipMainThread(CHIP_ERROR_INVALID_ARGUMENT)); + } + + if (shouldContinue) + { + ContinueOnChipMainThread(CHIP_NO_ERROR); + } + } + + CHIP_ERROR DoTestStep(uint16_t testIndex) override + { + using namespace chip::app::Clusters; + switch (testIndex) + { + case 0: { + LogStep(0, "Wait for the commissioned device to be retrieved"); + ListFreer listFreer; + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee(kIdentityAlpha, value); + } + case 1: { + LogStep(1, + "TH reads the InputList attribute from the DUT to show list of Inputs available and Verify list of available " + "inputs supported by the device is provided, where each entry in the list contains an index(type:uint 8), " + "InputType (InputType Enums), Name (type: Strings), and Description(Type:String)"); + VerifyOrDo(!ShouldSkip("MEDIAINPUT.S.A0000"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), MediaInput::Id, MediaInput::Attributes::InputList::Id, true, + chip::NullOptional); + } + case 2: { + LogStep(2, "Show Input Status Command"); + VerifyOrDo(!ShouldSkip("MEDIAINPUT.S.C01.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::MediaInput::Commands::ShowInputStatus::Type value; + return SendCommand(kIdentityAlpha, GetEndpoint(1), MediaInput::Id, MediaInput::Commands::ShowInputStatus::Id, value, + chip::NullOptional + + ); + } + case 3: { + LogStep(3, "Hide Input Status Command"); + VerifyOrDo(!ShouldSkip("MEDIAINPUT.S.C02.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::MediaInput::Commands::HideInputStatus::Type value; + return SendCommand(kIdentityAlpha, GetEndpoint(1), MediaInput::Id, MediaInput::Commands::HideInputStatus::Id, value, + chip::NullOptional + + ); + } + } + return CHIP_NO_ERROR; + } +}; + +class Test_TC_MEDIAINPUT_3_13Suite : public TestCommand +{ +public: + Test_TC_MEDIAINPUT_3_13Suite(CredentialIssuerCommands * credsIssuerConfig) : + TestCommand("Test_TC_MEDIAINPUT_3_13", 4, credsIssuerConfig) + { + AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); + AddArgument("cluster", &mCluster); + AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("timeout", 0, UINT16_MAX, &mTimeout); + } + + ~Test_TC_MEDIAINPUT_3_13Suite() {} + + chip::System::Clock::Timeout GetWaitDuration() const override + { + return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); + } + +private: + chip::Optional mNodeId; + chip::Optional mCluster; + chip::Optional mEndpoint; + chip::Optional mTimeout; + + chip::EndpointId GetEndpoint(chip::EndpointId endpoint) { return mEndpoint.HasValue() ? mEndpoint.Value() : endpoint; } + + // + // Tests methods + // + + void OnResponse(const chip::app::StatusIB & status, chip::TLV::TLVReader * data) override + { + bool shouldContinue = false; + + switch (mTestIndex - 1) + { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + shouldContinue = true; + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::DataModel::DecodableList value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + } + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + shouldContinue = true; + break; + default: + LogErrorOnFailure(ContinueOnChipMainThread(CHIP_ERROR_INVALID_ARGUMENT)); + } + + if (shouldContinue) + { + ContinueOnChipMainThread(CHIP_NO_ERROR); + } + } + + CHIP_ERROR DoTestStep(uint16_t testIndex) override + { + using namespace chip::app::Clusters; + switch (testIndex) + { + case 0: { + LogStep(0, "Wait for the commissioned device to be retrieved"); + ListFreer listFreer; + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee(kIdentityAlpha, value); + } + case 1: { + LogStep(1, "TH reads the InputList attribute from the DUT to show list of Inputs available"); VerifyOrDo(!ShouldSkip("MEDIAINPUT.S.A0000"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), MediaInput::Id, MediaInput::Attributes::InputList::Id, true, chip::NullOptional); } case 2: { - LogStep(2, "Select Input Command"); - VerifyOrDo(!ShouldSkip("MEDIAINPUT.S.C00.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + LogStep(2, "Rename Input Command"); + VerifyOrDo(!ShouldSkip("MEDIAINPUT.S.C03.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); ListFreer listFreer; - chip::app::Clusters::MediaInput::Commands::SelectInput::Type value; + chip::app::Clusters::MediaInput::Commands::RenameInput::Type value; value.index = 1U; - return SendCommand(kIdentityAlpha, GetEndpoint(1), MediaInput::Id, MediaInput::Commands::SelectInput::Id, value, - chip::NullOptional - - ); - } - case 3: { - LogStep(3, "Read current input list"); - VerifyOrDo(!ShouldSkip("MEDIAINPUT.S.A0001 && MEDIAINPUT.S.C00.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), MediaInput::Id, MediaInput::Attributes::CurrentInput::Id, true, - chip::NullOptional); - } - } - return CHIP_NO_ERROR; - } -}; - -class Test_TC_MEDIAINPUT_3_12Suite : public TestCommand -{ -public: - Test_TC_MEDIAINPUT_3_12Suite(CredentialIssuerCommands * credsIssuerConfig) : - TestCommand("Test_TC_MEDIAINPUT_3_12", 4, credsIssuerConfig) - { - AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); - AddArgument("cluster", &mCluster); - AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); - AddArgument("timeout", 0, UINT16_MAX, &mTimeout); - } - - ~Test_TC_MEDIAINPUT_3_12Suite() {} - - chip::System::Clock::Timeout GetWaitDuration() const override - { - return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); - } - -private: - chip::Optional mNodeId; - chip::Optional mCluster; - chip::Optional mEndpoint; - chip::Optional mTimeout; - - chip::EndpointId GetEndpoint(chip::EndpointId endpoint) { return mEndpoint.HasValue() ? mEndpoint.Value() : endpoint; } - - // - // Tests methods - // - - void OnResponse(const chip::app::StatusIB & status, chip::TLV::TLVReader * data) override - { - bool shouldContinue = false; - - switch (mTestIndex - 1) - { - case 0: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); - shouldContinue = true; - break; - case 1: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); - { - chip::app::DataModel::DecodableList value; - VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); - } - break; - case 2: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); - break; - case 3: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); - break; - default: - LogErrorOnFailure(ContinueOnChipMainThread(CHIP_ERROR_INVALID_ARGUMENT)); - } - - if (shouldContinue) - { - ContinueOnChipMainThread(CHIP_NO_ERROR); - } - } - - CHIP_ERROR DoTestStep(uint16_t testIndex) override - { - using namespace chip::app::Clusters; - switch (testIndex) - { - case 0: { - LogStep(0, "Wait for the commissioned device to be retrieved"); - ListFreer listFreer; - chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; - value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; - return WaitForCommissionee(kIdentityAlpha, value); - } - case 1: { - LogStep(1, - "TH reads the InputList attribute from the DUT to show list of Inputs available and Verify list of available " - "inputs supported by the device is provided, where each entry in the list contains an index(type:uint 8), " - "InputType (InputType Enums), Name (type: Strings), and Description(Type:String)"); - VerifyOrDo(!ShouldSkip("MEDIAINPUT.S.A0000"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), MediaInput::Id, MediaInput::Attributes::InputList::Id, true, - chip::NullOptional); - } - case 2: { - LogStep(2, "Show Input Status Command"); - VerifyOrDo(!ShouldSkip("MEDIAINPUT.S.C01.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); - ListFreer listFreer; - chip::app::Clusters::MediaInput::Commands::ShowInputStatus::Type value; - return SendCommand(kIdentityAlpha, GetEndpoint(1), MediaInput::Id, MediaInput::Commands::ShowInputStatus::Id, value, + value.name = chip::Span("A1garbage: not in length on purpose", 2); + return SendCommand(kIdentityAlpha, GetEndpoint(1), MediaInput::Id, MediaInput::Commands::RenameInput::Id, value, chip::NullOptional ); } case 3: { - LogStep(3, "Hide Input Status Command"); - VerifyOrDo(!ShouldSkip("MEDIAINPUT.S.C02.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + LogStep(3, "TH reads the InputList attribute from the DUT to show list of Inputs available"); + VerifyOrDo(!ShouldSkip("PICS_USER_PROMPT && MEDIAINPUT.S.A0000 && MEDIAINPUT.S.C03.Rsp"), + return ContinueOnChipMainThread(CHIP_NO_ERROR)); ListFreer listFreer; - chip::app::Clusters::MediaInput::Commands::HideInputStatus::Type value; - return SendCommand(kIdentityAlpha, GetEndpoint(1), MediaInput::Id, MediaInput::Commands::HideInputStatus::Id, value, - chip::NullOptional - - ); + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; + value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); + value.expectedValue.Emplace(); + value.expectedValue.Value() = chip::Span("ygarbage: not in length on purpose", 1); + return UserPrompt(kIdentityAlpha, value); } } return CHIP_NO_ERROR; } }; -class Test_TC_MEDIAINPUT_3_13Suite : public TestCommand +class Test_TC_WAKEONLAN_4_1Suite : public TestCommand { public: - Test_TC_MEDIAINPUT_3_13Suite(CredentialIssuerCommands * credsIssuerConfig) : - TestCommand("Test_TC_MEDIAINPUT_3_13", 4, credsIssuerConfig) + Test_TC_WAKEONLAN_4_1Suite(CredentialIssuerCommands * credsIssuerConfig) : + TestCommand("Test_TC_WAKEONLAN_4_1", 4, credsIssuerConfig) { AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); AddArgument("cluster", &mCluster); @@ -24763,7 +27173,7 @@ class Test_TC_MEDIAINPUT_3_13Suite : public TestCommand AddArgument("timeout", 0, UINT16_MAX, &mTimeout); } - ~Test_TC_MEDIAINPUT_3_13Suite() {} + ~Test_TC_WAKEONLAN_4_1Suite() {} chip::System::Clock::Timeout GetWaitDuration() const override { @@ -24795,8 +27205,9 @@ class Test_TC_MEDIAINPUT_3_13Suite : public TestCommand case 1: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { - chip::app::DataModel::DecodableList value; + chip::CharSpan value; VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintMinLength("value", value, 12)); } break; case 2: @@ -24829,30 +27240,27 @@ class Test_TC_MEDIAINPUT_3_13Suite : public TestCommand return WaitForCommissionee(kIdentityAlpha, value); } case 1: { - LogStep(1, "TH reads the InputList attribute from the DUT to show list of Inputs available"); - VerifyOrDo(!ShouldSkip("MEDIAINPUT.S.A0000"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), MediaInput::Id, MediaInput::Attributes::InputList::Id, true, + LogStep(1, "TH reads the MACAddress attribute from the DUT"); + VerifyOrDo(!ShouldSkip("WAKEONLAN.S.A0000"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), WakeOnLan::Id, WakeOnLan::Attributes::MACAddress::Id, true, chip::NullOptional); } case 2: { - LogStep(2, "Rename Input Command"); - VerifyOrDo(!ShouldSkip("MEDIAINPUT.S.C03.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + LogStep(2, "TH sends a Sleep command to DUT"); + VerifyOrDo(!ShouldSkip("LOWPOWER.S.C00.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); ListFreer listFreer; - chip::app::Clusters::MediaInput::Commands::RenameInput::Type value; - value.index = 1U; - value.name = chip::Span("A1garbage: not in length on purpose", 2); - return SendCommand(kIdentityAlpha, GetEndpoint(1), MediaInput::Id, MediaInput::Commands::RenameInput::Id, value, + chip::app::Clusters::LowPower::Commands::Sleep::Type value; + return SendCommand(kIdentityAlpha, GetEndpoint(1), LowPower::Id, LowPower::Commands::Sleep::Id, value, chip::NullOptional ); } case 3: { - LogStep(3, "TH reads the InputList attribute from the DUT to show list of Inputs available"); - VerifyOrDo(!ShouldSkip("PICS_USER_PROMPT && MEDIAINPUT.S.A0000 && MEDIAINPUT.S.C03.Rsp"), - return ContinueOnChipMainThread(CHIP_NO_ERROR)); + LogStep(3, "TH sends a Wake-On LAN magic packet containing the MAC address from step 1"); + VerifyOrDo(!ShouldSkip("PICS_USER_PROMPT"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); ListFreer listFreer; chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; - value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); + value.message = chip::Span("Please enter 'y' after successgarbage: not in length on purpose", 30); value.expectedValue.Emplace(); value.expectedValue.Value() = chip::Span("ygarbage: not in length on purpose", 1); return UserPrompt(kIdentityAlpha, value); @@ -34164,7 +36572,7 @@ class Test_TC_TSTAT_2_1Suite : public TestCommand { uint32_t value; VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); - VerifyOrReturn(CheckConstraintType("value", "utc", "utc")); + VerifyOrReturn(CheckConstraintType("value", "epoch_s", "epoch_s")); } break; case 53: @@ -38799,19 +41207,19 @@ class Test_TC_DGTHREAD_1_1Suite : public TestCommand } case 51: { LogStep(51, "Read the optional attribute (ActiveTimestamp) in AttributeList"); - VerifyOrDo(!ShouldSkip("DGTHREAD.S.A0039"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("DGTHREAD.S.A0038"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(0), ThreadNetworkDiagnostics::Id, ThreadNetworkDiagnostics::Attributes::AttributeList::Id, true, chip::NullOptional); } case 52: { LogStep(52, "Read the optional attribute (PendingTimestamp) in AttributeList"); - VerifyOrDo(!ShouldSkip("DGTHREAD.S.A003A"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("DGTHREAD.S.A0039"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(0), ThreadNetworkDiagnostics::Id, ThreadNetworkDiagnostics::Attributes::AttributeList::Id, true, chip::NullOptional); } case 53: { LogStep(53, "Read the optional attribute (Delay) in AttributeList"); - VerifyOrDo(!ShouldSkip("DGTHREAD.S.A003B"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("DGTHREAD.S.A003a"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(0), ThreadNetworkDiagnostics::Id, ThreadNetworkDiagnostics::Attributes::AttributeList::Id, true, chip::NullOptional); } @@ -39366,13 +41774,13 @@ class Test_TC_DGTHREAD_2_1Suite : public TestCommand } case 29: { LogStep(29, "TH reads Delay attribute value from DUT"); - VerifyOrDo(!ShouldSkip("DGTHREAD.S.A003A"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("DGTHREAD.S.A003a"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(0), ThreadNetworkDiagnostics::Id, ThreadNetworkDiagnostics::Attributes::Delay::Id, true, chip::NullOptional); } case 30: { LogStep(30, "Read SecurityPolicy struct attribute from DUT and Verify the each field"); - VerifyOrDo(!ShouldSkip("PICS_USER_PROMPT && DGTHREAD.S.A003B"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PICS_USER_PROMPT && DGTHREAD.S.A003b"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); ListFreer listFreer; chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); @@ -47900,7 +50308,7 @@ class TestCASERecoverySuite : public TestCommand class TestClusterSuite : public TestCommand { public: - TestClusterSuite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("TestCluster", 490, credsIssuerConfig) + TestClusterSuite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("TestCluster", 491, credsIssuerConfig) { AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); AddArgument("cluster", &mCluster); @@ -48866,6 +51274,9 @@ class TestClusterSuite : public TestCommand } break; case 136: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 137: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint64_t value; @@ -48873,10 +51284,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("epochUs", value, 0ULL)); } break; - case 137: + case 138: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 138: + case 139: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint64_t value; @@ -48884,10 +51295,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("epochUs", value, 18446744073709551615ULL)); } break; - case 139: + case 140: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 140: + case 141: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint64_t value; @@ -48895,7 +51306,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("epochUs", value, 0ULL)); } break; - case 141: + case 142: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint32_t value; @@ -48903,10 +51314,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("epochS", value, 0UL)); } break; - case 142: + case 143: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 143: + case 144: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint32_t value; @@ -48914,10 +51325,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("epochS", value, 4294967295UL)); } break; - case 144: + case 145: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 145: + case 146: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint32_t value; @@ -48925,7 +51336,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("epochS", value, 0UL)); } break; - case 146: + case 147: if (IsUnsupported(status.mStatus)) { return; @@ -48937,20 +51348,20 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("unsupported", value, 0)); } break; - case 147: + case 148: if (IsUnsupported(status.mStatus)) { return; } VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 148: + case 149: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_ENDPOINT)); break; - case 149: + case 150: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_CLUSTER)); break; - case 150: + case 151: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::VendorId value; @@ -48958,10 +51369,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("vendorId", value, 0U)); } break; - case 151: + case 152: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 152: + case 153: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::VendorId value; @@ -48969,10 +51380,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("vendorId", value, 17U)); } break; - case 153: + case 154: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 154: + case 155: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::TestEnumsResponse::DecodableType value; @@ -48981,7 +51392,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("arg2", value.arg2, 1U)); } break; - case 155: + case 156: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::TestEnumsResponse::DecodableType value; @@ -48990,7 +51401,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("arg2", value.arg2, 4U)); } break; - case 156: + case 157: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::BooleanResponse::DecodableType value; @@ -48998,7 +51409,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("value", value.value, true)); } break; - case 157: + case 158: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::BooleanResponse::DecodableType value; @@ -49006,7 +51417,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("value", value.value, false)); } break; - case 158: + case 159: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::BooleanResponse::DecodableType value; @@ -49014,7 +51425,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("value", value.value, true)); } break; - case 159: + case 160: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::BooleanResponse::DecodableType value; @@ -49022,7 +51433,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("value", value.value, false)); } break; - case 160: + case 161: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::BooleanResponse::DecodableType value; @@ -49030,7 +51441,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("value", value.value, true)); } break; - case 161: + case 162: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::BooleanResponse::DecodableType value; @@ -49038,7 +51449,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("value", value.value, false)); } break; - case 162: + case 163: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::SimpleStructResponse::DecodableType value; @@ -49054,7 +51465,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("arg1.h", value.arg1.h, 0.1)); } break; - case 163: + case 164: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::BooleanResponse::DecodableType value; @@ -49062,7 +51473,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("value", value.value, true)); } break; - case 164: + case 165: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::BooleanResponse::DecodableType value; @@ -49070,7 +51481,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("value", value.value, false)); } break; - case 165: + case 166: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::TestListInt8UReverseResponse::DecodableType value; @@ -49099,7 +51510,7 @@ class TestClusterSuite : public TestCommand } } break; - case 166: + case 167: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::TestListInt8UReverseResponse::DecodableType value; @@ -49110,7 +51521,7 @@ class TestClusterSuite : public TestCommand } } break; - case 167: + case 168: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::BooleanResponse::DecodableType value; @@ -49118,7 +51529,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("value", value.value, true)); } break; - case 168: + case 169: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::BooleanResponse::DecodableType value; @@ -49126,7 +51537,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("value", value.value, false)); } break; - case 169: + case 170: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::BooleanResponse::DecodableType value; @@ -49134,7 +51545,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("value", value.value, true)); } break; - case 170: + case 171: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::BooleanResponse::DecodableType value; @@ -49142,10 +51553,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("value", value.value, false)); } break; - case 171: + case 172: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 172: + case 173: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -49164,10 +51575,10 @@ class TestClusterSuite : public TestCommand } } break; - case 173: + case 174: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 174: + case 175: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -49190,10 +51601,10 @@ class TestClusterSuite : public TestCommand } } break; - case 175: + case 176: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 176: + case 177: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList @@ -49221,7 +51632,7 @@ class TestClusterSuite : public TestCommand } } break; - case 177: + case 178: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::TestNullableOptionalResponse::DecodableType value; @@ -49236,7 +51647,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("originalValue.Value().Value()", value.originalValue.Value().Value(), 5U)); } break; - case 178: + case 179: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Commands::TestNullableOptionalResponse::DecodableType value; @@ -49244,7 +51655,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("wasPresent", value.wasPresent, false)); } break; - case 179: + case 180: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList< @@ -49265,10 +51676,10 @@ class TestClusterSuite : public TestCommand } } break; - case 180: + case 181: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 181: + case 182: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList< @@ -49302,10 +51713,10 @@ class TestClusterSuite : public TestCommand } } break; - case 182: + case 183: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 183: + case 184: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49314,10 +51725,10 @@ class TestClusterSuite : public TestCommand booValueNull = value; } break; - case 184: + case 185: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 185: + case 186: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49326,7 +51737,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableBoolean.Value()", value.Value(), true)); } break; - case 186: + case 187: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49334,10 +51745,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, booValueNull)); } break; - case 187: + case 188: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 188: + case 189: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable> value; @@ -49346,10 +51757,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableBitmap8.Value()", value.Value(), 254U)); } break; - case 189: + case 190: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; - case 190: + case 191: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable> value; @@ -49359,10 +51770,10 @@ class TestClusterSuite : public TestCommand nullableValue254 = value; } break; - case 191: + case 192: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 192: + case 193: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable> value; @@ -49370,7 +51781,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableBitmap8", value)); } break; - case 193: + case 194: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable> value; @@ -49378,10 +51789,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, nullableValue254)); } break; - case 194: + case 195: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 195: + case 196: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable> value; @@ -49390,10 +51801,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableBitmap16.Value()", value.Value(), 65534U)); } break; - case 196: + case 197: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; - case 197: + case 198: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable> value; @@ -49402,10 +51813,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableBitmap16.Value()", value.Value(), 65534U)); } break; - case 198: + case 199: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 199: + case 200: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable> value; @@ -49413,10 +51824,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableBitmap16", value)); } break; - case 200: + case 201: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 201: + case 202: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable> value; @@ -49425,10 +51836,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableBitmap32.Value()", value.Value(), 4294967294UL)); } break; - case 202: + case 203: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; - case 203: + case 204: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable> value; @@ -49437,10 +51848,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableBitmap32.Value()", value.Value(), 4294967294UL)); } break; - case 204: + case 205: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 205: + case 206: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable> value; @@ -49448,10 +51859,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableBitmap32", value)); } break; - case 206: + case 207: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 207: + case 208: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable> value; @@ -49460,10 +51871,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableBitmap64.Value()", value.Value(), 18446744073709551614ULL)); } break; - case 208: + case 209: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; - case 209: + case 210: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable> value; @@ -49472,10 +51883,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableBitmap64.Value()", value.Value(), 18446744073709551614ULL)); } break; - case 210: + case 211: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 211: + case 212: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable> value; @@ -49483,10 +51894,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableBitmap64", value)); } break; - case 212: + case 213: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 213: + case 214: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49495,10 +51906,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt8u.Value()", value.Value(), 0U)); } break; - case 214: + case 215: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 215: + case 216: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49507,10 +51918,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt8u.Value()", value.Value(), 254U)); } break; - case 216: + case 217: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; - case 217: + case 218: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49519,7 +51930,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt8u.Value()", value.Value(), 254U)); } break; - case 218: + case 219: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49527,10 +51938,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNonNull("value", value)); } break; - case 219: + case 220: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 220: + case 221: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49538,7 +51949,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableInt8u", value)); } break; - case 221: + case 222: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49547,7 +51958,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 254U)); } break; - case 222: + case 223: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49555,10 +51966,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, 254U)); } break; - case 223: + case 224: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 224: + case 225: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49567,7 +51978,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 254U)); } break; - case 225: + case 226: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49575,10 +51986,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, 129U)); } break; - case 226: + case 227: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 227: + case 228: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49587,10 +51998,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt16u.Value()", value.Value(), 0U)); } break; - case 228: + case 229: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 229: + case 230: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49599,10 +52010,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt16u.Value()", value.Value(), 65534U)); } break; - case 230: + case 231: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; - case 231: + case 232: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49611,10 +52022,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt16u.Value()", value.Value(), 65534U)); } break; - case 232: + case 233: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 233: + case 234: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49622,7 +52033,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableInt16u", value)); } break; - case 234: + case 235: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49631,7 +52042,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 65534U)); } break; - case 235: + case 236: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49639,10 +52050,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, 65534U)); } break; - case 236: + case 237: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 237: + case 238: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49651,7 +52062,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 65534U)); } break; - case 238: + case 239: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49659,10 +52070,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, 32001U)); } break; - case 239: + case 240: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 240: + case 241: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49671,10 +52082,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt32u.Value()", value.Value(), 0UL)); } break; - case 241: + case 242: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 242: + case 243: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49683,10 +52094,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt32u.Value()", value.Value(), 4294967294UL)); } break; - case 243: + case 244: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; - case 244: + case 245: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49695,10 +52106,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt32u.Value()", value.Value(), 4294967294UL)); } break; - case 245: + case 246: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 246: + case 247: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49706,7 +52117,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableInt32u", value)); } break; - case 247: + case 248: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49715,7 +52126,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 4294967294UL)); } break; - case 248: + case 249: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49723,10 +52134,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, 4294967294UL)); } break; - case 249: + case 250: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 250: + case 251: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49735,7 +52146,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 4294967294UL)); } break; - case 251: + case 252: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49743,10 +52154,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, 2147483648UL)); } break; - case 252: + case 253: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 253: + case 254: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49755,10 +52166,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt64u.Value()", value.Value(), 0ULL)); } break; - case 254: + case 255: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 255: + case 256: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49767,10 +52178,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt64u.Value()", value.Value(), 18446744073709551614ULL)); } break; - case 256: + case 257: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; - case 257: + case 258: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49779,10 +52190,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt64u.Value()", value.Value(), 18446744073709551614ULL)); } break; - case 258: + case 259: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 259: + case 260: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49790,7 +52201,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableInt64u", value)); } break; - case 260: + case 261: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49799,7 +52210,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 18446744073709551614ULL)); } break; - case 261: + case 262: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49807,10 +52218,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, 18446744073709551614ULL)); } break; - case 262: + case 263: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 263: + case 264: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49819,7 +52230,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 18446744073709551614ULL)); } break; - case 264: + case 265: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49827,10 +52238,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, 18000000000000000001ULL)); } break; - case 265: + case 266: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 266: + case 267: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49839,10 +52250,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt8s.Value()", value.Value(), -127)); } break; - case 267: + case 268: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; - case 268: + case 269: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49851,10 +52262,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt8s.Value()", value.Value(), -127)); } break; - case 269: + case 270: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 270: + case 271: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49862,7 +52273,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableInt8s", value)); } break; - case 271: + case 272: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49871,7 +52282,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 127)); } break; - case 272: + case 273: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49879,10 +52290,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, -127)); } break; - case 273: + case 274: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 274: + case 275: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49891,7 +52302,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 127)); } break; - case 275: + case 276: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49899,10 +52310,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, -126)); } break; - case 276: + case 277: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 277: + case 278: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49911,10 +52322,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt16s.Value()", value.Value(), -32767)); } break; - case 278: + case 279: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; - case 279: + case 280: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49923,10 +52334,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt16s.Value()", value.Value(), -32767)); } break; - case 280: + case 281: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 281: + case 282: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49934,7 +52345,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableInt16s", value)); } break; - case 282: + case 283: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49943,7 +52354,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 32767)); } break; - case 283: + case 284: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49951,10 +52362,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, -32767)); } break; - case 284: + case 285: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 285: + case 286: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49963,7 +52374,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 32767)); } break; - case 286: + case 287: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49971,10 +52382,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, -32766)); } break; - case 287: + case 288: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 288: + case 289: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49983,10 +52394,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt32s.Value()", value.Value(), -2147483647L)); } break; - case 289: + case 290: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; - case 290: + case 291: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -49995,10 +52406,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt32s.Value()", value.Value(), -2147483647L)); } break; - case 291: + case 292: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 292: + case 293: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50006,7 +52417,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableInt32s", value)); } break; - case 293: + case 294: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50015,7 +52426,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 2147483647L)); } break; - case 294: + case 295: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50023,10 +52434,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, -2147483647L)); } break; - case 295: + case 296: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 296: + case 297: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50035,7 +52446,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 2147483647L)); } break; - case 297: + case 298: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50043,10 +52454,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, -2147483646L)); } break; - case 298: + case 299: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 299: + case 300: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50055,10 +52466,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt64s.Value()", value.Value(), -9223372036854775807LL)); } break; - case 300: + case 301: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; - case 301: + case 302: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50067,10 +52478,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableInt64s.Value()", value.Value(), -9223372036854775807LL)); } break; - case 302: + case 303: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 303: + case 304: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50078,7 +52489,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableInt64s", value)); } break; - case 304: + case 305: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50087,7 +52498,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 9223372036854775807LL)); } break; - case 305: + case 306: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50095,10 +52506,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, -9223372036854775807LL)); } break; - case 306: + case 307: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 307: + case 308: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50107,7 +52518,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 9223372036854775807LL)); } break; - case 308: + case 309: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50115,10 +52526,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, -9223372036854775806LL)); } break; - case 309: + case 310: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 310: + case 311: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50127,10 +52538,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableFloatSingle.Value()", value.Value(), 0.1f)); } break; - case 311: + case 312: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 312: + case 313: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50139,10 +52550,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableFloatSingle.Value()", value.Value(), INFINITY)); } break; - case 313: + case 314: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 314: + case 315: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50151,10 +52562,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableFloatSingle.Value()", value.Value(), -INFINITY)); } break; - case 315: + case 316: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 316: + case 317: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50162,10 +52573,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableFloatSingle", value)); } break; - case 317: + case 318: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 318: + case 319: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50174,10 +52585,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableFloatSingle.Value()", value.Value(), 0.0f)); } break; - case 319: + case 320: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 320: + case 321: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50186,10 +52597,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableFloatDouble.Value()", value.Value(), 0.1234567890123)); } break; - case 321: + case 322: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 322: + case 323: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50198,10 +52609,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableFloatDouble.Value()", value.Value(), INFINITY)); } break; - case 323: + case 324: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 324: + case 325: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50210,10 +52621,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableFloatDouble.Value()", value.Value(), -INFINITY)); } break; - case 325: + case 326: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 326: + case 327: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50221,10 +52632,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableFloatDouble", value)); } break; - case 327: + case 328: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 328: + case 329: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50233,10 +52644,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableFloatDouble.Value()", value.Value(), 0)); } break; - case 329: + case 330: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 330: + case 331: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50245,10 +52656,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableEnum8.Value()", value.Value(), 0U)); } break; - case 331: + case 332: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 332: + case 333: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50257,10 +52668,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableEnum8.Value()", value.Value(), 254U)); } break; - case 333: + case 334: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; - case 334: + case 335: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50269,10 +52680,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableEnum8.Value()", value.Value(), 254U)); } break; - case 335: + case 336: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 336: + case 337: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50280,10 +52691,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableEnum8", value)); } break; - case 337: + case 338: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 338: + case 339: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50292,10 +52703,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableEnum16.Value()", value.Value(), 0U)); } break; - case 339: + case 340: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 340: + case 341: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50304,10 +52715,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableEnum16.Value()", value.Value(), 65534U)); } break; - case 341: + case 342: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; - case 342: + case 343: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50316,10 +52727,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableEnum16.Value()", value.Value(), 65534U)); } break; - case 343: + case 344: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 344: + case 345: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50327,10 +52738,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableEnum16", value)); } break; - case 345: + case 346: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 346: + case 347: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50339,10 +52750,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableEnumAttr.Value()", value.Value(), 0U)); } break; - case 347: + case 348: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 348: + case 349: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50351,10 +52762,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableEnumAttr.Value()", value.Value(), 3U)); } break; - case 349: + case 350: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; - case 350: + case 351: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50364,10 +52775,10 @@ class TestClusterSuite : public TestCommand nullableEnumAttr3 = value; } break; - case 351: + case 352: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 352: + case 353: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50375,7 +52786,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableEnumAttr", value)); } break; - case 353: + case 354: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50383,7 +52794,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, nullableEnumAttr3)); } break; - case 354: + case 355: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50393,10 +52804,10 @@ class TestClusterSuite : public TestCommand chip::ByteSpan(chip::Uint8::from_const_char(""), 0))); } break; - case 355: + case 356: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 356: + case 357: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50420,10 +52831,10 @@ class TestClusterSuite : public TestCommand } } break; - case 357: + case 358: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 358: + case 359: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50431,10 +52842,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableOctetString", value)); } break; - case 359: + case 360: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 360: + case 361: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50444,7 +52855,7 @@ class TestClusterSuite : public TestCommand chip::ByteSpan(chip::Uint8::from_const_char(""), 0))); } break; - case 361: + case 362: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50452,7 +52863,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, nullableOctetStrTestValue)); } break; - case 362: + case 363: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50461,10 +52872,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueAsString("nullableCharString.Value()", value.Value(), chip::CharSpan("", 0))); } break; - case 363: + case 364: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 364: + case 365: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50487,7 +52898,7 @@ class TestClusterSuite : public TestCommand } } break; - case 365: + case 366: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50503,10 +52914,10 @@ class TestClusterSuite : public TestCommand } } break; - case 366: + case 367: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 367: + case 368: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50514,10 +52925,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableCharString", value)); } break; - case 368: + case 369: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 369: + case 370: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50526,7 +52937,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueAsString("nullableCharString.Value()", value.Value(), chip::CharSpan("", 0))); } break; - case 370: + case 371: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50534,19 +52945,19 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, nullableCharStringSave)); } break; - case 371: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_ENDPOINT)); - break; case 372: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_CLUSTER)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_ENDPOINT)); break; case 373: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_VALUE)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_CLUSTER)); break; case 374: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 375: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 376: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -50565,10 +52976,10 @@ class TestClusterSuite : public TestCommand } } break; - case 376: + case 377: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 377: + case 378: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -50588,7 +52999,7 @@ class TestClusterSuite : public TestCommand } shouldContinue = true; break; - case 378: + case 379: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint8_t value; @@ -50596,9 +53007,6 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt8u", value, 70U)); } break; - case 379: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); - break; case 380: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; @@ -50609,6 +53017,9 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 383: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 384: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint8_t value; @@ -50616,10 +53027,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt8u", value, 70U)); } break; - case 384: + case 385: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 385: + case 386: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint8_t value; @@ -50627,10 +53038,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt8u", value, 20U)); } break; - case 386: + case 387: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 387: + case 388: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint8_t value; @@ -50638,10 +53049,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt8u", value, 100U)); } break; - case 388: + case 389: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 389: + case 390: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint8_t value; @@ -50649,7 +53060,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt8u", value, 50U)); } break; - case 390: + case 391: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint16_t value; @@ -50657,9 +53068,6 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt16u", value, 200U)); } break; - case 391: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); - break; case 392: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; @@ -50670,6 +53078,9 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 395: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 396: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint16_t value; @@ -50677,10 +53088,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt16u", value, 200U)); } break; - case 396: + case 397: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 397: + case 398: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint16_t value; @@ -50688,10 +53099,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt16u", value, 100U)); } break; - case 398: + case 399: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 399: + case 400: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint16_t value; @@ -50699,10 +53110,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt16u", value, 1000U)); } break; - case 400: + case 401: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 401: + case 402: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint16_t value; @@ -50710,7 +53121,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt16u", value, 500U)); } break; - case 402: + case 403: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { int8_t value; @@ -50718,9 +53129,6 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt8s", value, -20)); } break; - case 403: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); - break; case 404: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; @@ -50731,6 +53139,9 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 407: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 408: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { int8_t value; @@ -50738,10 +53149,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt8s", value, -20)); } break; - case 408: + case 409: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 409: + case 410: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { int8_t value; @@ -50749,10 +53160,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt8s", value, -40)); } break; - case 410: + case 411: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 411: + case 412: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { int8_t value; @@ -50760,10 +53171,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt8s", value, 50)); } break; - case 412: + case 413: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 413: + case 414: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { int8_t value; @@ -50771,7 +53182,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt8s", value, 6)); } break; - case 414: + case 415: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { int16_t value; @@ -50779,9 +53190,6 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt16s", value, -100)); } break; - case 415: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); - break; case 416: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; @@ -50792,6 +53200,9 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 419: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 420: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { int16_t value; @@ -50799,10 +53210,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt16s", value, -100)); } break; - case 420: + case 421: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 421: + case 422: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { int16_t value; @@ -50810,10 +53221,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt16s", value, -150)); } break; - case 422: + case 423: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 423: + case 424: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { int16_t value; @@ -50821,10 +53232,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt16s", value, 200)); } break; - case 424: + case 425: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 425: + case 426: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { int16_t value; @@ -50832,7 +53243,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("rangeRestrictedInt16s", value, 7)); } break; - case 426: + case 427: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50841,9 +53252,6 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt8u.Value()", value.Value(), 70U)); } break; - case 427: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); - break; case 428: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; @@ -50854,6 +53262,9 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 431: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 432: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50862,10 +53273,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt8u.Value()", value.Value(), 70U)); } break; - case 432: + case 433: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 433: + case 434: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50874,10 +53285,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt8u.Value()", value.Value(), 20U)); } break; - case 434: + case 435: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 435: + case 436: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50886,10 +53297,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt8u.Value()", value.Value(), 100U)); } break; - case 436: + case 437: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 437: + case 438: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50898,10 +53309,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt8u.Value()", value.Value(), 50U)); } break; - case 438: + case 439: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 439: + case 440: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50909,7 +53320,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableRangeRestrictedInt8u", value)); } break; - case 440: + case 441: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50918,9 +53329,6 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt16u.Value()", value.Value(), 200U)); } break; - case 441: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); - break; case 442: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; @@ -50931,6 +53339,9 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 445: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 446: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50939,10 +53350,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt16u.Value()", value.Value(), 200U)); } break; - case 446: + case 447: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 447: + case 448: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50951,10 +53362,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt16u.Value()", value.Value(), 100U)); } break; - case 448: + case 449: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 449: + case 450: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50963,10 +53374,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt16u.Value()", value.Value(), 1000U)); } break; - case 450: + case 451: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 451: + case 452: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50975,10 +53386,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt16u.Value()", value.Value(), 500U)); } break; - case 452: + case 453: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 453: + case 454: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50986,7 +53397,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableRangeRestrictedInt16u", value)); } break; - case 454: + case 455: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -50995,9 +53406,6 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt8s.Value()", value.Value(), -20)); } break; - case 455: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); - break; case 456: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; @@ -51008,6 +53416,9 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 459: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 460: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -51016,10 +53427,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt8s.Value()", value.Value(), -20)); } break; - case 460: + case 461: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 461: + case 462: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -51028,10 +53439,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt8s.Value()", value.Value(), -40)); } break; - case 462: + case 463: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 463: + case 464: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -51040,10 +53451,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt8s.Value()", value.Value(), 50)); } break; - case 464: + case 465: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 465: + case 466: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -51052,10 +53463,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt8s.Value()", value.Value(), 6)); } break; - case 466: + case 467: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 467: + case 468: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -51063,7 +53474,7 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableRangeRestrictedInt8s", value)); } break; - case 468: + case 469: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -51072,9 +53483,6 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt16s.Value()", value.Value(), -100)); } break; - case 469: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); - break; case 470: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; @@ -51085,6 +53493,9 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 473: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 474: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -51093,10 +53504,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt16s.Value()", value.Value(), -100)); } break; - case 474: + case 475: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 475: + case 476: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -51105,10 +53516,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt16s.Value()", value.Value(), -150)); } break; - case 476: + case 477: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 477: + case 478: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -51117,10 +53528,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt16s.Value()", value.Value(), 200)); } break; - case 478: + case 479: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 479: + case 480: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -51129,10 +53540,10 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValue("nullableRangeRestrictedInt16s.Value()", value.Value(), 7)); } break; - case 480: + case 481: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 481: + case 482: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::Nullable value; @@ -51140,19 +53551,19 @@ class TestClusterSuite : public TestCommand VerifyOrReturn(CheckValueNull("nullableRangeRestrictedInt16s", value)); } break; - case 482: + case 483: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_DATA_TYPE)); break; - case 483: + case 484: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_FAILURE)); break; - case 484: + case 485: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_DATA_TYPE)); break; - case 485: + case 486: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_FAILURE)); break; - case 486: + case 487: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -51199,7 +53610,7 @@ class TestClusterSuite : public TestCommand } } break; - case 487: + case 488: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -51228,10 +53639,10 @@ class TestClusterSuite : public TestCommand } } break; - case 488: + case 489: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 489: + case 490: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::Clusters::UnitTesting::Structs::SimpleStruct::DecodableType value; @@ -52195,82 +54606,131 @@ class TestClusterSuite : public TestCommand true, chip::NullOptional); } case 136: { - LogStep(136, "Read attribute EPOCH_US Default Value"); + LogStep(136, "Write attribute LIST_LONG_OCTET_STRING (for chunked write)"); + ListFreer listFreer; + chip::app::DataModel::List value; + + { + auto * listHolder_0 = new ListHolder(4); + listFreer.add(listHolder_0); + listHolder_0->mList[0] = chip::ByteSpan( + chip::Uint8::from_const_char( + "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789" + "abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123" + "456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcd" + "ef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef01234567" + "89abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdefgarbage: not in " + "length on purpose"), + 512); + listHolder_0->mList[1] = chip::ByteSpan( + chip::Uint8::from_const_char( + "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789" + "abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123" + "456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcd" + "ef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef01234567" + "89abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdefgarbage: not in " + "length on purpose"), + 512); + listHolder_0->mList[2] = chip::ByteSpan( + chip::Uint8::from_const_char( + "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789" + "abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123" + "456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcd" + "ef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef01234567" + "89abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdefgarbage: not in " + "length on purpose"), + 512); + listHolder_0->mList[3] = chip::ByteSpan( + chip::Uint8::from_const_char( + "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789" + "abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123" + "456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcd" + "ef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef01234567" + "89abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdefgarbage: not in " + "length on purpose"), + 512); + value = chip::app::DataModel::List(listHolder_0->mList, 4); + } + return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::ListLongOctetString::Id, + value, chip::NullOptional, chip::NullOptional); + } + case 137: { + LogStep(137, "Read attribute EPOCH_US Default Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::EpochUs::Id, true, chip::NullOptional); } - case 137: { - LogStep(137, "Write attribute EPOCH_US Max Value"); + case 138: { + LogStep(138, "Write attribute EPOCH_US Max Value"); ListFreer listFreer; uint64_t value; value = 18446744073709551615ULL; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::EpochUs::Id, value, chip::NullOptional, chip::NullOptional); } - case 138: { - LogStep(138, "Read attribute EPOCH_US Max Value"); + case 139: { + LogStep(139, "Read attribute EPOCH_US Max Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::EpochUs::Id, true, chip::NullOptional); } - case 139: { - LogStep(139, "Write attribute EPOCH_US Min Value"); + case 140: { + LogStep(140, "Write attribute EPOCH_US Min Value"); ListFreer listFreer; uint64_t value; value = 0ULL; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::EpochUs::Id, value, chip::NullOptional, chip::NullOptional); } - case 140: { - LogStep(140, "Read attribute EPOCH_US Min Value"); + case 141: { + LogStep(141, "Read attribute EPOCH_US Min Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::EpochUs::Id, true, chip::NullOptional); } - case 141: { - LogStep(141, "Read attribute EPOCH_S Default Value"); + case 142: { + LogStep(142, "Read attribute EPOCH_S Default Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::EpochS::Id, true, chip::NullOptional); } - case 142: { - LogStep(142, "Write attribute EPOCH_S Max Value"); + case 143: { + LogStep(143, "Write attribute EPOCH_S Max Value"); ListFreer listFreer; uint32_t value; value = 4294967295UL; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::EpochS::Id, value, chip::NullOptional, chip::NullOptional); } - case 143: { - LogStep(143, "Read attribute EPOCH_S Max Value"); + case 144: { + LogStep(144, "Read attribute EPOCH_S Max Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::EpochS::Id, true, chip::NullOptional); } - case 144: { - LogStep(144, "Write attribute EPOCH_S Min Value"); + case 145: { + LogStep(145, "Write attribute EPOCH_S Min Value"); ListFreer listFreer; uint32_t value; value = 0UL; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::EpochS::Id, value, chip::NullOptional, chip::NullOptional); } - case 145: { - LogStep(145, "Read attribute EPOCH_S Min Value"); + case 146: { + LogStep(146, "Read attribute EPOCH_S Min Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::EpochS::Id, true, chip::NullOptional); } - case 146: { - LogStep(146, "Read attribute UNSUPPORTED"); + case 147: { + LogStep(147, "Read attribute UNSUPPORTED"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::Unsupported::Id, true, chip::NullOptional); } - case 147: { - LogStep(147, "Writeattribute UNSUPPORTED"); + case 148: { + LogStep(148, "Writeattribute UNSUPPORTED"); ListFreer listFreer; bool value; value = 0; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::Unsupported::Id, value, chip::NullOptional, chip::NullOptional); } - case 148: { - LogStep(148, "Send Test Command to unsupported endpoint"); + case 149: { + LogStep(149, "Send Test Command to unsupported endpoint"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::Test::Type value; return SendCommand(kIdentityAlpha, GetEndpoint(200), UnitTesting::Id, UnitTesting::Commands::Test::Id, value, @@ -52278,8 +54738,8 @@ class TestClusterSuite : public TestCommand ); } - case 149: { - LogStep(149, "Send Test Command to unsupported cluster"); + case 150: { + LogStep(150, "Send Test Command to unsupported cluster"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::Test::Type value; return SendCommand(kIdentityAlpha, GetEndpoint(0), UnitTesting::Id, UnitTesting::Commands::Test::Id, value, @@ -52287,34 +54747,34 @@ class TestClusterSuite : public TestCommand ); } - case 150: { - LogStep(150, "Read attribute vendor_id Default Value"); + case 151: { + LogStep(151, "Read attribute vendor_id Default Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::VendorId::Id, true, chip::NullOptional); } - case 151: { - LogStep(151, "Write attribute vendor_id"); + case 152: { + LogStep(152, "Write attribute vendor_id"); ListFreer listFreer; chip::VendorId value; value = static_cast(17); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::VendorId::Id, value, chip::NullOptional, chip::NullOptional); } - case 152: { - LogStep(152, "Read attribute vendor_id"); + case 153: { + LogStep(153, "Read attribute vendor_id"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::VendorId::Id, true, chip::NullOptional); } - case 153: { - LogStep(153, "Restore attribute vendor_id"); + case 154: { + LogStep(154, "Restore attribute vendor_id"); ListFreer listFreer; chip::VendorId value; value = static_cast(0); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::VendorId::Id, value, chip::NullOptional, chip::NullOptional); } - case 154: { - LogStep(154, "Send a command with a vendor_id and enum"); + case 155: { + LogStep(155, "Send a command with a vendor_id and enum"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestEnumsRequest::Type value; value.arg1 = static_cast(20003); @@ -52324,8 +54784,8 @@ class TestClusterSuite : public TestCommand ); } - case 155: { - LogStep(155, "Send a command with a vendor_id and invalid enum"); + case 156: { + LogStep(156, "Send a command with a vendor_id and invalid enum"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestEnumsRequest::Type value; value.arg1 = static_cast(20003); @@ -52335,8 +54795,8 @@ class TestClusterSuite : public TestCommand ); } - case 156: { - LogStep(156, "Send Test Command With Struct Argument and arg1.b is true"); + case 157: { + LogStep(157, "Send Test Command With Struct Argument and arg1.b is true"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestStructArgumentRequest::Type value; @@ -52354,8 +54814,8 @@ class TestClusterSuite : public TestCommand ); } - case 157: { - LogStep(157, "Send Test Command With Struct Argument and arg1.b is false"); + case 158: { + LogStep(158, "Send Test Command With Struct Argument and arg1.b is false"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestStructArgumentRequest::Type value; @@ -52373,8 +54833,8 @@ class TestClusterSuite : public TestCommand ); } - case 158: { - LogStep(158, "Send Test Command With Nested Struct Argument and arg1.c.b is true"); + case 159: { + LogStep(159, "Send Test Command With Nested Struct Argument and arg1.c.b is true"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestNestedStructArgumentRequest::Type value; @@ -52395,8 +54855,8 @@ class TestClusterSuite : public TestCommand ); } - case 159: { - LogStep(159, "Send Test Command With Nested Struct Argument arg1.c.b is false"); + case 160: { + LogStep(160, "Send Test Command With Nested Struct Argument arg1.c.b is false"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestNestedStructArgumentRequest::Type value; @@ -52417,8 +54877,8 @@ class TestClusterSuite : public TestCommand ); } - case 160: { - LogStep(160, "Send Test Command With Nested Struct List Argument and all fields b of arg1.d are true"); + case 161: { + LogStep(161, "Send Test Command With Nested Struct List Argument and all fields b of arg1.d are true"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestNestedStructListArgumentRequest::Type value; @@ -52496,8 +54956,8 @@ class TestClusterSuite : public TestCommand ); } - case 161: { - LogStep(161, "Send Test Command With Nested Struct List Argument and some fields b of arg1.d are false"); + case 162: { + LogStep(162, "Send Test Command With Nested Struct List Argument and some fields b of arg1.d are false"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestNestedStructListArgumentRequest::Type value; @@ -52575,8 +55035,8 @@ class TestClusterSuite : public TestCommand ); } - case 162: { - LogStep(162, "Send Test Command With Struct Argument and see what we get back"); + case 163: { + LogStep(163, "Send Test Command With Struct Argument and see what we get back"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::SimpleStructEchoRequest::Type value; @@ -52594,8 +55054,8 @@ class TestClusterSuite : public TestCommand ); } - case 163: { - LogStep(163, "Send Test Command With List of INT8U and none of them is set to 0"); + case 164: { + LogStep(164, "Send Test Command With List of INT8U and none of them is set to 0"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestListInt8UArgumentRequest::Type value; @@ -52618,8 +55078,8 @@ class TestClusterSuite : public TestCommand ); } - case 164: { - LogStep(164, "Send Test Command With List of INT8U and one of them is set to 0"); + case 165: { + LogStep(165, "Send Test Command With List of INT8U and one of them is set to 0"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestListInt8UArgumentRequest::Type value; @@ -52643,8 +55103,8 @@ class TestClusterSuite : public TestCommand ); } - case 165: { - LogStep(165, "Send Test Command With List of INT8U and get it reversed"); + case 166: { + LogStep(166, "Send Test Command With List of INT8U and get it reversed"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestListInt8UReverseRequest::Type value; @@ -52667,8 +55127,8 @@ class TestClusterSuite : public TestCommand ); } - case 166: { - LogStep(166, "Send Test Command With empty List of INT8U and get an empty list back"); + case 167: { + LogStep(167, "Send Test Command With empty List of INT8U and get an empty list back"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestListInt8UReverseRequest::Type value; @@ -52678,8 +55138,8 @@ class TestClusterSuite : public TestCommand ); } - case 167: { - LogStep(167, "Send Test Command With List of Struct Argument and arg1.b of first item is true"); + case 168: { + LogStep(168, "Send Test Command With List of Struct Argument and arg1.b of first item is true"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestListStructArgumentRequest::Type value; @@ -52715,8 +55175,8 @@ class TestClusterSuite : public TestCommand ); } - case 168: { - LogStep(168, "Send Test Command With List of Struct Argument and arg1.b of first item is false"); + case 169: { + LogStep(169, "Send Test Command With List of Struct Argument and arg1.b of first item is false"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestListStructArgumentRequest::Type value; @@ -52752,8 +55212,8 @@ class TestClusterSuite : public TestCommand ); } - case 169: { - LogStep(169, + case 170: { + LogStep(170, "Send Test Command With List of Nested Struct List Argument and all fields b of elements of arg1.d are true"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestListNestedStructListArgumentRequest::Type value; @@ -52841,8 +55301,8 @@ class TestClusterSuite : public TestCommand ); } - case 170: { - LogStep(170, "Send Test Command With Nested Struct List Argument and some fields b of elements of arg1.d are false"); + case 171: { + LogStep(171, "Send Test Command With Nested Struct List Argument and some fields b of elements of arg1.d are false"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestListNestedStructListArgumentRequest::Type value; @@ -52929,8 +55389,8 @@ class TestClusterSuite : public TestCommand ); } - case 171: { - LogStep(171, "Write attribute LIST With List of INT8U and none of them is set to 0"); + case 172: { + LogStep(172, "Write attribute LIST With List of INT8U and none of them is set to 0"); ListFreer listFreer; chip::app::DataModel::List value; @@ -52946,13 +55406,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::ListInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 172: { - LogStep(172, "Read attribute LIST With List of INT8U"); + case 173: { + LogStep(173, "Read attribute LIST With List of INT8U"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::ListInt8u::Id, true, chip::NullOptional); } - case 173: { - LogStep(173, "Write attribute LIST With List of OCTET_STRING"); + case 174: { + LogStep(174, "Write attribute LIST With List of OCTET_STRING"); ListFreer listFreer; chip::app::DataModel::List value; @@ -52968,13 +55428,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::ListOctetString::Id, value, chip::NullOptional, chip::NullOptional); } - case 174: { - LogStep(174, "Read attribute LIST With List of OCTET_STRING"); + case 175: { + LogStep(175, "Read attribute LIST With List of OCTET_STRING"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::ListOctetString::Id, true, chip::NullOptional); } - case 175: { - LogStep(175, "Write attribute LIST With List of LIST_STRUCT_OCTET_STRING"); + case 176: { + LogStep(176, "Write attribute LIST With List of LIST_STRUCT_OCTET_STRING"); ListFreer listFreer; chip::app::DataModel::List value; @@ -53005,13 +55465,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::ListStructOctetString::Id, value, chip::NullOptional, chip::NullOptional); } - case 176: { - LogStep(176, "Read attribute LIST With List of LIST_STRUCT_OCTET_STRING"); + case 177: { + LogStep(177, "Read attribute LIST With List of LIST_STRUCT_OCTET_STRING"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::ListStructOctetString::Id, true, chip::NullOptional); } - case 177: { - LogStep(177, "Send Test Command with optional arg set."); + case 178: { + LogStep(178, "Send Test Command with optional arg set."); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestNullableOptionalRequest::Type value; value.arg1.Emplace(); @@ -53022,8 +55482,8 @@ class TestClusterSuite : public TestCommand ); } - case 178: { - LogStep(178, "Send Test Command without its optional arg."); + case 179: { + LogStep(179, "Send Test Command without its optional arg."); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestNullableOptionalRequest::Type value; return SendCommand(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, @@ -53031,13 +55491,13 @@ class TestClusterSuite : public TestCommand ); } - case 179: { - LogStep(179, "Read list of structs containing nullables and optionals"); + case 180: { + LogStep(180, "Read list of structs containing nullables and optionals"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::ListNullablesAndOptionalsStruct::Id, true, chip::NullOptional); } - case 180: { - LogStep(180, "Write list of structs containing nullables and optionals"); + case 181: { + LogStep(181, "Write list of structs containing nullables and optionals"); ListFreer listFreer; chip::app::DataModel::List value; @@ -53067,26 +55527,26 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::ListNullablesAndOptionalsStruct::Id, value, chip::NullOptional, chip::NullOptional); } - case 181: { - LogStep(181, "Read list of structs containing nullables and optionals after writing"); + case 182: { + LogStep(182, "Read list of structs containing nullables and optionals after writing"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::ListNullablesAndOptionalsStruct::Id, true, chip::NullOptional); } - case 182: { - LogStep(182, "Write attribute NULLABLE_BOOLEAN null"); + case 183: { + LogStep(183, "Write attribute NULLABLE_BOOLEAN null"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBoolean::Id, value, chip::NullOptional, chip::NullOptional); } - case 183: { - LogStep(183, "Read attribute NULLABLE_BOOLEAN null"); + case 184: { + LogStep(184, "Read attribute NULLABLE_BOOLEAN null"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBoolean::Id, true, chip::NullOptional); } - case 184: { - LogStep(184, "Write attribute NULLABLE_BOOLEAN True"); + case 185: { + LogStep(185, "Write attribute NULLABLE_BOOLEAN True"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53094,18 +55554,18 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBoolean::Id, value, chip::NullOptional, chip::NullOptional); } - case 185: { - LogStep(185, "Read attribute NULLABLE_BOOLEAN True"); + case 186: { + LogStep(186, "Read attribute NULLABLE_BOOLEAN True"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBoolean::Id, true, chip::NullOptional); } - case 186: { - LogStep(186, "Read attribute NULLABLE_BOOLEAN not null"); + case 187: { + LogStep(187, "Read attribute NULLABLE_BOOLEAN not null"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBoolean::Id, true, chip::NullOptional); } - case 187: { - LogStep(187, "Write attribute NULLABLE_BITMAP8 Max Value"); + case 188: { + LogStep(188, "Write attribute NULLABLE_BITMAP8 Max Value"); ListFreer listFreer; chip::app::DataModel::Nullable> value; value.SetNonNull(); @@ -53113,13 +55573,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap8::Id, value, chip::NullOptional, chip::NullOptional); } - case 188: { - LogStep(188, "Read attribute NULLABLE_BITMAP8 Max Value"); + case 189: { + LogStep(189, "Read attribute NULLABLE_BITMAP8 Max Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap8::Id, true, chip::NullOptional); } - case 189: { - LogStep(189, "Write attribute NULLABLE_BITMAP8 Invalid Value"); + case 190: { + LogStep(190, "Write attribute NULLABLE_BITMAP8 Invalid Value"); ListFreer listFreer; chip::app::DataModel::Nullable> value; value.SetNonNull(); @@ -53127,31 +55587,31 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap8::Id, value, chip::NullOptional, chip::NullOptional); } - case 190: { - LogStep(190, "Read attribute NULLABLE_BITMAP8 unchanged Value"); + case 191: { + LogStep(191, "Read attribute NULLABLE_BITMAP8 unchanged Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap8::Id, true, chip::NullOptional); } - case 191: { - LogStep(191, "Write attribute NULLABLE_BITMAP8 null Value"); + case 192: { + LogStep(192, "Write attribute NULLABLE_BITMAP8 null Value"); ListFreer listFreer; chip::app::DataModel::Nullable> value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap8::Id, value, chip::NullOptional, chip::NullOptional); } - case 192: { - LogStep(192, "Read attribute NULLABLE_BITMAP8 null Value"); + case 193: { + LogStep(193, "Read attribute NULLABLE_BITMAP8 null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap8::Id, true, chip::NullOptional); } - case 193: { - LogStep(193, "Read attribute NULLABLE_BITMAP8 not 254 Value"); + case 194: { + LogStep(194, "Read attribute NULLABLE_BITMAP8 not 254 Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap8::Id, true, chip::NullOptional); } - case 194: { - LogStep(194, "Write attribute NULLABLE_BITMAP16 Max Value"); + case 195: { + LogStep(195, "Write attribute NULLABLE_BITMAP16 Max Value"); ListFreer listFreer; chip::app::DataModel::Nullable> value; value.SetNonNull(); @@ -53159,13 +55619,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap16::Id, value, chip::NullOptional, chip::NullOptional); } - case 195: { - LogStep(195, "Read attribute NULLABLE_BITMAP16 Max Value"); + case 196: { + LogStep(196, "Read attribute NULLABLE_BITMAP16 Max Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap16::Id, true, chip::NullOptional); } - case 196: { - LogStep(196, "Write attribute NULLABLE_BITMAP16 Invalid Value"); + case 197: { + LogStep(197, "Write attribute NULLABLE_BITMAP16 Invalid Value"); ListFreer listFreer; chip::app::DataModel::Nullable> value; value.SetNonNull(); @@ -53173,26 +55633,26 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap16::Id, value, chip::NullOptional, chip::NullOptional); } - case 197: { - LogStep(197, "Read attribute NULLABLE_BITMAP16 unchanged Value"); + case 198: { + LogStep(198, "Read attribute NULLABLE_BITMAP16 unchanged Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap16::Id, true, chip::NullOptional); } - case 198: { - LogStep(198, "Write attribute NULLABLE_BITMAP16 null Value"); + case 199: { + LogStep(199, "Write attribute NULLABLE_BITMAP16 null Value"); ListFreer listFreer; chip::app::DataModel::Nullable> value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap16::Id, value, chip::NullOptional, chip::NullOptional); } - case 199: { - LogStep(199, "Read attribute NULLABLE_BITMAP16 null Value"); + case 200: { + LogStep(200, "Read attribute NULLABLE_BITMAP16 null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap16::Id, true, chip::NullOptional); } - case 200: { - LogStep(200, "Write attribute NULLABLE_BITMAP32 Max Value"); + case 201: { + LogStep(201, "Write attribute NULLABLE_BITMAP32 Max Value"); ListFreer listFreer; chip::app::DataModel::Nullable> value; value.SetNonNull(); @@ -53200,13 +55660,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap32::Id, value, chip::NullOptional, chip::NullOptional); } - case 201: { - LogStep(201, "Read attribute NULLABLE_BITMAP32 Max Value"); + case 202: { + LogStep(202, "Read attribute NULLABLE_BITMAP32 Max Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap32::Id, true, chip::NullOptional); } - case 202: { - LogStep(202, "Write attribute NULLABLE_BITMAP32 Invalid Value"); + case 203: { + LogStep(203, "Write attribute NULLABLE_BITMAP32 Invalid Value"); ListFreer listFreer; chip::app::DataModel::Nullable> value; value.SetNonNull(); @@ -53214,26 +55674,26 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap32::Id, value, chip::NullOptional, chip::NullOptional); } - case 203: { - LogStep(203, "Read attribute NULLABLE_BITMAP32 unchanged Value"); + case 204: { + LogStep(204, "Read attribute NULLABLE_BITMAP32 unchanged Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap32::Id, true, chip::NullOptional); } - case 204: { - LogStep(204, "Write attribute NULLABLE_BITMAP32 null Value"); + case 205: { + LogStep(205, "Write attribute NULLABLE_BITMAP32 null Value"); ListFreer listFreer; chip::app::DataModel::Nullable> value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap32::Id, value, chip::NullOptional, chip::NullOptional); } - case 205: { - LogStep(205, "Read attribute NULLABLE_BITMAP32 null Value"); + case 206: { + LogStep(206, "Read attribute NULLABLE_BITMAP32 null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap32::Id, true, chip::NullOptional); } - case 206: { - LogStep(206, "Write attribute NULLABLE_BITMAP64 Max Value"); + case 207: { + LogStep(207, "Write attribute NULLABLE_BITMAP64 Max Value"); ListFreer listFreer; chip::app::DataModel::Nullable> value; value.SetNonNull(); @@ -53241,13 +55701,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap64::Id, value, chip::NullOptional, chip::NullOptional); } - case 207: { - LogStep(207, "Read attribute NULLABLE_BITMAP64 Max Value"); + case 208: { + LogStep(208, "Read attribute NULLABLE_BITMAP64 Max Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap64::Id, true, chip::NullOptional); } - case 208: { - LogStep(208, "Write attribute NULLABLE_BITMAP64 Invalid Value"); + case 209: { + LogStep(209, "Write attribute NULLABLE_BITMAP64 Invalid Value"); ListFreer listFreer; chip::app::DataModel::Nullable> value; value.SetNonNull(); @@ -53255,26 +55715,26 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap64::Id, value, chip::NullOptional, chip::NullOptional); } - case 209: { - LogStep(209, "Read attribute NULLABLE_BITMAP64 unchanged Value"); + case 210: { + LogStep(210, "Read attribute NULLABLE_BITMAP64 unchanged Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap64::Id, true, chip::NullOptional); } - case 210: { - LogStep(210, "Write attribute NULLABLE_BITMAP64 null Value"); + case 211: { + LogStep(211, "Write attribute NULLABLE_BITMAP64 null Value"); ListFreer listFreer; chip::app::DataModel::Nullable> value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap64::Id, value, chip::NullOptional, chip::NullOptional); } - case 211: { - LogStep(211, "Read attribute NULLABLE_BITMAP64 null Value"); + case 212: { + LogStep(212, "Read attribute NULLABLE_BITMAP64 null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableBitmap64::Id, true, chip::NullOptional); } - case 212: { - LogStep(212, "Write attribute NULLABLE_INT8U Min Value"); + case 213: { + LogStep(213, "Write attribute NULLABLE_INT8U Min Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53282,13 +55742,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 213: { - LogStep(213, "Read attribute NULLABLE_INT8U Min Value"); + case 214: { + LogStep(214, "Read attribute NULLABLE_INT8U Min Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8u::Id, true, chip::NullOptional); } - case 214: { - LogStep(214, "Write attribute NULLABLE_INT8U Max Value"); + case 215: { + LogStep(215, "Write attribute NULLABLE_INT8U Max Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53296,13 +55756,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 215: { - LogStep(215, "Read attribute NULLABLE_INT8U Max Value"); + case 216: { + LogStep(216, "Read attribute NULLABLE_INT8U Max Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8u::Id, true, chip::NullOptional); } - case 216: { - LogStep(216, "Write attribute NULLABLE_INT8U Invalid Value"); + case 217: { + LogStep(217, "Write attribute NULLABLE_INT8U Invalid Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53310,41 +55770,41 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 217: { - LogStep(217, "Read attribute NULLABLE_INT8U unchanged Value"); + case 218: { + LogStep(218, "Read attribute NULLABLE_INT8U unchanged Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8u::Id, true, chip::NullOptional); } - case 218: { - LogStep(218, "Read attribute NULLABLE_INT8U unchanged Value with constraint"); + case 219: { + LogStep(219, "Read attribute NULLABLE_INT8U unchanged Value with constraint"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8u::Id, true, chip::NullOptional); } - case 219: { - LogStep(219, "Write attribute NULLABLE_INT8U null Value"); + case 220: { + LogStep(220, "Write attribute NULLABLE_INT8U null Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 220: { - LogStep(220, "Read attribute NULLABLE_INT8U null Value"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8u::Id, true, - chip::NullOptional); - } case 221: { - LogStep(221, "Read attribute NULLABLE_INT8U null Value & range"); + LogStep(221, "Read attribute NULLABLE_INT8U null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8u::Id, true, chip::NullOptional); } case 222: { - LogStep(222, "Read attribute NULLABLE_INT8U null Value & not"); + LogStep(222, "Read attribute NULLABLE_INT8U null Value & range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8u::Id, true, chip::NullOptional); } case 223: { - LogStep(223, "Write attribute NULLABLE_INT8U Value"); + LogStep(223, "Read attribute NULLABLE_INT8U null Value & not"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8u::Id, true, + chip::NullOptional); + } + case 224: { + LogStep(224, "Write attribute NULLABLE_INT8U Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53352,18 +55812,18 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 224: { - LogStep(224, "Read attribute NULLABLE_INT8U Value in range"); + case 225: { + LogStep(225, "Read attribute NULLABLE_INT8U Value in range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8u::Id, true, chip::NullOptional); } - case 225: { - LogStep(225, "Read attribute NULLABLE_INT8U notValue OK"); + case 226: { + LogStep(226, "Read attribute NULLABLE_INT8U notValue OK"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8u::Id, true, chip::NullOptional); } - case 226: { - LogStep(226, "Write attribute NULLABLE_INT16U Min Value"); + case 227: { + LogStep(227, "Write attribute NULLABLE_INT16U Min Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53371,13 +55831,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 227: { - LogStep(227, "Read attribute NULLABLE_INT16U Min Value"); + case 228: { + LogStep(228, "Read attribute NULLABLE_INT16U Min Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16u::Id, true, chip::NullOptional); } - case 228: { - LogStep(228, "Write attribute NULLABLE_INT16U Max Value"); + case 229: { + LogStep(229, "Write attribute NULLABLE_INT16U Max Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53385,13 +55845,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 229: { - LogStep(229, "Read attribute NULLABLE_INT16U Max Value"); + case 230: { + LogStep(230, "Read attribute NULLABLE_INT16U Max Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16u::Id, true, chip::NullOptional); } - case 230: { - LogStep(230, "Write attribute NULLABLE_INT16U Invalid Value"); + case 231: { + LogStep(231, "Write attribute NULLABLE_INT16U Invalid Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53399,36 +55859,36 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 231: { - LogStep(231, "Read attribute NULLABLE_INT16U unchanged Value"); + case 232: { + LogStep(232, "Read attribute NULLABLE_INT16U unchanged Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16u::Id, true, chip::NullOptional); } - case 232: { - LogStep(232, "Write attribute NULLABLE_INT16U null Value"); + case 233: { + LogStep(233, "Write attribute NULLABLE_INT16U null Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 233: { - LogStep(233, "Read attribute NULLABLE_INT16U null Value"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16u::Id, true, - chip::NullOptional); - } case 234: { - LogStep(234, "Read attribute NULLABLE_INT16U null Value & range"); + LogStep(234, "Read attribute NULLABLE_INT16U null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16u::Id, true, chip::NullOptional); } case 235: { - LogStep(235, "Read attribute NULLABLE_INT16U null Value & not"); + LogStep(235, "Read attribute NULLABLE_INT16U null Value & range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16u::Id, true, chip::NullOptional); } case 236: { - LogStep(236, "Write attribute NULLABLE_INT16U Value"); + LogStep(236, "Read attribute NULLABLE_INT16U null Value & not"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16u::Id, true, + chip::NullOptional); + } + case 237: { + LogStep(237, "Write attribute NULLABLE_INT16U Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53436,18 +55896,18 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 237: { - LogStep(237, "Read attribute NULLABLE_INT16U Value in range"); + case 238: { + LogStep(238, "Read attribute NULLABLE_INT16U Value in range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16u::Id, true, chip::NullOptional); } - case 238: { - LogStep(238, "Read attribute NULLABLE_INT16U notValue OK"); + case 239: { + LogStep(239, "Read attribute NULLABLE_INT16U notValue OK"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16u::Id, true, chip::NullOptional); } - case 239: { - LogStep(239, "Write attribute NULLABLE_INT32U Min Value"); + case 240: { + LogStep(240, "Write attribute NULLABLE_INT32U Min Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53455,13 +55915,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32u::Id, value, chip::NullOptional, chip::NullOptional); } - case 240: { - LogStep(240, "Read attribute NULLABLE_INT32U Min Value"); + case 241: { + LogStep(241, "Read attribute NULLABLE_INT32U Min Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32u::Id, true, chip::NullOptional); } - case 241: { - LogStep(241, "Write attribute NULLABLE_INT32U Max Value"); + case 242: { + LogStep(242, "Write attribute NULLABLE_INT32U Max Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53469,13 +55929,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32u::Id, value, chip::NullOptional, chip::NullOptional); } - case 242: { - LogStep(242, "Read attribute NULLABLE_INT32U Max Value"); + case 243: { + LogStep(243, "Read attribute NULLABLE_INT32U Max Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32u::Id, true, chip::NullOptional); } - case 243: { - LogStep(243, "Write attribute NULLABLE_INT32U Invalid Value"); + case 244: { + LogStep(244, "Write attribute NULLABLE_INT32U Invalid Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53483,36 +55943,36 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32u::Id, value, chip::NullOptional, chip::NullOptional); } - case 244: { - LogStep(244, "Read attribute NULLABLE_INT32U unchanged Value"); + case 245: { + LogStep(245, "Read attribute NULLABLE_INT32U unchanged Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32u::Id, true, chip::NullOptional); } - case 245: { - LogStep(245, "Write attribute NULLABLE_INT32U null Value"); + case 246: { + LogStep(246, "Write attribute NULLABLE_INT32U null Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32u::Id, value, chip::NullOptional, chip::NullOptional); } - case 246: { - LogStep(246, "Read attribute NULLABLE_INT32U null Value"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32u::Id, true, - chip::NullOptional); - } case 247: { - LogStep(247, "Read attribute NULLABLE_INT32U null Value & range"); + LogStep(247, "Read attribute NULLABLE_INT32U null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32u::Id, true, chip::NullOptional); } case 248: { - LogStep(248, "Read attribute NULLABLE_INT32U null Value & not"); + LogStep(248, "Read attribute NULLABLE_INT32U null Value & range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32u::Id, true, chip::NullOptional); } case 249: { - LogStep(249, "Write attribute NULLABLE_INT32U Value"); + LogStep(249, "Read attribute NULLABLE_INT32U null Value & not"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32u::Id, true, + chip::NullOptional); + } + case 250: { + LogStep(250, "Write attribute NULLABLE_INT32U Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53520,18 +55980,18 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32u::Id, value, chip::NullOptional, chip::NullOptional); } - case 250: { - LogStep(250, "Read attribute NULLABLE_INT32U Value in range"); + case 251: { + LogStep(251, "Read attribute NULLABLE_INT32U Value in range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32u::Id, true, chip::NullOptional); } - case 251: { - LogStep(251, "Read attribute NULLABLE_INT32U notValue OK"); + case 252: { + LogStep(252, "Read attribute NULLABLE_INT32U notValue OK"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32u::Id, true, chip::NullOptional); } - case 252: { - LogStep(252, "Write attribute NULLABLE_INT64U Min Value"); + case 253: { + LogStep(253, "Write attribute NULLABLE_INT64U Min Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53539,13 +55999,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64u::Id, value, chip::NullOptional, chip::NullOptional); } - case 253: { - LogStep(253, "Read attribute NULLABLE_INT64U Min Value"); + case 254: { + LogStep(254, "Read attribute NULLABLE_INT64U Min Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64u::Id, true, chip::NullOptional); } - case 254: { - LogStep(254, "Write attribute NULLABLE_INT64U Max Value"); + case 255: { + LogStep(255, "Write attribute NULLABLE_INT64U Max Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53553,13 +56013,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64u::Id, value, chip::NullOptional, chip::NullOptional); } - case 255: { - LogStep(255, "Read attribute NULLABLE_INT64U Max Value"); + case 256: { + LogStep(256, "Read attribute NULLABLE_INT64U Max Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64u::Id, true, chip::NullOptional); } - case 256: { - LogStep(256, "Write attribute NULLABLE_INT64U Invalid Value"); + case 257: { + LogStep(257, "Write attribute NULLABLE_INT64U Invalid Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53567,36 +56027,36 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64u::Id, value, chip::NullOptional, chip::NullOptional); } - case 257: { - LogStep(257, "Read attribute NULLABLE_INT64U unchanged Value"); + case 258: { + LogStep(258, "Read attribute NULLABLE_INT64U unchanged Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64u::Id, true, chip::NullOptional); } - case 258: { - LogStep(258, "Write attribute NULLABLE_INT64U null Value"); + case 259: { + LogStep(259, "Write attribute NULLABLE_INT64U null Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64u::Id, value, chip::NullOptional, chip::NullOptional); } - case 259: { - LogStep(259, "Read attribute NULLABLE_INT64U null Value"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64u::Id, true, - chip::NullOptional); - } case 260: { - LogStep(260, "Read attribute NULLABLE_INT64U null Value & range"); + LogStep(260, "Read attribute NULLABLE_INT64U null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64u::Id, true, chip::NullOptional); } case 261: { - LogStep(261, "Read attribute NULLABLE_INT64U null Value & not"); + LogStep(261, "Read attribute NULLABLE_INT64U null Value & range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64u::Id, true, chip::NullOptional); } case 262: { - LogStep(262, "Write attribute NULLABLE_INT64U Value"); + LogStep(262, "Read attribute NULLABLE_INT64U null Value & not"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64u::Id, true, + chip::NullOptional); + } + case 263: { + LogStep(263, "Write attribute NULLABLE_INT64U Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53604,18 +56064,18 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64u::Id, value, chip::NullOptional, chip::NullOptional); } - case 263: { - LogStep(263, "Read attribute NULLABLE_INT64U Value in range"); + case 264: { + LogStep(264, "Read attribute NULLABLE_INT64U Value in range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64u::Id, true, chip::NullOptional); } - case 264: { - LogStep(264, "Read attribute NULLABLE_INT64U notValue OK"); + case 265: { + LogStep(265, "Read attribute NULLABLE_INT64U notValue OK"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64u::Id, true, chip::NullOptional); } - case 265: { - LogStep(265, "Write attribute NULLABLE_INT8S Min Value"); + case 266: { + LogStep(266, "Write attribute NULLABLE_INT8S Min Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53623,13 +56083,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 266: { - LogStep(266, "Read attribute NULLABLE_INT8S Min Value"); + case 267: { + LogStep(267, "Read attribute NULLABLE_INT8S Min Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8s::Id, true, chip::NullOptional); } - case 267: { - LogStep(267, "Write attribute NULLABLE_INT8S Invalid Value"); + case 268: { + LogStep(268, "Write attribute NULLABLE_INT8S Invalid Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53637,36 +56097,36 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 268: { - LogStep(268, "Read attribute NULLABLE_INT8S unchanged Value"); + case 269: { + LogStep(269, "Read attribute NULLABLE_INT8S unchanged Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8s::Id, true, chip::NullOptional); } - case 269: { - LogStep(269, "Write attribute NULLABLE_INT8S null Value"); + case 270: { + LogStep(270, "Write attribute NULLABLE_INT8S null Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 270: { - LogStep(270, "Read attribute NULLABLE_INT8S null Value"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8s::Id, true, - chip::NullOptional); - } case 271: { - LogStep(271, "Read attribute NULLABLE_INT8S null Value & range"); + LogStep(271, "Read attribute NULLABLE_INT8S null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8s::Id, true, chip::NullOptional); } case 272: { - LogStep(272, "Read attribute NULLABLE_INT8S null Value & not"); + LogStep(272, "Read attribute NULLABLE_INT8S null Value & range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8s::Id, true, chip::NullOptional); } case 273: { - LogStep(273, "Write attribute NULLABLE_INT8S Value"); + LogStep(273, "Read attribute NULLABLE_INT8S null Value & not"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8s::Id, true, + chip::NullOptional); + } + case 274: { + LogStep(274, "Write attribute NULLABLE_INT8S Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53674,18 +56134,18 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 274: { - LogStep(274, "Read attribute NULLABLE_INT8S Value in range"); + case 275: { + LogStep(275, "Read attribute NULLABLE_INT8S Value in range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8s::Id, true, chip::NullOptional); } - case 275: { - LogStep(275, "Read attribute NULLABLE_INT8S notValue OK"); + case 276: { + LogStep(276, "Read attribute NULLABLE_INT8S notValue OK"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt8s::Id, true, chip::NullOptional); } - case 276: { - LogStep(276, "Write attribute NULLABLE_INT16S Min Value"); + case 277: { + LogStep(277, "Write attribute NULLABLE_INT16S Min Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53693,13 +56153,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 277: { - LogStep(277, "Read attribute NULLABLE_INT16S Min Value"); + case 278: { + LogStep(278, "Read attribute NULLABLE_INT16S Min Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16s::Id, true, chip::NullOptional); } - case 278: { - LogStep(278, "Write attribute NULLABLE_INT16S Invalid Value"); + case 279: { + LogStep(279, "Write attribute NULLABLE_INT16S Invalid Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53707,36 +56167,36 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 279: { - LogStep(279, "Read attribute NULLABLE_INT16S unchanged Value"); + case 280: { + LogStep(280, "Read attribute NULLABLE_INT16S unchanged Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16s::Id, true, chip::NullOptional); } - case 280: { - LogStep(280, "Write attribute NULLABLE_INT16S null Value"); + case 281: { + LogStep(281, "Write attribute NULLABLE_INT16S null Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 281: { - LogStep(281, "Read attribute NULLABLE_INT16S null Value"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16s::Id, true, - chip::NullOptional); - } case 282: { - LogStep(282, "Read attribute NULLABLE_INT16S null Value & range"); + LogStep(282, "Read attribute NULLABLE_INT16S null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16s::Id, true, chip::NullOptional); } case 283: { - LogStep(283, "Read attribute NULLABLE_INT16S null Value & not"); + LogStep(283, "Read attribute NULLABLE_INT16S null Value & range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16s::Id, true, chip::NullOptional); } case 284: { - LogStep(284, "Write attribute NULLABLE_INT16S Value"); + LogStep(284, "Read attribute NULLABLE_INT16S null Value & not"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16s::Id, true, + chip::NullOptional); + } + case 285: { + LogStep(285, "Write attribute NULLABLE_INT16S Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53744,18 +56204,18 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 285: { - LogStep(285, "Read attribute NULLABLE_INT16S Value in range"); + case 286: { + LogStep(286, "Read attribute NULLABLE_INT16S Value in range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16s::Id, true, chip::NullOptional); } - case 286: { - LogStep(286, "Read attribute NULLABLE_INT16S notValue OK"); + case 287: { + LogStep(287, "Read attribute NULLABLE_INT16S notValue OK"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt16s::Id, true, chip::NullOptional); } - case 287: { - LogStep(287, "Write attribute NULLABLE_INT32S Min Value"); + case 288: { + LogStep(288, "Write attribute NULLABLE_INT32S Min Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53763,13 +56223,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32s::Id, value, chip::NullOptional, chip::NullOptional); } - case 288: { - LogStep(288, "Read attribute NULLABLE_INT32S Min Value"); + case 289: { + LogStep(289, "Read attribute NULLABLE_INT32S Min Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32s::Id, true, chip::NullOptional); } - case 289: { - LogStep(289, "Write attribute NULLABLE_INT32S Invalid Value"); + case 290: { + LogStep(290, "Write attribute NULLABLE_INT32S Invalid Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53777,36 +56237,36 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32s::Id, value, chip::NullOptional, chip::NullOptional); } - case 290: { - LogStep(290, "Read attribute NULLABLE_INT32S unchanged Value"); + case 291: { + LogStep(291, "Read attribute NULLABLE_INT32S unchanged Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32s::Id, true, chip::NullOptional); } - case 291: { - LogStep(291, "Write attribute NULLABLE_INT32S null Value"); + case 292: { + LogStep(292, "Write attribute NULLABLE_INT32S null Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32s::Id, value, chip::NullOptional, chip::NullOptional); } - case 292: { - LogStep(292, "Read attribute NULLABLE_INT32S null Value"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32s::Id, true, - chip::NullOptional); - } case 293: { - LogStep(293, "Read attribute NULLABLE_INT32S null Value & range"); + LogStep(293, "Read attribute NULLABLE_INT32S null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32s::Id, true, chip::NullOptional); } case 294: { - LogStep(294, "Read attribute NULLABLE_INT32S null Value & not"); + LogStep(294, "Read attribute NULLABLE_INT32S null Value & range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32s::Id, true, chip::NullOptional); } case 295: { - LogStep(295, "Write attribute NULLABLE_INT32S Value"); + LogStep(295, "Read attribute NULLABLE_INT32S null Value & not"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32s::Id, true, + chip::NullOptional); + } + case 296: { + LogStep(296, "Write attribute NULLABLE_INT32S Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53814,18 +56274,18 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32s::Id, value, chip::NullOptional, chip::NullOptional); } - case 296: { - LogStep(296, "Read attribute NULLABLE_INT32S Value in range"); + case 297: { + LogStep(297, "Read attribute NULLABLE_INT32S Value in range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32s::Id, true, chip::NullOptional); } - case 297: { - LogStep(297, "Read attribute NULLABLE_INT32S notValue OK"); + case 298: { + LogStep(298, "Read attribute NULLABLE_INT32S notValue OK"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt32s::Id, true, chip::NullOptional); } - case 298: { - LogStep(298, "Write attribute NULLABLE_INT64S Min Value"); + case 299: { + LogStep(299, "Write attribute NULLABLE_INT64S Min Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53833,13 +56293,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64s::Id, value, chip::NullOptional, chip::NullOptional); } - case 299: { - LogStep(299, "Read attribute NULLABLE_INT64S Min Value"); + case 300: { + LogStep(300, "Read attribute NULLABLE_INT64S Min Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64s::Id, true, chip::NullOptional); } - case 300: { - LogStep(300, "Write attribute NULLABLE_INT64S Invalid Value"); + case 301: { + LogStep(301, "Write attribute NULLABLE_INT64S Invalid Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53847,36 +56307,36 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64s::Id, value, chip::NullOptional, chip::NullOptional); } - case 301: { - LogStep(301, "Read attribute NULLABLE_INT64S unchanged Value"); + case 302: { + LogStep(302, "Read attribute NULLABLE_INT64S unchanged Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64s::Id, true, chip::NullOptional); } - case 302: { - LogStep(302, "Write attribute NULLABLE_INT64S null Value"); + case 303: { + LogStep(303, "Write attribute NULLABLE_INT64S null Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64s::Id, value, chip::NullOptional, chip::NullOptional); } - case 303: { - LogStep(303, "Read attribute NULLABLE_INT64S null Value"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64s::Id, true, - chip::NullOptional); - } case 304: { - LogStep(304, "Read attribute NULLABLE_INT64S null Value & range"); + LogStep(304, "Read attribute NULLABLE_INT64S null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64s::Id, true, chip::NullOptional); } case 305: { - LogStep(305, "Read attribute NULLABLE_INT64S null Value & not"); + LogStep(305, "Read attribute NULLABLE_INT64S null Value & range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64s::Id, true, chip::NullOptional); } case 306: { - LogStep(306, "Write attribute NULLABLE_INT64S Value"); + LogStep(306, "Read attribute NULLABLE_INT64S null Value & not"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64s::Id, true, + chip::NullOptional); + } + case 307: { + LogStep(307, "Write attribute NULLABLE_INT64S Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53884,18 +56344,18 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64s::Id, value, chip::NullOptional, chip::NullOptional); } - case 307: { - LogStep(307, "Read attribute NULLABLE_INT64S Value in range"); + case 308: { + LogStep(308, "Read attribute NULLABLE_INT64S Value in range"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64s::Id, true, chip::NullOptional); } - case 308: { - LogStep(308, "Read attribute NULLABLE_INT64S notValue OK"); + case 309: { + LogStep(309, "Read attribute NULLABLE_INT64S notValue OK"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableInt64s::Id, true, chip::NullOptional); } - case 309: { - LogStep(309, "Write attribute NULLABLE_SINGLE medium Value"); + case 310: { + LogStep(310, "Write attribute NULLABLE_SINGLE medium Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53903,13 +56363,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatSingle::Id, value, chip::NullOptional, chip::NullOptional); } - case 310: { - LogStep(310, "Read attribute NULLABLE_SINGLE medium Value"); + case 311: { + LogStep(311, "Read attribute NULLABLE_SINGLE medium Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatSingle::Id, true, chip::NullOptional); } - case 311: { - LogStep(311, "Write attribute NULLABLE_SINGLE largest Value"); + case 312: { + LogStep(312, "Write attribute NULLABLE_SINGLE largest Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53917,13 +56377,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatSingle::Id, value, chip::NullOptional, chip::NullOptional); } - case 312: { - LogStep(312, "Read attribute NULLABLE_SINGLE largest Value"); + case 313: { + LogStep(313, "Read attribute NULLABLE_SINGLE largest Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatSingle::Id, true, chip::NullOptional); } - case 313: { - LogStep(313, "Write attribute NULLABLE_SINGLE smallest Value"); + case 314: { + LogStep(314, "Write attribute NULLABLE_SINGLE smallest Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53931,26 +56391,26 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatSingle::Id, value, chip::NullOptional, chip::NullOptional); } - case 314: { - LogStep(314, "Read attribute NULLABLE_SINGLE smallest Value"); + case 315: { + LogStep(315, "Read attribute NULLABLE_SINGLE smallest Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatSingle::Id, true, chip::NullOptional); } - case 315: { - LogStep(315, "Write attribute NULLABLE_SINGLE null Value"); + case 316: { + LogStep(316, "Write attribute NULLABLE_SINGLE null Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatSingle::Id, value, chip::NullOptional, chip::NullOptional); } - case 316: { - LogStep(316, "Read attribute NULLABLE_SINGLE null Value"); + case 317: { + LogStep(317, "Read attribute NULLABLE_SINGLE null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatSingle::Id, true, chip::NullOptional); } - case 317: { - LogStep(317, "Write attribute NULLABLE_SINGLE 0 Value"); + case 318: { + LogStep(318, "Write attribute NULLABLE_SINGLE 0 Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53958,13 +56418,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatSingle::Id, value, chip::NullOptional, chip::NullOptional); } - case 318: { - LogStep(318, "Read attribute NULLABLE_SINGLE 0 Value"); + case 319: { + LogStep(319, "Read attribute NULLABLE_SINGLE 0 Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatSingle::Id, true, chip::NullOptional); } - case 319: { - LogStep(319, "Write attribute NULLABLE_DOUBLE medium Value"); + case 320: { + LogStep(320, "Write attribute NULLABLE_DOUBLE medium Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53972,13 +56432,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatDouble::Id, value, chip::NullOptional, chip::NullOptional); } - case 320: { - LogStep(320, "Read attribute NULLABLE_DOUBLE medium Value"); + case 321: { + LogStep(321, "Read attribute NULLABLE_DOUBLE medium Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatDouble::Id, true, chip::NullOptional); } - case 321: { - LogStep(321, "Write attribute NULLABLE_DOUBLE largest Value"); + case 322: { + LogStep(322, "Write attribute NULLABLE_DOUBLE largest Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -53986,13 +56446,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatDouble::Id, value, chip::NullOptional, chip::NullOptional); } - case 322: { - LogStep(322, "Read attribute NULLABLE_DOUBLE largest Value"); + case 323: { + LogStep(323, "Read attribute NULLABLE_DOUBLE largest Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatDouble::Id, true, chip::NullOptional); } - case 323: { - LogStep(323, "Write attribute NULLABLE_DOUBLE smallest Value"); + case 324: { + LogStep(324, "Write attribute NULLABLE_DOUBLE smallest Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54000,26 +56460,26 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatDouble::Id, value, chip::NullOptional, chip::NullOptional); } - case 324: { - LogStep(324, "Read attribute NULLABLE_DOUBLE smallest Value"); + case 325: { + LogStep(325, "Read attribute NULLABLE_DOUBLE smallest Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatDouble::Id, true, chip::NullOptional); } - case 325: { - LogStep(325, "Write attribute NULLABLE_DOUBLE null Value"); + case 326: { + LogStep(326, "Write attribute NULLABLE_DOUBLE null Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatDouble::Id, value, chip::NullOptional, chip::NullOptional); } - case 326: { - LogStep(326, "Read attribute NULLABLE_DOUBLE null Value"); + case 327: { + LogStep(327, "Read attribute NULLABLE_DOUBLE null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatDouble::Id, true, chip::NullOptional); } - case 327: { - LogStep(327, "Write attribute NULLABLE_DOUBLE 0 Value"); + case 328: { + LogStep(328, "Write attribute NULLABLE_DOUBLE 0 Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54027,13 +56487,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatDouble::Id, value, chip::NullOptional, chip::NullOptional); } - case 328: { - LogStep(328, "Read attribute NULLABLE_DOUBLE 0 Value"); + case 329: { + LogStep(329, "Read attribute NULLABLE_DOUBLE 0 Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableFloatDouble::Id, true, chip::NullOptional); } - case 329: { - LogStep(329, "Write attribute NULLABLE_ENUM8 Min Value"); + case 330: { + LogStep(330, "Write attribute NULLABLE_ENUM8 Min Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54041,13 +56501,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum8::Id, value, chip::NullOptional, chip::NullOptional); } - case 330: { - LogStep(330, "Read attribute NULLABLE_ENUM8 Min Value"); + case 331: { + LogStep(331, "Read attribute NULLABLE_ENUM8 Min Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum8::Id, true, chip::NullOptional); } - case 331: { - LogStep(331, "Write attribute NULLABLE_ENUM8 Max Value"); + case 332: { + LogStep(332, "Write attribute NULLABLE_ENUM8 Max Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54055,13 +56515,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum8::Id, value, chip::NullOptional, chip::NullOptional); } - case 332: { - LogStep(332, "Read attribute NULLABLE_ENUM8 Max Value"); + case 333: { + LogStep(333, "Read attribute NULLABLE_ENUM8 Max Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum8::Id, true, chip::NullOptional); } - case 333: { - LogStep(333, "Write attribute NULLABLE_ENUM8 Invalid Value"); + case 334: { + LogStep(334, "Write attribute NULLABLE_ENUM8 Invalid Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54069,26 +56529,26 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum8::Id, value, chip::NullOptional, chip::NullOptional); } - case 334: { - LogStep(334, "Read attribute NULLABLE_ENUM8 unchanged Value"); + case 335: { + LogStep(335, "Read attribute NULLABLE_ENUM8 unchanged Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum8::Id, true, chip::NullOptional); } - case 335: { - LogStep(335, "Write attribute NULLABLE_ENUM8 null Value"); + case 336: { + LogStep(336, "Write attribute NULLABLE_ENUM8 null Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum8::Id, value, chip::NullOptional, chip::NullOptional); } - case 336: { - LogStep(336, "Read attribute NULLABLE_ENUM8 null Value"); + case 337: { + LogStep(337, "Read attribute NULLABLE_ENUM8 null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum8::Id, true, chip::NullOptional); } - case 337: { - LogStep(337, "Write attribute NULLABLE_ENUM16 Min Value"); + case 338: { + LogStep(338, "Write attribute NULLABLE_ENUM16 Min Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54096,13 +56556,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum16::Id, value, chip::NullOptional, chip::NullOptional); } - case 338: { - LogStep(338, "Read attribute NULLABLE_ENUM16 Min Value"); + case 339: { + LogStep(339, "Read attribute NULLABLE_ENUM16 Min Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum16::Id, true, chip::NullOptional); } - case 339: { - LogStep(339, "Write attribute NULLABLE_ENUM16 Max Value"); + case 340: { + LogStep(340, "Write attribute NULLABLE_ENUM16 Max Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54110,13 +56570,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum16::Id, value, chip::NullOptional, chip::NullOptional); } - case 340: { - LogStep(340, "Read attribute NULLABLE_ENUM16 Max Value"); + case 341: { + LogStep(341, "Read attribute NULLABLE_ENUM16 Max Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum16::Id, true, chip::NullOptional); } - case 341: { - LogStep(341, "Write attribute NULLABLE_ENUM16 Invalid Value"); + case 342: { + LogStep(342, "Write attribute NULLABLE_ENUM16 Invalid Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54124,26 +56584,26 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum16::Id, value, chip::NullOptional, chip::NullOptional); } - case 342: { - LogStep(342, "Read attribute NULLABLE_ENUM16 unchanged Value"); + case 343: { + LogStep(343, "Read attribute NULLABLE_ENUM16 unchanged Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum16::Id, true, chip::NullOptional); } - case 343: { - LogStep(343, "Write attribute NULLABLE_ENUM16 null Value"); + case 344: { + LogStep(344, "Write attribute NULLABLE_ENUM16 null Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum16::Id, value, chip::NullOptional, chip::NullOptional); } - case 344: { - LogStep(344, "Read attribute NULLABLE_ENUM16 null Value"); + case 345: { + LogStep(345, "Read attribute NULLABLE_ENUM16 null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnum16::Id, true, chip::NullOptional); } - case 345: { - LogStep(345, "Write attribute NULLABLE_SIMPLE_ENUM Min Value"); + case 346: { + LogStep(346, "Write attribute NULLABLE_SIMPLE_ENUM Min Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54151,13 +56611,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnumAttr::Id, value, chip::NullOptional, chip::NullOptional); } - case 346: { - LogStep(346, "Read attribute NULLABLE_SIMPLE_ENUM Min Value"); + case 347: { + LogStep(347, "Read attribute NULLABLE_SIMPLE_ENUM Min Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnumAttr::Id, true, chip::NullOptional); } - case 347: { - LogStep(347, "Write attribute NULLABLE_SIMPLE_ENUM Max Value"); + case 348: { + LogStep(348, "Write attribute NULLABLE_SIMPLE_ENUM Max Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54165,13 +56625,13 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnumAttr::Id, value, chip::NullOptional, chip::NullOptional); } - case 348: { - LogStep(348, "Read attribute NULLABLE_SIMPLE_ENUM Max Value"); + case 349: { + LogStep(349, "Read attribute NULLABLE_SIMPLE_ENUM Max Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnumAttr::Id, true, chip::NullOptional); } - case 349: { - LogStep(349, "Write attribute NULLABLE_SIMPLE_ENUM Invalid Value"); + case 350: { + LogStep(350, "Write attribute NULLABLE_SIMPLE_ENUM Invalid Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54179,36 +56639,36 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnumAttr::Id, value, chip::NullOptional, chip::NullOptional); } - case 350: { - LogStep(350, "Read attribute NULLABLE_SIMPLE_ENUM unchanged Value"); + case 351: { + LogStep(351, "Read attribute NULLABLE_SIMPLE_ENUM unchanged Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnumAttr::Id, true, chip::NullOptional); } - case 351: { - LogStep(351, "Write attribute NULLABLE_SIMPLE_ENUM null Value"); + case 352: { + LogStep(352, "Write attribute NULLABLE_SIMPLE_ENUM null Value"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnumAttr::Id, value, chip::NullOptional, chip::NullOptional); } - case 352: { - LogStep(352, "Read attribute NULLABLE_SIMPLE_ENUM null Value"); + case 353: { + LogStep(353, "Read attribute NULLABLE_SIMPLE_ENUM null Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnumAttr::Id, true, chip::NullOptional); } - case 353: { - LogStep(353, "Read attribute NULLABLE_SIMPLE_ENUM not 3 Value"); + case 354: { + LogStep(354, "Read attribute NULLABLE_SIMPLE_ENUM not 3 Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableEnumAttr::Id, true, chip::NullOptional); } - case 354: { - LogStep(354, "Read attribute NULLABLE_OCTET_STRING Default Value"); + case 355: { + LogStep(355, "Read attribute NULLABLE_OCTET_STRING Default Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableOctetString::Id, true, chip::NullOptional); } - case 355: { - LogStep(355, "Write attribute NULLABLE_OCTET_STRING"); + case 356: { + LogStep(356, "Write attribute NULLABLE_OCTET_STRING"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54216,26 +56676,26 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableOctetString::Id, value, chip::NullOptional, chip::NullOptional); } - case 356: { - LogStep(356, "Read attribute NULLABLE_OCTET_STRING"); + case 357: { + LogStep(357, "Read attribute NULLABLE_OCTET_STRING"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableOctetString::Id, true, chip::NullOptional); } - case 357: { - LogStep(357, "Write attribute NULLABLE_OCTET_STRING"); + case 358: { + LogStep(358, "Write attribute NULLABLE_OCTET_STRING"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableOctetString::Id, value, chip::NullOptional, chip::NullOptional); } - case 358: { - LogStep(358, "Read attribute NULLABLE_OCTET_STRING"); + case 359: { + LogStep(359, "Read attribute NULLABLE_OCTET_STRING"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableOctetString::Id, true, chip::NullOptional); } - case 359: { - LogStep(359, "Write attribute NULLABLE_OCTET_STRING"); + case 360: { + LogStep(360, "Write attribute NULLABLE_OCTET_STRING"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54243,23 +56703,23 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableOctetString::Id, value, chip::NullOptional, chip::NullOptional); } - case 360: { - LogStep(360, "Read attribute NULLABLE_OCTET_STRING"); + case 361: { + LogStep(361, "Read attribute NULLABLE_OCTET_STRING"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableOctetString::Id, true, chip::NullOptional); } - case 361: { - LogStep(361, "Read attribute NULLABLE_OCTET_STRING not TestValue"); + case 362: { + LogStep(362, "Read attribute NULLABLE_OCTET_STRING not TestValue"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableOctetString::Id, true, chip::NullOptional); } - case 362: { - LogStep(362, "Read attribute NULLABLE_CHAR_STRING Default Value"); + case 363: { + LogStep(363, "Read attribute NULLABLE_CHAR_STRING Default Value"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableCharString::Id, true, chip::NullOptional); } - case 363: { - LogStep(363, "Write attribute NULLABLE_CHAR_STRING"); + case 364: { + LogStep(364, "Write attribute NULLABLE_CHAR_STRING"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54267,31 +56727,31 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableCharString::Id, value, chip::NullOptional, chip::NullOptional); } - case 364: { - LogStep(364, "Read attribute NULLABLE_CHAR_STRING"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableCharString::Id, - true, chip::NullOptional); - } case 365: { LogStep(365, "Read attribute NULLABLE_CHAR_STRING"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableCharString::Id, true, chip::NullOptional); } case 366: { - LogStep(366, "Write attribute NULLABLE_CHAR_STRING - Value too long"); + LogStep(366, "Read attribute NULLABLE_CHAR_STRING"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableCharString::Id, + true, chip::NullOptional); + } + case 367: { + LogStep(367, "Write attribute NULLABLE_CHAR_STRING - Value too long"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableCharString::Id, value, chip::NullOptional, chip::NullOptional); } - case 367: { - LogStep(367, "Read attribute NULLABLE_CHAR_STRING"); + case 368: { + LogStep(368, "Read attribute NULLABLE_CHAR_STRING"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableCharString::Id, true, chip::NullOptional); } - case 368: { - LogStep(368, "Write attribute NULLABLE_CHAR_STRING - Empty"); + case 369: { + LogStep(369, "Write attribute NULLABLE_CHAR_STRING - Empty"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54299,28 +56759,28 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableCharString::Id, value, chip::NullOptional, chip::NullOptional); } - case 369: { - LogStep(369, "Read attribute NULLABLE_CHAR_STRING"); + case 370: { + LogStep(370, "Read attribute NULLABLE_CHAR_STRING"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableCharString::Id, true, chip::NullOptional); } - case 370: { - LogStep(370, "Read attribute NULLABLE_CHAR_STRING not ☉T☉"); + case 371: { + LogStep(371, "Read attribute NULLABLE_CHAR_STRING not ☉T☉"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableCharString::Id, true, chip::NullOptional); } - case 371: { - LogStep(371, "Read attribute from nonexistent endpoint."); + case 372: { + LogStep(372, "Read attribute from nonexistent endpoint."); return ReadAttribute(kIdentityAlpha, GetEndpoint(200), UnitTesting::Id, UnitTesting::Attributes::ListInt8u::Id, true, chip::NullOptional); } - case 372: { - LogStep(372, "Read attribute from nonexistent cluster."); + case 373: { + LogStep(373, "Read attribute from nonexistent cluster."); return ReadAttribute(kIdentityAlpha, GetEndpoint(0), UnitTesting::Id, UnitTesting::Attributes::ListInt8u::Id, true, chip::NullOptional); } - case 373: { - LogStep(373, "Send a command that takes an optional parameter but do not set it."); + case 374: { + LogStep(374, "Send a command that takes an optional parameter but do not set it."); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestSimpleOptionalArgumentRequest::Type value; return SendCommand(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, @@ -54328,8 +56788,8 @@ class TestClusterSuite : public TestCommand ); } - case 374: { - LogStep(374, "Send a command that takes an optional parameter but do not set it."); + case 375: { + LogStep(375, "Send a command that takes an optional parameter but do not set it."); ListFreer listFreer; chip::app::Clusters::UnitTesting::Commands::TestSimpleOptionalArgumentRequest::Type value; value.arg1.Emplace(); @@ -54339,13 +56799,13 @@ class TestClusterSuite : public TestCommand ); } - case 375: { - LogStep(375, "Subscribe to list attribute"); + case 376: { + LogStep(376, "Subscribe to list attribute"); return SubscribeAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::ListInt8u::Id, 2, 5, true, chip::NullOptional, chip::NullOptional, /* autoResubscribe = */ chip::NullOptional); } - case 376: { - LogStep(376, "Write subscribed-to list attribute"); + case 377: { + LogStep(377, "Write subscribed-to list attribute"); ListFreer listFreer; chip::app::DataModel::List value; @@ -54361,98 +56821,98 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::ListInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 377: { - LogStep(377, "Check for list attribute report"); + case 378: { + LogStep(378, "Check for list attribute report"); return WaitForReport(); } - case 378: { - LogStep(378, "Read range-restricted unsigned 8-bit integer"); + case 379: { + LogStep(379, "Read range-restricted unsigned 8-bit integer"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8u::Id, true, chip::NullOptional); } - case 379: { - LogStep(379, "Write min value to a range-restricted unsigned 8-bit integer"); + case 380: { + LogStep(380, "Write min value to a range-restricted unsigned 8-bit integer"); ListFreer listFreer; uint8_t value; value = 0U; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 380: { - LogStep(380, "Write just-below-range value to a range-restricted unsigned 8-bit integer"); + case 381: { + LogStep(381, "Write just-below-range value to a range-restricted unsigned 8-bit integer"); ListFreer listFreer; uint8_t value; value = 19U; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 381: { - LogStep(381, "Write just-above-range value to a range-restricted unsigned 8-bit integer"); + case 382: { + LogStep(382, "Write just-above-range value to a range-restricted unsigned 8-bit integer"); ListFreer listFreer; uint8_t value; value = 101U; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 382: { - LogStep(382, "Write max value to a range-restricted unsigned 8-bit integer"); + case 383: { + LogStep(383, "Write max value to a range-restricted unsigned 8-bit integer"); ListFreer listFreer; uint8_t value; value = 255U; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 383: { - LogStep(383, "Verify range-restricted unsigned 8-bit integer value has not changed"); + case 384: { + LogStep(384, "Verify range-restricted unsigned 8-bit integer value has not changed"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8u::Id, true, chip::NullOptional); } - case 384: { - LogStep(384, "Write min valid value to a range-restricted unsigned 8-bit integer"); + case 385: { + LogStep(385, "Write min valid value to a range-restricted unsigned 8-bit integer"); ListFreer listFreer; uint8_t value; value = 20U; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 385: { - LogStep(385, "Verify range-restricted unsigned 8-bit integer value is at min valid"); + case 386: { + LogStep(386, "Verify range-restricted unsigned 8-bit integer value is at min valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8u::Id, true, chip::NullOptional); } - case 386: { - LogStep(386, "Write max valid value to a range-restricted unsigned 8-bit integer"); + case 387: { + LogStep(387, "Write max valid value to a range-restricted unsigned 8-bit integer"); ListFreer listFreer; uint8_t value; value = 100U; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 387: { - LogStep(387, "Verify range-restricted unsigned 8-bit integer value is at max valid"); + case 388: { + LogStep(388, "Verify range-restricted unsigned 8-bit integer value is at max valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8u::Id, true, chip::NullOptional); } - case 388: { - LogStep(388, "Write middle valid value to a range-restricted unsigned 8-bit integer"); + case 389: { + LogStep(389, "Write middle valid value to a range-restricted unsigned 8-bit integer"); ListFreer listFreer; uint8_t value; value = 50U; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 389: { - LogStep(389, "Verify range-restricted unsigned 8-bit integer value is at mid valid"); + case 390: { + LogStep(390, "Verify range-restricted unsigned 8-bit integer value is at mid valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8u::Id, true, chip::NullOptional); } - case 390: { - LogStep(390, "Read range-restricted unsigned 16-bit integer"); + case 391: { + LogStep(391, "Read range-restricted unsigned 16-bit integer"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt16u::Id, true, chip::NullOptional); } - case 391: { - LogStep(391, "Write min value to a range-restricted unsigned 16-bit integer"); + case 392: { + LogStep(392, "Write min value to a range-restricted unsigned 16-bit integer"); ListFreer listFreer; uint16_t value; value = 0U; @@ -54460,8 +56920,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::RangeRestrictedInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 392: { - LogStep(392, "Write just-below-range value to a range-restricted unsigned 16-bit integer"); + case 393: { + LogStep(393, "Write just-below-range value to a range-restricted unsigned 16-bit integer"); ListFreer listFreer; uint16_t value; value = 99U; @@ -54469,8 +56929,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::RangeRestrictedInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 393: { - LogStep(393, "Write just-above-range value to a range-restricted unsigned 16-bit integer"); + case 394: { + LogStep(394, "Write just-above-range value to a range-restricted unsigned 16-bit integer"); ListFreer listFreer; uint16_t value; value = 1001U; @@ -54478,8 +56938,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::RangeRestrictedInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 394: { - LogStep(394, "Write max value to a range-restricted unsigned 16-bit integer"); + case 395: { + LogStep(395, "Write max value to a range-restricted unsigned 16-bit integer"); ListFreer listFreer; uint16_t value; value = 65535U; @@ -54487,13 +56947,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::RangeRestrictedInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 395: { - LogStep(395, "Verify range-restricted unsigned 16-bit integer value has not changed"); + case 396: { + LogStep(396, "Verify range-restricted unsigned 16-bit integer value has not changed"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt16u::Id, true, chip::NullOptional); } - case 396: { - LogStep(396, "Write min valid value to a range-restricted unsigned 16-bit integer"); + case 397: { + LogStep(397, "Write min valid value to a range-restricted unsigned 16-bit integer"); ListFreer listFreer; uint16_t value; value = 100U; @@ -54501,13 +56961,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::RangeRestrictedInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 397: { - LogStep(397, "Verify range-restricted unsigned 16-bit integer value is at min valid"); + case 398: { + LogStep(398, "Verify range-restricted unsigned 16-bit integer value is at min valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt16u::Id, true, chip::NullOptional); } - case 398: { - LogStep(398, "Write max valid value to a range-restricted unsigned 16-bit integer"); + case 399: { + LogStep(399, "Write max valid value to a range-restricted unsigned 16-bit integer"); ListFreer listFreer; uint16_t value; value = 1000U; @@ -54515,13 +56975,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::RangeRestrictedInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 399: { - LogStep(399, "Verify range-restricted unsigned 16-bit integer value is at max valid"); + case 400: { + LogStep(400, "Verify range-restricted unsigned 16-bit integer value is at max valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt16u::Id, true, chip::NullOptional); } - case 400: { - LogStep(400, "Write middle valid value to a range-restricted unsigned 16-bit integer"); + case 401: { + LogStep(401, "Write middle valid value to a range-restricted unsigned 16-bit integer"); ListFreer listFreer; uint16_t value; value = 500U; @@ -54529,99 +56989,99 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::RangeRestrictedInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 401: { - LogStep(401, "Verify range-restricted unsigned 16-bit integer value is at mid valid"); + case 402: { + LogStep(402, "Verify range-restricted unsigned 16-bit integer value is at mid valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt16u::Id, true, chip::NullOptional); } - case 402: { - LogStep(402, "Read range-restricted signed 8-bit integer"); + case 403: { + LogStep(403, "Read range-restricted signed 8-bit integer"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8s::Id, true, chip::NullOptional); } - case 403: { - LogStep(403, "Write min value to a range-restricted signed 8-bit integer"); + case 404: { + LogStep(404, "Write min value to a range-restricted signed 8-bit integer"); ListFreer listFreer; int8_t value; value = -128; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 404: { - LogStep(404, "Write just-below-range value to a range-restricted signed 8-bit integer"); + case 405: { + LogStep(405, "Write just-below-range value to a range-restricted signed 8-bit integer"); ListFreer listFreer; int8_t value; value = -41; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 405: { - LogStep(405, "Write just-above-range value to a range-restricted signed 8-bit integer"); + case 406: { + LogStep(406, "Write just-above-range value to a range-restricted signed 8-bit integer"); ListFreer listFreer; int8_t value; value = 51; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 406: { - LogStep(406, "Write max value to a range-restricted signed 8-bit integer"); + case 407: { + LogStep(407, "Write max value to a range-restricted signed 8-bit integer"); ListFreer listFreer; int8_t value; value = 127; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 407: { - LogStep(407, "Verify range-restricted signed 8-bit integer value has not changed"); + case 408: { + LogStep(408, "Verify range-restricted signed 8-bit integer value has not changed"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8s::Id, true, chip::NullOptional); } - case 408: { - LogStep(408, "Write min valid value to a range-restricted signed 8-bit integer"); + case 409: { + LogStep(409, "Write min valid value to a range-restricted signed 8-bit integer"); ListFreer listFreer; int8_t value; value = -40; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 409: { - LogStep(409, "Verify range-restricted signed 8-bit integer value is at min valid"); + case 410: { + LogStep(410, "Verify range-restricted signed 8-bit integer value is at min valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8s::Id, true, chip::NullOptional); } - case 410: { - LogStep(410, "Write max valid value to a range-restricted signed 8-bit integer"); + case 411: { + LogStep(411, "Write max valid value to a range-restricted signed 8-bit integer"); ListFreer listFreer; int8_t value; value = 50; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 411: { - LogStep(411, "Verify range-restricted signed 8-bit integer value is at max valid"); + case 412: { + LogStep(412, "Verify range-restricted signed 8-bit integer value is at max valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8s::Id, true, chip::NullOptional); } - case 412: { - LogStep(412, "Write middle valid value to a range-restricted signed 8-bit integer"); + case 413: { + LogStep(413, "Write middle valid value to a range-restricted signed 8-bit integer"); ListFreer listFreer; int8_t value; value = 6; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 413: { - LogStep(413, "Verify range-restricted signed 8-bit integer value is at mid valid"); + case 414: { + LogStep(414, "Verify range-restricted signed 8-bit integer value is at mid valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt8s::Id, true, chip::NullOptional); } - case 414: { - LogStep(414, "Read range-restricted signed 16-bit integer"); + case 415: { + LogStep(415, "Read range-restricted signed 16-bit integer"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt16s::Id, true, chip::NullOptional); } - case 415: { - LogStep(415, "Write min value to a range-restricted signed 16-bit integer"); + case 416: { + LogStep(416, "Write min value to a range-restricted signed 16-bit integer"); ListFreer listFreer; int16_t value; value = -32768; @@ -54629,8 +57089,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::RangeRestrictedInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 416: { - LogStep(416, "Write just-below-range value to a range-restricted signed 16-bit integer"); + case 417: { + LogStep(417, "Write just-below-range value to a range-restricted signed 16-bit integer"); ListFreer listFreer; int16_t value; value = -151; @@ -54638,8 +57098,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::RangeRestrictedInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 417: { - LogStep(417, "Write just-above-range value to a range-restricted signed 16-bit integer"); + case 418: { + LogStep(418, "Write just-above-range value to a range-restricted signed 16-bit integer"); ListFreer listFreer; int16_t value; value = 201; @@ -54647,8 +57107,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::RangeRestrictedInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 418: { - LogStep(418, "Write max value to a range-restricted signed 16-bit integer"); + case 419: { + LogStep(419, "Write max value to a range-restricted signed 16-bit integer"); ListFreer listFreer; int16_t value; value = 32767; @@ -54656,13 +57116,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::RangeRestrictedInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 419: { - LogStep(419, "Verify range-restricted signed 16-bit integer value has not changed"); + case 420: { + LogStep(420, "Verify range-restricted signed 16-bit integer value has not changed"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt16s::Id, true, chip::NullOptional); } - case 420: { - LogStep(420, "Write min valid value to a range-restricted signed 16-bit integer"); + case 421: { + LogStep(421, "Write min valid value to a range-restricted signed 16-bit integer"); ListFreer listFreer; int16_t value; value = -150; @@ -54670,13 +57130,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::RangeRestrictedInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 421: { - LogStep(421, "Verify range-restricted signed 16-bit integer value is at min valid"); + case 422: { + LogStep(422, "Verify range-restricted signed 16-bit integer value is at min valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt16s::Id, true, chip::NullOptional); } - case 422: { - LogStep(422, "Write max valid value to a range-restricted signed 16-bit integer"); + case 423: { + LogStep(423, "Write max valid value to a range-restricted signed 16-bit integer"); ListFreer listFreer; int16_t value; value = 200; @@ -54684,13 +57144,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::RangeRestrictedInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 423: { - LogStep(423, "Verify range-restricted signed 16-bit integer value is at max valid"); + case 424: { + LogStep(424, "Verify range-restricted signed 16-bit integer value is at max valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt16s::Id, true, chip::NullOptional); } - case 424: { - LogStep(424, "Write middle valid value to a range-restricted signed 16-bit integer"); + case 425: { + LogStep(425, "Write middle valid value to a range-restricted signed 16-bit integer"); ListFreer listFreer; int16_t value; value = 7; @@ -54698,18 +57158,18 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::RangeRestrictedInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 425: { - LogStep(425, "Verify range-restricted signed 16-bit integer value is at mid valid"); + case 426: { + LogStep(426, "Verify range-restricted signed 16-bit integer value is at mid valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::RangeRestrictedInt16s::Id, true, chip::NullOptional); } - case 426: { - LogStep(426, "Read nullable range-restricted unsigned 8-bit integer"); + case 427: { + LogStep(427, "Read nullable range-restricted unsigned 8-bit integer"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt8u::Id, true, chip::NullOptional); } - case 427: { - LogStep(427, "Write min value to a nullable range-restricted unsigned 8-bit integer"); + case 428: { + LogStep(428, "Write min value to a nullable range-restricted unsigned 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54718,8 +57178,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 428: { - LogStep(428, "Write just-below-range value to a nullable range-restricted unsigned 8-bit integer"); + case 429: { + LogStep(429, "Write just-below-range value to a nullable range-restricted unsigned 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54728,8 +57188,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 429: { - LogStep(429, "Write just-above-range value to a nullable range-restricted unsigned 8-bit integer"); + case 430: { + LogStep(430, "Write just-above-range value to a nullable range-restricted unsigned 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54738,8 +57198,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 430: { - LogStep(430, "Write max value to a nullable range-restricted unsigned 8-bit integer"); + case 431: { + LogStep(431, "Write max value to a nullable range-restricted unsigned 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54748,13 +57208,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 431: { - LogStep(431, "Verify nullable range-restricted unsigned 8-bit integer value has not changed"); + case 432: { + LogStep(432, "Verify nullable range-restricted unsigned 8-bit integer value has not changed"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt8u::Id, true, chip::NullOptional); } - case 432: { - LogStep(432, "Write min valid value to a nullable range-restricted unsigned 8-bit integer"); + case 433: { + LogStep(433, "Write min valid value to a nullable range-restricted unsigned 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54763,13 +57223,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 433: { - LogStep(433, "Verify nullable range-restricted unsigned 8-bit integer value is at min valid"); + case 434: { + LogStep(434, "Verify nullable range-restricted unsigned 8-bit integer value is at min valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt8u::Id, true, chip::NullOptional); } - case 434: { - LogStep(434, "Write max valid value to a nullable range-restricted unsigned 8-bit integer"); + case 435: { + LogStep(435, "Write max valid value to a nullable range-restricted unsigned 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54778,13 +57238,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 435: { - LogStep(435, "Verify nullable range-restricted unsigned 8-bit integer value is at max valid"); + case 436: { + LogStep(436, "Verify nullable range-restricted unsigned 8-bit integer value is at max valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt8u::Id, true, chip::NullOptional); } - case 436: { - LogStep(436, "Write middle valid value to a nullable range-restricted unsigned 8-bit integer"); + case 437: { + LogStep(437, "Write middle valid value to a nullable range-restricted unsigned 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54793,13 +57253,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 437: { - LogStep(437, "Verify nullable range-restricted unsigned 8-bit integer value is at mid valid"); + case 438: { + LogStep(438, "Verify nullable range-restricted unsigned 8-bit integer value is at mid valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt8u::Id, true, chip::NullOptional); } - case 438: { - LogStep(438, "Write null value to a nullable range-restricted unsigned 8-bit integer"); + case 439: { + LogStep(439, "Write null value to a nullable range-restricted unsigned 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); @@ -54807,18 +57267,18 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8u::Id, value, chip::NullOptional, chip::NullOptional); } - case 439: { - LogStep(439, "Verify nullable range-restricted unsigned 8-bit integer value is null"); + case 440: { + LogStep(440, "Verify nullable range-restricted unsigned 8-bit integer value is null"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt8u::Id, true, chip::NullOptional); } - case 440: { - LogStep(440, "Read nullable range-restricted unsigned 16-bit integer"); + case 441: { + LogStep(441, "Read nullable range-restricted unsigned 16-bit integer"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt16u::Id, true, chip::NullOptional); } - case 441: { - LogStep(441, "Write min value to a nullable range-restricted unsigned 16-bit integer"); + case 442: { + LogStep(442, "Write min value to a nullable range-restricted unsigned 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54827,8 +57287,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 442: { - LogStep(442, "Write just-below-range value to a nullable range-restricted unsigned 16-bit integer"); + case 443: { + LogStep(443, "Write just-below-range value to a nullable range-restricted unsigned 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54837,8 +57297,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 443: { - LogStep(443, "Write just-above-range value to a nullable range-restricted unsigned 16-bit integer"); + case 444: { + LogStep(444, "Write just-above-range value to a nullable range-restricted unsigned 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54847,8 +57307,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 444: { - LogStep(444, "Write max value to a nullable range-restricted unsigned 16-bit integer"); + case 445: { + LogStep(445, "Write max value to a nullable range-restricted unsigned 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54857,13 +57317,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 445: { - LogStep(445, "Verify nullable range-restricted unsigned 16-bit integer value has not changed"); + case 446: { + LogStep(446, "Verify nullable range-restricted unsigned 16-bit integer value has not changed"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt16u::Id, true, chip::NullOptional); } - case 446: { - LogStep(446, "Write min valid value to a nullable range-restricted unsigned 16-bit integer"); + case 447: { + LogStep(447, "Write min valid value to a nullable range-restricted unsigned 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54872,13 +57332,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 447: { - LogStep(447, "Verify nullable range-restricted unsigned 16-bit integer value is at min valid"); + case 448: { + LogStep(448, "Verify nullable range-restricted unsigned 16-bit integer value is at min valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt16u::Id, true, chip::NullOptional); } - case 448: { - LogStep(448, "Write max valid value to a nullable range-restricted unsigned 16-bit integer"); + case 449: { + LogStep(449, "Write max valid value to a nullable range-restricted unsigned 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54887,13 +57347,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 449: { - LogStep(449, "Verify nullable range-restricted unsigned 16-bit integer value is at max valid"); + case 450: { + LogStep(450, "Verify nullable range-restricted unsigned 16-bit integer value is at max valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt16u::Id, true, chip::NullOptional); } - case 450: { - LogStep(450, "Write middle valid value to a nullable range-restricted unsigned 16-bit integer"); + case 451: { + LogStep(451, "Write middle valid value to a nullable range-restricted unsigned 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54902,13 +57362,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 451: { - LogStep(451, "Verify nullable range-restricted unsigned 16-bit integer value is at mid valid"); + case 452: { + LogStep(452, "Verify nullable range-restricted unsigned 16-bit integer value is at mid valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt16u::Id, true, chip::NullOptional); } - case 452: { - LogStep(452, "Write null value to a nullable range-restricted unsigned 16-bit integer"); + case 453: { + LogStep(453, "Write null value to a nullable range-restricted unsigned 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); @@ -54916,18 +57376,18 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16u::Id, value, chip::NullOptional, chip::NullOptional); } - case 453: { - LogStep(453, "Verify nullable range-restricted unsigned 16-bit integer value is null"); + case 454: { + LogStep(454, "Verify nullable range-restricted unsigned 16-bit integer value is null"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt16u::Id, true, chip::NullOptional); } - case 454: { - LogStep(454, "Read nullable range-restricted signed 8-bit integer"); + case 455: { + LogStep(455, "Read nullable range-restricted signed 8-bit integer"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt8s::Id, true, chip::NullOptional); } - case 455: { - LogStep(455, "Write min value to a nullable range-restricted signed 8-bit integer"); + case 456: { + LogStep(456, "Write min value to a nullable range-restricted signed 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54936,8 +57396,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 456: { - LogStep(456, "Write just-below-range value to a nullable range-restricted signed 8-bit integer"); + case 457: { + LogStep(457, "Write just-below-range value to a nullable range-restricted signed 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54946,8 +57406,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 457: { - LogStep(457, "Write just-above-range value to a nullable range-restricted signed 8-bit integer"); + case 458: { + LogStep(458, "Write just-above-range value to a nullable range-restricted signed 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54956,8 +57416,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 458: { - LogStep(458, "Write max value to a nullable range-restricted signed 8-bit integer"); + case 459: { + LogStep(459, "Write max value to a nullable range-restricted signed 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54966,13 +57426,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 459: { - LogStep(459, "Verify nullable range-restricted signed 8-bit integer value has not changed"); + case 460: { + LogStep(460, "Verify nullable range-restricted signed 8-bit integer value has not changed"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt8s::Id, true, chip::NullOptional); } - case 460: { - LogStep(460, "Write min valid value to a nullable range-restricted signed 8-bit integer"); + case 461: { + LogStep(461, "Write min valid value to a nullable range-restricted signed 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54981,13 +57441,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 461: { - LogStep(461, "Verify nullable range-restricted signed 8-bit integer value is at min valid"); + case 462: { + LogStep(462, "Verify nullable range-restricted signed 8-bit integer value is at min valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt8s::Id, true, chip::NullOptional); } - case 462: { - LogStep(462, "Write max valid value to a nullable range-restricted signed 8-bit integer"); + case 463: { + LogStep(463, "Write max valid value to a nullable range-restricted signed 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -54996,13 +57456,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 463: { - LogStep(463, "Verify nullable range-restricted signed 8-bit integer value is at max valid"); + case 464: { + LogStep(464, "Verify nullable range-restricted signed 8-bit integer value is at max valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt8s::Id, true, chip::NullOptional); } - case 464: { - LogStep(464, "Write middle valid value to a nullable range-restricted signed 8-bit integer"); + case 465: { + LogStep(465, "Write middle valid value to a nullable range-restricted signed 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -55011,13 +57471,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 465: { - LogStep(465, "Verify nullable range-restricted signed 8-bit integer value is at mid valid"); + case 466: { + LogStep(466, "Verify nullable range-restricted signed 8-bit integer value is at mid valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt8s::Id, true, chip::NullOptional); } - case 466: { - LogStep(466, "Write null value to a nullable range-restricted signed 8-bit integer"); + case 467: { + LogStep(467, "Write null value to a nullable range-restricted signed 8-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); @@ -55025,18 +57485,18 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt8s::Id, value, chip::NullOptional, chip::NullOptional); } - case 467: { - LogStep(467, "Verify nullable range-restricted signed 8-bit integer value is at null"); + case 468: { + LogStep(468, "Verify nullable range-restricted signed 8-bit integer value is at null"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt8s::Id, true, chip::NullOptional); } - case 468: { - LogStep(468, "Read nullable range-restricted signed 16-bit integer"); + case 469: { + LogStep(469, "Read nullable range-restricted signed 16-bit integer"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt16s::Id, true, chip::NullOptional); } - case 469: { - LogStep(469, "Write min value to a nullable range-restricted signed 16-bit integer"); + case 470: { + LogStep(470, "Write min value to a nullable range-restricted signed 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -55045,8 +57505,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 470: { - LogStep(470, "Write just-below-range value to a nullable range-restricted signed 16-bit integer"); + case 471: { + LogStep(471, "Write just-below-range value to a nullable range-restricted signed 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -55055,8 +57515,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 471: { - LogStep(471, "Write just-above-range value to a nullable range-restricted signed 16-bit integer"); + case 472: { + LogStep(472, "Write just-above-range value to a nullable range-restricted signed 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -55065,8 +57525,8 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 472: { - LogStep(472, "Write max value to a nullable range-restricted signed 16-bit integer"); + case 473: { + LogStep(473, "Write max value to a nullable range-restricted signed 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -55075,13 +57535,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 473: { - LogStep(473, "Verify nullable range-restricted signed 16-bit integer value has not changed"); + case 474: { + LogStep(474, "Verify nullable range-restricted signed 16-bit integer value has not changed"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt16s::Id, true, chip::NullOptional); } - case 474: { - LogStep(474, "Write min valid value to a nullable range-restricted signed 16-bit integer"); + case 475: { + LogStep(475, "Write min valid value to a nullable range-restricted signed 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -55090,13 +57550,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 475: { - LogStep(475, "Verify nullable range-restricted signed 16-bit integer value is at min valid"); + case 476: { + LogStep(476, "Verify nullable range-restricted signed 16-bit integer value is at min valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt16s::Id, true, chip::NullOptional); } - case 476: { - LogStep(476, "Write max valid value to a nullable range-restricted signed 16-bit integer"); + case 477: { + LogStep(477, "Write max valid value to a nullable range-restricted signed 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -55105,13 +57565,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 477: { - LogStep(477, "Verify nullable range-restricted signed 16-bit integer value is at max valid"); + case 478: { + LogStep(478, "Verify nullable range-restricted signed 16-bit integer value is at max valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt16s::Id, true, chip::NullOptional); } - case 478: { - LogStep(478, "Write middle valid value to a nullable range-restricted signed 16-bit integer"); + case 479: { + LogStep(479, "Write middle valid value to a nullable range-restricted signed 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNonNull(); @@ -55120,13 +57580,13 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 479: { - LogStep(479, "Verify nullable range-restricted signed 16-bit integer value is at mid valid"); + case 480: { + LogStep(480, "Verify nullable range-restricted signed 16-bit integer value is at mid valid"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt16s::Id, true, chip::NullOptional); } - case 480: { - LogStep(480, "Write null value to a nullable range-restricted signed 16-bit integer"); + case 481: { + LogStep(481, "Write null value to a nullable range-restricted signed 16-bit integer"); ListFreer listFreer; chip::app::DataModel::Nullable value; value.SetNull(); @@ -55134,49 +57594,49 @@ class TestClusterSuite : public TestCommand UnitTesting::Attributes::NullableRangeRestrictedInt16s::Id, value, chip::NullOptional, chip::NullOptional); } - case 481: { - LogStep(481, "Verify nullable range-restricted signed 16-bit integer value is null"); + case 482: { + LogStep(482, "Verify nullable range-restricted signed 16-bit integer value is null"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::NullableRangeRestrictedInt16s::Id, true, chip::NullOptional); } - case 482: { - LogStep(482, "Write attribute that returns general status on write"); + case 483: { + LogStep(483, "Write attribute that returns general status on write"); ListFreer listFreer; bool value; value = false; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::GeneralErrorBoolean::Id, value, chip::NullOptional, chip::NullOptional); } - case 483: { - LogStep(483, "Write attribute that returns cluster-specific status on write"); + case 484: { + LogStep(484, "Write attribute that returns cluster-specific status on write"); ListFreer listFreer; bool value; value = false; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::ClusterErrorBoolean::Id, value, chip::NullOptional, chip::NullOptional); } - case 484: { - LogStep(484, "Read attribute that returns general status on read"); + case 485: { + LogStep(485, "Read attribute that returns general status on read"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::GeneralErrorBoolean::Id, true, chip::NullOptional); } - case 485: { - LogStep(485, "read attribute that returns cluster-specific status on read"); + case 486: { + LogStep(486, "read attribute that returns cluster-specific status on read"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::ClusterErrorBoolean::Id, true, chip::NullOptional); } - case 486: { - LogStep(486, "read AcceptedCommandList attribute"); + case 487: { + LogStep(487, "read AcceptedCommandList attribute"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::AcceptedCommandList::Id, true, chip::NullOptional); } - case 487: { - LogStep(487, "read GeneratedCommandList attribute"); + case 488: { + LogStep(488, "read GeneratedCommandList attribute"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::GeneratedCommandList::Id, true, chip::NullOptional); } - case 488: { - LogStep(488, "Write struct-typed attribute"); + case 489: { + LogStep(489, "Write struct-typed attribute"); ListFreer listFreer; chip::app::Clusters::UnitTesting::Structs::SimpleStruct::Type value; @@ -55192,8 +57652,8 @@ class TestClusterSuite : public TestCommand return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::StructAttr::Id, value, chip::NullOptional, chip::NullOptional); } - case 489: { - LogStep(489, "Read struct-typed attribute"); + case 490: { + LogStep(490, "Read struct-typed attribute"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::StructAttr::Id, true, chip::NullOptional); } @@ -55539,7 +57999,7 @@ class TestClusterComplexTypesSuite : public TestCommand class TestConstraintsSuite : public TestCommand { public: - TestConstraintsSuite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("TestConstraints", 32, credsIssuerConfig) + TestConstraintsSuite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("TestConstraints", 33, credsIssuerConfig) { AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); AddArgument("cluster", &mCluster); @@ -55653,6 +58113,9 @@ class TestConstraintsSuite : public TestCommand VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 12: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 13: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint32_t value; @@ -55660,7 +58123,7 @@ class TestConstraintsSuite : public TestCommand VerifyOrReturn(CheckConstraintMinValue("value", value, 5UL)); } break; - case 13: + case 14: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint32_t value; @@ -55668,7 +58131,7 @@ class TestConstraintsSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxValue("value", value, 5UL)); } break; - case 14: + case 15: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { uint32_t value; @@ -55676,13 +58139,13 @@ class TestConstraintsSuite : public TestCommand VerifyOrReturn(CheckConstraintNotValue("value", value, 6UL)); } break; - case 15: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); - break; case 16: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 17: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 18: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::CharSpan value; @@ -55690,7 +58153,7 @@ class TestConstraintsSuite : public TestCommand VerifyOrReturn(CheckConstraintMinLength("value", value, 5)); } break; - case 18: + case 19: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::CharSpan value; @@ -55698,7 +58161,7 @@ class TestConstraintsSuite : public TestCommand VerifyOrReturn(CheckConstraintMaxLength("value", value, 20)); } break; - case 19: + case 20: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::CharSpan value; @@ -55706,7 +58169,7 @@ class TestConstraintsSuite : public TestCommand VerifyOrReturn(CheckConstraintStartsWith("value", value, "**")); } break; - case 20: + case 21: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::CharSpan value; @@ -55714,10 +58177,10 @@ class TestConstraintsSuite : public TestCommand VerifyOrReturn(CheckConstraintEndsWith("value", value, "**")); } break; - case 21: + case 22: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 22: + case 23: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::CharSpan value; @@ -55726,10 +58189,10 @@ class TestConstraintsSuite : public TestCommand VerifyOrReturn(CheckConstraintIsUpperCase("value", value, false)); } break; - case 23: + case 24: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 24: + case 25: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::CharSpan value; @@ -55738,10 +58201,10 @@ class TestConstraintsSuite : public TestCommand VerifyOrReturn(CheckConstraintIsLowerCase("value", value, false)); } break; - case 25: + case 26: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 26: + case 27: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::CharSpan value; @@ -55750,10 +58213,10 @@ class TestConstraintsSuite : public TestCommand VerifyOrReturn(CheckConstraintIsLowerCase("value", value, false)); } break; - case 27: + case 28: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 28: + case 29: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::CharSpan value; @@ -55761,10 +58224,10 @@ class TestConstraintsSuite : public TestCommand VerifyOrReturn(CheckConstraintIsHexString("value", value, false)); } break; - case 29: + case 30: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; - case 30: + case 31: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::CharSpan value; @@ -55772,7 +58235,7 @@ class TestConstraintsSuite : public TestCommand VerifyOrReturn(CheckConstraintIsHexString("value", value, true)); } break; - case 31: + case 32: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; default: @@ -55867,131 +58330,139 @@ class TestConstraintsSuite : public TestCommand chip::NullOptional); } case 11: { - LogStep(11, "Write attribute INT32U Value"); + LogStep(11, "Write attribute BITMAP32 Back to Default Value"); + ListFreer listFreer; + chip::BitMask value; + value = static_cast>(0UL); + return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::Bitmap32::Id, value, + chip::NullOptional, chip::NullOptional); + } + case 12: { + LogStep(12, "Write attribute INT32U Value"); ListFreer listFreer; uint32_t value; value = 5UL; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::Int32u::Id, value, chip::NullOptional, chip::NullOptional); } - case 12: { - LogStep(12, "Read attribute INT32U Value MinValue Constraints"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::Int32u::Id, true, - chip::NullOptional); - } case 13: { - LogStep(13, "Read attribute INT32U Value MaxValue Constraints"); + LogStep(13, "Read attribute INT32U Value MinValue Constraints"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::Int32u::Id, true, chip::NullOptional); } case 14: { - LogStep(14, "Read attribute INT32U Value NotValue Constraints"); + LogStep(14, "Read attribute INT32U Value MaxValue Constraints"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::Int32u::Id, true, chip::NullOptional); } case 15: { - LogStep(15, "Write attribute INT32U Value Back to Default Value"); + LogStep(15, "Read attribute INT32U Value NotValue Constraints"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::Int32u::Id, true, + chip::NullOptional); + } + case 16: { + LogStep(16, "Write attribute INT32U Value Back to Default Value"); ListFreer listFreer; uint32_t value; value = 0UL; return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::Int32u::Id, value, chip::NullOptional, chip::NullOptional); } - case 16: { - LogStep(16, "Write attribute CHAR_STRING Value"); + case 17: { + LogStep(17, "Write attribute CHAR_STRING Value"); ListFreer listFreer; chip::CharSpan value; value = chip::Span("** Test **garbage: not in length on purpose", 10); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, value, chip::NullOptional, chip::NullOptional); } - case 17: { - LogStep(17, "Read attribute CHAR_STRING Value MinLength Constraints"); - return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, true, - chip::NullOptional); - } case 18: { - LogStep(18, "Read attribute CHAR_STRING Value MaxLength Constraints"); + LogStep(18, "Read attribute CHAR_STRING Value MinLength Constraints"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, true, chip::NullOptional); } case 19: { - LogStep(19, "Read attribute CHAR_STRING Value StartsWith Constraints"); + LogStep(19, "Read attribute CHAR_STRING Value MaxLength Constraints"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, true, chip::NullOptional); } case 20: { - LogStep(20, "Read attribute CHAR_STRING Value EndsWith Constraints"); + LogStep(20, "Read attribute CHAR_STRING Value StartsWith Constraints"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, true, chip::NullOptional); } case 21: { - LogStep(21, "Write attribute CHAR_STRING Value"); + LogStep(21, "Read attribute CHAR_STRING Value EndsWith Constraints"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, true, + chip::NullOptional); + } + case 22: { + LogStep(22, "Write attribute CHAR_STRING Value"); ListFreer listFreer; chip::CharSpan value; value = chip::Span("lowercasegarbage: not in length on purpose", 9); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, value, chip::NullOptional, chip::NullOptional); } - case 22: { - LogStep(22, "Read attribute CHAR_STRING Value isLowerCase/isUpperCase Constraints"); + case 23: { + LogStep(23, "Read attribute CHAR_STRING Value isLowerCase/isUpperCase Constraints"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, true, chip::NullOptional); } - case 23: { - LogStep(23, "Write attribute CHAR_STRING Value"); + case 24: { + LogStep(24, "Write attribute CHAR_STRING Value"); ListFreer listFreer; chip::CharSpan value; value = chip::Span("UPPERCASEgarbage: not in length on purpose", 9); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, value, chip::NullOptional, chip::NullOptional); } - case 24: { - LogStep(24, "Read attribute CHAR_STRING Value isLowerCase/isUpperCase Constraints"); + case 25: { + LogStep(25, "Read attribute CHAR_STRING Value isLowerCase/isUpperCase Constraints"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, true, chip::NullOptional); } - case 25: { - LogStep(25, "Write attribute CHAR_STRING Value"); + case 26: { + LogStep(26, "Write attribute CHAR_STRING Value"); ListFreer listFreer; chip::CharSpan value; value = chip::Span("lowUPPERgarbage: not in length on purpose", 8); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, value, chip::NullOptional, chip::NullOptional); } - case 26: { - LogStep(26, "Read attribute CHAR_STRING Value isLowerCase/isUpperCase Constraints"); + case 27: { + LogStep(27, "Read attribute CHAR_STRING Value isLowerCase/isUpperCase Constraints"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, true, chip::NullOptional); } - case 27: { - LogStep(27, "Write attribute CHAR_STRING Value"); + case 28: { + LogStep(28, "Write attribute CHAR_STRING Value"); ListFreer listFreer; chip::CharSpan value; value = chip::Span("ABCDEF012Vgarbage: not in length on purpose", 10); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, value, chip::NullOptional, chip::NullOptional); } - case 28: { - LogStep(28, "Read attribute CHAR_STRING Value isHexString Constraints"); + case 29: { + LogStep(29, "Read attribute CHAR_STRING Value isHexString Constraints"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, true, chip::NullOptional); } - case 29: { - LogStep(29, "Write attribute CHAR_STRING Value"); + case 30: { + LogStep(30, "Write attribute CHAR_STRING Value"); ListFreer listFreer; chip::CharSpan value; value = chip::Span("ABCDEF0123garbage: not in length on purpose", 10); return WriteAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, value, chip::NullOptional, chip::NullOptional); } - case 30: { - LogStep(30, "Read attribute CHAR_STRING Value isHexString Constraints"); + case 31: { + LogStep(31, "Read attribute CHAR_STRING Value isHexString Constraints"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), UnitTesting::Id, UnitTesting::Attributes::CharString::Id, true, chip::NullOptional); } - case 31: { - LogStep(31, "Write attribute CHAR_STRING Value Back to Default Value"); + case 32: { + LogStep(32, "Write attribute CHAR_STRING Value Back to Default Value"); ListFreer listFreer; chip::CharSpan value; value = chip::Span("garbage: not in length on purpose", 0); @@ -60145,6 +62616,7 @@ class TestModeSelectClusterSuite : public TestCommand auto iter_2 = iter_0.GetValue().semanticTags.begin(); VerifyOrReturn(CheckNextListItemDecodes( "supportedModes[0].semanticTags", iter_2, 0)); + VerifyOrReturn(CheckValue("supportedModes[0].semanticTags[0].value", iter_2.GetValue().value, 0U)); VerifyOrReturn(CheckNoMoreListItems( "supportedModes[0].semanticTags", iter_2, 1)); } @@ -60156,6 +62628,7 @@ class TestModeSelectClusterSuite : public TestCommand auto iter_2 = iter_0.GetValue().semanticTags.begin(); VerifyOrReturn(CheckNextListItemDecodes( "supportedModes[1].semanticTags", iter_2, 0)); + VerifyOrReturn(CheckValue("supportedModes[1].semanticTags[0].value", iter_2.GetValue().value, 0U)); VerifyOrReturn(CheckNoMoreListItems( "supportedModes[1].semanticTags", iter_2, 1)); } @@ -60167,6 +62640,7 @@ class TestModeSelectClusterSuite : public TestCommand auto iter_2 = iter_0.GetValue().semanticTags.begin(); VerifyOrReturn(CheckNextListItemDecodes( "supportedModes[2].semanticTags", iter_2, 0)); + VerifyOrReturn(CheckValue("supportedModes[2].semanticTags[0].value", iter_2.GetValue().value, 0U)); VerifyOrReturn(CheckNoMoreListItems( "supportedModes[2].semanticTags", iter_2, 1)); } @@ -61684,6 +64158,8 @@ class TestArmFailSafeSuite : public TestCommand { auto iter_0 = value.begin(); VerifyOrReturn(CheckNextListItemDecodes("fabrics", iter_0, 0)); + VerifyOrReturn(CheckValue("fabrics[0].nodeId", iter_0.GetValue().nodeId, + mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL)); VerifyOrReturn(CheckValueAsString("fabrics[0].label", iter_0.GetValue().label, chip::CharSpan("", 0))); VerifyOrReturn(CheckNoMoreListItems("fabrics", iter_0, 1)); } @@ -63689,6 +66165,8 @@ class TestMultiAdminSuite : public TestCommand { auto iter_0 = value.begin(); VerifyOrReturn(CheckNextListItemDecodes("fabrics", iter_0, 0)); + VerifyOrReturn(CheckValue("fabrics[0].nodeId", iter_0.GetValue().nodeId, + mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL)); VerifyOrReturn(CheckNoMoreListItems("fabrics", iter_0, 1)); } } @@ -68517,46 +70995,46 @@ class DL_SchedulesSuite : public TestCommand } break; case 6: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 7: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 8: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 9: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 10: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_FAILURE)); break; case 11: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 12: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 13: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 14: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 15: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 16: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 17: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 18: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 19: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 20: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -68620,16 +71098,16 @@ class DL_SchedulesSuite : public TestCommand } break; case 26: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 27: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 28: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 29: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 30: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_FAILURE)); @@ -68699,16 +71177,16 @@ class DL_SchedulesSuite : public TestCommand } break; case 38: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 39: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 40: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 41: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 42: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -68797,16 +71275,16 @@ class DL_SchedulesSuite : public TestCommand } break; case 51: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 52: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 53: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 54: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 55: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_FAILURE)); @@ -68861,16 +71339,16 @@ class DL_SchedulesSuite : public TestCommand } break; case 59: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 60: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 61: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 62: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 63: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_FAILURE)); @@ -68925,10 +71403,10 @@ class DL_SchedulesSuite : public TestCommand } break; case 67: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 68: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 69: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -73467,6 +75945,246 @@ class Test_TC_DRLK_2_5Suite : public TestCommand } }; +class Test_TC_DRLK_2_6Suite : public TestCommand +{ +public: + Test_TC_DRLK_2_6Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_DRLK_2_6", 10, credsIssuerConfig) + { + AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); + AddArgument("cluster", &mCluster); + AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("timeout", 0, UINT16_MAX, &mTimeout); + } + + ~Test_TC_DRLK_2_6Suite() {} + + chip::System::Clock::Timeout GetWaitDuration() const override + { + return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); + } + +private: + chip::Optional mNodeId; + chip::Optional mCluster; + chip::Optional mEndpoint; + chip::Optional mTimeout; + + uint8_t NumberOfHolidaySchedulesSupported; + + chip::EndpointId GetEndpoint(chip::EndpointId endpoint) { return mEndpoint.HasValue() ? mEndpoint.Value() : endpoint; } + + // + // Tests methods + // + + void OnResponse(const chip::app::StatusIB & status, chip::TLV::TLVReader * data) override + { + bool shouldContinue = false; + + switch (mTestIndex - 1) + { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + shouldContinue = true; + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint8_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintMinValue("value", value, 0U)); + VerifyOrReturn(CheckConstraintMaxValue("value", value, 255U)); + NumberOfHolidaySchedulesSupported = value; + } + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::Clusters::DoorLock::Commands::GetHolidayScheduleResponse::DecodableType value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("holidayIndex", value.holidayIndex, 1U)); + VerifyOrReturn(CheckValue("status", value.status, 0U)); + VerifyOrReturn(CheckValuePresent("localStartTime", value.localStartTime)); + VerifyOrReturn(CheckValue("localStartTime.Value()", value.localStartTime.Value(), 20UL)); + VerifyOrReturn(CheckValuePresent("localEndTime", value.localEndTime)); + VerifyOrReturn(CheckValue("localEndTime.Value()", value.localEndTime.Value(), 30UL)); + if (value.localEndTime.HasValue()) + { + VerifyOrReturn(CheckConstraintMinValue("value.localEndTime.Value()", value.localEndTime.Value(), 21UL)); + } + VerifyOrReturn(CheckValuePresent("operatingMode", value.operatingMode)); + VerifyOrReturn(CheckValue("operatingMode.Value()", value.operatingMode.Value(), 0U)); + } + break; + case 4: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); + break; + case 5: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::Clusters::DoorLock::Commands::GetHolidayScheduleResponse::DecodableType value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("holidayIndex", value.holidayIndex, 15U)); + VerifyOrReturn(CheckValue("status", value.status, 133U)); + } + break; + case 6: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::Clusters::DoorLock::Commands::GetHolidayScheduleResponse::DecodableType value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("holidayIndex", value.holidayIndex, 10U)); + VerifyOrReturn(CheckValue("status", value.status, 139U)); + } + break; + case 7: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 8: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + chip::app::Clusters::DoorLock::Commands::GetHolidayScheduleResponse::DecodableType value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckValue("holidayIndex", value.holidayIndex, 1U)); + VerifyOrReturn(CheckValue("status", value.status, 139U)); + } + break; + case 9: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + default: + LogErrorOnFailure(ContinueOnChipMainThread(CHIP_ERROR_INVALID_ARGUMENT)); + } + + if (shouldContinue) + { + ContinueOnChipMainThread(CHIP_NO_ERROR); + } + } + + CHIP_ERROR DoTestStep(uint16_t testIndex) override + { + using namespace chip::app::Clusters; + switch (testIndex) + { + case 0: { + LogStep(0, "Wait for commissionee"); + ListFreer listFreer; + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee(kIdentityAlpha, value); + } + case 1: { + LogStep(1, "TH reads NumberOfHoliday SchedulesSupported and saves for future use."); + VerifyOrDo(!ShouldSkip("DRLK.S.F0b && DRLK.S.A0016"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), DoorLock::Id, + DoorLock::Attributes::NumberOfHolidaySchedulesSupported::Id, true, chip::NullOptional); + } + case 2: { + LogStep(2, "Create Holiday schedule with 1 index"); + VerifyOrDo(!ShouldSkip("DRLK.S.F0b && DRLK.S.C11.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::DoorLock::Commands::SetHolidaySchedule::Type value; + value.holidayIndex = 1U; + value.localStartTime = 20UL; + value.localEndTime = 30UL; + value.operatingMode = static_cast(0); + return SendCommand(kIdentityAlpha, GetEndpoint(1), DoorLock::Id, DoorLock::Commands::SetHolidaySchedule::Id, value, + chip::NullOptional + + ); + } + case 3: { + LogStep(3, "Get Holiday Schedule with HolidayIndex as 1"); + VerifyOrDo(!ShouldSkip("DRLK.S.F0b && DRLK.S.C12.Rsp && DRLK.S.C12.Tx"), + return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::DoorLock::Commands::GetHolidaySchedule::Type value; + value.holidayIndex = 1U; + return SendCommand(kIdentityAlpha, GetEndpoint(1), DoorLock::Id, DoorLock::Commands::GetHolidaySchedule::Id, value, + chip::NullOptional + + ); + } + case 4: { + LogStep(4, "Create Holiday schedule with invalid operating mode"); + VerifyOrDo(!ShouldSkip("DRLK.S.C11.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::DoorLock::Commands::SetHolidaySchedule::Type value; + value.holidayIndex = 1U; + value.localStartTime = 20UL; + value.localEndTime = 30UL; + value.operatingMode = static_cast(5); + return SendCommand(kIdentityAlpha, GetEndpoint(1), DoorLock::Id, DoorLock::Commands::SetHolidaySchedule::Id, value, + chip::NullOptional + + ); + } + case 5: { + LogStep(5, "Get Holiday Schedule with Invalid HolidayIndex 15."); + VerifyOrDo(!ShouldSkip("DRLK.S.F0b && DRLK.S.C12.Rsp && DRLK.S.C12.Tx"), + return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::DoorLock::Commands::GetHolidaySchedule::Type value; + value.holidayIndex = 15U; + return SendCommand(kIdentityAlpha, GetEndpoint(1), DoorLock::Id, DoorLock::Commands::GetHolidaySchedule::Id, value, + chip::NullOptional + + ); + } + case 6: { + LogStep(6, "Get Holiday Schedule with the Non-scheduled HolidayIndex"); + VerifyOrDo(!ShouldSkip("DRLK.S.F0b && DRLK.S.C12.Rsp && DRLK.S.C12.Tx"), + return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::DoorLock::Commands::GetHolidaySchedule::Type value; + value.holidayIndex = 10U; + return SendCommand(kIdentityAlpha, GetEndpoint(1), DoorLock::Id, DoorLock::Commands::GetHolidaySchedule::Id, value, + chip::NullOptional + + ); + } + case 7: { + LogStep(7, "Clear Holiday schedule with 1 index"); + VerifyOrDo(!ShouldSkip("DRLK.S.F0b && DRLK.S.C13.Rsp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::DoorLock::Commands::ClearHolidaySchedule::Type value; + value.holidayIndex = 1U; + return SendCommand(kIdentityAlpha, GetEndpoint(1), DoorLock::Id, DoorLock::Commands::ClearHolidaySchedule::Id, value, + chip::NullOptional + + ); + } + case 8: { + LogStep(8, "Make sure that holiday schedule was deleted"); + VerifyOrDo(!ShouldSkip("DRLK.S.F0b && DRLK.S.C12.Rsp && DRLK.S.C12.Tx"), + return ContinueOnChipMainThread(CHIP_NO_ERROR)); + ListFreer listFreer; + chip::app::Clusters::DoorLock::Commands::GetHolidaySchedule::Type value; + value.holidayIndex = 1U; + return SendCommand(kIdentityAlpha, GetEndpoint(1), DoorLock::Id, DoorLock::Commands::GetHolidaySchedule::Id, value, + chip::NullOptional + + ); + } + case 9: { + LogStep(9, "Cleanup the created user"); + ListFreer listFreer; + chip::app::Clusters::DoorLock::Commands::ClearUser::Type value; + value.userIndex = 1U; + return SendCommand(kIdentityAlpha, GetEndpoint(1), DoorLock::Id, DoorLock::Commands::ClearUser::Id, value, + chip::Optional(10000), chip::NullOptional + + ); + } + } + return CHIP_NO_ERROR; + } +}; + class Test_TC_DRLK_2_7Suite : public TestCommand { public: @@ -84192,63 +86910,6 @@ class Test_TC_MEDIAINPUT_3_17Suite : public TestCommand } }; -class Test_TC_WAKEONLAN_4_1Suite : public TestCommand -{ -public: - Test_TC_WAKEONLAN_4_1Suite(CredentialIssuerCommands * credsIssuerConfig) : - TestCommand("Test_TC_WAKEONLAN_4_1", 0, credsIssuerConfig) - { - AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); - AddArgument("cluster", &mCluster); - AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); - AddArgument("timeout", 0, UINT16_MAX, &mTimeout); - } - - ~Test_TC_WAKEONLAN_4_1Suite() {} - - chip::System::Clock::Timeout GetWaitDuration() const override - { - return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); - } - -private: - chip::Optional mNodeId; - chip::Optional mCluster; - chip::Optional mEndpoint; - chip::Optional mTimeout; - - chip::EndpointId GetEndpoint(chip::EndpointId endpoint) { return mEndpoint.HasValue() ? mEndpoint.Value() : endpoint; } - - // - // Tests methods - // - - void OnResponse(const chip::app::StatusIB & status, chip::TLV::TLVReader * data) override - { - bool shouldContinue = false; - - switch (mTestIndex - 1) - { - default: - LogErrorOnFailure(ContinueOnChipMainThread(CHIP_ERROR_INVALID_ARGUMENT)); - } - - if (shouldContinue) - { - ContinueOnChipMainThread(CHIP_NO_ERROR); - } - } - - CHIP_ERROR DoTestStep(uint16_t testIndex) override - { - using namespace chip::app::Clusters; - switch (testIndex) - { - } - return CHIP_NO_ERROR; - } -}; - class Test_TC_CHANNEL_5_4Suite : public TestCommand { public: @@ -84819,68 +87480,11 @@ class Test_TC_CONTENTLAUNCHER_10_4Suite : public TestCommand } }; -class Test_TC_CONTENTLAUNCHER_10_5Suite : public TestCommand -{ -public: - Test_TC_CONTENTLAUNCHER_10_5Suite(CredentialIssuerCommands * credsIssuerConfig) : - TestCommand("Test_TC_CONTENTLAUNCHER_10_5", 0, credsIssuerConfig) - { - AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); - AddArgument("cluster", &mCluster); - AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); - AddArgument("timeout", 0, UINT16_MAX, &mTimeout); - } - - ~Test_TC_CONTENTLAUNCHER_10_5Suite() {} - - chip::System::Clock::Timeout GetWaitDuration() const override - { - return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); - } - -private: - chip::Optional mNodeId; - chip::Optional mCluster; - chip::Optional mEndpoint; - chip::Optional mTimeout; - - chip::EndpointId GetEndpoint(chip::EndpointId endpoint) { return mEndpoint.HasValue() ? mEndpoint.Value() : endpoint; } - - // - // Tests methods - // - - void OnResponse(const chip::app::StatusIB & status, chip::TLV::TLVReader * data) override - { - bool shouldContinue = false; - - switch (mTestIndex - 1) - { - default: - LogErrorOnFailure(ContinueOnChipMainThread(CHIP_ERROR_INVALID_ARGUMENT)); - } - - if (shouldContinue) - { - ContinueOnChipMainThread(CHIP_NO_ERROR); - } - } - - CHIP_ERROR DoTestStep(uint16_t testIndex) override - { - using namespace chip::app::Clusters; - switch (testIndex) - { - } - return CHIP_NO_ERROR; - } -}; - -class Test_TC_CONTENTLAUNCHER_10_7Suite : public TestCommand +class Test_TC_CONTENTLAUNCHER_10_5Suite : public TestCommand { public: - Test_TC_CONTENTLAUNCHER_10_7Suite(CredentialIssuerCommands * credsIssuerConfig) : - TestCommand("Test_TC_CONTENTLAUNCHER_10_7", 0, credsIssuerConfig) + Test_TC_CONTENTLAUNCHER_10_5Suite(CredentialIssuerCommands * credsIssuerConfig) : + TestCommand("Test_TC_CONTENTLAUNCHER_10_5", 0, credsIssuerConfig) { AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); AddArgument("cluster", &mCluster); @@ -84888,7 +87492,7 @@ class Test_TC_CONTENTLAUNCHER_10_7Suite : public TestCommand AddArgument("timeout", 0, UINT16_MAX, &mTimeout); } - ~Test_TC_CONTENTLAUNCHER_10_7Suite() {} + ~Test_TC_CONTENTLAUNCHER_10_5Suite() {} chip::System::Clock::Timeout GetWaitDuration() const override { @@ -84933,10 +87537,11 @@ class Test_TC_CONTENTLAUNCHER_10_7Suite : public TestCommand } }; -class Test_TC_MC_11_1Suite : public TestCommand +class Test_TC_CONTENTLAUNCHER_10_7Suite : public TestCommand { public: - Test_TC_MC_11_1Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_MC_11_1", 0, credsIssuerConfig) + Test_TC_CONTENTLAUNCHER_10_7Suite(CredentialIssuerCommands * credsIssuerConfig) : + TestCommand("Test_TC_CONTENTLAUNCHER_10_7", 0, credsIssuerConfig) { AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); AddArgument("cluster", &mCluster); @@ -84944,7 +87549,7 @@ class Test_TC_MC_11_1Suite : public TestCommand AddArgument("timeout", 0, UINT16_MAX, &mTimeout); } - ~Test_TC_MC_11_1Suite() {} + ~Test_TC_CONTENTLAUNCHER_10_7Suite() {} chip::System::Clock::Timeout GetWaitDuration() const override { @@ -84989,10 +87594,10 @@ class Test_TC_MC_11_1Suite : public TestCommand } }; -class Test_TC_MC_11_2Suite : public TestCommand +class Test_TC_MC_11_1Suite : public TestCommand { public: - Test_TC_MC_11_2Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_MC_11_2", 0, credsIssuerConfig) + Test_TC_MC_11_1Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_MC_11_1", 0, credsIssuerConfig) { AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); AddArgument("cluster", &mCluster); @@ -85000,7 +87605,7 @@ class Test_TC_MC_11_2Suite : public TestCommand AddArgument("timeout", 0, UINT16_MAX, &mTimeout); } - ~Test_TC_MC_11_2Suite() {} + ~Test_TC_MC_11_1Suite() {} chip::System::Clock::Timeout GetWaitDuration() const override { @@ -85045,11 +87650,10 @@ class Test_TC_MC_11_2Suite : public TestCommand } }; -class Test_TC_ALOGIN_12_1Suite : public TestCommand +class Test_TC_MC_11_2Suite : public TestCommand { public: - Test_TC_ALOGIN_12_1Suite(CredentialIssuerCommands * credsIssuerConfig) : - TestCommand("Test_TC_ALOGIN_12_1", 0, credsIssuerConfig) + Test_TC_MC_11_2Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_MC_11_2", 0, credsIssuerConfig) { AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); AddArgument("cluster", &mCluster); @@ -85057,7 +87661,7 @@ class Test_TC_ALOGIN_12_1Suite : public TestCommand AddArgument("timeout", 0, UINT16_MAX, &mTimeout); } - ~Test_TC_ALOGIN_12_1Suite() {} + ~Test_TC_MC_11_2Suite() {} chip::System::Clock::Timeout GetWaitDuration() const override { @@ -98997,62 +101601,6 @@ class Test_TC_DRLK_2_1Suite : public TestCommand } }; -class Test_TC_DRLK_2_6Suite : public TestCommand -{ -public: - Test_TC_DRLK_2_6Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_DRLK_2_6", 0, credsIssuerConfig) - { - AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); - AddArgument("cluster", &mCluster); - AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); - AddArgument("timeout", 0, UINT16_MAX, &mTimeout); - } - - ~Test_TC_DRLK_2_6Suite() {} - - chip::System::Clock::Timeout GetWaitDuration() const override - { - return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); - } - -private: - chip::Optional mNodeId; - chip::Optional mCluster; - chip::Optional mEndpoint; - chip::Optional mTimeout; - - chip::EndpointId GetEndpoint(chip::EndpointId endpoint) { return mEndpoint.HasValue() ? mEndpoint.Value() : endpoint; } - - // - // Tests methods - // - - void OnResponse(const chip::app::StatusIB & status, chip::TLV::TLVReader * data) override - { - bool shouldContinue = false; - - switch (mTestIndex - 1) - { - default: - LogErrorOnFailure(ContinueOnChipMainThread(CHIP_ERROR_INVALID_ARGUMENT)); - } - - if (shouldContinue) - { - ContinueOnChipMainThread(CHIP_NO_ERROR); - } - } - - CHIP_ERROR DoTestStep(uint16_t testIndex) override - { - using namespace chip::app::Clusters; - switch (testIndex) - { - } - return CHIP_NO_ERROR; - } -}; - class Test_TC_DRLK_2_8Suite : public TestCommand { public: @@ -103877,62 +106425,6 @@ class Test_TC_PCC_3_1Suite : public TestCommand } }; -class Test_TC_ACL_2_3Suite : public TestCommand -{ -public: - Test_TC_ACL_2_3Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_ACL_2_3", 0, credsIssuerConfig) - { - AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); - AddArgument("cluster", &mCluster); - AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); - AddArgument("timeout", 0, UINT16_MAX, &mTimeout); - } - - ~Test_TC_ACL_2_3Suite() {} - - chip::System::Clock::Timeout GetWaitDuration() const override - { - return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); - } - -private: - chip::Optional mNodeId; - chip::Optional mCluster; - chip::Optional mEndpoint; - chip::Optional mTimeout; - - chip::EndpointId GetEndpoint(chip::EndpointId endpoint) { return mEndpoint.HasValue() ? mEndpoint.Value() : endpoint; } - - // - // Tests methods - // - - void OnResponse(const chip::app::StatusIB & status, chip::TLV::TLVReader * data) override - { - bool shouldContinue = false; - - switch (mTestIndex - 1) - { - default: - LogErrorOnFailure(ContinueOnChipMainThread(CHIP_ERROR_INVALID_ARGUMENT)); - } - - if (shouldContinue) - { - ContinueOnChipMainThread(CHIP_NO_ERROR); - } - } - - CHIP_ERROR DoTestStep(uint16_t testIndex) override - { - using namespace chip::app::Clusters; - switch (testIndex) - { - } - return CHIP_NO_ERROR; - } -}; - class Test_TC_ACL_2_4Suite : public TestCommand { public: @@ -104381,120 +106873,6 @@ class Test_TC_ULABEL_3_1Suite : public TestCommand } }; -class Test_TC_BRBINFO_1_1Suite : public TestCommand -{ -public: - Test_TC_BRBINFO_1_1Suite(CredentialIssuerCommands * credsIssuerConfig) : - TestCommand("Test_TC_BRBINFO_1_1", 0, credsIssuerConfig) - { - AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); - AddArgument("cluster", &mCluster); - AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); - AddArgument("timeout", 0, UINT16_MAX, &mTimeout); - } - - ~Test_TC_BRBINFO_1_1Suite() {} - - chip::System::Clock::Timeout GetWaitDuration() const override - { - return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); - } - -private: - chip::Optional mNodeId; - chip::Optional mCluster; - chip::Optional mEndpoint; - chip::Optional mTimeout; - - chip::EndpointId GetEndpoint(chip::EndpointId endpoint) { return mEndpoint.HasValue() ? mEndpoint.Value() : endpoint; } - - // - // Tests methods - // - - void OnResponse(const chip::app::StatusIB & status, chip::TLV::TLVReader * data) override - { - bool shouldContinue = false; - - switch (mTestIndex - 1) - { - default: - LogErrorOnFailure(ContinueOnChipMainThread(CHIP_ERROR_INVALID_ARGUMENT)); - } - - if (shouldContinue) - { - ContinueOnChipMainThread(CHIP_NO_ERROR); - } - } - - CHIP_ERROR DoTestStep(uint16_t testIndex) override - { - using namespace chip::app::Clusters; - switch (testIndex) - { - } - return CHIP_NO_ERROR; - } -}; - -class Test_TC_BRBINFO_2_1Suite : public TestCommand -{ -public: - Test_TC_BRBINFO_2_1Suite(CredentialIssuerCommands * credsIssuerConfig) : - TestCommand("Test_TC_BRBINFO_2_1", 0, credsIssuerConfig) - { - AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); - AddArgument("cluster", &mCluster); - AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); - AddArgument("timeout", 0, UINT16_MAX, &mTimeout); - } - - ~Test_TC_BRBINFO_2_1Suite() {} - - chip::System::Clock::Timeout GetWaitDuration() const override - { - return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); - } - -private: - chip::Optional mNodeId; - chip::Optional mCluster; - chip::Optional mEndpoint; - chip::Optional mTimeout; - - chip::EndpointId GetEndpoint(chip::EndpointId endpoint) { return mEndpoint.HasValue() ? mEndpoint.Value() : endpoint; } - - // - // Tests methods - // - - void OnResponse(const chip::app::StatusIB & status, chip::TLV::TLVReader * data) override - { - bool shouldContinue = false; - - switch (mTestIndex - 1) - { - default: - LogErrorOnFailure(ContinueOnChipMainThread(CHIP_ERROR_INVALID_ARGUMENT)); - } - - if (shouldContinue) - { - ContinueOnChipMainThread(CHIP_NO_ERROR); - } - } - - CHIP_ERROR DoTestStep(uint16_t testIndex) override - { - using namespace chip::app::Clusters; - switch (testIndex) - { - } - return CHIP_NO_ERROR; - } -}; - class Test_TC_BRBINFO_2_2Suite : public TestCommand { public: @@ -104735,8 +107113,11 @@ void registerCommandsTests(Commands & commands, CredentialIssuerCommands * creds make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), + make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), + make_unique(credsIssuerConfig), + make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), @@ -104804,6 +107185,7 @@ void registerCommandsTests(Commands & commands, CredentialIssuerCommands * creds make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), + make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), @@ -104816,6 +107198,7 @@ void registerCommandsTests(Commands & commands, CredentialIssuerCommands * creds make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), + make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), @@ -104940,6 +107323,7 @@ void registerCommandsTests(Commands & commands, CredentialIssuerCommands * creds make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), + make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), @@ -105075,7 +107459,6 @@ void registerCommandsTests(Commands & commands, CredentialIssuerCommands * creds make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), - make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), @@ -105090,7 +107473,6 @@ void registerCommandsTests(Commands & commands, CredentialIssuerCommands * creds make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), - make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), @@ -105202,7 +107584,6 @@ void registerCommandsTests(Commands & commands, CredentialIssuerCommands * creds make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), - make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), @@ -105252,7 +107633,6 @@ void registerCommandsTests(Commands & commands, CredentialIssuerCommands * creds make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), - make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), @@ -105261,8 +107641,6 @@ void registerCommandsTests(Commands & commands, CredentialIssuerCommands * creds make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), - make_unique(credsIssuerConfig), - make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), make_unique(credsIssuerConfig), diff --git a/zzz_generated/darwin-framework-tool/zap-generated/cluster/Commands.h b/zzz_generated/darwin-framework-tool/zap-generated/cluster/Commands.h index 8b1fb536c318d6..ff16d0a26e1d58 100644 --- a/zzz_generated/darwin-framework-tool/zap-generated/cluster/Commands.h +++ b/zzz_generated/darwin-framework-tool/zap-generated/cluster/Commands.h @@ -104,6 +104,7 @@ | ApplicationBasic | 0x050D | | AccountLogin | 0x050E | | ElectricalMeasurement | 0x0B04 | +| ClientMonitoring | 0x1046 | | UnitTesting | 0xFFF1FC05| | FaultInjection | 0xFFF1FC06| \*----------------------------------------------------------------------------*/ @@ -144,9 +145,7 @@ class IdentifyIdentify : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000003) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRIdentifyClusterIdentifyParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -191,9 +190,7 @@ class IdentifyTriggerEffect : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000003) command (0x00000040) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRIdentifyClusterTriggerEffectParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -238,9 +235,7 @@ class ReadIdentifyIdentifyTime : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000003) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeIdentifyTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Identify.IdentifyTime response %@", [value description]); if (error != nil) { @@ -268,10 +263,8 @@ class WriteIdentifyIdentifyTime : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000003) WriteAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -305,10 +298,8 @@ class SubscribeAttributeIdentifyIdentifyTime : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000003) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -348,9 +339,7 @@ class ReadIdentifyIdentifyType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000003) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeIdentifyTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Identify.IdentifyType response %@", [value description]); if (error != nil) { @@ -375,10 +364,8 @@ class SubscribeAttributeIdentifyIdentifyType : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000003) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -418,9 +405,7 @@ class ReadIdentifyGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000003) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Identify.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -445,10 +430,8 @@ class SubscribeAttributeIdentifyGeneratedCommandList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000003) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -488,9 +471,7 @@ class ReadIdentifyAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000003) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Identify.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -515,10 +496,8 @@ class SubscribeAttributeIdentifyAcceptedCommandList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000003) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -558,9 +537,7 @@ class ReadIdentifyAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000003) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Identify.AttributeList response %@", [value description]); if (error != nil) { @@ -585,10 +562,8 @@ class SubscribeAttributeIdentifyAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000003) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -628,9 +603,7 @@ class ReadIdentifyFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000003) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Identify.FeatureMap response %@", [value description]); if (error != nil) { @@ -655,10 +628,8 @@ class SubscribeAttributeIdentifyFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000003) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -698,9 +669,7 @@ class ReadIdentifyClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000003) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Identify.ClusterRevision response %@", [value description]); if (error != nil) { @@ -725,10 +694,8 @@ class SubscribeAttributeIdentifyClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000003) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -791,9 +758,7 @@ class GroupsAddGroup : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000004) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRGroupsClusterAddGroupParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -841,9 +806,7 @@ class GroupsViewGroup : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000004) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRGroupsClusterViewGroupParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -889,9 +852,7 @@ class GroupsGetGroupMembership : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000004) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRGroupsClusterGetGroupMembershipParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -946,9 +907,7 @@ class GroupsRemoveGroup : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000004) command (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRGroupsClusterRemoveGroupParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -993,9 +952,7 @@ class GroupsRemoveAllGroups : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000004) command (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRGroupsClusterRemoveAllGroupsParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -1038,9 +995,7 @@ class GroupsAddGroupIfIdentifying : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000004) command (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRGroupsClusterAddGroupIfIdentifyingParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -1087,9 +1042,7 @@ class ReadGroupsNameSupport : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000004) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeNameSupportWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Groups.NameSupport response %@", [value description]); if (error != nil) { @@ -1114,10 +1067,8 @@ class SubscribeAttributeGroupsNameSupport : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000004) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -1157,9 +1108,7 @@ class ReadGroupsGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000004) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Groups.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -1184,10 +1133,8 @@ class SubscribeAttributeGroupsGeneratedCommandList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000004) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -1227,9 +1174,7 @@ class ReadGroupsAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000004) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Groups.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -1254,10 +1199,8 @@ class SubscribeAttributeGroupsAcceptedCommandList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000004) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -1297,9 +1240,7 @@ class ReadGroupsAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000004) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Groups.AttributeList response %@", [value description]); if (error != nil) { @@ -1324,10 +1265,8 @@ class SubscribeAttributeGroupsAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000004) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -1367,9 +1306,7 @@ class ReadGroupsFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000004) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Groups.FeatureMap response %@", [value description]); if (error != nil) { @@ -1394,10 +1331,8 @@ class SubscribeAttributeGroupsFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000004) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -1437,9 +1372,7 @@ class ReadGroupsClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000004) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Groups.ClusterRevision response %@", [value description]); if (error != nil) { @@ -1464,10 +1397,8 @@ class SubscribeAttributeGroupsClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000004) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -1543,9 +1474,7 @@ class ScenesAddScene : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000005) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRScenesClusterAddSceneParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -1631,9 +1560,7 @@ class ScenesViewScene : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000005) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRScenesClusterViewSceneParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -1680,9 +1607,7 @@ class ScenesRemoveScene : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000005) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRScenesClusterRemoveSceneParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -1729,9 +1654,7 @@ class ScenesRemoveAllScenes : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000005) command (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRScenesClusterRemoveAllScenesParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -1778,9 +1701,7 @@ class ScenesStoreScene : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000005) command (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRScenesClusterStoreSceneParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -1829,9 +1750,7 @@ class ScenesRecallScene : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000005) command (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRScenesClusterRecallSceneParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -1885,9 +1804,7 @@ class ScenesGetSceneMembership : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000005) command (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRScenesClusterGetSceneMembershipParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -1938,9 +1855,7 @@ class ScenesEnhancedAddScene : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000005) command (0x00000040) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRScenesClusterEnhancedAddSceneParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -2027,9 +1942,7 @@ class ScenesEnhancedViewScene : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000005) command (0x00000041) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRScenesClusterEnhancedViewSceneParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -2080,9 +1993,7 @@ class ScenesCopyScene : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000005) command (0x00000042) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRScenesClusterCopySceneParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -2131,9 +2042,7 @@ class ReadScenesSceneCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeSceneCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Scenes.SceneCount response %@", [value description]); if (error != nil) { @@ -2158,10 +2067,8 @@ class SubscribeAttributeScenesSceneCount : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -2201,9 +2108,7 @@ class ReadScenesCurrentScene : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeCurrentSceneWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Scenes.CurrentScene response %@", [value description]); if (error != nil) { @@ -2228,10 +2133,8 @@ class SubscribeAttributeScenesCurrentScene : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -2271,9 +2174,7 @@ class ReadScenesCurrentGroup : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeCurrentGroupWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Scenes.CurrentGroup response %@", [value description]); if (error != nil) { @@ -2298,10 +2199,8 @@ class SubscribeAttributeScenesCurrentGroup : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -2341,9 +2240,7 @@ class ReadScenesSceneValid : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeSceneValidWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Scenes.SceneValid response %@", [value description]); if (error != nil) { @@ -2368,10 +2265,8 @@ class SubscribeAttributeScenesSceneValid : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -2411,9 +2306,7 @@ class ReadScenesNameSupport : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeNameSupportWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Scenes.NameSupport response %@", [value description]); if (error != nil) { @@ -2438,10 +2331,8 @@ class SubscribeAttributeScenesNameSupport : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -2481,9 +2372,7 @@ class ReadScenesLastConfiguredBy : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeLastConfiguredByWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Scenes.LastConfiguredBy response %@", [value description]); if (error != nil) { @@ -2508,10 +2397,8 @@ class SubscribeAttributeScenesLastConfiguredBy : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -2551,9 +2438,7 @@ class ReadScenesGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Scenes.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -2578,10 +2463,8 @@ class SubscribeAttributeScenesGeneratedCommandList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -2621,9 +2504,7 @@ class ReadScenesAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Scenes.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -2648,10 +2529,8 @@ class SubscribeAttributeScenesAcceptedCommandList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -2691,9 +2570,7 @@ class ReadScenesAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Scenes.AttributeList response %@", [value description]); if (error != nil) { @@ -2718,10 +2595,8 @@ class SubscribeAttributeScenesAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -2761,9 +2636,7 @@ class ReadScenesFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Scenes.FeatureMap response %@", [value description]); if (error != nil) { @@ -2788,10 +2661,8 @@ class SubscribeAttributeScenesFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -2831,9 +2702,7 @@ class ReadScenesClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Scenes.ClusterRevision response %@", [value description]); if (error != nil) { @@ -2858,10 +2727,8 @@ class SubscribeAttributeScenesClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000005) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterScenes * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterScenes alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -2926,9 +2793,7 @@ class OnOffOff : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000006) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTROnOffClusterOffParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -2969,9 +2834,7 @@ class OnOffOn : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000006) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTROnOffClusterOnParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -3012,9 +2875,7 @@ class OnOffToggle : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000006) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTROnOffClusterToggleParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -3057,9 +2918,7 @@ class OnOffOffWithEffect : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000006) command (0x00000040) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTROnOffClusterOffWithEffectParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -3103,9 +2962,7 @@ class OnOffOnWithRecallGlobalScene : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000006) command (0x00000041) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTROnOffClusterOnWithRecallGlobalSceneParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -3149,9 +3006,7 @@ class OnOffOnWithTimedOff : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000006) command (0x00000042) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTROnOffClusterOnWithTimedOffParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -3197,9 +3052,7 @@ class ReadOnOffOnOff : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOff.OnOff response %@", [value description]); if (error != nil) { @@ -3224,10 +3077,8 @@ class SubscribeAttributeOnOffOnOff : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -3267,9 +3118,7 @@ class ReadOnOffGlobalSceneControl : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReadAttribute (0x00004000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeGlobalSceneControlWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOff.GlobalSceneControl response %@", [value description]); if (error != nil) { @@ -3294,10 +3143,8 @@ class SubscribeAttributeOnOffGlobalSceneControl : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReportAttribute (0x00004000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -3337,9 +3184,7 @@ class ReadOnOffOnTime : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReadAttribute (0x00004001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeOnTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOff.OnTime response %@", [value description]); if (error != nil) { @@ -3367,10 +3212,8 @@ class WriteOnOffOnTime : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000006) WriteAttribute (0x00004001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -3404,10 +3247,8 @@ class SubscribeAttributeOnOffOnTime : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReportAttribute (0x00004001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -3447,9 +3288,7 @@ class ReadOnOffOffWaitTime : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReadAttribute (0x00004002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeOffWaitTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOff.OffWaitTime response %@", [value description]); if (error != nil) { @@ -3477,10 +3316,8 @@ class WriteOnOffOffWaitTime : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000006) WriteAttribute (0x00004002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -3514,10 +3351,8 @@ class SubscribeAttributeOnOffOffWaitTime : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReportAttribute (0x00004002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -3557,9 +3392,7 @@ class ReadOnOffStartUpOnOff : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReadAttribute (0x00004003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeStartUpOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOff.StartUpOnOff response %@", [value description]); if (error != nil) { @@ -3587,10 +3420,8 @@ class WriteOnOffStartUpOnOff : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000006) WriteAttribute (0x00004003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -3624,10 +3455,8 @@ class SubscribeAttributeOnOffStartUpOnOff : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReportAttribute (0x00004003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -3667,9 +3496,7 @@ class ReadOnOffGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOff.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -3694,10 +3521,8 @@ class SubscribeAttributeOnOffGeneratedCommandList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -3737,9 +3562,7 @@ class ReadOnOffAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOff.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -3764,10 +3587,8 @@ class SubscribeAttributeOnOffAcceptedCommandList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -3807,9 +3628,7 @@ class ReadOnOffAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOff.AttributeList response %@", [value description]); if (error != nil) { @@ -3834,10 +3653,8 @@ class SubscribeAttributeOnOffAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -3877,9 +3694,7 @@ class ReadOnOffFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOff.FeatureMap response %@", [value description]); if (error != nil) { @@ -3904,10 +3719,8 @@ class SubscribeAttributeOnOffFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -3947,9 +3760,7 @@ class ReadOnOffClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOff.ClusterRevision response %@", [value description]); if (error != nil) { @@ -3974,10 +3785,8 @@ class SubscribeAttributeOnOffClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000006) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -4034,8 +3843,9 @@ class ReadOnOffSwitchConfigurationSwitchType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000007) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOffSwitchConfiguration * cluster = - [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSwitchTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOffSwitchConfiguration.SwitchType response %@", [value description]); if (error != nil) { @@ -4060,9 +3870,10 @@ class SubscribeAttributeOnOffSwitchConfigurationSwitchType : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000007) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOffSwitchConfiguration * cluster = - [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -4102,8 +3913,9 @@ class ReadOnOffSwitchConfigurationSwitchActions : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000007) ReadAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOffSwitchConfiguration * cluster = - [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSwitchActionsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOffSwitchConfiguration.SwitchActions response %@", [value description]); if (error != nil) { @@ -4131,9 +3943,10 @@ class WriteOnOffSwitchConfigurationSwitchActions : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000007) WriteAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOffSwitchConfiguration * cluster = - [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -4167,9 +3980,10 @@ class SubscribeAttributeOnOffSwitchConfigurationSwitchActions : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000007) ReportAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOffSwitchConfiguration * cluster = - [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -4209,8 +4023,9 @@ class ReadOnOffSwitchConfigurationGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000007) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOffSwitchConfiguration * cluster = - [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOffSwitchConfiguration.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -4235,9 +4050,10 @@ class SubscribeAttributeOnOffSwitchConfigurationGeneratedCommandList : public Su { ChipLogProgress(chipTool, "Sending cluster (0x00000007) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOffSwitchConfiguration * cluster = - [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -4277,8 +4093,9 @@ class ReadOnOffSwitchConfigurationAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000007) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOffSwitchConfiguration * cluster = - [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOffSwitchConfiguration.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -4303,9 +4120,10 @@ class SubscribeAttributeOnOffSwitchConfigurationAcceptedCommandList : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x00000007) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOffSwitchConfiguration * cluster = - [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -4345,8 +4163,9 @@ class ReadOnOffSwitchConfigurationAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000007) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOffSwitchConfiguration * cluster = - [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOffSwitchConfiguration.AttributeList response %@", [value description]); if (error != nil) { @@ -4371,9 +4190,10 @@ class SubscribeAttributeOnOffSwitchConfigurationAttributeList : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000007) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOffSwitchConfiguration * cluster = - [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -4413,8 +4233,9 @@ class ReadOnOffSwitchConfigurationFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000007) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOffSwitchConfiguration * cluster = - [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOffSwitchConfiguration.FeatureMap response %@", [value description]); if (error != nil) { @@ -4439,9 +4260,10 @@ class SubscribeAttributeOnOffSwitchConfigurationFeatureMap : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000007) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOffSwitchConfiguration * cluster = - [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -4481,8 +4303,9 @@ class ReadOnOffSwitchConfigurationClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000007) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOffSwitchConfiguration * cluster = - [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OnOffSwitchConfiguration.ClusterRevision response %@", [value description]); if (error != nil) { @@ -4507,9 +4330,10 @@ class SubscribeAttributeOnOffSwitchConfigurationClusterRevision : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000007) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOnOffSwitchConfiguration * cluster = - [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOnOffSwitchConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -4590,9 +4414,9 @@ class LevelControlMoveToLevel : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000008) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -4646,9 +4470,9 @@ class LevelControlMove : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000008) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRLevelControlClusterMoveParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -4703,9 +4527,9 @@ class LevelControlStep : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000008) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRLevelControlClusterStepParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -4758,9 +4582,9 @@ class LevelControlStop : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000008) command (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRLevelControlClusterStopParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -4808,9 +4632,9 @@ class LevelControlMoveToLevelWithOnOff : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000008) command (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRLevelControlClusterMoveToLevelWithOnOffParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -4864,9 +4688,9 @@ class LevelControlMoveWithOnOff : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000008) command (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRLevelControlClusterMoveWithOnOffParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -4921,9 +4745,9 @@ class LevelControlStepWithOnOff : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000008) command (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRLevelControlClusterStepWithOnOffParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -4976,9 +4800,9 @@ class LevelControlStopWithOnOff : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000008) command (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRLevelControlClusterStopWithOnOffParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -5023,9 +4847,9 @@ class LevelControlMoveToClosestFrequency : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000008) command (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRLevelControlClusterMoveToClosestFrequencyParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -5069,9 +4893,9 @@ class ReadLevelControlCurrentLevel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.CurrentLevel response %@", [value description]); if (error != nil) { @@ -5096,10 +4920,10 @@ class SubscribeAttributeLevelControlCurrentLevel : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -5139,9 +4963,9 @@ class ReadLevelControlRemainingTime : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRemainingTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.RemainingTime response %@", [value description]); if (error != nil) { @@ -5166,10 +4990,10 @@ class SubscribeAttributeLevelControlRemainingTime : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -5209,9 +5033,9 @@ class ReadLevelControlMinLevel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.MinLevel response %@", [value description]); if (error != nil) { @@ -5236,10 +5060,10 @@ class SubscribeAttributeLevelControlMinLevel : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -5279,9 +5103,9 @@ class ReadLevelControlMaxLevel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.MaxLevel response %@", [value description]); if (error != nil) { @@ -5306,10 +5130,10 @@ class SubscribeAttributeLevelControlMaxLevel : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -5349,9 +5173,9 @@ class ReadLevelControlCurrentFrequency : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentFrequencyWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.CurrentFrequency response %@", [value description]); if (error != nil) { @@ -5376,10 +5200,10 @@ class SubscribeAttributeLevelControlCurrentFrequency : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -5419,9 +5243,9 @@ class ReadLevelControlMinFrequency : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinFrequencyWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.MinFrequency response %@", [value description]); if (error != nil) { @@ -5446,10 +5270,10 @@ class SubscribeAttributeLevelControlMinFrequency : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -5489,9 +5313,9 @@ class ReadLevelControlMaxFrequency : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxFrequencyWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.MaxFrequency response %@", [value description]); if (error != nil) { @@ -5516,10 +5340,10 @@ class SubscribeAttributeLevelControlMaxFrequency : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -5559,9 +5383,9 @@ class ReadLevelControlOptions : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOptionsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.Options response %@", [value description]); if (error != nil) { @@ -5589,10 +5413,10 @@ class WriteLevelControlOptions : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) WriteAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -5626,10 +5450,10 @@ class SubscribeAttributeLevelControlOptions : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -5669,9 +5493,9 @@ class ReadLevelControlOnOffTransitionTime : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOnOffTransitionTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.OnOffTransitionTime response %@", [value description]); if (error != nil) { @@ -5699,10 +5523,10 @@ class WriteLevelControlOnOffTransitionTime : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) WriteAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -5736,10 +5560,10 @@ class SubscribeAttributeLevelControlOnOffTransitionTime : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -5779,9 +5603,9 @@ class ReadLevelControlOnLevel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOnLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.OnLevel response %@", [value description]); if (error != nil) { @@ -5809,10 +5633,10 @@ class WriteLevelControlOnLevel : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) WriteAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -5846,10 +5670,10 @@ class SubscribeAttributeLevelControlOnLevel : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -5889,9 +5713,9 @@ class ReadLevelControlOnTransitionTime : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOnTransitionTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.OnTransitionTime response %@", [value description]); if (error != nil) { @@ -5919,10 +5743,10 @@ class WriteLevelControlOnTransitionTime : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) WriteAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -5956,10 +5780,10 @@ class SubscribeAttributeLevelControlOnTransitionTime : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -5999,9 +5823,9 @@ class ReadLevelControlOffTransitionTime : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOffTransitionTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.OffTransitionTime response %@", [value description]); if (error != nil) { @@ -6029,10 +5853,10 @@ class WriteLevelControlOffTransitionTime : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) WriteAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -6066,10 +5890,10 @@ class SubscribeAttributeLevelControlOffTransitionTime : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -6109,9 +5933,9 @@ class ReadLevelControlDefaultMoveRate : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDefaultMoveRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.DefaultMoveRate response %@", [value description]); if (error != nil) { @@ -6139,10 +5963,10 @@ class WriteLevelControlDefaultMoveRate : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) WriteAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -6176,10 +6000,10 @@ class SubscribeAttributeLevelControlDefaultMoveRate : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -6219,9 +6043,9 @@ class ReadLevelControlStartUpCurrentLevel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x00004000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeStartUpCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.StartUpCurrentLevel response %@", [value description]); if (error != nil) { @@ -6249,10 +6073,10 @@ class WriteLevelControlStartUpCurrentLevel : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) WriteAttribute (0x00004000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -6286,10 +6110,10 @@ class SubscribeAttributeLevelControlStartUpCurrentLevel : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x00004000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -6329,9 +6153,9 @@ class ReadLevelControlGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -6356,10 +6180,10 @@ class SubscribeAttributeLevelControlGeneratedCommandList : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -6399,9 +6223,9 @@ class ReadLevelControlAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -6426,10 +6250,10 @@ class SubscribeAttributeLevelControlAcceptedCommandList : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -6469,9 +6293,9 @@ class ReadLevelControlAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.AttributeList response %@", [value description]); if (error != nil) { @@ -6496,10 +6320,10 @@ class SubscribeAttributeLevelControlAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -6539,9 +6363,9 @@ class ReadLevelControlFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.FeatureMap response %@", [value description]); if (error != nil) { @@ -6566,10 +6390,10 @@ class SubscribeAttributeLevelControlFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -6609,9 +6433,9 @@ class ReadLevelControlClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LevelControl.ClusterRevision response %@", [value description]); if (error != nil) { @@ -6636,10 +6460,10 @@ class SubscribeAttributeLevelControlClusterRevision : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000008) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -6703,9 +6527,9 @@ class ReadBinaryInputBasicActiveText : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActiveTextWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BinaryInputBasic.ActiveText response %@", [value description]); if (error != nil) { @@ -6733,10 +6557,10 @@ class WriteBinaryInputBasicActiveText : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) WriteAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -6772,10 +6596,10 @@ class SubscribeAttributeBinaryInputBasicActiveText : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -6815,9 +6639,9 @@ class ReadBinaryInputBasicDescription : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReadAttribute (0x0000001C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDescriptionWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BinaryInputBasic.Description response %@", [value description]); if (error != nil) { @@ -6845,10 +6669,10 @@ class WriteBinaryInputBasicDescription : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) WriteAttribute (0x0000001C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -6884,10 +6708,10 @@ class SubscribeAttributeBinaryInputBasicDescription : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReportAttribute (0x0000001C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -6927,9 +6751,9 @@ class ReadBinaryInputBasicInactiveText : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReadAttribute (0x0000002E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInactiveTextWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BinaryInputBasic.InactiveText response %@", [value description]); if (error != nil) { @@ -6957,10 +6781,10 @@ class WriteBinaryInputBasicInactiveText : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) WriteAttribute (0x0000002E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -6996,10 +6820,10 @@ class SubscribeAttributeBinaryInputBasicInactiveText : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReportAttribute (0x0000002E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -7039,9 +6863,9 @@ class ReadBinaryInputBasicOutOfService : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReadAttribute (0x00000051) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOutOfServiceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BinaryInputBasic.OutOfService response %@", [value description]); if (error != nil) { @@ -7069,10 +6893,10 @@ class WriteBinaryInputBasicOutOfService : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) WriteAttribute (0x00000051) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -7106,10 +6930,10 @@ class SubscribeAttributeBinaryInputBasicOutOfService : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReportAttribute (0x00000051) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -7149,9 +6973,9 @@ class ReadBinaryInputBasicPolarity : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReadAttribute (0x00000054) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePolarityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BinaryInputBasic.Polarity response %@", [value description]); if (error != nil) { @@ -7176,10 +7000,10 @@ class SubscribeAttributeBinaryInputBasicPolarity : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReportAttribute (0x00000054) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -7219,9 +7043,9 @@ class ReadBinaryInputBasicPresentValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReadAttribute (0x00000055) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePresentValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BinaryInputBasic.PresentValue response %@", [value description]); if (error != nil) { @@ -7249,10 +7073,10 @@ class WriteBinaryInputBasicPresentValue : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) WriteAttribute (0x00000055) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -7286,10 +7110,10 @@ class SubscribeAttributeBinaryInputBasicPresentValue : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReportAttribute (0x00000055) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -7329,9 +7153,9 @@ class ReadBinaryInputBasicReliability : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReadAttribute (0x00000067) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeReliabilityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BinaryInputBasic.Reliability response %@", [value description]); if (error != nil) { @@ -7359,10 +7183,10 @@ class WriteBinaryInputBasicReliability : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) WriteAttribute (0x00000067) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -7396,10 +7220,10 @@ class SubscribeAttributeBinaryInputBasicReliability : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReportAttribute (0x00000067) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -7439,9 +7263,9 @@ class ReadBinaryInputBasicStatusFlags : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReadAttribute (0x0000006F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeStatusFlagsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BinaryInputBasic.StatusFlags response %@", [value description]); if (error != nil) { @@ -7466,10 +7290,10 @@ class SubscribeAttributeBinaryInputBasicStatusFlags : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReportAttribute (0x0000006F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -7509,9 +7333,9 @@ class ReadBinaryInputBasicApplicationType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReadAttribute (0x00000100) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeApplicationTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BinaryInputBasic.ApplicationType response %@", [value description]); if (error != nil) { @@ -7536,10 +7360,10 @@ class SubscribeAttributeBinaryInputBasicApplicationType : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReportAttribute (0x00000100) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -7579,9 +7403,9 @@ class ReadBinaryInputBasicGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"BinaryInputBasic.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -7606,10 +7430,10 @@ class SubscribeAttributeBinaryInputBasicGeneratedCommandList : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -7649,9 +7473,9 @@ class ReadBinaryInputBasicAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"BinaryInputBasic.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -7676,10 +7500,10 @@ class SubscribeAttributeBinaryInputBasicAcceptedCommandList : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -7719,9 +7543,9 @@ class ReadBinaryInputBasicAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"BinaryInputBasic.AttributeList response %@", [value description]); if (error != nil) { @@ -7746,10 +7570,10 @@ class SubscribeAttributeBinaryInputBasicAttributeList : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -7789,9 +7613,9 @@ class ReadBinaryInputBasicFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BinaryInputBasic.FeatureMap response %@", [value description]); if (error != nil) { @@ -7816,10 +7640,10 @@ class SubscribeAttributeBinaryInputBasicFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -7859,9 +7683,9 @@ class ReadBinaryInputBasicClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BinaryInputBasic.ClusterRevision response %@", [value description]); if (error != nil) { @@ -7886,10 +7710,10 @@ class SubscribeAttributeBinaryInputBasicClusterRevision : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x0000000F) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinaryInputBasic * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinaryInputBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -7948,9 +7772,9 @@ class ReadDescriptorDeviceTypeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDeviceTypeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Descriptor.DeviceTypeList response %@", [value description]); if (error != nil) { @@ -7975,10 +7799,10 @@ class SubscribeAttributeDescriptorDeviceTypeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -8018,9 +7842,9 @@ class ReadDescriptorServerList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeServerListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Descriptor.ServerList response %@", [value description]); if (error != nil) { @@ -8045,10 +7869,10 @@ class SubscribeAttributeDescriptorServerList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -8088,9 +7912,9 @@ class ReadDescriptorClientList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClientListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Descriptor.ClientList response %@", [value description]); if (error != nil) { @@ -8115,10 +7939,10 @@ class SubscribeAttributeDescriptorClientList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -8158,9 +7982,9 @@ class ReadDescriptorPartsList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePartsListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Descriptor.PartsList response %@", [value description]); if (error != nil) { @@ -8185,10 +8009,10 @@ class SubscribeAttributeDescriptorPartsList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -8228,9 +8052,9 @@ class ReadDescriptorGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Descriptor.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -8255,10 +8079,10 @@ class SubscribeAttributeDescriptorGeneratedCommandList : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -8298,9 +8122,9 @@ class ReadDescriptorAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Descriptor.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -8325,10 +8149,10 @@ class SubscribeAttributeDescriptorAcceptedCommandList : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -8368,9 +8192,9 @@ class ReadDescriptorAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Descriptor.AttributeList response %@", [value description]); if (error != nil) { @@ -8395,10 +8219,10 @@ class SubscribeAttributeDescriptorAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -8438,9 +8262,9 @@ class ReadDescriptorFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Descriptor.FeatureMap response %@", [value description]); if (error != nil) { @@ -8465,10 +8289,10 @@ class SubscribeAttributeDescriptorFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -8508,9 +8332,9 @@ class ReadDescriptorClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Descriptor.ClusterRevision response %@", [value description]); if (error != nil) { @@ -8535,10 +8359,10 @@ class SubscribeAttributeDescriptorClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001D) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -8594,10 +8418,8 @@ class ReadBindingBinding : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001E) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRReadParams alloc] init]; if (mFabricFiltered.HasValue()) { params.filterByFabric = mFabricFiltered.Value(); } @@ -8630,10 +8452,8 @@ class WriteBindingBinding : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001E) WriteAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -8698,10 +8518,8 @@ class SubscribeAttributeBindingBinding : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001E) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -8741,9 +8559,7 @@ class ReadBindingGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001E) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Binding.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -8768,10 +8584,8 @@ class SubscribeAttributeBindingGeneratedCommandList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001E) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -8811,9 +8625,7 @@ class ReadBindingAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001E) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Binding.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -8838,10 +8650,8 @@ class SubscribeAttributeBindingAcceptedCommandList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001E) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -8881,9 +8691,7 @@ class ReadBindingAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001E) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Binding.AttributeList response %@", [value description]); if (error != nil) { @@ -8908,10 +8716,8 @@ class SubscribeAttributeBindingAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001E) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -8951,9 +8757,7 @@ class ReadBindingFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001E) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Binding.FeatureMap response %@", [value description]); if (error != nil) { @@ -8978,10 +8782,8 @@ class SubscribeAttributeBindingFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001E) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -9021,9 +8823,7 @@ class ReadBindingClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001E) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Binding.ClusterRevision response %@", [value description]); if (error != nil) { @@ -9048,10 +8848,8 @@ class SubscribeAttributeBindingClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001E) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -9113,18 +8911,18 @@ class ReadAccessControlAcl : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRReadParams alloc] init]; if (mFabricFiltered.HasValue()) { params.filterByFabric = mFabricFiltered.Value(); } - [cluster readAttributeAclWithParams:params + [cluster readAttributeACLWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"AccessControl.Acl response %@", [value description]); + NSLog(@"AccessControl.ACL response %@", [value description]); if (error != nil) { - LogNSError("AccessControl Acl read Error", error); + LogNSError("AccessControl ACL read Error", error); } SetCommandExitStatus(error); }]; @@ -9149,10 +8947,10 @@ class WriteAccessControlAcl : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) WriteAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -9211,11 +9009,11 @@ class WriteAccessControlAcl : public WriteAttribute { value = array_0; } - [cluster writeAttributeAclWithValue:value + [cluster writeAttributeACLWithValue:value params:params completion:^(NSError * _Nullable error) { if (error != nil) { - LogNSError("AccessControl Acl write Error", error); + LogNSError("AccessControl ACL write Error", error); } SetCommandExitStatus(error); }]; @@ -9241,10 +9039,10 @@ class SubscribeAttributeAccessControlAcl : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -9254,12 +9052,12 @@ class SubscribeAttributeAccessControlAcl : public SubscribeAttribute { if (mAutoResubscribe.HasValue()) { params.resubscribeIfLost = mAutoResubscribe.Value(); } - [cluster subscribeAttributeAclWithParams:params + [cluster subscribeAttributeACLWithParams:params subscriptionEstablished:^() { mSubscriptionEstablished = YES; } reportHandler:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"AccessControl.Acl response %@", [value description]); + NSLog(@"AccessControl.ACL response %@", [value description]); SetCommandExitStatus(error); }]; @@ -9284,10 +9082,10 @@ class ReadAccessControlExtension : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRReadParams alloc] init]; if (mFabricFiltered.HasValue()) { params.filterByFabric = mFabricFiltered.Value(); } @@ -9320,10 +9118,10 @@ class WriteAccessControlExtension : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) WriteAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -9370,10 +9168,10 @@ class SubscribeAttributeAccessControlExtension : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -9413,9 +9211,9 @@ class ReadAccessControlSubjectsPerAccessControlEntry : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSubjectsPerAccessControlEntryWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"AccessControl.SubjectsPerAccessControlEntry response %@", [value description]); if (error != nil) { @@ -9440,10 +9238,10 @@ class SubscribeAttributeAccessControlSubjectsPerAccessControlEntry : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -9483,9 +9281,9 @@ class ReadAccessControlTargetsPerAccessControlEntry : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTargetsPerAccessControlEntryWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"AccessControl.TargetsPerAccessControlEntry response %@", [value description]); if (error != nil) { @@ -9510,10 +9308,10 @@ class SubscribeAttributeAccessControlTargetsPerAccessControlEntry : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -9553,9 +9351,9 @@ class ReadAccessControlAccessControlEntriesPerFabric : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAccessControlEntriesPerFabricWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"AccessControl.AccessControlEntriesPerFabric response %@", [value description]); if (error != nil) { @@ -9580,10 +9378,10 @@ class SubscribeAttributeAccessControlAccessControlEntriesPerFabric : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -9623,9 +9421,9 @@ class ReadAccessControlGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"AccessControl.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -9650,10 +9448,10 @@ class SubscribeAttributeAccessControlGeneratedCommandList : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -9693,9 +9491,9 @@ class ReadAccessControlAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"AccessControl.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -9720,10 +9518,10 @@ class SubscribeAttributeAccessControlAcceptedCommandList : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -9763,9 +9561,9 @@ class ReadAccessControlAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"AccessControl.AttributeList response %@", [value description]); if (error != nil) { @@ -9790,10 +9588,10 @@ class SubscribeAttributeAccessControlAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -9833,9 +9631,9 @@ class ReadAccessControlFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"AccessControl.FeatureMap response %@", [value description]); if (error != nil) { @@ -9860,10 +9658,10 @@ class SubscribeAttributeAccessControlFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -9903,9 +9701,9 @@ class ReadAccessControlClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"AccessControl.ClusterRevision response %@", [value description]); if (error != nil) { @@ -9930,10 +9728,10 @@ class SubscribeAttributeAccessControlClusterRevision : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000001F) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -10006,9 +9804,7 @@ class ActionsInstantAction : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000025) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRActionsClusterInstantActionParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -10059,9 +9855,7 @@ class ActionsInstantActionWithTransition : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000025) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRActionsClusterInstantActionWithTransitionParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -10112,9 +9906,7 @@ class ActionsStartAction : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000025) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRActionsClusterStartActionParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -10165,9 +9957,7 @@ class ActionsStartActionWithDuration : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000025) command (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRActionsClusterStartActionWithDurationParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -10218,9 +10008,7 @@ class ActionsStopAction : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000025) command (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRActionsClusterStopActionParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -10270,9 +10058,7 @@ class ActionsPauseAction : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000025) command (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRActionsClusterPauseActionParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -10323,9 +10109,7 @@ class ActionsPauseActionWithDuration : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000025) command (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRActionsClusterPauseActionWithDurationParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -10376,9 +10160,7 @@ class ActionsResumeAction : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000025) command (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRActionsClusterResumeActionParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -10428,9 +10210,7 @@ class ActionsEnableAction : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000025) command (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRActionsClusterEnableActionParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -10481,9 +10261,7 @@ class ActionsEnableActionWithDuration : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000025) command (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRActionsClusterEnableActionWithDurationParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -10534,9 +10312,7 @@ class ActionsDisableAction : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000025) command (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRActionsClusterDisableActionParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -10587,9 +10363,7 @@ class ActionsDisableActionWithDuration : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000025) command (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRActionsClusterDisableActionWithDurationParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -10639,9 +10413,7 @@ class ReadActionsActionList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeActionListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Actions.ActionList response %@", [value description]); if (error != nil) { @@ -10666,10 +10438,8 @@ class SubscribeAttributeActionsActionList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -10709,9 +10479,7 @@ class ReadActionsEndpointLists : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeEndpointListsWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Actions.EndpointLists response %@", [value description]); if (error != nil) { @@ -10736,10 +10504,8 @@ class SubscribeAttributeActionsEndpointLists : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -10779,9 +10545,7 @@ class ReadActionsSetupURL : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeSetupURLWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"Actions.SetupURL response %@", [value description]); if (error != nil) { @@ -10806,10 +10570,8 @@ class SubscribeAttributeActionsSetupURL : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -10849,9 +10611,7 @@ class ReadActionsGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Actions.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -10876,10 +10636,8 @@ class SubscribeAttributeActionsGeneratedCommandList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -10919,9 +10677,7 @@ class ReadActionsAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Actions.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -10946,10 +10702,8 @@ class SubscribeAttributeActionsAcceptedCommandList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -10989,9 +10743,7 @@ class ReadActionsAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Actions.AttributeList response %@", [value description]); if (error != nil) { @@ -11016,10 +10768,8 @@ class SubscribeAttributeActionsAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -11059,9 +10809,7 @@ class ReadActionsFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Actions.FeatureMap response %@", [value description]); if (error != nil) { @@ -11086,10 +10834,8 @@ class SubscribeAttributeActionsFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -11129,9 +10875,7 @@ class ReadActionsClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Actions.ClusterRevision response %@", [value description]); if (error != nil) { @@ -11156,10 +10900,8 @@ class SubscribeAttributeActionsClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000025) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -11238,9 +10980,7 @@ class BasicMfgSpecificPing : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000028) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRBasicClusterMfgSpecificPingParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -11282,9 +11022,7 @@ class ReadBasicDataModelRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeDataModelRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.DataModelRevision response %@", [value description]); if (error != nil) { @@ -11309,10 +11047,8 @@ class SubscribeAttributeBasicDataModelRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -11352,9 +11088,7 @@ class ReadBasicVendorName : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeVendorNameWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.VendorName response %@", [value description]); if (error != nil) { @@ -11379,10 +11113,8 @@ class SubscribeAttributeBasicVendorName : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -11422,9 +11154,7 @@ class ReadBasicVendorID : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeVendorIDWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.VendorID response %@", [value description]); if (error != nil) { @@ -11449,10 +11179,8 @@ class SubscribeAttributeBasicVendorID : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -11492,9 +11220,7 @@ class ReadBasicProductName : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeProductNameWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.ProductName response %@", [value description]); if (error != nil) { @@ -11519,10 +11245,8 @@ class SubscribeAttributeBasicProductName : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -11562,9 +11286,7 @@ class ReadBasicProductID : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeProductIDWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.ProductID response %@", [value description]); if (error != nil) { @@ -11589,10 +11311,8 @@ class SubscribeAttributeBasicProductID : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -11632,9 +11352,7 @@ class ReadBasicNodeLabel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeNodeLabelWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.NodeLabel response %@", [value description]); if (error != nil) { @@ -11662,10 +11380,8 @@ class WriteBasicNodeLabel : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) WriteAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -11701,10 +11417,8 @@ class SubscribeAttributeBasicNodeLabel : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -11744,9 +11458,7 @@ class ReadBasicLocation : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeLocationWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.Location response %@", [value description]); if (error != nil) { @@ -11774,10 +11486,8 @@ class WriteBasicLocation : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) WriteAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -11813,10 +11523,8 @@ class SubscribeAttributeBasicLocation : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -11856,9 +11564,7 @@ class ReadBasicHardwareVersion : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeHardwareVersionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.HardwareVersion response %@", [value description]); if (error != nil) { @@ -11883,10 +11589,8 @@ class SubscribeAttributeBasicHardwareVersion : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -11926,9 +11630,7 @@ class ReadBasicHardwareVersionString : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeHardwareVersionStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.HardwareVersionString response %@", [value description]); if (error != nil) { @@ -11953,10 +11655,8 @@ class SubscribeAttributeBasicHardwareVersionString : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -11996,9 +11696,7 @@ class ReadBasicSoftwareVersion : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeSoftwareVersionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.SoftwareVersion response %@", [value description]); if (error != nil) { @@ -12023,10 +11721,8 @@ class SubscribeAttributeBasicSoftwareVersion : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -12066,9 +11762,7 @@ class ReadBasicSoftwareVersionString : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeSoftwareVersionStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.SoftwareVersionString response %@", [value description]); if (error != nil) { @@ -12093,10 +11787,8 @@ class SubscribeAttributeBasicSoftwareVersionString : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -12136,9 +11828,7 @@ class ReadBasicManufacturingDate : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeManufacturingDateWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.ManufacturingDate response %@", [value description]); if (error != nil) { @@ -12163,10 +11853,8 @@ class SubscribeAttributeBasicManufacturingDate : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -12206,9 +11894,7 @@ class ReadBasicPartNumber : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributePartNumberWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.PartNumber response %@", [value description]); if (error != nil) { @@ -12233,10 +11919,8 @@ class SubscribeAttributeBasicPartNumber : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -12276,9 +11960,7 @@ class ReadBasicProductURL : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x0000000D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeProductURLWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.ProductURL response %@", [value description]); if (error != nil) { @@ -12303,10 +11985,8 @@ class SubscribeAttributeBasicProductURL : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x0000000D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -12346,9 +12026,7 @@ class ReadBasicProductLabel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x0000000E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeProductLabelWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.ProductLabel response %@", [value description]); if (error != nil) { @@ -12373,10 +12051,8 @@ class SubscribeAttributeBasicProductLabel : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x0000000E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -12416,9 +12092,7 @@ class ReadBasicSerialNumber : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeSerialNumberWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.SerialNumber response %@", [value description]); if (error != nil) { @@ -12443,10 +12117,8 @@ class SubscribeAttributeBasicSerialNumber : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -12486,9 +12158,7 @@ class ReadBasicLocalConfigDisabled : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeLocalConfigDisabledWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.LocalConfigDisabled response %@", [value description]); if (error != nil) { @@ -12516,10 +12186,8 @@ class WriteBasicLocalConfigDisabled : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) WriteAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -12553,10 +12221,8 @@ class SubscribeAttributeBasicLocalConfigDisabled : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -12596,9 +12262,7 @@ class ReadBasicReachable : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeReachableWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.Reachable response %@", [value description]); if (error != nil) { @@ -12623,10 +12287,8 @@ class SubscribeAttributeBasicReachable : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -12666,9 +12328,7 @@ class ReadBasicUniqueID : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeUniqueIDWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.UniqueID response %@", [value description]); if (error != nil) { @@ -12693,10 +12353,8 @@ class SubscribeAttributeBasicUniqueID : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -12736,9 +12394,7 @@ class ReadBasicCapabilityMinima : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeCapabilityMinimaWithCompletion:^( MTRBasicClusterCapabilityMinimaStruct * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.CapabilityMinima response %@", [value description]); @@ -12764,10 +12420,8 @@ class SubscribeAttributeBasicCapabilityMinima : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -12807,9 +12461,7 @@ class ReadBasicGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -12834,10 +12486,8 @@ class SubscribeAttributeBasicGeneratedCommandList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -12877,9 +12527,7 @@ class ReadBasicAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -12904,10 +12552,8 @@ class SubscribeAttributeBasicAcceptedCommandList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -12947,9 +12593,7 @@ class ReadBasicAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.AttributeList response %@", [value description]); if (error != nil) { @@ -12974,10 +12618,8 @@ class SubscribeAttributeBasicAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -13017,9 +12659,7 @@ class ReadBasicFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.FeatureMap response %@", [value description]); if (error != nil) { @@ -13044,10 +12684,8 @@ class SubscribeAttributeBasicFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -13087,9 +12725,7 @@ class ReadBasicClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Basic.ClusterRevision response %@", [value description]); if (error != nil) { @@ -13114,10 +12750,8 @@ class SubscribeAttributeBasicClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000028) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -13183,9 +12817,10 @@ class OtaSoftwareUpdateProviderQueryImage : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000029) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateProvider * cluster = - [[MTRBaseClusterOtaSoftwareUpdateProvider alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - __auto_type * params = [[MTROtaSoftwareUpdateProviderClusterQueryImageParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateProvider alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTROTASoftwareUpdateProviderClusterQueryImageParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.vendorId = [NSNumber numberWithUnsignedShort:chip::to_underlying(mRequest.vendorId)]; @@ -13227,7 +12862,7 @@ class OtaSoftwareUpdateProviderQueryImage : public ClusterCommand { uint16_t __block responsesNeeded = repeatCount; while (repeatCount--) { [cluster queryImageWithParams:params - completion:^(MTROtaSoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable values, + completion:^(MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable values, NSError * _Nullable error) { NSLog(@"Values: %@", values); responsesNeeded--; @@ -13267,9 +12902,10 @@ class OtaSoftwareUpdateProviderApplyUpdateRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000029) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateProvider * cluster = - [[MTRBaseClusterOtaSoftwareUpdateProvider alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - __auto_type * params = [[MTROtaSoftwareUpdateProviderClusterApplyUpdateRequestParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateProvider alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.updateToken = [NSData dataWithBytes:mRequest.updateToken.data() length:mRequest.updateToken.size()]; @@ -13278,7 +12914,7 @@ class OtaSoftwareUpdateProviderApplyUpdateRequest : public ClusterCommand { uint16_t __block responsesNeeded = repeatCount; while (repeatCount--) { [cluster applyUpdateRequestWithParams:params - completion:^(MTROtaSoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable values, + completion:^(MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable values, NSError * _Nullable error) { NSLog(@"Values: %@", values); responsesNeeded--; @@ -13316,9 +12952,10 @@ class OtaSoftwareUpdateProviderNotifyUpdateApplied : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000029) command (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateProvider * cluster = - [[MTRBaseClusterOtaSoftwareUpdateProvider alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - __auto_type * params = [[MTROtaSoftwareUpdateProviderClusterNotifyUpdateAppliedParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateProvider alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTROTASoftwareUpdateProviderClusterNotifyUpdateAppliedParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.updateToken = [NSData dataWithBytes:mRequest.updateToken.data() length:mRequest.updateToken.size()]; @@ -13362,12 +12999,13 @@ class ReadOtaSoftwareUpdateProviderGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000029) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateProvider * cluster = - [[MTRBaseClusterOtaSoftwareUpdateProvider alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateProvider alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateProvider.GeneratedCommandList response %@", [value description]); + NSLog(@"OTASoftwareUpdateProvider.GeneratedCommandList response %@", [value description]); if (error != nil) { - LogNSError("OtaSoftwareUpdateProvider GeneratedCommandList read Error", error); + LogNSError("OTASoftwareUpdateProvider GeneratedCommandList read Error", error); } SetCommandExitStatus(error); }]; @@ -13388,9 +13026,10 @@ class SubscribeAttributeOtaSoftwareUpdateProviderGeneratedCommandList : public S { ChipLogProgress(chipTool, "Sending cluster (0x00000029) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateProvider * cluster = - [[MTRBaseClusterOtaSoftwareUpdateProvider alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateProvider alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -13405,7 +13044,7 @@ class SubscribeAttributeOtaSoftwareUpdateProviderGeneratedCommandList : public S mSubscriptionEstablished = YES; } reportHandler:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateProvider.GeneratedCommandList response %@", [value description]); + NSLog(@"OTASoftwareUpdateProvider.GeneratedCommandList response %@", [value description]); SetCommandExitStatus(error); }]; @@ -13430,12 +13069,13 @@ class ReadOtaSoftwareUpdateProviderAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000029) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateProvider * cluster = - [[MTRBaseClusterOtaSoftwareUpdateProvider alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateProvider alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateProvider.AcceptedCommandList response %@", [value description]); + NSLog(@"OTASoftwareUpdateProvider.AcceptedCommandList response %@", [value description]); if (error != nil) { - LogNSError("OtaSoftwareUpdateProvider AcceptedCommandList read Error", error); + LogNSError("OTASoftwareUpdateProvider AcceptedCommandList read Error", error); } SetCommandExitStatus(error); }]; @@ -13456,9 +13096,10 @@ class SubscribeAttributeOtaSoftwareUpdateProviderAcceptedCommandList : public Su { ChipLogProgress(chipTool, "Sending cluster (0x00000029) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateProvider * cluster = - [[MTRBaseClusterOtaSoftwareUpdateProvider alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateProvider alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -13473,7 +13114,7 @@ class SubscribeAttributeOtaSoftwareUpdateProviderAcceptedCommandList : public Su mSubscriptionEstablished = YES; } reportHandler:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateProvider.AcceptedCommandList response %@", [value description]); + NSLog(@"OTASoftwareUpdateProvider.AcceptedCommandList response %@", [value description]); SetCommandExitStatus(error); }]; @@ -13498,12 +13139,13 @@ class ReadOtaSoftwareUpdateProviderAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000029) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateProvider * cluster = - [[MTRBaseClusterOtaSoftwareUpdateProvider alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateProvider alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateProvider.AttributeList response %@", [value description]); + NSLog(@"OTASoftwareUpdateProvider.AttributeList response %@", [value description]); if (error != nil) { - LogNSError("OtaSoftwareUpdateProvider AttributeList read Error", error); + LogNSError("OTASoftwareUpdateProvider AttributeList read Error", error); } SetCommandExitStatus(error); }]; @@ -13524,9 +13166,10 @@ class SubscribeAttributeOtaSoftwareUpdateProviderAttributeList : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000029) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateProvider * cluster = - [[MTRBaseClusterOtaSoftwareUpdateProvider alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateProvider alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -13541,7 +13184,7 @@ class SubscribeAttributeOtaSoftwareUpdateProviderAttributeList : public Subscrib mSubscriptionEstablished = YES; } reportHandler:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateProvider.AttributeList response %@", [value description]); + NSLog(@"OTASoftwareUpdateProvider.AttributeList response %@", [value description]); SetCommandExitStatus(error); }]; @@ -13566,12 +13209,13 @@ class ReadOtaSoftwareUpdateProviderFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000029) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateProvider * cluster = - [[MTRBaseClusterOtaSoftwareUpdateProvider alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateProvider alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateProvider.FeatureMap response %@", [value description]); + NSLog(@"OTASoftwareUpdateProvider.FeatureMap response %@", [value description]); if (error != nil) { - LogNSError("OtaSoftwareUpdateProvider FeatureMap read Error", error); + LogNSError("OTASoftwareUpdateProvider FeatureMap read Error", error); } SetCommandExitStatus(error); }]; @@ -13592,9 +13236,10 @@ class SubscribeAttributeOtaSoftwareUpdateProviderFeatureMap : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000029) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateProvider * cluster = - [[MTRBaseClusterOtaSoftwareUpdateProvider alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateProvider alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -13609,7 +13254,7 @@ class SubscribeAttributeOtaSoftwareUpdateProviderFeatureMap : public SubscribeAt mSubscriptionEstablished = YES; } reportHandler:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateProvider.FeatureMap response %@", [value description]); + NSLog(@"OTASoftwareUpdateProvider.FeatureMap response %@", [value description]); SetCommandExitStatus(error); }]; @@ -13634,12 +13279,13 @@ class ReadOtaSoftwareUpdateProviderClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000029) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateProvider * cluster = - [[MTRBaseClusterOtaSoftwareUpdateProvider alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateProvider alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateProvider.ClusterRevision response %@", [value description]); + NSLog(@"OTASoftwareUpdateProvider.ClusterRevision response %@", [value description]); if (error != nil) { - LogNSError("OtaSoftwareUpdateProvider ClusterRevision read Error", error); + LogNSError("OTASoftwareUpdateProvider ClusterRevision read Error", error); } SetCommandExitStatus(error); }]; @@ -13660,9 +13306,10 @@ class SubscribeAttributeOtaSoftwareUpdateProviderClusterRevision : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000029) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateProvider * cluster = - [[MTRBaseClusterOtaSoftwareUpdateProvider alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateProvider alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -13677,7 +13324,7 @@ class SubscribeAttributeOtaSoftwareUpdateProviderClusterRevision : public Subscr mSubscriptionEstablished = YES; } reportHandler:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateProvider.ClusterRevision response %@", [value description]); + NSLog(@"OTASoftwareUpdateProvider.ClusterRevision response %@", [value description]); SetCommandExitStatus(error); }]; @@ -13729,9 +13376,10 @@ class OtaSoftwareUpdateRequestorAnnounceOtaProvider : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - __auto_type * params = [[MTROtaSoftwareUpdateRequestorClusterAnnounceOtaProviderParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTROTASoftwareUpdateRequestorClusterAnnounceOtaProviderParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.providerNodeId = [NSNumber numberWithUnsignedLongLong:mRequest.providerNodeId]; @@ -13783,19 +13431,20 @@ class ReadOtaSoftwareUpdateRequestorDefaultOtaProviders : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRReadParams alloc] init]; if (mFabricFiltered.HasValue()) { params.filterByFabric = mFabricFiltered.Value(); } [cluster readAttributeDefaultOtaProvidersWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.DefaultOtaProviders response %@", + NSLog(@"OTASoftwareUpdateRequestor.DefaultOtaProviders response %@", [value description]); if (error != nil) { - LogNSError("OtaSoftwareUpdateRequestor DefaultOtaProviders read Error", error); + LogNSError("OTASoftwareUpdateRequestor DefaultOtaProviders read Error", error); } SetCommandExitStatus(error); }]; @@ -13820,9 +13469,10 @@ class WriteOtaSoftwareUpdateRequestorDefaultOtaProviders : public WriteAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) WriteAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -13830,8 +13480,8 @@ class WriteOtaSoftwareUpdateRequestorDefaultOtaProviders : public WriteAttribute { // Scope for our temporary variables auto * array_0 = [NSMutableArray new]; for (auto & entry_0 : mValue) { - MTROtaSoftwareUpdateRequestorClusterProviderLocation * newElement_0; - newElement_0 = [MTROtaSoftwareUpdateRequestorClusterProviderLocation new]; + MTROTASoftwareUpdateRequestorClusterProviderLocation * newElement_0; + newElement_0 = [MTROTASoftwareUpdateRequestorClusterProviderLocation new]; newElement_0.providerNodeID = [NSNumber numberWithUnsignedLongLong:entry_0.providerNodeID]; newElement_0.endpoint = [NSNumber numberWithUnsignedShort:entry_0.endpoint]; newElement_0.fabricIndex = [NSNumber numberWithUnsignedChar:entry_0.fabricIndex]; @@ -13845,7 +13495,7 @@ class WriteOtaSoftwareUpdateRequestorDefaultOtaProviders : public WriteAttribute params:params completion:^(NSError * _Nullable error) { if (error != nil) { - LogNSError("OtaSoftwareUpdateRequestor DefaultOtaProviders write Error", error); + LogNSError("OTASoftwareUpdateRequestor DefaultOtaProviders write Error", error); } SetCommandExitStatus(error); }]; @@ -13872,9 +13522,10 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorDefaultOtaProviders : public S { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -13889,7 +13540,7 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorDefaultOtaProviders : public S mSubscriptionEstablished = YES; } reportHandler:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.DefaultOtaProviders response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.DefaultOtaProviders response %@", [value description]); SetCommandExitStatus(error); }]; @@ -13914,12 +13565,13 @@ class ReadOtaSoftwareUpdateRequestorUpdatePossible : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeUpdatePossibleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.UpdatePossible response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.UpdatePossible response %@", [value description]); if (error != nil) { - LogNSError("OtaSoftwareUpdateRequestor UpdatePossible read Error", error); + LogNSError("OTASoftwareUpdateRequestor UpdatePossible read Error", error); } SetCommandExitStatus(error); }]; @@ -13940,9 +13592,10 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorUpdatePossible : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -13957,7 +13610,7 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorUpdatePossible : public Subscr mSubscriptionEstablished = YES; } reportHandler:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.UpdatePossible response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.UpdatePossible response %@", [value description]); SetCommandExitStatus(error); }]; @@ -13982,12 +13635,13 @@ class ReadOtaSoftwareUpdateRequestorUpdateState : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeUpdateStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.UpdateState response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.UpdateState response %@", [value description]); if (error != nil) { - LogNSError("OtaSoftwareUpdateRequestor UpdateState read Error", error); + LogNSError("OTASoftwareUpdateRequestor UpdateState read Error", error); } SetCommandExitStatus(error); }]; @@ -14008,9 +13662,10 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorUpdateState : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -14025,7 +13680,7 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorUpdateState : public Subscribe mSubscriptionEstablished = YES; } reportHandler:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.UpdateState response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.UpdateState response %@", [value description]); SetCommandExitStatus(error); }]; @@ -14050,12 +13705,13 @@ class ReadOtaSoftwareUpdateRequestorUpdateStateProgress : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeUpdateStateProgressWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.UpdateStateProgress response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.UpdateStateProgress response %@", [value description]); if (error != nil) { - LogNSError("OtaSoftwareUpdateRequestor UpdateStateProgress read Error", error); + LogNSError("OTASoftwareUpdateRequestor UpdateStateProgress read Error", error); } SetCommandExitStatus(error); }]; @@ -14076,9 +13732,10 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorUpdateStateProgress : public S { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -14093,7 +13750,7 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorUpdateStateProgress : public S mSubscriptionEstablished = YES; } reportHandler:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.UpdateStateProgress response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.UpdateStateProgress response %@", [value description]); SetCommandExitStatus(error); }]; @@ -14118,12 +13775,13 @@ class ReadOtaSoftwareUpdateRequestorGeneratedCommandList : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.GeneratedCommandList response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.GeneratedCommandList response %@", [value description]); if (error != nil) { - LogNSError("OtaSoftwareUpdateRequestor GeneratedCommandList read Error", error); + LogNSError("OTASoftwareUpdateRequestor GeneratedCommandList read Error", error); } SetCommandExitStatus(error); }]; @@ -14144,9 +13802,10 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorGeneratedCommandList : public { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -14161,7 +13820,7 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorGeneratedCommandList : public mSubscriptionEstablished = YES; } reportHandler:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.GeneratedCommandList response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.GeneratedCommandList response %@", [value description]); SetCommandExitStatus(error); }]; @@ -14186,12 +13845,13 @@ class ReadOtaSoftwareUpdateRequestorAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.AcceptedCommandList response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.AcceptedCommandList response %@", [value description]); if (error != nil) { - LogNSError("OtaSoftwareUpdateRequestor AcceptedCommandList read Error", error); + LogNSError("OTASoftwareUpdateRequestor AcceptedCommandList read Error", error); } SetCommandExitStatus(error); }]; @@ -14212,9 +13872,10 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorAcceptedCommandList : public S { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -14229,7 +13890,7 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorAcceptedCommandList : public S mSubscriptionEstablished = YES; } reportHandler:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.AcceptedCommandList response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.AcceptedCommandList response %@", [value description]); SetCommandExitStatus(error); }]; @@ -14254,12 +13915,13 @@ class ReadOtaSoftwareUpdateRequestorAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.AttributeList response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.AttributeList response %@", [value description]); if (error != nil) { - LogNSError("OtaSoftwareUpdateRequestor AttributeList read Error", error); + LogNSError("OTASoftwareUpdateRequestor AttributeList read Error", error); } SetCommandExitStatus(error); }]; @@ -14280,9 +13942,10 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorAttributeList : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -14297,7 +13960,7 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorAttributeList : public Subscri mSubscriptionEstablished = YES; } reportHandler:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.AttributeList response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.AttributeList response %@", [value description]); SetCommandExitStatus(error); }]; @@ -14322,12 +13985,13 @@ class ReadOtaSoftwareUpdateRequestorFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.FeatureMap response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.FeatureMap response %@", [value description]); if (error != nil) { - LogNSError("OtaSoftwareUpdateRequestor FeatureMap read Error", error); + LogNSError("OTASoftwareUpdateRequestor FeatureMap read Error", error); } SetCommandExitStatus(error); }]; @@ -14348,9 +14012,10 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorFeatureMap : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -14365,7 +14030,7 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorFeatureMap : public SubscribeA mSubscriptionEstablished = YES; } reportHandler:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.FeatureMap response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.FeatureMap response %@", [value description]); SetCommandExitStatus(error); }]; @@ -14390,12 +14055,13 @@ class ReadOtaSoftwareUpdateRequestorClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.ClusterRevision response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.ClusterRevision response %@", [value description]); if (error != nil) { - LogNSError("OtaSoftwareUpdateRequestor ClusterRevision read Error", error); + LogNSError("OTASoftwareUpdateRequestor ClusterRevision read Error", error); } SetCommandExitStatus(error); }]; @@ -14416,9 +14082,10 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorClusterRevision : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x0000002A) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -14433,7 +14100,7 @@ class SubscribeAttributeOtaSoftwareUpdateRequestorClusterRevision : public Subsc mSubscriptionEstablished = YES; } reportHandler:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OtaSoftwareUpdateRequestor.ClusterRevision response %@", [value description]); + NSLog(@"OTASoftwareUpdateRequestor.ClusterRevision response %@", [value description]); SetCommandExitStatus(error); }]; @@ -14475,8 +14142,9 @@ class ReadLocalizationConfigurationActiveLocale : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002B) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActiveLocaleWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"LocalizationConfiguration.ActiveLocale response %@", [value description]); if (error != nil) { @@ -14504,9 +14172,10 @@ class WriteLocalizationConfigurationActiveLocale : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002B) WriteAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -14542,9 +14211,10 @@ class SubscribeAttributeLocalizationConfigurationActiveLocale : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x0000002B) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -14584,8 +14254,9 @@ class ReadLocalizationConfigurationSupportedLocales : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002B) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSupportedLocalesWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"LocalizationConfiguration.SupportedLocales response %@", [value description]); if (error != nil) { @@ -14610,9 +14281,10 @@ class SubscribeAttributeLocalizationConfigurationSupportedLocales : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x0000002B) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -14652,8 +14324,9 @@ class ReadLocalizationConfigurationGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002B) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"LocalizationConfiguration.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -14678,9 +14351,10 @@ class SubscribeAttributeLocalizationConfigurationGeneratedCommandList : public S { ChipLogProgress(chipTool, "Sending cluster (0x0000002B) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -14720,8 +14394,9 @@ class ReadLocalizationConfigurationAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002B) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"LocalizationConfiguration.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -14746,9 +14421,10 @@ class SubscribeAttributeLocalizationConfigurationAcceptedCommandList : public Su { ChipLogProgress(chipTool, "Sending cluster (0x0000002B) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -14788,8 +14464,9 @@ class ReadLocalizationConfigurationAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002B) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"LocalizationConfiguration.AttributeList response %@", [value description]); if (error != nil) { @@ -14814,9 +14491,10 @@ class SubscribeAttributeLocalizationConfigurationAttributeList : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x0000002B) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -14856,8 +14534,9 @@ class ReadLocalizationConfigurationFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002B) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LocalizationConfiguration.FeatureMap response %@", [value description]); if (error != nil) { @@ -14882,9 +14561,10 @@ class SubscribeAttributeLocalizationConfigurationFeatureMap : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x0000002B) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -14924,8 +14604,9 @@ class ReadLocalizationConfigurationClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002B) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LocalizationConfiguration.ClusterRevision response %@", [value description]); if (error != nil) { @@ -14950,9 +14631,10 @@ class SubscribeAttributeLocalizationConfigurationClusterRevision : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x0000002B) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -15010,8 +14692,9 @@ class ReadTimeFormatLocalizationHourFormat : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeHourFormatWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"TimeFormatLocalization.HourFormat response %@", [value description]); if (error != nil) { @@ -15039,9 +14722,10 @@ class WriteTimeFormatLocalizationHourFormat : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) WriteAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -15075,9 +14759,10 @@ class SubscribeAttributeTimeFormatLocalizationHourFormat : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -15117,8 +14802,9 @@ class ReadTimeFormatLocalizationActiveCalendarType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActiveCalendarTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"TimeFormatLocalization.ActiveCalendarType response %@", [value description]); if (error != nil) { @@ -15146,9 +14832,10 @@ class WriteTimeFormatLocalizationActiveCalendarType : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) WriteAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -15182,9 +14869,10 @@ class SubscribeAttributeTimeFormatLocalizationActiveCalendarType : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -15224,8 +14912,9 @@ class ReadTimeFormatLocalizationSupportedCalendarTypes : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSupportedCalendarTypesWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"TimeFormatLocalization.SupportedCalendarTypes response %@", [value description]); if (error != nil) { @@ -15250,9 +14939,10 @@ class SubscribeAttributeTimeFormatLocalizationSupportedCalendarTypes : public Su { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -15292,8 +14982,9 @@ class ReadTimeFormatLocalizationGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"TimeFormatLocalization.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -15318,9 +15009,10 @@ class SubscribeAttributeTimeFormatLocalizationGeneratedCommandList : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -15360,8 +15052,9 @@ class ReadTimeFormatLocalizationAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"TimeFormatLocalization.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -15386,9 +15079,10 @@ class SubscribeAttributeTimeFormatLocalizationAcceptedCommandList : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -15428,8 +15122,9 @@ class ReadTimeFormatLocalizationAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"TimeFormatLocalization.AttributeList response %@", [value description]); if (error != nil) { @@ -15454,9 +15149,10 @@ class SubscribeAttributeTimeFormatLocalizationAttributeList : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -15496,8 +15192,9 @@ class ReadTimeFormatLocalizationFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"TimeFormatLocalization.FeatureMap response %@", [value description]); if (error != nil) { @@ -15522,9 +15219,10 @@ class SubscribeAttributeTimeFormatLocalizationFeatureMap : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -15564,8 +15262,9 @@ class ReadTimeFormatLocalizationClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"TimeFormatLocalization.ClusterRevision response %@", [value description]); if (error != nil) { @@ -15590,9 +15289,10 @@ class SubscribeAttributeTimeFormatLocalizationClusterRevision : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x0000002C) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -15648,9 +15348,9 @@ class ReadUnitLocalizationTemperatureUnit : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002D) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTemperatureUnitWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitLocalization.TemperatureUnit response %@", [value description]); if (error != nil) { @@ -15678,10 +15378,10 @@ class WriteUnitLocalizationTemperatureUnit : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002D) WriteAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -15715,10 +15415,10 @@ class SubscribeAttributeUnitLocalizationTemperatureUnit : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x0000002D) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -15758,9 +15458,9 @@ class ReadUnitLocalizationGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002D) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitLocalization.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -15785,10 +15485,10 @@ class SubscribeAttributeUnitLocalizationGeneratedCommandList : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x0000002D) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -15828,9 +15528,9 @@ class ReadUnitLocalizationAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002D) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitLocalization.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -15855,10 +15555,10 @@ class SubscribeAttributeUnitLocalizationAcceptedCommandList : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x0000002D) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -15898,9 +15598,9 @@ class ReadUnitLocalizationAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002D) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitLocalization.AttributeList response %@", [value description]); if (error != nil) { @@ -15925,10 +15625,10 @@ class SubscribeAttributeUnitLocalizationAttributeList : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x0000002D) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -15968,9 +15668,9 @@ class ReadUnitLocalizationFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002D) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitLocalization.FeatureMap response %@", [value description]); if (error != nil) { @@ -15995,10 +15695,10 @@ class SubscribeAttributeUnitLocalizationFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002D) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -16038,9 +15738,9 @@ class ReadUnitLocalizationClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002D) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitLocalization.ClusterRevision response %@", [value description]); if (error != nil) { @@ -16065,10 +15765,10 @@ class SubscribeAttributeUnitLocalizationClusterRevision : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x0000002D) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -16124,8 +15824,9 @@ class ReadPowerSourceConfigurationSources : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002E) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSourcesWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSourceConfiguration.Sources response %@", [value description]); if (error != nil) { @@ -16150,9 +15851,10 @@ class SubscribeAttributePowerSourceConfigurationSources : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x0000002E) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -16192,8 +15894,9 @@ class ReadPowerSourceConfigurationGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002E) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSourceConfiguration.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -16218,9 +15921,10 @@ class SubscribeAttributePowerSourceConfigurationGeneratedCommandList : public Su { ChipLogProgress(chipTool, "Sending cluster (0x0000002E) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -16260,8 +15964,9 @@ class ReadPowerSourceConfigurationAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002E) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSourceConfiguration.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -16286,9 +15991,10 @@ class SubscribeAttributePowerSourceConfigurationAcceptedCommandList : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x0000002E) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -16328,8 +16034,9 @@ class ReadPowerSourceConfigurationAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002E) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSourceConfiguration.AttributeList response %@", [value description]); if (error != nil) { @@ -16354,9 +16061,10 @@ class SubscribeAttributePowerSourceConfigurationAttributeList : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x0000002E) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -16396,8 +16104,9 @@ class ReadPowerSourceConfigurationFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002E) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSourceConfiguration.FeatureMap response %@", [value description]); if (error != nil) { @@ -16422,9 +16131,10 @@ class SubscribeAttributePowerSourceConfigurationFeatureMap : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x0000002E) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -16464,8 +16174,9 @@ class ReadPowerSourceConfigurationClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002E) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSourceConfiguration.ClusterRevision response %@", [value description]); if (error != nil) { @@ -16490,9 +16201,10 @@ class SubscribeAttributePowerSourceConfigurationClusterRevision : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x0000002E) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -16578,9 +16290,9 @@ class ReadPowerSourceStatus : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.Status response %@", [value description]); if (error != nil) { @@ -16605,10 +16317,10 @@ class SubscribeAttributePowerSourceStatus : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -16648,9 +16360,9 @@ class ReadPowerSourceOrder : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOrderWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.Order response %@", [value description]); if (error != nil) { @@ -16675,10 +16387,10 @@ class SubscribeAttributePowerSourceOrder : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -16718,9 +16430,9 @@ class ReadPowerSourceDescription : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDescriptionWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.Description response %@", [value description]); if (error != nil) { @@ -16745,10 +16457,10 @@ class SubscribeAttributePowerSourceDescription : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -16788,9 +16500,9 @@ class ReadPowerSourceWiredAssessedInputVoltage : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeWiredAssessedInputVoltageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.WiredAssessedInputVoltage response %@", [value description]); if (error != nil) { @@ -16815,10 +16527,10 @@ class SubscribeAttributePowerSourceWiredAssessedInputVoltage : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -16858,9 +16570,9 @@ class ReadPowerSourceWiredAssessedInputFrequency : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeWiredAssessedInputFrequencyWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.WiredAssessedInputFrequency response %@", [value description]); if (error != nil) { @@ -16885,10 +16597,10 @@ class SubscribeAttributePowerSourceWiredAssessedInputFrequency : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -16928,9 +16640,9 @@ class ReadPowerSourceWiredCurrentType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeWiredCurrentTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.WiredCurrentType response %@", [value description]); if (error != nil) { @@ -16955,10 +16667,10 @@ class SubscribeAttributePowerSourceWiredCurrentType : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -16998,9 +16710,9 @@ class ReadPowerSourceWiredAssessedCurrent : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeWiredAssessedCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.WiredAssessedCurrent response %@", [value description]); if (error != nil) { @@ -17025,10 +16737,10 @@ class SubscribeAttributePowerSourceWiredAssessedCurrent : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -17068,9 +16780,9 @@ class ReadPowerSourceWiredNominalVoltage : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeWiredNominalVoltageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.WiredNominalVoltage response %@", [value description]); if (error != nil) { @@ -17095,10 +16807,10 @@ class SubscribeAttributePowerSourceWiredNominalVoltage : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -17138,9 +16850,9 @@ class ReadPowerSourceWiredMaximumCurrent : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeWiredMaximumCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.WiredMaximumCurrent response %@", [value description]); if (error != nil) { @@ -17165,10 +16877,10 @@ class SubscribeAttributePowerSourceWiredMaximumCurrent : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -17208,9 +16920,9 @@ class ReadPowerSourceWiredPresent : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeWiredPresentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.WiredPresent response %@", [value description]); if (error != nil) { @@ -17235,10 +16947,10 @@ class SubscribeAttributePowerSourceWiredPresent : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -17278,9 +16990,9 @@ class ReadPowerSourceActiveWiredFaults : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActiveWiredFaultsWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.ActiveWiredFaults response %@", [value description]); if (error != nil) { @@ -17305,10 +17017,10 @@ class SubscribeAttributePowerSourceActiveWiredFaults : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -17348,9 +17060,9 @@ class ReadPowerSourceBatVoltage : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatVoltageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatVoltage response %@", [value description]); if (error != nil) { @@ -17375,10 +17087,10 @@ class SubscribeAttributePowerSourceBatVoltage : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -17418,9 +17130,9 @@ class ReadPowerSourceBatPercentRemaining : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatPercentRemainingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatPercentRemaining response %@", [value description]); if (error != nil) { @@ -17445,10 +17157,10 @@ class SubscribeAttributePowerSourceBatPercentRemaining : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -17488,9 +17200,9 @@ class ReadPowerSourceBatTimeRemaining : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000000D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatTimeRemainingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatTimeRemaining response %@", [value description]); if (error != nil) { @@ -17515,10 +17227,10 @@ class SubscribeAttributePowerSourceBatTimeRemaining : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000000D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -17558,9 +17270,9 @@ class ReadPowerSourceBatChargeLevel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000000E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatChargeLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatChargeLevel response %@", [value description]); if (error != nil) { @@ -17585,10 +17297,10 @@ class SubscribeAttributePowerSourceBatChargeLevel : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000000E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -17628,9 +17340,9 @@ class ReadPowerSourceBatReplacementNeeded : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatReplacementNeededWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatReplacementNeeded response %@", [value description]); if (error != nil) { @@ -17655,10 +17367,10 @@ class SubscribeAttributePowerSourceBatReplacementNeeded : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -17698,9 +17410,9 @@ class ReadPowerSourceBatReplaceability : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatReplaceabilityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatReplaceability response %@", [value description]); if (error != nil) { @@ -17725,10 +17437,10 @@ class SubscribeAttributePowerSourceBatReplaceability : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -17768,9 +17480,9 @@ class ReadPowerSourceBatPresent : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatPresentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatPresent response %@", [value description]); if (error != nil) { @@ -17795,10 +17507,10 @@ class SubscribeAttributePowerSourceBatPresent : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -17838,9 +17550,9 @@ class ReadPowerSourceActiveBatFaults : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActiveBatFaultsWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.ActiveBatFaults response %@", [value description]); if (error != nil) { @@ -17865,10 +17577,10 @@ class SubscribeAttributePowerSourceActiveBatFaults : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -17908,9 +17620,9 @@ class ReadPowerSourceBatReplacementDescription : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatReplacementDescriptionWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatReplacementDescription response %@", [value description]); if (error != nil) { @@ -17935,10 +17647,10 @@ class SubscribeAttributePowerSourceBatReplacementDescription : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -17978,9 +17690,9 @@ class ReadPowerSourceBatCommonDesignation : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatCommonDesignationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatCommonDesignation response %@", [value description]); if (error != nil) { @@ -18005,10 +17717,10 @@ class SubscribeAttributePowerSourceBatCommonDesignation : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -18048,9 +17760,9 @@ class ReadPowerSourceBatANSIDesignation : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatANSIDesignationWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatANSIDesignation response %@", [value description]); if (error != nil) { @@ -18075,10 +17787,10 @@ class SubscribeAttributePowerSourceBatANSIDesignation : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -18118,9 +17830,9 @@ class ReadPowerSourceBatIECDesignation : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatIECDesignationWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatIECDesignation response %@", [value description]); if (error != nil) { @@ -18145,10 +17857,10 @@ class SubscribeAttributePowerSourceBatIECDesignation : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -18188,9 +17900,9 @@ class ReadPowerSourceBatApprovedChemistry : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatApprovedChemistryWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatApprovedChemistry response %@", [value description]); if (error != nil) { @@ -18215,10 +17927,10 @@ class SubscribeAttributePowerSourceBatApprovedChemistry : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -18258,9 +17970,9 @@ class ReadPowerSourceBatCapacity : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000018) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatCapacityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatCapacity response %@", [value description]); if (error != nil) { @@ -18285,10 +17997,10 @@ class SubscribeAttributePowerSourceBatCapacity : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000018) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -18328,9 +18040,9 @@ class ReadPowerSourceBatQuantity : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x00000019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatQuantityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatQuantity response %@", [value description]); if (error != nil) { @@ -18355,10 +18067,10 @@ class SubscribeAttributePowerSourceBatQuantity : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x00000019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -18398,9 +18110,9 @@ class ReadPowerSourceBatChargeState : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatChargeStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatChargeState response %@", [value description]); if (error != nil) { @@ -18425,10 +18137,10 @@ class SubscribeAttributePowerSourceBatChargeState : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -18468,9 +18180,9 @@ class ReadPowerSourceBatTimeToFullCharge : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000001B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatTimeToFullChargeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatTimeToFullCharge response %@", [value description]); if (error != nil) { @@ -18495,10 +18207,10 @@ class SubscribeAttributePowerSourceBatTimeToFullCharge : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000001B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -18538,9 +18250,9 @@ class ReadPowerSourceBatFunctionalWhileCharging : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000001C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatFunctionalWhileChargingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatFunctionalWhileCharging response %@", [value description]); if (error != nil) { @@ -18565,10 +18277,10 @@ class SubscribeAttributePowerSourceBatFunctionalWhileCharging : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000001C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -18608,9 +18320,9 @@ class ReadPowerSourceBatChargingCurrent : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000001D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBatChargingCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.BatChargingCurrent response %@", [value description]); if (error != nil) { @@ -18635,10 +18347,10 @@ class SubscribeAttributePowerSourceBatChargingCurrent : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000001D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -18678,9 +18390,9 @@ class ReadPowerSourceActiveBatChargeFaults : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000001E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActiveBatChargeFaultsWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.ActiveBatChargeFaults response %@", [value description]); if (error != nil) { @@ -18705,10 +18417,10 @@ class SubscribeAttributePowerSourceActiveBatChargeFaults : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000001E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -18748,9 +18460,9 @@ class ReadPowerSourceGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -18775,10 +18487,10 @@ class SubscribeAttributePowerSourceGeneratedCommandList : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -18818,9 +18530,9 @@ class ReadPowerSourceAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -18845,10 +18557,10 @@ class SubscribeAttributePowerSourceAcceptedCommandList : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -18888,9 +18600,9 @@ class ReadPowerSourceAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.AttributeList response %@", [value description]); if (error != nil) { @@ -18915,10 +18627,10 @@ class SubscribeAttributePowerSourceAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -18958,9 +18670,9 @@ class ReadPowerSourceFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.FeatureMap response %@", [value description]); if (error != nil) { @@ -18985,10 +18697,10 @@ class SubscribeAttributePowerSourceFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -19028,9 +18740,9 @@ class ReadPowerSourceClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PowerSource.ClusterRevision response %@", [value description]); if (error != nil) { @@ -19055,10 +18767,10 @@ class SubscribeAttributePowerSourceClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000002F) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -19122,9 +18834,9 @@ class GeneralCommissioningArmFailSafe : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000030) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRGeneralCommissioningClusterArmFailSafeParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -19173,9 +18885,9 @@ class GeneralCommissioningSetRegulatoryConfig : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000030) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRGeneralCommissioningClusterSetRegulatoryConfigParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -19225,9 +18937,9 @@ class GeneralCommissioningCommissioningComplete : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000030) command (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRGeneralCommissioningClusterCommissioningCompleteParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -19272,9 +18984,9 @@ class ReadGeneralCommissioningBreadcrumb : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBreadcrumbWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralCommissioning.Breadcrumb response %@", [value description]); if (error != nil) { @@ -19302,10 +19014,10 @@ class WriteGeneralCommissioningBreadcrumb : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000030) WriteAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -19339,10 +19051,10 @@ class SubscribeAttributeGeneralCommissioningBreadcrumb : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -19382,9 +19094,9 @@ class ReadGeneralCommissioningBasicCommissioningInfo : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBasicCommissioningInfoWithCompletion:^( MTRGeneralCommissioningClusterBasicCommissioningInfo * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralCommissioning.BasicCommissioningInfo response %@", [value description]); @@ -19410,10 +19122,10 @@ class SubscribeAttributeGeneralCommissioningBasicCommissioningInfo : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -19453,9 +19165,9 @@ class ReadGeneralCommissioningRegulatoryConfig : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRegulatoryConfigWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralCommissioning.RegulatoryConfig response %@", [value description]); if (error != nil) { @@ -19480,10 +19192,10 @@ class SubscribeAttributeGeneralCommissioningRegulatoryConfig : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -19523,9 +19235,9 @@ class ReadGeneralCommissioningLocationCapability : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLocationCapabilityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralCommissioning.LocationCapability response %@", [value description]); if (error != nil) { @@ -19550,10 +19262,10 @@ class SubscribeAttributeGeneralCommissioningLocationCapability : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -19593,9 +19305,9 @@ class ReadGeneralCommissioningSupportsConcurrentConnection : public ReadAttribut ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSupportsConcurrentConnectionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralCommissioning.SupportsConcurrentConnection response %@", [value description]); if (error != nil) { @@ -19620,10 +19332,10 @@ class SubscribeAttributeGeneralCommissioningSupportsConcurrentConnection : publi { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -19663,9 +19375,9 @@ class ReadGeneralCommissioningGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralCommissioning.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -19690,10 +19402,10 @@ class SubscribeAttributeGeneralCommissioningGeneratedCommandList : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -19733,9 +19445,9 @@ class ReadGeneralCommissioningAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralCommissioning.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -19760,10 +19472,10 @@ class SubscribeAttributeGeneralCommissioningAcceptedCommandList : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -19803,9 +19515,9 @@ class ReadGeneralCommissioningAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralCommissioning.AttributeList response %@", [value description]); if (error != nil) { @@ -19830,10 +19542,10 @@ class SubscribeAttributeGeneralCommissioningAttributeList : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -19873,9 +19585,9 @@ class ReadGeneralCommissioningFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralCommissioning.FeatureMap response %@", [value description]); if (error != nil) { @@ -19900,10 +19612,10 @@ class SubscribeAttributeGeneralCommissioningFeatureMap : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -19943,9 +19655,9 @@ class ReadGeneralCommissioningClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralCommissioning.ClusterRevision response %@", [value description]); if (error != nil) { @@ -19970,10 +19682,10 @@ class SubscribeAttributeGeneralCommissioningClusterRevision : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000030) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -20043,9 +19755,9 @@ class NetworkCommissioningScanNetworks : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000031) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRNetworkCommissioningClusterScanNetworksParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -20107,9 +19819,9 @@ class NetworkCommissioningAddOrUpdateWiFiNetwork : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000031) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRNetworkCommissioningClusterAddOrUpdateWiFiNetworkParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -20163,9 +19875,9 @@ class NetworkCommissioningAddOrUpdateThreadNetwork : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000031) command (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRNetworkCommissioningClusterAddOrUpdateThreadNetworkParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -20219,9 +19931,9 @@ class NetworkCommissioningRemoveNetwork : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000031) command (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRNetworkCommissioningClusterRemoveNetworkParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -20273,9 +19985,9 @@ class NetworkCommissioningConnectNetwork : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000031) command (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRNetworkCommissioningClusterConnectNetworkParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -20328,9 +20040,9 @@ class NetworkCommissioningReorderNetwork : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000031) command (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRNetworkCommissioningClusterReorderNetworkParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -20382,9 +20094,9 @@ class ReadNetworkCommissioningMaxNetworks : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxNetworksWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"NetworkCommissioning.MaxNetworks response %@", [value description]); if (error != nil) { @@ -20409,10 +20121,10 @@ class SubscribeAttributeNetworkCommissioningMaxNetworks : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -20452,9 +20164,9 @@ class ReadNetworkCommissioningNetworks : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNetworksWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"NetworkCommissioning.Networks response %@", [value description]); if (error != nil) { @@ -20479,10 +20191,10 @@ class SubscribeAttributeNetworkCommissioningNetworks : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -20522,9 +20234,9 @@ class ReadNetworkCommissioningScanMaxTimeSeconds : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeScanMaxTimeSecondsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"NetworkCommissioning.ScanMaxTimeSeconds response %@", [value description]); if (error != nil) { @@ -20549,10 +20261,10 @@ class SubscribeAttributeNetworkCommissioningScanMaxTimeSeconds : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -20592,9 +20304,9 @@ class ReadNetworkCommissioningConnectMaxTimeSeconds : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeConnectMaxTimeSecondsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"NetworkCommissioning.ConnectMaxTimeSeconds response %@", [value description]); if (error != nil) { @@ -20619,10 +20331,10 @@ class SubscribeAttributeNetworkCommissioningConnectMaxTimeSeconds : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -20662,9 +20374,9 @@ class ReadNetworkCommissioningInterfaceEnabled : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInterfaceEnabledWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"NetworkCommissioning.InterfaceEnabled response %@", [value description]); if (error != nil) { @@ -20692,10 +20404,10 @@ class WriteNetworkCommissioningInterfaceEnabled : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000031) WriteAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -20729,10 +20441,10 @@ class SubscribeAttributeNetworkCommissioningInterfaceEnabled : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -20772,9 +20484,9 @@ class ReadNetworkCommissioningLastNetworkingStatus : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLastNetworkingStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"NetworkCommissioning.LastNetworkingStatus response %@", [value description]); if (error != nil) { @@ -20799,10 +20511,10 @@ class SubscribeAttributeNetworkCommissioningLastNetworkingStatus : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -20842,9 +20554,9 @@ class ReadNetworkCommissioningLastNetworkID : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLastNetworkIDWithCompletion:^(NSData * _Nullable value, NSError * _Nullable error) { NSLog(@"NetworkCommissioning.LastNetworkID response %@", [value description]); if (error != nil) { @@ -20869,10 +20581,10 @@ class SubscribeAttributeNetworkCommissioningLastNetworkID : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -20912,9 +20624,9 @@ class ReadNetworkCommissioningLastConnectErrorValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLastConnectErrorValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"NetworkCommissioning.LastConnectErrorValue response %@", [value description]); if (error != nil) { @@ -20939,10 +20651,10 @@ class SubscribeAttributeNetworkCommissioningLastConnectErrorValue : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -20982,9 +20694,9 @@ class ReadNetworkCommissioningGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"NetworkCommissioning.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -21009,10 +20721,10 @@ class SubscribeAttributeNetworkCommissioningGeneratedCommandList : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -21052,9 +20764,9 @@ class ReadNetworkCommissioningAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"NetworkCommissioning.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -21079,10 +20791,10 @@ class SubscribeAttributeNetworkCommissioningAcceptedCommandList : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -21122,9 +20834,9 @@ class ReadNetworkCommissioningAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"NetworkCommissioning.AttributeList response %@", [value description]); if (error != nil) { @@ -21149,10 +20861,10 @@ class SubscribeAttributeNetworkCommissioningAttributeList : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -21192,9 +20904,9 @@ class ReadNetworkCommissioningFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"NetworkCommissioning.FeatureMap response %@", [value description]); if (error != nil) { @@ -21219,10 +20931,10 @@ class SubscribeAttributeNetworkCommissioningFeatureMap : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -21262,9 +20974,9 @@ class ReadNetworkCommissioningClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"NetworkCommissioning.ClusterRevision response %@", [value description]); if (error != nil) { @@ -21289,10 +21001,10 @@ class SubscribeAttributeNetworkCommissioningClusterRevision : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000031) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterNetworkCommissioning * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -21350,9 +21062,9 @@ class DiagnosticLogsRetrieveLogsRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000032) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRDiagnosticLogsClusterRetrieveLogsRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -21401,9 +21113,9 @@ class ReadDiagnosticLogsGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000032) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"DiagnosticLogs.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -21428,10 +21140,10 @@ class SubscribeAttributeDiagnosticLogsGeneratedCommandList : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000032) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -21471,9 +21183,9 @@ class ReadDiagnosticLogsAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000032) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"DiagnosticLogs.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -21498,10 +21210,10 @@ class SubscribeAttributeDiagnosticLogsAcceptedCommandList : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000032) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -21541,9 +21253,9 @@ class ReadDiagnosticLogsAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000032) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"DiagnosticLogs.AttributeList response %@", [value description]); if (error != nil) { @@ -21568,10 +21280,10 @@ class SubscribeAttributeDiagnosticLogsAttributeList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000032) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -21611,9 +21323,9 @@ class ReadDiagnosticLogsFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000032) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DiagnosticLogs.FeatureMap response %@", [value description]); if (error != nil) { @@ -21638,10 +21350,10 @@ class SubscribeAttributeDiagnosticLogsFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000032) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -21681,9 +21393,9 @@ class ReadDiagnosticLogsClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000032) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DiagnosticLogs.ClusterRevision response %@", [value description]); if (error != nil) { @@ -21708,10 +21420,10 @@ class SubscribeAttributeDiagnosticLogsClusterRevision : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000032) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -21781,9 +21493,9 @@ class GeneralDiagnosticsTestEventTrigger : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000033) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRGeneralDiagnosticsClusterTestEventTriggerParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -21828,9 +21540,9 @@ class ReadGeneralDiagnosticsNetworkInterfaces : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNetworkInterfacesWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralDiagnostics.NetworkInterfaces response %@", [value description]); if (error != nil) { @@ -21855,10 +21567,10 @@ class SubscribeAttributeGeneralDiagnosticsNetworkInterfaces : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -21898,9 +21610,9 @@ class ReadGeneralDiagnosticsRebootCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRebootCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralDiagnostics.RebootCount response %@", [value description]); if (error != nil) { @@ -21925,10 +21637,10 @@ class SubscribeAttributeGeneralDiagnosticsRebootCount : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -21968,9 +21680,9 @@ class ReadGeneralDiagnosticsUpTime : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeUpTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralDiagnostics.UpTime response %@", [value description]); if (error != nil) { @@ -21995,10 +21707,10 @@ class SubscribeAttributeGeneralDiagnosticsUpTime : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -22038,9 +21750,9 @@ class ReadGeneralDiagnosticsTotalOperationalHours : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTotalOperationalHoursWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralDiagnostics.TotalOperationalHours response %@", [value description]); if (error != nil) { @@ -22065,10 +21777,10 @@ class SubscribeAttributeGeneralDiagnosticsTotalOperationalHours : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -22108,9 +21820,9 @@ class ReadGeneralDiagnosticsBootReasons : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBootReasonsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralDiagnostics.BootReasons response %@", [value description]); if (error != nil) { @@ -22135,10 +21847,10 @@ class SubscribeAttributeGeneralDiagnosticsBootReasons : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -22178,9 +21890,9 @@ class ReadGeneralDiagnosticsActiveHardwareFaults : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActiveHardwareFaultsWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralDiagnostics.ActiveHardwareFaults response %@", [value description]); if (error != nil) { @@ -22205,10 +21917,10 @@ class SubscribeAttributeGeneralDiagnosticsActiveHardwareFaults : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -22248,9 +21960,9 @@ class ReadGeneralDiagnosticsActiveRadioFaults : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActiveRadioFaultsWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralDiagnostics.ActiveRadioFaults response %@", [value description]); if (error != nil) { @@ -22275,10 +21987,10 @@ class SubscribeAttributeGeneralDiagnosticsActiveRadioFaults : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -22318,9 +22030,9 @@ class ReadGeneralDiagnosticsActiveNetworkFaults : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActiveNetworkFaultsWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralDiagnostics.ActiveNetworkFaults response %@", [value description]); if (error != nil) { @@ -22345,10 +22057,10 @@ class SubscribeAttributeGeneralDiagnosticsActiveNetworkFaults : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -22388,9 +22100,9 @@ class ReadGeneralDiagnosticsTestEventTriggersEnabled : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReadAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTestEventTriggersEnabledWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralDiagnostics.TestEventTriggersEnabled response %@", [value description]); if (error != nil) { @@ -22415,10 +22127,10 @@ class SubscribeAttributeGeneralDiagnosticsTestEventTriggersEnabled : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReportAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -22458,9 +22170,9 @@ class ReadGeneralDiagnosticsGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralDiagnostics.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -22485,10 +22197,10 @@ class SubscribeAttributeGeneralDiagnosticsGeneratedCommandList : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -22528,9 +22240,9 @@ class ReadGeneralDiagnosticsAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralDiagnostics.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -22555,10 +22267,10 @@ class SubscribeAttributeGeneralDiagnosticsAcceptedCommandList : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -22598,9 +22310,9 @@ class ReadGeneralDiagnosticsAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralDiagnostics.AttributeList response %@", [value description]); if (error != nil) { @@ -22625,10 +22337,10 @@ class SubscribeAttributeGeneralDiagnosticsAttributeList : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -22668,9 +22380,9 @@ class ReadGeneralDiagnosticsFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralDiagnostics.FeatureMap response %@", [value description]); if (error != nil) { @@ -22695,10 +22407,10 @@ class SubscribeAttributeGeneralDiagnosticsFeatureMap : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -22738,9 +22450,9 @@ class ReadGeneralDiagnosticsClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GeneralDiagnostics.ClusterRevision response %@", [value description]); if (error != nil) { @@ -22765,10 +22477,10 @@ class SubscribeAttributeGeneralDiagnosticsClusterRevision : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000033) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -22828,9 +22540,9 @@ class SoftwareDiagnosticsResetWatermarks : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000034) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRSoftwareDiagnosticsClusterResetWatermarksParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -22872,9 +22584,9 @@ class ReadSoftwareDiagnosticsThreadMetrics : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeThreadMetricsWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"SoftwareDiagnostics.ThreadMetrics response %@", [value description]); if (error != nil) { @@ -22899,10 +22611,10 @@ class SubscribeAttributeSoftwareDiagnosticsThreadMetrics : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -22942,9 +22654,9 @@ class ReadSoftwareDiagnosticsCurrentHeapFree : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentHeapFreeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"SoftwareDiagnostics.CurrentHeapFree response %@", [value description]); if (error != nil) { @@ -22969,10 +22681,10 @@ class SubscribeAttributeSoftwareDiagnosticsCurrentHeapFree : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -23012,9 +22724,9 @@ class ReadSoftwareDiagnosticsCurrentHeapUsed : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentHeapUsedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"SoftwareDiagnostics.CurrentHeapUsed response %@", [value description]); if (error != nil) { @@ -23039,10 +22751,10 @@ class SubscribeAttributeSoftwareDiagnosticsCurrentHeapUsed : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -23082,9 +22794,9 @@ class ReadSoftwareDiagnosticsCurrentHeapHighWatermark : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentHeapHighWatermarkWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"SoftwareDiagnostics.CurrentHeapHighWatermark response %@", [value description]); if (error != nil) { @@ -23109,10 +22821,10 @@ class SubscribeAttributeSoftwareDiagnosticsCurrentHeapHighWatermark : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -23152,9 +22864,9 @@ class ReadSoftwareDiagnosticsGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"SoftwareDiagnostics.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -23179,10 +22891,10 @@ class SubscribeAttributeSoftwareDiagnosticsGeneratedCommandList : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -23222,9 +22934,9 @@ class ReadSoftwareDiagnosticsAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"SoftwareDiagnostics.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -23249,10 +22961,10 @@ class SubscribeAttributeSoftwareDiagnosticsAcceptedCommandList : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -23292,9 +23004,9 @@ class ReadSoftwareDiagnosticsAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"SoftwareDiagnostics.AttributeList response %@", [value description]); if (error != nil) { @@ -23319,10 +23031,10 @@ class SubscribeAttributeSoftwareDiagnosticsAttributeList : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -23362,9 +23074,9 @@ class ReadSoftwareDiagnosticsFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"SoftwareDiagnostics.FeatureMap response %@", [value description]); if (error != nil) { @@ -23389,10 +23101,10 @@ class SubscribeAttributeSoftwareDiagnosticsFeatureMap : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -23432,9 +23144,9 @@ class ReadSoftwareDiagnosticsClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"SoftwareDiagnostics.ClusterRevision response %@", [value description]); if (error != nil) { @@ -23459,10 +23171,10 @@ class SubscribeAttributeSoftwareDiagnosticsClusterRevision : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000034) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -23582,8 +23294,9 @@ class ThreadNetworkDiagnosticsResetCounts : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000035) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRThreadNetworkDiagnosticsClusterResetCountsParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -23625,8 +23338,9 @@ class ReadThreadNetworkDiagnosticsChannel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeChannelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.Channel response %@", [value description]); if (error != nil) { @@ -23651,9 +23365,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsChannel : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -23693,8 +23408,9 @@ class ReadThreadNetworkDiagnosticsRoutingRole : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRoutingRoleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RoutingRole response %@", [value description]); if (error != nil) { @@ -23719,9 +23435,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRoutingRole : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -23761,8 +23478,9 @@ class ReadThreadNetworkDiagnosticsNetworkName : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNetworkNameWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.NetworkName response %@", [value description]); if (error != nil) { @@ -23787,9 +23505,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsNetworkName : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -23829,8 +23548,9 @@ class ReadThreadNetworkDiagnosticsPanId : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePanIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.PanId response %@", [value description]); if (error != nil) { @@ -23855,9 +23575,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsPanId : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -23897,8 +23618,9 @@ class ReadThreadNetworkDiagnosticsExtendedPanId : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeExtendedPanIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.ExtendedPanId response %@", [value description]); if (error != nil) { @@ -23923,9 +23645,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsExtendedPanId : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -23965,8 +23688,9 @@ class ReadThreadNetworkDiagnosticsMeshLocalPrefix : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeshLocalPrefixWithCompletion:^(NSData * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.MeshLocalPrefix response %@", [value description]); if (error != nil) { @@ -23991,9 +23715,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsMeshLocalPrefix : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -24033,8 +23758,9 @@ class ReadThreadNetworkDiagnosticsOverrunCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOverrunCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.OverrunCount response %@", [value description]); if (error != nil) { @@ -24059,9 +23785,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsOverrunCount : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -24101,8 +23828,9 @@ class ReadThreadNetworkDiagnosticsNeighborTableList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNeighborTableListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.NeighborTableList response %@", [value description]); if (error != nil) { @@ -24127,9 +23855,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsNeighborTableList : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -24169,8 +23898,9 @@ class ReadThreadNetworkDiagnosticsRouteTableList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRouteTableListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RouteTableList response %@", [value description]); if (error != nil) { @@ -24195,9 +23925,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRouteTableList : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -24237,8 +23968,9 @@ class ReadThreadNetworkDiagnosticsPartitionId : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePartitionIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.PartitionId response %@", [value description]); if (error != nil) { @@ -24263,9 +23995,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsPartitionId : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -24305,8 +24038,9 @@ class ReadThreadNetworkDiagnosticsWeighting : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeWeightingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.Weighting response %@", [value description]); if (error != nil) { @@ -24331,9 +24065,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsWeighting : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -24373,8 +24108,9 @@ class ReadThreadNetworkDiagnosticsDataVersion : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDataVersionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.DataVersion response %@", [value description]); if (error != nil) { @@ -24399,9 +24135,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsDataVersion : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -24441,8 +24178,9 @@ class ReadThreadNetworkDiagnosticsStableDataVersion : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeStableDataVersionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.StableDataVersion response %@", [value description]); if (error != nil) { @@ -24467,9 +24205,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsStableDataVersion : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -24509,8 +24248,9 @@ class ReadThreadNetworkDiagnosticsLeaderRouterId : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000000D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLeaderRouterIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.LeaderRouterId response %@", [value description]); if (error != nil) { @@ -24535,9 +24275,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsLeaderRouterId : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000000D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -24577,8 +24318,9 @@ class ReadThreadNetworkDiagnosticsDetachedRoleCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000000E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDetachedRoleCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.DetachedRoleCount response %@", [value description]); if (error != nil) { @@ -24603,9 +24345,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsDetachedRoleCount : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000000E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -24645,8 +24388,9 @@ class ReadThreadNetworkDiagnosticsChildRoleCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeChildRoleCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.ChildRoleCount response %@", [value description]); if (error != nil) { @@ -24671,9 +24415,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsChildRoleCount : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -24713,8 +24458,9 @@ class ReadThreadNetworkDiagnosticsRouterRoleCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRouterRoleCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RouterRoleCount response %@", [value description]); if (error != nil) { @@ -24739,9 +24485,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRouterRoleCount : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -24781,8 +24528,9 @@ class ReadThreadNetworkDiagnosticsLeaderRoleCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLeaderRoleCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.LeaderRoleCount response %@", [value description]); if (error != nil) { @@ -24807,9 +24555,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsLeaderRoleCount : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -24849,8 +24598,9 @@ class ReadThreadNetworkDiagnosticsAttachAttemptCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttachAttemptCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.AttachAttemptCount response %@", [value description]); if (error != nil) { @@ -24875,9 +24625,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsAttachAttemptCount : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -24917,8 +24668,9 @@ class ReadThreadNetworkDiagnosticsPartitionIdChangeCount : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePartitionIdChangeCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.PartitionIdChangeCount response %@", [value description]); if (error != nil) { @@ -24943,9 +24695,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsPartitionIdChangeCount : public { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -24985,8 +24738,9 @@ class ReadThreadNetworkDiagnosticsBetterPartitionAttachAttemptCount : public Rea ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBetterPartitionAttachAttemptCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.BetterPartitionAttachAttemptCount response %@", [value description]); @@ -25012,9 +24766,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsBetterPartitionAttachAttemptCoun { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -25054,8 +24809,9 @@ class ReadThreadNetworkDiagnosticsParentChangeCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeParentChangeCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.ParentChangeCount response %@", [value description]); if (error != nil) { @@ -25080,9 +24836,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsParentChangeCount : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -25122,8 +24879,9 @@ class ReadThreadNetworkDiagnosticsTxTotalCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxTotalCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxTotalCount response %@", [value description]); if (error != nil) { @@ -25148,9 +24906,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxTotalCount : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -25190,8 +24949,9 @@ class ReadThreadNetworkDiagnosticsTxUnicastCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxUnicastCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxUnicastCount response %@", [value description]); if (error != nil) { @@ -25216,9 +24976,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxUnicastCount : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -25258,8 +25019,9 @@ class ReadThreadNetworkDiagnosticsTxBroadcastCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000018) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxBroadcastCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxBroadcastCount response %@", [value description]); if (error != nil) { @@ -25284,9 +25046,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxBroadcastCount : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000018) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -25326,8 +25089,9 @@ class ReadThreadNetworkDiagnosticsTxAckRequestedCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxAckRequestedCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxAckRequestedCount response %@", [value description]); if (error != nil) { @@ -25352,9 +25116,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxAckRequestedCount : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -25394,8 +25159,9 @@ class ReadThreadNetworkDiagnosticsTxAckedCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxAckedCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxAckedCount response %@", [value description]); if (error != nil) { @@ -25420,9 +25186,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxAckedCount : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -25462,8 +25229,9 @@ class ReadThreadNetworkDiagnosticsTxNoAckRequestedCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000001B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxNoAckRequestedCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxNoAckRequestedCount response %@", [value description]); if (error != nil) { @@ -25488,9 +25256,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxNoAckRequestedCount : public S { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000001B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -25530,8 +25299,9 @@ class ReadThreadNetworkDiagnosticsTxDataCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000001C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxDataCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxDataCount response %@", [value description]); if (error != nil) { @@ -25556,9 +25326,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxDataCount : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000001C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -25598,8 +25369,9 @@ class ReadThreadNetworkDiagnosticsTxDataPollCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000001D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxDataPollCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxDataPollCount response %@", [value description]); if (error != nil) { @@ -25624,9 +25396,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxDataPollCount : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000001D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -25666,8 +25439,9 @@ class ReadThreadNetworkDiagnosticsTxBeaconCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000001E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxBeaconCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxBeaconCount response %@", [value description]); if (error != nil) { @@ -25692,9 +25466,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxBeaconCount : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000001E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -25734,8 +25509,9 @@ class ReadThreadNetworkDiagnosticsTxBeaconRequestCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000001F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxBeaconRequestCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxBeaconRequestCount response %@", [value description]); if (error != nil) { @@ -25760,9 +25536,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxBeaconRequestCount : public Su { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000001F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -25802,8 +25579,9 @@ class ReadThreadNetworkDiagnosticsTxOtherCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxOtherCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxOtherCount response %@", [value description]); if (error != nil) { @@ -25828,9 +25606,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxOtherCount : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -25870,8 +25649,9 @@ class ReadThreadNetworkDiagnosticsTxRetryCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxRetryCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxRetryCount response %@", [value description]); if (error != nil) { @@ -25896,9 +25676,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxRetryCount : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -25938,8 +25719,9 @@ class ReadThreadNetworkDiagnosticsTxDirectMaxRetryExpiryCount : public ReadAttri ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxDirectMaxRetryExpiryCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxDirectMaxRetryExpiryCount response %@", [value description]); if (error != nil) { @@ -25964,9 +25746,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxDirectMaxRetryExpiryCount : pu { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -26006,8 +25789,9 @@ class ReadThreadNetworkDiagnosticsTxIndirectMaxRetryExpiryCount : public ReadAtt ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000023) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxIndirectMaxRetryExpiryCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxIndirectMaxRetryExpiryCount response %@", [value description]); if (error != nil) { @@ -26032,9 +25816,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxIndirectMaxRetryExpiryCount : { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000023) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -26074,8 +25859,9 @@ class ReadThreadNetworkDiagnosticsTxErrCcaCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxErrCcaCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxErrCcaCount response %@", [value description]); if (error != nil) { @@ -26100,9 +25886,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxErrCcaCount : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -26142,8 +25929,9 @@ class ReadThreadNetworkDiagnosticsTxErrAbortCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxErrAbortCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxErrAbortCount response %@", [value description]); if (error != nil) { @@ -26168,9 +25956,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxErrAbortCount : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -26210,8 +25999,9 @@ class ReadThreadNetworkDiagnosticsTxErrBusyChannelCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000026) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxErrBusyChannelCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.TxErrBusyChannelCount response %@", [value description]); if (error != nil) { @@ -26236,9 +26026,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsTxErrBusyChannelCount : public S { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000026) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -26278,8 +26069,9 @@ class ReadThreadNetworkDiagnosticsRxTotalCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000027) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxTotalCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxTotalCount response %@", [value description]); if (error != nil) { @@ -26304,9 +26096,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxTotalCount : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000027) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -26346,8 +26139,9 @@ class ReadThreadNetworkDiagnosticsRxUnicastCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000028) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxUnicastCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxUnicastCount response %@", [value description]); if (error != nil) { @@ -26372,9 +26166,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxUnicastCount : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000028) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -26414,8 +26209,9 @@ class ReadThreadNetworkDiagnosticsRxBroadcastCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000029) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxBroadcastCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxBroadcastCount response %@", [value description]); if (error != nil) { @@ -26440,9 +26236,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxBroadcastCount : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000029) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -26482,8 +26279,9 @@ class ReadThreadNetworkDiagnosticsRxDataCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000002A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxDataCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxDataCount response %@", [value description]); if (error != nil) { @@ -26508,9 +26306,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxDataCount : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000002A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -26550,8 +26349,9 @@ class ReadThreadNetworkDiagnosticsRxDataPollCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000002B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxDataPollCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxDataPollCount response %@", [value description]); if (error != nil) { @@ -26576,9 +26376,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxDataPollCount : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000002B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -26618,8 +26419,9 @@ class ReadThreadNetworkDiagnosticsRxBeaconCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000002C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxBeaconCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxBeaconCount response %@", [value description]); if (error != nil) { @@ -26644,9 +26446,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxBeaconCount : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000002C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -26686,8 +26489,9 @@ class ReadThreadNetworkDiagnosticsRxBeaconRequestCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000002D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxBeaconRequestCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxBeaconRequestCount response %@", [value description]); if (error != nil) { @@ -26712,9 +26516,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxBeaconRequestCount : public Su { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000002D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -26754,8 +26559,9 @@ class ReadThreadNetworkDiagnosticsRxOtherCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000002E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxOtherCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxOtherCount response %@", [value description]); if (error != nil) { @@ -26780,9 +26586,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxOtherCount : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000002E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -26822,8 +26629,9 @@ class ReadThreadNetworkDiagnosticsRxAddressFilteredCount : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000002F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxAddressFilteredCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxAddressFilteredCount response %@", [value description]); if (error != nil) { @@ -26848,9 +26656,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxAddressFilteredCount : public { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000002F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -26890,8 +26699,9 @@ class ReadThreadNetworkDiagnosticsRxDestAddrFilteredCount : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxDestAddrFilteredCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxDestAddrFilteredCount response %@", [value description]); if (error != nil) { @@ -26916,9 +26726,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxDestAddrFilteredCount : public { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -26958,8 +26769,9 @@ class ReadThreadNetworkDiagnosticsRxDuplicatedCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxDuplicatedCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxDuplicatedCount response %@", [value description]); if (error != nil) { @@ -26984,9 +26796,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxDuplicatedCount : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -27026,8 +26839,9 @@ class ReadThreadNetworkDiagnosticsRxErrNoFrameCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxErrNoFrameCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxErrNoFrameCount response %@", [value description]); if (error != nil) { @@ -27052,9 +26866,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxErrNoFrameCount : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -27094,8 +26909,9 @@ class ReadThreadNetworkDiagnosticsRxErrUnknownNeighborCount : public ReadAttribu ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000033) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxErrUnknownNeighborCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxErrUnknownNeighborCount response %@", [value description]); if (error != nil) { @@ -27120,9 +26936,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxErrUnknownNeighborCount : publ { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000033) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -27162,8 +26979,9 @@ class ReadThreadNetworkDiagnosticsRxErrInvalidSrcAddrCount : public ReadAttribut ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000034) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxErrInvalidSrcAddrCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxErrInvalidSrcAddrCount response %@", [value description]); if (error != nil) { @@ -27188,9 +27006,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxErrInvalidSrcAddrCount : publi { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000034) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -27230,8 +27049,9 @@ class ReadThreadNetworkDiagnosticsRxErrSecCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000035) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxErrSecCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxErrSecCount response %@", [value description]); if (error != nil) { @@ -27256,9 +27076,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxErrSecCount : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000035) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -27298,8 +27119,9 @@ class ReadThreadNetworkDiagnosticsRxErrFcsCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000036) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxErrFcsCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxErrFcsCount response %@", [value description]); if (error != nil) { @@ -27324,9 +27146,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxErrFcsCount : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000036) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -27366,8 +27189,9 @@ class ReadThreadNetworkDiagnosticsRxErrOtherCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000037) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRxErrOtherCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.RxErrOtherCount response %@", [value description]); if (error != nil) { @@ -27392,9 +27216,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsRxErrOtherCount : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000037) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -27434,8 +27259,9 @@ class ReadThreadNetworkDiagnosticsActiveTimestamp : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000038) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActiveTimestampWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.ActiveTimestamp response %@", [value description]); if (error != nil) { @@ -27460,9 +27286,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsActiveTimestamp : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000038) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -27502,8 +27329,9 @@ class ReadThreadNetworkDiagnosticsPendingTimestamp : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x00000039) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePendingTimestampWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.PendingTimestamp response %@", [value description]); if (error != nil) { @@ -27528,9 +27356,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsPendingTimestamp : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x00000039) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -27570,8 +27399,9 @@ class ReadThreadNetworkDiagnosticsDelay : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000003A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDelayWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.Delay response %@", [value description]); if (error != nil) { @@ -27596,9 +27426,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsDelay : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000003A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -27638,8 +27469,9 @@ class ReadThreadNetworkDiagnosticsSecurityPolicy : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000003B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSecurityPolicyWithCompletion:^( MTRThreadNetworkDiagnosticsClusterSecurityPolicy * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.SecurityPolicy response %@", [value description]); @@ -27665,9 +27497,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsSecurityPolicy : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000003B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -27707,8 +27540,9 @@ class ReadThreadNetworkDiagnosticsChannelPage0Mask : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000003C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeChannelPage0MaskWithCompletion:^(NSData * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.ChannelPage0Mask response %@", [value description]); if (error != nil) { @@ -27733,9 +27567,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsChannelPage0Mask : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000003C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -27775,8 +27610,9 @@ class ReadThreadNetworkDiagnosticsOperationalDatasetComponents : public ReadAttr ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000003D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOperationalDatasetComponentsWithCompletion:^( MTRThreadNetworkDiagnosticsClusterOperationalDatasetComponents * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.OperationalDatasetComponents response %@", [value description]); @@ -27802,9 +27638,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsOperationalDatasetComponents : p { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000003D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -27845,8 +27682,9 @@ class ReadThreadNetworkDiagnosticsActiveNetworkFaultsList : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000003E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActiveNetworkFaultsListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.ActiveNetworkFaultsList response %@", [value description]); if (error != nil) { @@ -27871,9 +27709,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsActiveNetworkFaultsList : public { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000003E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -27913,8 +27752,9 @@ class ReadThreadNetworkDiagnosticsGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -27939,9 +27779,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsGeneratedCommandList : public Su { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -27981,8 +27822,9 @@ class ReadThreadNetworkDiagnosticsAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -28007,9 +27849,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsAcceptedCommandList : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -28049,8 +27892,9 @@ class ReadThreadNetworkDiagnosticsAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.AttributeList response %@", [value description]); if (error != nil) { @@ -28075,9 +27919,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsAttributeList : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -28117,8 +27962,9 @@ class ReadThreadNetworkDiagnosticsFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.FeatureMap response %@", [value description]); if (error != nil) { @@ -28143,9 +27989,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsFeatureMap : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -28185,8 +28032,9 @@ class ReadThreadNetworkDiagnosticsClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThreadNetworkDiagnostics.ClusterRevision response %@", [value description]); if (error != nil) { @@ -28211,9 +28059,10 @@ class SubscribeAttributeThreadNetworkDiagnosticsClusterRevision : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000035) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -28284,8 +28133,9 @@ class WiFiNetworkDiagnosticsResetCounts : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000036) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRWiFiNetworkDiagnosticsClusterResetCountsParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -28327,8 +28177,9 @@ class ReadWiFiNetworkDiagnosticsBssid : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBssidWithCompletion:^(NSData * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.Bssid response %@", [value description]); if (error != nil) { @@ -28353,9 +28204,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsBssid : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -28395,8 +28247,9 @@ class ReadWiFiNetworkDiagnosticsSecurityType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSecurityTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.SecurityType response %@", [value description]); if (error != nil) { @@ -28421,9 +28274,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsSecurityType : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -28463,8 +28317,9 @@ class ReadWiFiNetworkDiagnosticsWiFiVersion : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeWiFiVersionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.WiFiVersion response %@", [value description]); if (error != nil) { @@ -28489,9 +28344,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsWiFiVersion : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -28531,8 +28387,9 @@ class ReadWiFiNetworkDiagnosticsChannelNumber : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeChannelNumberWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.ChannelNumber response %@", [value description]); if (error != nil) { @@ -28557,9 +28414,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsChannelNumber : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -28599,8 +28457,9 @@ class ReadWiFiNetworkDiagnosticsRssi : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRssiWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.Rssi response %@", [value description]); if (error != nil) { @@ -28625,9 +28484,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsRssi : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -28667,8 +28527,9 @@ class ReadWiFiNetworkDiagnosticsBeaconLostCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBeaconLostCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.BeaconLostCount response %@", [value description]); if (error != nil) { @@ -28693,9 +28554,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsBeaconLostCount : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -28735,8 +28597,9 @@ class ReadWiFiNetworkDiagnosticsBeaconRxCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBeaconRxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.BeaconRxCount response %@", [value description]); if (error != nil) { @@ -28761,9 +28624,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsBeaconRxCount : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -28803,8 +28667,9 @@ class ReadWiFiNetworkDiagnosticsPacketMulticastRxCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePacketMulticastRxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.PacketMulticastRxCount response %@", [value description]); if (error != nil) { @@ -28829,9 +28694,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsPacketMulticastRxCount : public Su { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -28871,8 +28737,9 @@ class ReadWiFiNetworkDiagnosticsPacketMulticastTxCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePacketMulticastTxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.PacketMulticastTxCount response %@", [value description]); if (error != nil) { @@ -28897,9 +28764,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsPacketMulticastTxCount : public Su { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -28939,8 +28807,9 @@ class ReadWiFiNetworkDiagnosticsPacketUnicastRxCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePacketUnicastRxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.PacketUnicastRxCount response %@", [value description]); if (error != nil) { @@ -28965,9 +28834,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsPacketUnicastRxCount : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -29007,8 +28877,9 @@ class ReadWiFiNetworkDiagnosticsPacketUnicastTxCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePacketUnicastTxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.PacketUnicastTxCount response %@", [value description]); if (error != nil) { @@ -29033,9 +28904,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsPacketUnicastTxCount : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -29075,8 +28947,9 @@ class ReadWiFiNetworkDiagnosticsCurrentMaxRate : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentMaxRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.CurrentMaxRate response %@", [value description]); if (error != nil) { @@ -29101,9 +28974,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsCurrentMaxRate : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -29143,8 +29017,9 @@ class ReadWiFiNetworkDiagnosticsOverrunCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOverrunCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.OverrunCount response %@", [value description]); if (error != nil) { @@ -29169,9 +29044,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsOverrunCount : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -29211,8 +29087,9 @@ class ReadWiFiNetworkDiagnosticsGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -29237,9 +29114,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsGeneratedCommandList : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -29279,8 +29157,9 @@ class ReadWiFiNetworkDiagnosticsAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -29305,9 +29184,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsAcceptedCommandList : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -29347,8 +29227,9 @@ class ReadWiFiNetworkDiagnosticsAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.AttributeList response %@", [value description]); if (error != nil) { @@ -29373,9 +29254,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsAttributeList : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -29415,8 +29297,9 @@ class ReadWiFiNetworkDiagnosticsFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.FeatureMap response %@", [value description]); if (error != nil) { @@ -29441,9 +29324,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsFeatureMap : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -29483,8 +29367,9 @@ class ReadWiFiNetworkDiagnosticsClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WiFiNetworkDiagnostics.ClusterRevision response %@", [value description]); if (error != nil) { @@ -29509,9 +29394,10 @@ class SubscribeAttributeWiFiNetworkDiagnosticsClusterRevision : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000036) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -29575,8 +29461,9 @@ class EthernetNetworkDiagnosticsResetCounts : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000037) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTREthernetNetworkDiagnosticsClusterResetCountsParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -29618,8 +29505,9 @@ class ReadEthernetNetworkDiagnosticsPHYRate : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePHYRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"EthernetNetworkDiagnostics.PHYRate response %@", [value description]); if (error != nil) { @@ -29644,9 +29532,10 @@ class SubscribeAttributeEthernetNetworkDiagnosticsPHYRate : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -29686,8 +29575,9 @@ class ReadEthernetNetworkDiagnosticsFullDuplex : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFullDuplexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"EthernetNetworkDiagnostics.FullDuplex response %@", [value description]); if (error != nil) { @@ -29712,9 +29602,10 @@ class SubscribeAttributeEthernetNetworkDiagnosticsFullDuplex : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -29754,8 +29645,9 @@ class ReadEthernetNetworkDiagnosticsPacketRxCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePacketRxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"EthernetNetworkDiagnostics.PacketRxCount response %@", [value description]); if (error != nil) { @@ -29780,9 +29672,10 @@ class SubscribeAttributeEthernetNetworkDiagnosticsPacketRxCount : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -29822,8 +29715,9 @@ class ReadEthernetNetworkDiagnosticsPacketTxCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePacketTxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"EthernetNetworkDiagnostics.PacketTxCount response %@", [value description]); if (error != nil) { @@ -29848,9 +29742,10 @@ class SubscribeAttributeEthernetNetworkDiagnosticsPacketTxCount : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -29890,8 +29785,9 @@ class ReadEthernetNetworkDiagnosticsTxErrCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTxErrCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"EthernetNetworkDiagnostics.TxErrCount response %@", [value description]); if (error != nil) { @@ -29916,9 +29812,10 @@ class SubscribeAttributeEthernetNetworkDiagnosticsTxErrCount : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -29958,8 +29855,9 @@ class ReadEthernetNetworkDiagnosticsCollisionCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCollisionCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"EthernetNetworkDiagnostics.CollisionCount response %@", [value description]); if (error != nil) { @@ -29984,9 +29882,10 @@ class SubscribeAttributeEthernetNetworkDiagnosticsCollisionCount : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -30026,8 +29925,9 @@ class ReadEthernetNetworkDiagnosticsOverrunCount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOverrunCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"EthernetNetworkDiagnostics.OverrunCount response %@", [value description]); if (error != nil) { @@ -30052,9 +29952,10 @@ class SubscribeAttributeEthernetNetworkDiagnosticsOverrunCount : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -30094,8 +29995,9 @@ class ReadEthernetNetworkDiagnosticsCarrierDetect : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCarrierDetectWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"EthernetNetworkDiagnostics.CarrierDetect response %@", [value description]); if (error != nil) { @@ -30120,9 +30022,10 @@ class SubscribeAttributeEthernetNetworkDiagnosticsCarrierDetect : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -30162,8 +30065,9 @@ class ReadEthernetNetworkDiagnosticsTimeSinceReset : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReadAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTimeSinceResetWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"EthernetNetworkDiagnostics.TimeSinceReset response %@", [value description]); if (error != nil) { @@ -30188,9 +30092,10 @@ class SubscribeAttributeEthernetNetworkDiagnosticsTimeSinceReset : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReportAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -30230,8 +30135,9 @@ class ReadEthernetNetworkDiagnosticsGeneratedCommandList : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"EthernetNetworkDiagnostics.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -30256,9 +30162,10 @@ class SubscribeAttributeEthernetNetworkDiagnosticsGeneratedCommandList : public { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -30298,8 +30205,9 @@ class ReadEthernetNetworkDiagnosticsAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"EthernetNetworkDiagnostics.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -30324,9 +30232,10 @@ class SubscribeAttributeEthernetNetworkDiagnosticsAcceptedCommandList : public S { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -30366,8 +30275,9 @@ class ReadEthernetNetworkDiagnosticsAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"EthernetNetworkDiagnostics.AttributeList response %@", [value description]); if (error != nil) { @@ -30392,9 +30302,10 @@ class SubscribeAttributeEthernetNetworkDiagnosticsAttributeList : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -30434,8 +30345,9 @@ class ReadEthernetNetworkDiagnosticsFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"EthernetNetworkDiagnostics.FeatureMap response %@", [value description]); if (error != nil) { @@ -30460,9 +30372,10 @@ class SubscribeAttributeEthernetNetworkDiagnosticsFeatureMap : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -30502,8 +30415,9 @@ class ReadEthernetNetworkDiagnosticsClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"EthernetNetworkDiagnostics.ClusterRevision response %@", [value description]); if (error != nil) { @@ -30528,9 +30442,10 @@ class SubscribeAttributeEthernetNetworkDiagnosticsClusterRevision : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000037) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -30604,9 +30519,9 @@ class ReadBridgedDeviceBasicVendorName : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeVendorNameWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.VendorName response %@", [value description]); if (error != nil) { @@ -30631,10 +30546,10 @@ class SubscribeAttributeBridgedDeviceBasicVendorName : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -30674,9 +30589,9 @@ class ReadBridgedDeviceBasicVendorID : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeVendorIDWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.VendorID response %@", [value description]); if (error != nil) { @@ -30701,10 +30616,10 @@ class SubscribeAttributeBridgedDeviceBasicVendorID : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -30744,9 +30659,9 @@ class ReadBridgedDeviceBasicProductName : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeProductNameWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.ProductName response %@", [value description]); if (error != nil) { @@ -30771,10 +30686,10 @@ class SubscribeAttributeBridgedDeviceBasicProductName : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -30814,9 +30729,9 @@ class ReadBridgedDeviceBasicNodeLabel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNodeLabelWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.NodeLabel response %@", [value description]); if (error != nil) { @@ -30844,10 +30759,10 @@ class WriteBridgedDeviceBasicNodeLabel : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000039) WriteAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -30883,10 +30798,10 @@ class SubscribeAttributeBridgedDeviceBasicNodeLabel : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -30926,9 +30841,9 @@ class ReadBridgedDeviceBasicHardwareVersion : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeHardwareVersionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.HardwareVersion response %@", [value description]); if (error != nil) { @@ -30953,10 +30868,10 @@ class SubscribeAttributeBridgedDeviceBasicHardwareVersion : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -30996,9 +30911,9 @@ class ReadBridgedDeviceBasicHardwareVersionString : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeHardwareVersionStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.HardwareVersionString response %@", [value description]); if (error != nil) { @@ -31023,10 +30938,10 @@ class SubscribeAttributeBridgedDeviceBasicHardwareVersionString : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -31066,9 +30981,9 @@ class ReadBridgedDeviceBasicSoftwareVersion : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSoftwareVersionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.SoftwareVersion response %@", [value description]); if (error != nil) { @@ -31093,10 +31008,10 @@ class SubscribeAttributeBridgedDeviceBasicSoftwareVersion : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -31136,9 +31051,9 @@ class ReadBridgedDeviceBasicSoftwareVersionString : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSoftwareVersionStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.SoftwareVersionString response %@", [value description]); if (error != nil) { @@ -31163,10 +31078,10 @@ class SubscribeAttributeBridgedDeviceBasicSoftwareVersionString : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -31206,9 +31121,9 @@ class ReadBridgedDeviceBasicManufacturingDate : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeManufacturingDateWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.ManufacturingDate response %@", [value description]); if (error != nil) { @@ -31233,10 +31148,10 @@ class SubscribeAttributeBridgedDeviceBasicManufacturingDate : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -31276,9 +31191,9 @@ class ReadBridgedDeviceBasicPartNumber : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePartNumberWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.PartNumber response %@", [value description]); if (error != nil) { @@ -31303,10 +31218,10 @@ class SubscribeAttributeBridgedDeviceBasicPartNumber : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -31346,9 +31261,9 @@ class ReadBridgedDeviceBasicProductURL : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x0000000D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeProductURLWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.ProductURL response %@", [value description]); if (error != nil) { @@ -31373,10 +31288,10 @@ class SubscribeAttributeBridgedDeviceBasicProductURL : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x0000000D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -31416,9 +31331,9 @@ class ReadBridgedDeviceBasicProductLabel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x0000000E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeProductLabelWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.ProductLabel response %@", [value description]); if (error != nil) { @@ -31443,10 +31358,10 @@ class SubscribeAttributeBridgedDeviceBasicProductLabel : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x0000000E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -31486,9 +31401,9 @@ class ReadBridgedDeviceBasicSerialNumber : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSerialNumberWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.SerialNumber response %@", [value description]); if (error != nil) { @@ -31513,10 +31428,10 @@ class SubscribeAttributeBridgedDeviceBasicSerialNumber : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -31556,9 +31471,9 @@ class ReadBridgedDeviceBasicReachable : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeReachableWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.Reachable response %@", [value description]); if (error != nil) { @@ -31583,10 +31498,10 @@ class SubscribeAttributeBridgedDeviceBasicReachable : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -31626,9 +31541,9 @@ class ReadBridgedDeviceBasicUniqueID : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeUniqueIDWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.UniqueID response %@", [value description]); if (error != nil) { @@ -31653,10 +31568,10 @@ class SubscribeAttributeBridgedDeviceBasicUniqueID : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -31696,9 +31611,9 @@ class ReadBridgedDeviceBasicGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -31723,10 +31638,10 @@ class SubscribeAttributeBridgedDeviceBasicGeneratedCommandList : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -31766,9 +31681,9 @@ class ReadBridgedDeviceBasicAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -31793,10 +31708,10 @@ class SubscribeAttributeBridgedDeviceBasicAcceptedCommandList : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -31836,9 +31751,9 @@ class ReadBridgedDeviceBasicAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.AttributeList response %@", [value description]); if (error != nil) { @@ -31863,10 +31778,10 @@ class SubscribeAttributeBridgedDeviceBasicAttributeList : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -31906,9 +31821,9 @@ class ReadBridgedDeviceBasicFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.FeatureMap response %@", [value description]); if (error != nil) { @@ -31933,10 +31848,10 @@ class SubscribeAttributeBridgedDeviceBasicFeatureMap : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -31976,9 +31891,9 @@ class ReadBridgedDeviceBasicClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BridgedDeviceBasic.ClusterRevision response %@", [value description]); if (error != nil) { @@ -32003,10 +31918,10 @@ class SubscribeAttributeBridgedDeviceBasicClusterRevision : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000039) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBridgedDeviceBasic * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -32071,9 +31986,7 @@ class ReadSwitchNumberOfPositions : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeNumberOfPositionsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Switch.NumberOfPositions response %@", [value description]); if (error != nil) { @@ -32098,10 +32011,8 @@ class SubscribeAttributeSwitchNumberOfPositions : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -32141,9 +32052,7 @@ class ReadSwitchCurrentPosition : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeCurrentPositionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Switch.CurrentPosition response %@", [value description]); if (error != nil) { @@ -32168,10 +32077,8 @@ class SubscribeAttributeSwitchCurrentPosition : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -32211,9 +32118,7 @@ class ReadSwitchMultiPressMax : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeMultiPressMaxWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Switch.MultiPressMax response %@", [value description]); if (error != nil) { @@ -32238,10 +32143,8 @@ class SubscribeAttributeSwitchMultiPressMax : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -32281,9 +32184,7 @@ class ReadSwitchGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Switch.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -32308,10 +32209,8 @@ class SubscribeAttributeSwitchGeneratedCommandList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -32351,9 +32250,7 @@ class ReadSwitchAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Switch.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -32378,10 +32275,8 @@ class SubscribeAttributeSwitchAcceptedCommandList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -32421,9 +32316,7 @@ class ReadSwitchAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Switch.AttributeList response %@", [value description]); if (error != nil) { @@ -32448,10 +32341,8 @@ class SubscribeAttributeSwitchAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -32491,9 +32382,7 @@ class ReadSwitchFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Switch.FeatureMap response %@", [value description]); if (error != nil) { @@ -32518,10 +32407,8 @@ class SubscribeAttributeSwitchFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -32561,9 +32448,7 @@ class ReadSwitchClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Switch.ClusterRevision response %@", [value description]); if (error != nil) { @@ -32588,10 +32473,8 @@ class SubscribeAttributeSwitchClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000003B) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -32656,8 +32539,9 @@ class AdministratorCommissioningOpenCommissioningWindow : public ClusterCommand ChipLogProgress(chipTool, "Sending cluster (0x0000003C) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRAdministratorCommissioningClusterOpenCommissioningWindowParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -32705,8 +32589,9 @@ class AdministratorCommissioningOpenBasicCommissioningWindow : public ClusterCom ChipLogProgress(chipTool, "Sending cluster (0x0000003C) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRAdministratorCommissioningClusterOpenBasicCommissioningWindowParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -32749,8 +32634,9 @@ class AdministratorCommissioningRevokeCommissioning : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRAdministratorCommissioningClusterRevokeCommissioningParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -32792,8 +32678,9 @@ class ReadAdministratorCommissioningWindowStatus : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeWindowStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"AdministratorCommissioning.WindowStatus response %@", [value description]); if (error != nil) { @@ -32818,9 +32705,10 @@ class SubscribeAttributeAdministratorCommissioningWindowStatus : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -32860,8 +32748,9 @@ class ReadAdministratorCommissioningAdminFabricIndex : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAdminFabricIndexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"AdministratorCommissioning.AdminFabricIndex response %@", [value description]); if (error != nil) { @@ -32886,9 +32775,10 @@ class SubscribeAttributeAdministratorCommissioningAdminFabricIndex : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -32928,8 +32818,9 @@ class ReadAdministratorCommissioningAdminVendorId : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAdminVendorIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"AdministratorCommissioning.AdminVendorId response %@", [value description]); if (error != nil) { @@ -32954,9 +32845,10 @@ class SubscribeAttributeAdministratorCommissioningAdminVendorId : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -32996,8 +32888,9 @@ class ReadAdministratorCommissioningGeneratedCommandList : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"AdministratorCommissioning.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -33022,9 +32915,10 @@ class SubscribeAttributeAdministratorCommissioningGeneratedCommandList : public { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -33064,8 +32958,9 @@ class ReadAdministratorCommissioningAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"AdministratorCommissioning.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -33090,9 +32985,10 @@ class SubscribeAttributeAdministratorCommissioningAcceptedCommandList : public S { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -33132,8 +33028,9 @@ class ReadAdministratorCommissioningAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"AdministratorCommissioning.AttributeList response %@", [value description]); if (error != nil) { @@ -33158,9 +33055,10 @@ class SubscribeAttributeAdministratorCommissioningAttributeList : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -33200,8 +33098,9 @@ class ReadAdministratorCommissioningFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"AdministratorCommissioning.FeatureMap response %@", [value description]); if (error != nil) { @@ -33226,9 +33125,10 @@ class SubscribeAttributeAdministratorCommissioningFeatureMap : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -33268,8 +33168,9 @@ class ReadAdministratorCommissioningClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"AdministratorCommissioning.ClusterRevision response %@", [value description]); if (error != nil) { @@ -33294,9 +33195,10 @@ class SubscribeAttributeAdministratorCommissioningClusterRevision : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x0000003C) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -33365,8 +33267,9 @@ class OperationalCredentialsAttestationRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTROperationalCredentialsClusterAttestationRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -33412,8 +33315,9 @@ class OperationalCredentialsCertificateChainRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTROperationalCredentialsClusterCertificateChainRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -33461,8 +33365,9 @@ class OperationalCredentialsCSRRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) command (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTROperationalCredentialsClusterCSRRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -33517,8 +33422,9 @@ class OperationalCredentialsAddNOC : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) command (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTROperationalCredentialsClusterAddNOCParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -33573,8 +33479,9 @@ class OperationalCredentialsUpdateNOC : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) command (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTROperationalCredentialsClusterUpdateNOCParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -33625,8 +33532,9 @@ class OperationalCredentialsUpdateFabricLabel : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) command (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTROperationalCredentialsClusterUpdateFabricLabelParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -33674,8 +33582,9 @@ class OperationalCredentialsRemoveFabric : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) command (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTROperationalCredentialsClusterRemoveFabricParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -33721,8 +33630,9 @@ class OperationalCredentialsAddTrustedRootCertificate : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) command (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTROperationalCredentialsClusterAddTrustedRootCertificateParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -33766,9 +33676,10 @@ class ReadOperationalCredentialsNOCs : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRReadParams alloc] init]; if (mFabricFiltered.HasValue()) { params.filterByFabric = mFabricFiltered.Value(); } @@ -33797,9 +33708,10 @@ class SubscribeAttributeOperationalCredentialsNOCs : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -33839,9 +33751,10 @@ class ReadOperationalCredentialsFabrics : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRReadParams alloc] init]; if (mFabricFiltered.HasValue()) { params.filterByFabric = mFabricFiltered.Value(); } @@ -33870,9 +33783,10 @@ class SubscribeAttributeOperationalCredentialsFabrics : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -33912,8 +33826,9 @@ class ReadOperationalCredentialsSupportedFabrics : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSupportedFabricsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OperationalCredentials.SupportedFabrics response %@", [value description]); if (error != nil) { @@ -33938,9 +33853,10 @@ class SubscribeAttributeOperationalCredentialsSupportedFabrics : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -33980,8 +33896,9 @@ class ReadOperationalCredentialsCommissionedFabrics : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCommissionedFabricsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OperationalCredentials.CommissionedFabrics response %@", [value description]); if (error != nil) { @@ -34006,9 +33923,10 @@ class SubscribeAttributeOperationalCredentialsCommissionedFabrics : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -34048,8 +33966,9 @@ class ReadOperationalCredentialsTrustedRootCertificates : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTrustedRootCertificatesWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"OperationalCredentials.TrustedRootCertificates response %@", [value description]); if (error != nil) { @@ -34074,9 +33993,10 @@ class SubscribeAttributeOperationalCredentialsTrustedRootCertificates : public S { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -34116,8 +34036,9 @@ class ReadOperationalCredentialsCurrentFabricIndex : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentFabricIndexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OperationalCredentials.CurrentFabricIndex response %@", [value description]); if (error != nil) { @@ -34142,9 +34063,10 @@ class SubscribeAttributeOperationalCredentialsCurrentFabricIndex : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -34184,8 +34106,9 @@ class ReadOperationalCredentialsGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"OperationalCredentials.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -34210,9 +34133,10 @@ class SubscribeAttributeOperationalCredentialsGeneratedCommandList : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -34252,8 +34176,9 @@ class ReadOperationalCredentialsAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"OperationalCredentials.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -34278,9 +34203,10 @@ class SubscribeAttributeOperationalCredentialsAcceptedCommandList : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -34320,8 +34246,9 @@ class ReadOperationalCredentialsAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"OperationalCredentials.AttributeList response %@", [value description]); if (error != nil) { @@ -34346,9 +34273,10 @@ class SubscribeAttributeOperationalCredentialsAttributeList : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -34388,8 +34316,9 @@ class ReadOperationalCredentialsFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OperationalCredentials.FeatureMap response %@", [value description]); if (error != nil) { @@ -34414,9 +34343,10 @@ class SubscribeAttributeOperationalCredentialsFeatureMap : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -34456,8 +34386,9 @@ class ReadOperationalCredentialsClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OperationalCredentials.ClusterRevision response %@", [value description]); if (error != nil) { @@ -34482,9 +34413,10 @@ class SubscribeAttributeOperationalCredentialsClusterRevision : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x0000003E) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -34548,9 +34480,9 @@ class GroupKeyManagementKeySetWrite : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRGroupKeyManagementClusterKeySetWriteParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -34631,9 +34563,9 @@ class GroupKeyManagementKeySetRead : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRGroupKeyManagementClusterKeySetReadParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -34679,9 +34611,9 @@ class GroupKeyManagementKeySetRemove : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) command (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRGroupKeyManagementClusterKeySetRemoveParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -34726,9 +34658,9 @@ class GroupKeyManagementKeySetReadAllIndices : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) command (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRGroupKeyManagementClusterKeySetReadAllIndicesParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -34784,10 +34716,10 @@ class ReadGroupKeyManagementGroupKeyMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRReadParams alloc] init]; if (mFabricFiltered.HasValue()) { params.filterByFabric = mFabricFiltered.Value(); } @@ -34820,10 +34752,10 @@ class WriteGroupKeyManagementGroupKeyMap : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) WriteAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -34872,10 +34804,10 @@ class SubscribeAttributeGroupKeyManagementGroupKeyMap : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -34915,10 +34847,10 @@ class ReadGroupKeyManagementGroupTable : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRReadParams alloc] init]; if (mFabricFiltered.HasValue()) { params.filterByFabric = mFabricFiltered.Value(); } @@ -34947,10 +34879,10 @@ class SubscribeAttributeGroupKeyManagementGroupTable : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -34990,9 +34922,9 @@ class ReadGroupKeyManagementMaxGroupsPerFabric : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxGroupsPerFabricWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GroupKeyManagement.MaxGroupsPerFabric response %@", [value description]); if (error != nil) { @@ -35017,10 +34949,10 @@ class SubscribeAttributeGroupKeyManagementMaxGroupsPerFabric : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -35060,9 +34992,9 @@ class ReadGroupKeyManagementMaxGroupKeysPerFabric : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxGroupKeysPerFabricWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GroupKeyManagement.MaxGroupKeysPerFabric response %@", [value description]); if (error != nil) { @@ -35087,10 +35019,10 @@ class SubscribeAttributeGroupKeyManagementMaxGroupKeysPerFabric : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -35130,9 +35062,9 @@ class ReadGroupKeyManagementGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"GroupKeyManagement.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -35157,10 +35089,10 @@ class SubscribeAttributeGroupKeyManagementGeneratedCommandList : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -35200,9 +35132,9 @@ class ReadGroupKeyManagementAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"GroupKeyManagement.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -35227,10 +35159,10 @@ class SubscribeAttributeGroupKeyManagementAcceptedCommandList : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -35270,9 +35202,9 @@ class ReadGroupKeyManagementAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"GroupKeyManagement.AttributeList response %@", [value description]); if (error != nil) { @@ -35297,10 +35229,10 @@ class SubscribeAttributeGroupKeyManagementAttributeList : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -35340,9 +35272,9 @@ class ReadGroupKeyManagementFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GroupKeyManagement.FeatureMap response %@", [value description]); if (error != nil) { @@ -35367,10 +35299,10 @@ class SubscribeAttributeGroupKeyManagementFeatureMap : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -35410,9 +35342,9 @@ class ReadGroupKeyManagementClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"GroupKeyManagement.ClusterRevision response %@", [value description]); if (error != nil) { @@ -35437,10 +35369,10 @@ class SubscribeAttributeGroupKeyManagementClusterRevision : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x0000003F) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -35496,9 +35428,9 @@ class ReadFixedLabelLabelList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000040) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLabelListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"FixedLabel.LabelList response %@", [value description]); if (error != nil) { @@ -35523,10 +35455,10 @@ class SubscribeAttributeFixedLabelLabelList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000040) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -35566,9 +35498,9 @@ class ReadFixedLabelGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000040) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"FixedLabel.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -35593,10 +35525,10 @@ class SubscribeAttributeFixedLabelGeneratedCommandList : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000040) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -35636,9 +35568,9 @@ class ReadFixedLabelAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000040) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"FixedLabel.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -35663,10 +35595,10 @@ class SubscribeAttributeFixedLabelAcceptedCommandList : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000040) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -35706,9 +35638,9 @@ class ReadFixedLabelAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000040) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"FixedLabel.AttributeList response %@", [value description]); if (error != nil) { @@ -35733,10 +35665,10 @@ class SubscribeAttributeFixedLabelAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000040) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -35776,9 +35708,9 @@ class ReadFixedLabelFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000040) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FixedLabel.FeatureMap response %@", [value description]); if (error != nil) { @@ -35803,10 +35735,10 @@ class SubscribeAttributeFixedLabelFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000040) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -35846,9 +35778,9 @@ class ReadFixedLabelClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000040) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FixedLabel.ClusterRevision response %@", [value description]); if (error != nil) { @@ -35873,10 +35805,10 @@ class SubscribeAttributeFixedLabelClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000040) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -35932,9 +35864,9 @@ class ReadUserLabelLabelList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000041) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLabelListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"UserLabel.LabelList response %@", [value description]); if (error != nil) { @@ -35963,10 +35895,10 @@ class WriteUserLabelLabelList : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000041) WriteAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -36016,10 +35948,10 @@ class SubscribeAttributeUserLabelLabelList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000041) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -36059,9 +35991,9 @@ class ReadUserLabelGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000041) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"UserLabel.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -36086,10 +36018,10 @@ class SubscribeAttributeUserLabelGeneratedCommandList : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000041) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -36129,9 +36061,9 @@ class ReadUserLabelAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000041) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"UserLabel.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -36156,10 +36088,10 @@ class SubscribeAttributeUserLabelAcceptedCommandList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000041) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -36199,9 +36131,9 @@ class ReadUserLabelAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000041) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"UserLabel.AttributeList response %@", [value description]); if (error != nil) { @@ -36226,10 +36158,10 @@ class SubscribeAttributeUserLabelAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000041) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -36269,9 +36201,9 @@ class ReadUserLabelFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000041) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UserLabel.FeatureMap response %@", [value description]); if (error != nil) { @@ -36296,10 +36228,10 @@ class SubscribeAttributeUserLabelFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000041) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -36339,9 +36271,9 @@ class ReadUserLabelClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000041) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UserLabel.ClusterRevision response %@", [value description]); if (error != nil) { @@ -36366,10 +36298,10 @@ class SubscribeAttributeUserLabelClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000041) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -36426,9 +36358,9 @@ class ReadBooleanStateStateValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000045) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeStateValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BooleanState.StateValue response %@", [value description]); if (error != nil) { @@ -36453,10 +36385,10 @@ class SubscribeAttributeBooleanStateStateValue : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000045) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -36496,9 +36428,9 @@ class ReadBooleanStateGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000045) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"BooleanState.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -36523,10 +36455,10 @@ class SubscribeAttributeBooleanStateGeneratedCommandList : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000045) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -36566,9 +36498,9 @@ class ReadBooleanStateAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000045) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"BooleanState.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -36593,10 +36525,10 @@ class SubscribeAttributeBooleanStateAcceptedCommandList : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000045) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -36636,9 +36568,9 @@ class ReadBooleanStateAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000045) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"BooleanState.AttributeList response %@", [value description]); if (error != nil) { @@ -36663,10 +36595,10 @@ class SubscribeAttributeBooleanStateAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000045) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -36706,9 +36638,9 @@ class ReadBooleanStateFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000045) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BooleanState.FeatureMap response %@", [value description]); if (error != nil) { @@ -36733,10 +36665,10 @@ class SubscribeAttributeBooleanStateFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000045) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -36776,9 +36708,9 @@ class ReadBooleanStateClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000045) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BooleanState.ClusterRevision response %@", [value description]); if (error != nil) { @@ -36803,10 +36735,10 @@ class SubscribeAttributeBooleanStateClusterRevision : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000045) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -36868,9 +36800,9 @@ class ModeSelectChangeToMode : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000050) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRModeSelectClusterChangeToModeParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -36914,9 +36846,9 @@ class ReadModeSelectDescription : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDescriptionWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"ModeSelect.Description response %@", [value description]); if (error != nil) { @@ -36941,10 +36873,10 @@ class SubscribeAttributeModeSelectDescription : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -36984,9 +36916,9 @@ class ReadModeSelectStandardNamespace : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeStandardNamespaceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ModeSelect.StandardNamespace response %@", [value description]); if (error != nil) { @@ -37011,10 +36943,10 @@ class SubscribeAttributeModeSelectStandardNamespace : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -37054,9 +36986,9 @@ class ReadModeSelectSupportedModes : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSupportedModesWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ModeSelect.SupportedModes response %@", [value description]); if (error != nil) { @@ -37081,10 +37013,10 @@ class SubscribeAttributeModeSelectSupportedModes : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -37124,9 +37056,9 @@ class ReadModeSelectCurrentMode : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ModeSelect.CurrentMode response %@", [value description]); if (error != nil) { @@ -37151,10 +37083,10 @@ class SubscribeAttributeModeSelectCurrentMode : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -37194,9 +37126,9 @@ class ReadModeSelectStartUpMode : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeStartUpModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ModeSelect.StartUpMode response %@", [value description]); if (error != nil) { @@ -37224,10 +37156,10 @@ class WriteModeSelectStartUpMode : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000050) WriteAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -37261,10 +37193,10 @@ class SubscribeAttributeModeSelectStartUpMode : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -37304,9 +37236,9 @@ class ReadModeSelectOnMode : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOnModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ModeSelect.OnMode response %@", [value description]); if (error != nil) { @@ -37334,10 +37266,10 @@ class WriteModeSelectOnMode : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000050) WriteAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -37371,10 +37303,10 @@ class SubscribeAttributeModeSelectOnMode : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -37414,9 +37346,9 @@ class ReadModeSelectGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ModeSelect.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -37441,10 +37373,10 @@ class SubscribeAttributeModeSelectGeneratedCommandList : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -37484,9 +37416,9 @@ class ReadModeSelectAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ModeSelect.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -37511,10 +37443,10 @@ class SubscribeAttributeModeSelectAcceptedCommandList : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -37554,9 +37486,9 @@ class ReadModeSelectAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ModeSelect.AttributeList response %@", [value description]); if (error != nil) { @@ -37581,10 +37513,10 @@ class SubscribeAttributeModeSelectAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -37624,9 +37556,9 @@ class ReadModeSelectFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ModeSelect.FeatureMap response %@", [value description]); if (error != nil) { @@ -37651,10 +37583,10 @@ class SubscribeAttributeModeSelectFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -37694,9 +37626,9 @@ class ReadModeSelectClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ModeSelect.ClusterRevision response %@", [value description]); if (error != nil) { @@ -37721,10 +37653,10 @@ class SubscribeAttributeModeSelectClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000050) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -37838,9 +37770,7 @@ class DoorLockLockDoor : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterLockDoorParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -37888,9 +37818,7 @@ class DoorLockUnlockDoor : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -37939,9 +37867,7 @@ class DoorLockUnlockWithTimeout : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterUnlockWithTimeoutParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -37996,9 +37922,7 @@ class DoorLockSetWeekDaySchedule : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -38049,9 +37973,7 @@ class DoorLockGetWeekDaySchedule : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -38099,9 +38021,7 @@ class DoorLockClearWeekDaySchedule : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x0000000D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterClearWeekDayScheduleParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -38149,9 +38069,7 @@ class DoorLockSetYearDaySchedule : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x0000000E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterSetYearDayScheduleParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -38199,9 +38117,7 @@ class DoorLockGetYearDaySchedule : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -38249,9 +38165,7 @@ class DoorLockClearYearDaySchedule : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterClearYearDayScheduleParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -38299,9 +38213,7 @@ class DoorLockSetHolidaySchedule : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterSetHolidayScheduleParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -38348,9 +38260,7 @@ class DoorLockGetHolidaySchedule : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -38396,9 +38306,7 @@ class DoorLockClearHolidaySchedule : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterClearHolidayScheduleParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -38448,9 +38356,7 @@ class DoorLockSetUser : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -38522,9 +38428,7 @@ class DoorLockGetUser : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x0000001B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -38569,9 +38473,7 @@ class DoorLockClearUser : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x0000001D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -38621,9 +38523,7 @@ class DoorLockSetCredential : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -38691,9 +38591,7 @@ class DoorLockGetCredentialStatus : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x00000024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -38744,9 +38642,7 @@ class DoorLockClearCredential : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000101) command (0x00000026) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -38799,9 +38695,7 @@ class ReadDoorLockLockState : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeLockStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.LockState response %@", [value description]); if (error != nil) { @@ -38826,10 +38720,8 @@ class SubscribeAttributeDoorLockLockState : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -38869,9 +38761,7 @@ class ReadDoorLockLockType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeLockTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.LockType response %@", [value description]); if (error != nil) { @@ -38896,10 +38786,8 @@ class SubscribeAttributeDoorLockLockType : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -38939,9 +38827,7 @@ class ReadDoorLockActuatorEnabled : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeActuatorEnabledWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.ActuatorEnabled response %@", [value description]); if (error != nil) { @@ -38966,10 +38852,8 @@ class SubscribeAttributeDoorLockActuatorEnabled : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -39009,9 +38893,7 @@ class ReadDoorLockDoorState : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeDoorStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.DoorState response %@", [value description]); if (error != nil) { @@ -39036,10 +38918,8 @@ class SubscribeAttributeDoorLockDoorState : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -39079,9 +38959,7 @@ class ReadDoorLockDoorOpenEvents : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeDoorOpenEventsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.DoorOpenEvents response %@", [value description]); if (error != nil) { @@ -39109,10 +38987,8 @@ class WriteDoorLockDoorOpenEvents : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -39146,10 +39022,8 @@ class SubscribeAttributeDoorLockDoorOpenEvents : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -39189,9 +39063,7 @@ class ReadDoorLockDoorClosedEvents : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeDoorClosedEventsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.DoorClosedEvents response %@", [value description]); if (error != nil) { @@ -39219,10 +39091,8 @@ class WriteDoorLockDoorClosedEvents : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -39256,10 +39126,8 @@ class SubscribeAttributeDoorLockDoorClosedEvents : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -39299,9 +39167,7 @@ class ReadDoorLockOpenPeriod : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeOpenPeriodWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.OpenPeriod response %@", [value description]); if (error != nil) { @@ -39329,10 +39195,8 @@ class WriteDoorLockOpenPeriod : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -39366,10 +39230,8 @@ class SubscribeAttributeDoorLockOpenPeriod : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -39409,9 +39271,7 @@ class ReadDoorLockNumberOfTotalUsersSupported : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeNumberOfTotalUsersSupportedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.NumberOfTotalUsersSupported response %@", [value description]); if (error != nil) { @@ -39436,10 +39296,8 @@ class SubscribeAttributeDoorLockNumberOfTotalUsersSupported : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -39479,9 +39337,7 @@ class ReadDoorLockNumberOfPINUsersSupported : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeNumberOfPINUsersSupportedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.NumberOfPINUsersSupported response %@", [value description]); if (error != nil) { @@ -39506,10 +39362,8 @@ class SubscribeAttributeDoorLockNumberOfPINUsersSupported : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -39549,9 +39403,7 @@ class ReadDoorLockNumberOfRFIDUsersSupported : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeNumberOfRFIDUsersSupportedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.NumberOfRFIDUsersSupported response %@", [value description]); if (error != nil) { @@ -39576,10 +39428,8 @@ class SubscribeAttributeDoorLockNumberOfRFIDUsersSupported : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -39619,9 +39469,7 @@ class ReadDoorLockNumberOfWeekDaySchedulesSupportedPerUser : public ReadAttribut ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeNumberOfWeekDaySchedulesSupportedPerUserWithCompletion:^( NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.NumberOfWeekDaySchedulesSupportedPerUser response %@", [value description]); @@ -39647,10 +39495,8 @@ class SubscribeAttributeDoorLockNumberOfWeekDaySchedulesSupportedPerUser : publi { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -39690,9 +39536,7 @@ class ReadDoorLockNumberOfYearDaySchedulesSupportedPerUser : public ReadAttribut ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeNumberOfYearDaySchedulesSupportedPerUserWithCompletion:^( NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.NumberOfYearDaySchedulesSupportedPerUser response %@", [value description]); @@ -39718,10 +39562,8 @@ class SubscribeAttributeDoorLockNumberOfYearDaySchedulesSupportedPerUser : publi { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -39761,9 +39603,7 @@ class ReadDoorLockNumberOfHolidaySchedulesSupported : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeNumberOfHolidaySchedulesSupportedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.NumberOfHolidaySchedulesSupported response %@", [value description]); @@ -39789,10 +39629,8 @@ class SubscribeAttributeDoorLockNumberOfHolidaySchedulesSupported : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -39832,9 +39670,7 @@ class ReadDoorLockMaxPINCodeLength : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeMaxPINCodeLengthWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.MaxPINCodeLength response %@", [value description]); if (error != nil) { @@ -39859,10 +39695,8 @@ class SubscribeAttributeDoorLockMaxPINCodeLength : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -39902,9 +39736,7 @@ class ReadDoorLockMinPINCodeLength : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000018) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeMinPINCodeLengthWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.MinPINCodeLength response %@", [value description]); if (error != nil) { @@ -39929,10 +39761,8 @@ class SubscribeAttributeDoorLockMinPINCodeLength : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000018) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -39972,9 +39802,7 @@ class ReadDoorLockMaxRFIDCodeLength : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeMaxRFIDCodeLengthWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.MaxRFIDCodeLength response %@", [value description]); if (error != nil) { @@ -39999,10 +39827,8 @@ class SubscribeAttributeDoorLockMaxRFIDCodeLength : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -40042,9 +39868,7 @@ class ReadDoorLockMinRFIDCodeLength : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeMinRFIDCodeLengthWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.MinRFIDCodeLength response %@", [value description]); if (error != nil) { @@ -40069,10 +39893,8 @@ class SubscribeAttributeDoorLockMinRFIDCodeLength : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -40112,9 +39934,7 @@ class ReadDoorLockCredentialRulesSupport : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x0000001B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeCredentialRulesSupportWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.CredentialRulesSupport response %@", [value description]); if (error != nil) { @@ -40139,10 +39959,8 @@ class SubscribeAttributeDoorLockCredentialRulesSupport : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x0000001B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -40182,9 +40000,7 @@ class ReadDoorLockNumberOfCredentialsSupportedPerUser : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x0000001C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeNumberOfCredentialsSupportedPerUserWithCompletion:^( NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.NumberOfCredentialsSupportedPerUser response %@", [value description]); @@ -40210,10 +40026,8 @@ class SubscribeAttributeDoorLockNumberOfCredentialsSupportedPerUser : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x0000001C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -40253,9 +40067,7 @@ class ReadDoorLockLanguage : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeLanguageWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.Language response %@", [value description]); if (error != nil) { @@ -40283,10 +40095,8 @@ class WriteDoorLockLanguage : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -40322,10 +40132,8 @@ class SubscribeAttributeDoorLockLanguage : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -40365,9 +40173,7 @@ class ReadDoorLockLEDSettings : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeLEDSettingsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.LEDSettings response %@", [value description]); if (error != nil) { @@ -40395,10 +40201,8 @@ class WriteDoorLockLEDSettings : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -40432,10 +40236,8 @@ class SubscribeAttributeDoorLockLEDSettings : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -40475,9 +40277,7 @@ class ReadDoorLockAutoRelockTime : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000023) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAutoRelockTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.AutoRelockTime response %@", [value description]); if (error != nil) { @@ -40505,10 +40305,8 @@ class WriteDoorLockAutoRelockTime : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x00000023) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -40542,10 +40340,8 @@ class SubscribeAttributeDoorLockAutoRelockTime : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000023) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -40585,9 +40381,7 @@ class ReadDoorLockSoundVolume : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeSoundVolumeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.SoundVolume response %@", [value description]); if (error != nil) { @@ -40615,10 +40409,8 @@ class WriteDoorLockSoundVolume : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x00000024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -40652,10 +40444,8 @@ class SubscribeAttributeDoorLockSoundVolume : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -40695,9 +40485,7 @@ class ReadDoorLockOperatingMode : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeOperatingModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.OperatingMode response %@", [value description]); if (error != nil) { @@ -40725,10 +40513,8 @@ class WriteDoorLockOperatingMode : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x00000025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -40762,10 +40548,8 @@ class SubscribeAttributeDoorLockOperatingMode : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -40805,9 +40589,7 @@ class ReadDoorLockSupportedOperatingModes : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000026) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeSupportedOperatingModesWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.SupportedOperatingModes response %@", [value description]); if (error != nil) { @@ -40832,10 +40614,8 @@ class SubscribeAttributeDoorLockSupportedOperatingModes : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000026) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -40875,9 +40655,7 @@ class ReadDoorLockDefaultConfigurationRegister : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000027) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeDefaultConfigurationRegisterWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.DefaultConfigurationRegister response %@", [value description]); if (error != nil) { @@ -40902,10 +40680,8 @@ class SubscribeAttributeDoorLockDefaultConfigurationRegister : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000027) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -40945,9 +40721,7 @@ class ReadDoorLockEnableLocalProgramming : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000028) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeEnableLocalProgrammingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.EnableLocalProgramming response %@", [value description]); if (error != nil) { @@ -40975,10 +40749,8 @@ class WriteDoorLockEnableLocalProgramming : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x00000028) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -41012,10 +40784,8 @@ class SubscribeAttributeDoorLockEnableLocalProgramming : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000028) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -41055,9 +40825,7 @@ class ReadDoorLockEnableOneTouchLocking : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000029) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeEnableOneTouchLockingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.EnableOneTouchLocking response %@", [value description]); if (error != nil) { @@ -41085,10 +40853,8 @@ class WriteDoorLockEnableOneTouchLocking : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x00000029) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -41122,10 +40888,8 @@ class SubscribeAttributeDoorLockEnableOneTouchLocking : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000029) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -41165,9 +40929,7 @@ class ReadDoorLockEnableInsideStatusLED : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x0000002A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeEnableInsideStatusLEDWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.EnableInsideStatusLED response %@", [value description]); if (error != nil) { @@ -41195,10 +40957,8 @@ class WriteDoorLockEnableInsideStatusLED : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x0000002A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -41232,10 +40992,8 @@ class SubscribeAttributeDoorLockEnableInsideStatusLED : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x0000002A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -41275,9 +41033,7 @@ class ReadDoorLockEnablePrivacyModeButton : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x0000002B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeEnablePrivacyModeButtonWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.EnablePrivacyModeButton response %@", [value description]); if (error != nil) { @@ -41305,10 +41061,8 @@ class WriteDoorLockEnablePrivacyModeButton : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x0000002B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -41342,10 +41096,8 @@ class SubscribeAttributeDoorLockEnablePrivacyModeButton : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x0000002B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -41385,9 +41137,7 @@ class ReadDoorLockLocalProgrammingFeatures : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x0000002C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeLocalProgrammingFeaturesWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.LocalProgrammingFeatures response %@", [value description]); if (error != nil) { @@ -41415,10 +41165,8 @@ class WriteDoorLockLocalProgrammingFeatures : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x0000002C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -41452,10 +41200,8 @@ class SubscribeAttributeDoorLockLocalProgrammingFeatures : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x0000002C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -41495,9 +41241,7 @@ class ReadDoorLockWrongCodeEntryLimit : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeWrongCodeEntryLimitWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.WrongCodeEntryLimit response %@", [value description]); if (error != nil) { @@ -41525,10 +41269,8 @@ class WriteDoorLockWrongCodeEntryLimit : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -41562,10 +41304,8 @@ class SubscribeAttributeDoorLockWrongCodeEntryLimit : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -41605,9 +41345,7 @@ class ReadDoorLockUserCodeTemporaryDisableTime : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeUserCodeTemporaryDisableTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.UserCodeTemporaryDisableTime response %@", [value description]); if (error != nil) { @@ -41635,10 +41373,8 @@ class WriteDoorLockUserCodeTemporaryDisableTime : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -41673,10 +41409,8 @@ class SubscribeAttributeDoorLockUserCodeTemporaryDisableTime : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -41716,9 +41450,7 @@ class ReadDoorLockSendPINOverTheAir : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeSendPINOverTheAirWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.SendPINOverTheAir response %@", [value description]); if (error != nil) { @@ -41746,10 +41478,8 @@ class WriteDoorLockSendPINOverTheAir : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -41783,10 +41513,8 @@ class SubscribeAttributeDoorLockSendPINOverTheAir : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -41826,9 +41554,7 @@ class ReadDoorLockRequirePINforRemoteOperation : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000033) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeRequirePINforRemoteOperationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.RequirePINforRemoteOperation response %@", [value description]); if (error != nil) { @@ -41856,10 +41582,8 @@ class WriteDoorLockRequirePINforRemoteOperation : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x00000033) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -41894,10 +41618,8 @@ class SubscribeAttributeDoorLockRequirePINforRemoteOperation : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000033) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -41937,9 +41659,7 @@ class ReadDoorLockExpiringUserTimeout : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x00000035) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeExpiringUserTimeoutWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.ExpiringUserTimeout response %@", [value description]); if (error != nil) { @@ -41967,10 +41687,8 @@ class WriteDoorLockExpiringUserTimeout : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) WriteAttribute (0x00000035) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -42004,10 +41722,8 @@ class SubscribeAttributeDoorLockExpiringUserTimeout : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x00000035) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -42047,9 +41763,7 @@ class ReadDoorLockGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -42074,10 +41788,8 @@ class SubscribeAttributeDoorLockGeneratedCommandList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -42117,9 +41829,7 @@ class ReadDoorLockAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -42144,10 +41854,8 @@ class SubscribeAttributeDoorLockAcceptedCommandList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -42187,9 +41895,7 @@ class ReadDoorLockAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.AttributeList response %@", [value description]); if (error != nil) { @@ -42214,10 +41920,8 @@ class SubscribeAttributeDoorLockAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -42257,9 +41961,7 @@ class ReadDoorLockFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.FeatureMap response %@", [value description]); if (error != nil) { @@ -42284,10 +41986,8 @@ class SubscribeAttributeDoorLockFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -42327,9 +42027,7 @@ class ReadDoorLockClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"DoorLock.ClusterRevision response %@", [value description]); if (error != nil) { @@ -42354,10 +42052,8 @@ class SubscribeAttributeDoorLockClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000101) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -42440,9 +42136,9 @@ class WindowCoveringUpOrOpen : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000102) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRWindowCoveringClusterUpOrOpenParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -42483,9 +42179,9 @@ class WindowCoveringDownOrClose : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000102) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRWindowCoveringClusterDownOrCloseParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -42526,9 +42222,9 @@ class WindowCoveringStopMotion : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000102) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRWindowCoveringClusterStopMotionParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -42570,9 +42266,9 @@ class WindowCoveringGoToLiftValue : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000102) command (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRWindowCoveringClusterGoToLiftValueParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -42616,9 +42312,9 @@ class WindowCoveringGoToLiftPercentage : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000102) command (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRWindowCoveringClusterGoToLiftPercentageParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -42662,9 +42358,9 @@ class WindowCoveringGoToTiltValue : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000102) command (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRWindowCoveringClusterGoToTiltValueParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -42708,9 +42404,9 @@ class WindowCoveringGoToTiltPercentage : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000102) command (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRWindowCoveringClusterGoToTiltPercentageParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -42754,9 +42450,9 @@ class ReadWindowCoveringType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.Type response %@", [value description]); if (error != nil) { @@ -42781,10 +42477,10 @@ class SubscribeAttributeWindowCoveringType : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -42824,9 +42520,9 @@ class ReadWindowCoveringPhysicalClosedLimitLift : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePhysicalClosedLimitLiftWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.PhysicalClosedLimitLift response %@", [value description]); if (error != nil) { @@ -42851,10 +42547,10 @@ class SubscribeAttributeWindowCoveringPhysicalClosedLimitLift : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -42894,9 +42590,9 @@ class ReadWindowCoveringPhysicalClosedLimitTilt : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePhysicalClosedLimitTiltWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.PhysicalClosedLimitTilt response %@", [value description]); if (error != nil) { @@ -42921,10 +42617,10 @@ class SubscribeAttributeWindowCoveringPhysicalClosedLimitTilt : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -42964,9 +42660,9 @@ class ReadWindowCoveringCurrentPositionLift : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentPositionLiftWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.CurrentPositionLift response %@", [value description]); if (error != nil) { @@ -42991,10 +42687,10 @@ class SubscribeAttributeWindowCoveringCurrentPositionLift : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -43034,9 +42730,9 @@ class ReadWindowCoveringCurrentPositionTilt : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentPositionTiltWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.CurrentPositionTilt response %@", [value description]); if (error != nil) { @@ -43061,10 +42757,10 @@ class SubscribeAttributeWindowCoveringCurrentPositionTilt : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -43104,9 +42800,9 @@ class ReadWindowCoveringNumberOfActuationsLift : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNumberOfActuationsLiftWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.NumberOfActuationsLift response %@", [value description]); if (error != nil) { @@ -43131,10 +42827,10 @@ class SubscribeAttributeWindowCoveringNumberOfActuationsLift : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -43174,9 +42870,9 @@ class ReadWindowCoveringNumberOfActuationsTilt : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNumberOfActuationsTiltWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.NumberOfActuationsTilt response %@", [value description]); if (error != nil) { @@ -43201,10 +42897,10 @@ class SubscribeAttributeWindowCoveringNumberOfActuationsTilt : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -43244,9 +42940,9 @@ class ReadWindowCoveringConfigStatus : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeConfigStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.ConfigStatus response %@", [value description]); if (error != nil) { @@ -43271,10 +42967,10 @@ class SubscribeAttributeWindowCoveringConfigStatus : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -43314,9 +43010,9 @@ class ReadWindowCoveringCurrentPositionLiftPercentage : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentPositionLiftPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.CurrentPositionLiftPercentage response %@", [value description]); if (error != nil) { @@ -43341,10 +43037,10 @@ class SubscribeAttributeWindowCoveringCurrentPositionLiftPercentage : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -43384,9 +43080,9 @@ class ReadWindowCoveringCurrentPositionTiltPercentage : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentPositionTiltPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.CurrentPositionTiltPercentage response %@", [value description]); if (error != nil) { @@ -43411,10 +43107,10 @@ class SubscribeAttributeWindowCoveringCurrentPositionTiltPercentage : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -43454,9 +43150,9 @@ class ReadWindowCoveringOperationalStatus : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.OperationalStatus response %@", [value description]); if (error != nil) { @@ -43481,10 +43177,10 @@ class SubscribeAttributeWindowCoveringOperationalStatus : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -43524,9 +43220,9 @@ class ReadWindowCoveringTargetPositionLiftPercent100ths : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTargetPositionLiftPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.TargetPositionLiftPercent100ths response %@", [value description]); @@ -43552,10 +43248,10 @@ class SubscribeAttributeWindowCoveringTargetPositionLiftPercent100ths : public S { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -43595,9 +43291,9 @@ class ReadWindowCoveringTargetPositionTiltPercent100ths : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTargetPositionTiltPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.TargetPositionTiltPercent100ths response %@", [value description]); @@ -43623,10 +43319,10 @@ class SubscribeAttributeWindowCoveringTargetPositionTiltPercent100ths : public S { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -43666,9 +43362,9 @@ class ReadWindowCoveringEndProductType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x0000000D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeEndProductTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.EndProductType response %@", [value description]); if (error != nil) { @@ -43693,10 +43389,10 @@ class SubscribeAttributeWindowCoveringEndProductType : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x0000000D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -43736,9 +43432,9 @@ class ReadWindowCoveringCurrentPositionLiftPercent100ths : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x0000000E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentPositionLiftPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.CurrentPositionLiftPercent100ths response %@", [value description]); @@ -43764,10 +43460,10 @@ class SubscribeAttributeWindowCoveringCurrentPositionLiftPercent100ths : public { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x0000000E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -43807,9 +43503,9 @@ class ReadWindowCoveringCurrentPositionTiltPercent100ths : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentPositionTiltPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.CurrentPositionTiltPercent100ths response %@", [value description]); @@ -43835,10 +43531,10 @@ class SubscribeAttributeWindowCoveringCurrentPositionTiltPercent100ths : public { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -43878,9 +43574,9 @@ class ReadWindowCoveringInstalledOpenLimitLift : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInstalledOpenLimitLiftWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.InstalledOpenLimitLift response %@", [value description]); if (error != nil) { @@ -43905,10 +43601,10 @@ class SubscribeAttributeWindowCoveringInstalledOpenLimitLift : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -43948,9 +43644,9 @@ class ReadWindowCoveringInstalledClosedLimitLift : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInstalledClosedLimitLiftWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.InstalledClosedLimitLift response %@", [value description]); if (error != nil) { @@ -43975,10 +43671,10 @@ class SubscribeAttributeWindowCoveringInstalledClosedLimitLift : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -44018,9 +43714,9 @@ class ReadWindowCoveringInstalledOpenLimitTilt : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInstalledOpenLimitTiltWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.InstalledOpenLimitTilt response %@", [value description]); if (error != nil) { @@ -44045,10 +43741,10 @@ class SubscribeAttributeWindowCoveringInstalledOpenLimitTilt : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -44088,9 +43784,9 @@ class ReadWindowCoveringInstalledClosedLimitTilt : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInstalledClosedLimitTiltWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.InstalledClosedLimitTilt response %@", [value description]); if (error != nil) { @@ -44115,10 +43811,10 @@ class SubscribeAttributeWindowCoveringInstalledClosedLimitTilt : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -44158,9 +43854,9 @@ class ReadWindowCoveringMode : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.Mode response %@", [value description]); if (error != nil) { @@ -44188,10 +43884,10 @@ class WriteWindowCoveringMode : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000102) WriteAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -44225,10 +43921,10 @@ class SubscribeAttributeWindowCoveringMode : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -44268,9 +43964,9 @@ class ReadWindowCoveringSafetyStatus : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSafetyStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.SafetyStatus response %@", [value description]); if (error != nil) { @@ -44295,10 +43991,10 @@ class SubscribeAttributeWindowCoveringSafetyStatus : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -44338,9 +44034,9 @@ class ReadWindowCoveringGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -44365,10 +44061,10 @@ class SubscribeAttributeWindowCoveringGeneratedCommandList : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -44408,9 +44104,9 @@ class ReadWindowCoveringAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -44435,10 +44131,10 @@ class SubscribeAttributeWindowCoveringAcceptedCommandList : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -44478,9 +44174,9 @@ class ReadWindowCoveringAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.AttributeList response %@", [value description]); if (error != nil) { @@ -44505,10 +44201,10 @@ class SubscribeAttributeWindowCoveringAttributeList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -44548,9 +44244,9 @@ class ReadWindowCoveringFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.FeatureMap response %@", [value description]); if (error != nil) { @@ -44575,10 +44271,10 @@ class SubscribeAttributeWindowCoveringFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -44618,9 +44314,9 @@ class ReadWindowCoveringClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"WindowCovering.ClusterRevision response %@", [value description]); if (error != nil) { @@ -44645,10 +44341,10 @@ class SubscribeAttributeWindowCoveringClusterRevision : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000102) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -44715,9 +44411,9 @@ class BarrierControlBarrierControlGoToPercent : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000103) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRBarrierControlClusterBarrierControlGoToPercentParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -44760,9 +44456,9 @@ class BarrierControlBarrierControlStop : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000103) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRBarrierControlClusterBarrierControlStopParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -44804,9 +44500,9 @@ class ReadBarrierControlBarrierMovingState : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBarrierMovingStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BarrierControl.BarrierMovingState response %@", [value description]); if (error != nil) { @@ -44831,10 +44527,10 @@ class SubscribeAttributeBarrierControlBarrierMovingState : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -44874,9 +44570,9 @@ class ReadBarrierControlBarrierSafetyStatus : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBarrierSafetyStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BarrierControl.BarrierSafetyStatus response %@", [value description]); if (error != nil) { @@ -44901,10 +44597,10 @@ class SubscribeAttributeBarrierControlBarrierSafetyStatus : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -44944,9 +44640,9 @@ class ReadBarrierControlBarrierCapabilities : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBarrierCapabilitiesWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BarrierControl.BarrierCapabilities response %@", [value description]); if (error != nil) { @@ -44971,10 +44667,10 @@ class SubscribeAttributeBarrierControlBarrierCapabilities : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -45014,9 +44710,9 @@ class ReadBarrierControlBarrierOpenEvents : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBarrierOpenEventsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BarrierControl.BarrierOpenEvents response %@", [value description]); if (error != nil) { @@ -45044,10 +44740,10 @@ class WriteBarrierControlBarrierOpenEvents : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000103) WriteAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -45081,10 +44777,10 @@ class SubscribeAttributeBarrierControlBarrierOpenEvents : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -45124,9 +44820,9 @@ class ReadBarrierControlBarrierCloseEvents : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBarrierCloseEventsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BarrierControl.BarrierCloseEvents response %@", [value description]); if (error != nil) { @@ -45154,10 +44850,10 @@ class WriteBarrierControlBarrierCloseEvents : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000103) WriteAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -45191,10 +44887,10 @@ class SubscribeAttributeBarrierControlBarrierCloseEvents : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -45234,9 +44930,9 @@ class ReadBarrierControlBarrierCommandOpenEvents : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBarrierCommandOpenEventsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BarrierControl.BarrierCommandOpenEvents response %@", [value description]); if (error != nil) { @@ -45264,10 +44960,10 @@ class WriteBarrierControlBarrierCommandOpenEvents : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000103) WriteAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -45302,10 +44998,10 @@ class SubscribeAttributeBarrierControlBarrierCommandOpenEvents : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -45345,9 +45041,9 @@ class ReadBarrierControlBarrierCommandCloseEvents : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBarrierCommandCloseEventsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BarrierControl.BarrierCommandCloseEvents response %@", [value description]); if (error != nil) { @@ -45375,10 +45071,10 @@ class WriteBarrierControlBarrierCommandCloseEvents : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000103) WriteAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -45413,10 +45109,10 @@ class SubscribeAttributeBarrierControlBarrierCommandCloseEvents : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -45456,9 +45152,9 @@ class ReadBarrierControlBarrierOpenPeriod : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReadAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBarrierOpenPeriodWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BarrierControl.BarrierOpenPeriod response %@", [value description]); if (error != nil) { @@ -45486,10 +45182,10 @@ class WriteBarrierControlBarrierOpenPeriod : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000103) WriteAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -45523,10 +45219,10 @@ class SubscribeAttributeBarrierControlBarrierOpenPeriod : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReportAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -45566,9 +45262,9 @@ class ReadBarrierControlBarrierClosePeriod : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReadAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBarrierClosePeriodWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BarrierControl.BarrierClosePeriod response %@", [value description]); if (error != nil) { @@ -45596,10 +45292,10 @@ class WriteBarrierControlBarrierClosePeriod : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000103) WriteAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -45633,10 +45329,10 @@ class SubscribeAttributeBarrierControlBarrierClosePeriod : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReportAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -45676,9 +45372,9 @@ class ReadBarrierControlBarrierPosition : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReadAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBarrierPositionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BarrierControl.BarrierPosition response %@", [value description]); if (error != nil) { @@ -45703,10 +45399,10 @@ class SubscribeAttributeBarrierControlBarrierPosition : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReportAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -45746,9 +45442,9 @@ class ReadBarrierControlGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"BarrierControl.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -45773,10 +45469,10 @@ class SubscribeAttributeBarrierControlGeneratedCommandList : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -45816,9 +45512,9 @@ class ReadBarrierControlAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"BarrierControl.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -45843,10 +45539,10 @@ class SubscribeAttributeBarrierControlAcceptedCommandList : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -45886,9 +45582,9 @@ class ReadBarrierControlAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"BarrierControl.AttributeList response %@", [value description]); if (error != nil) { @@ -45913,10 +45609,10 @@ class SubscribeAttributeBarrierControlAttributeList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -45956,9 +45652,9 @@ class ReadBarrierControlFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BarrierControl.FeatureMap response %@", [value description]); if (error != nil) { @@ -45983,10 +45679,10 @@ class SubscribeAttributeBarrierControlFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -46026,9 +45722,9 @@ class ReadBarrierControlClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BarrierControl.ClusterRevision response %@", [value description]); if (error != nil) { @@ -46053,10 +45749,10 @@ class SubscribeAttributeBarrierControlClusterRevision : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000103) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBarrierControl * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBarrierControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -46151,8 +45847,9 @@ class ReadPumpConfigurationAndControlMaxPressure : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxPressureWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.MaxPressure response %@", [value description]); if (error != nil) { @@ -46177,9 +45874,10 @@ class SubscribeAttributePumpConfigurationAndControlMaxPressure : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -46219,8 +45917,9 @@ class ReadPumpConfigurationAndControlMaxSpeed : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxSpeedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.MaxSpeed response %@", [value description]); if (error != nil) { @@ -46245,9 +45944,10 @@ class SubscribeAttributePumpConfigurationAndControlMaxSpeed : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -46287,8 +45987,9 @@ class ReadPumpConfigurationAndControlMaxFlow : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxFlowWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.MaxFlow response %@", [value description]); if (error != nil) { @@ -46313,9 +46014,10 @@ class SubscribeAttributePumpConfigurationAndControlMaxFlow : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -46355,8 +46057,9 @@ class ReadPumpConfigurationAndControlMinConstPressure : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinConstPressureWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.MinConstPressure response %@", [value description]); if (error != nil) { @@ -46381,9 +46084,10 @@ class SubscribeAttributePumpConfigurationAndControlMinConstPressure : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -46423,8 +46127,9 @@ class ReadPumpConfigurationAndControlMaxConstPressure : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxConstPressureWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.MaxConstPressure response %@", [value description]); if (error != nil) { @@ -46449,9 +46154,10 @@ class SubscribeAttributePumpConfigurationAndControlMaxConstPressure : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -46491,8 +46197,9 @@ class ReadPumpConfigurationAndControlMinCompPressure : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinCompPressureWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.MinCompPressure response %@", [value description]); if (error != nil) { @@ -46517,9 +46224,10 @@ class SubscribeAttributePumpConfigurationAndControlMinCompPressure : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -46559,8 +46267,9 @@ class ReadPumpConfigurationAndControlMaxCompPressure : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxCompPressureWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.MaxCompPressure response %@", [value description]); if (error != nil) { @@ -46585,9 +46294,10 @@ class SubscribeAttributePumpConfigurationAndControlMaxCompPressure : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -46627,8 +46337,9 @@ class ReadPumpConfigurationAndControlMinConstSpeed : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinConstSpeedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.MinConstSpeed response %@", [value description]); if (error != nil) { @@ -46653,9 +46364,10 @@ class SubscribeAttributePumpConfigurationAndControlMinConstSpeed : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -46695,8 +46407,9 @@ class ReadPumpConfigurationAndControlMaxConstSpeed : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxConstSpeedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.MaxConstSpeed response %@", [value description]); if (error != nil) { @@ -46721,9 +46434,10 @@ class SubscribeAttributePumpConfigurationAndControlMaxConstSpeed : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -46763,8 +46477,9 @@ class ReadPumpConfigurationAndControlMinConstFlow : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinConstFlowWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.MinConstFlow response %@", [value description]); if (error != nil) { @@ -46789,9 +46504,10 @@ class SubscribeAttributePumpConfigurationAndControlMinConstFlow : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -46831,8 +46547,9 @@ class ReadPumpConfigurationAndControlMaxConstFlow : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxConstFlowWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.MaxConstFlow response %@", [value description]); if (error != nil) { @@ -46857,9 +46574,10 @@ class SubscribeAttributePumpConfigurationAndControlMaxConstFlow : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -46899,8 +46617,9 @@ class ReadPumpConfigurationAndControlMinConstTemp : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinConstTempWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.MinConstTemp response %@", [value description]); if (error != nil) { @@ -46925,9 +46644,10 @@ class SubscribeAttributePumpConfigurationAndControlMinConstTemp : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -46967,8 +46687,9 @@ class ReadPumpConfigurationAndControlMaxConstTemp : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxConstTempWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.MaxConstTemp response %@", [value description]); if (error != nil) { @@ -46993,9 +46714,10 @@ class SubscribeAttributePumpConfigurationAndControlMaxConstTemp : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -47035,8 +46757,9 @@ class ReadPumpConfigurationAndControlPumpStatus : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePumpStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.PumpStatus response %@", [value description]); if (error != nil) { @@ -47061,9 +46784,10 @@ class SubscribeAttributePumpConfigurationAndControlPumpStatus : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -47103,8 +46827,9 @@ class ReadPumpConfigurationAndControlEffectiveOperationMode : public ReadAttribu ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeEffectiveOperationModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.EffectiveOperationMode response %@", [value description]); if (error != nil) { @@ -47129,9 +46854,10 @@ class SubscribeAttributePumpConfigurationAndControlEffectiveOperationMode : publ { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -47171,8 +46897,9 @@ class ReadPumpConfigurationAndControlEffectiveControlMode : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeEffectiveControlModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.EffectiveControlMode response %@", [value description]); if (error != nil) { @@ -47197,9 +46924,10 @@ class SubscribeAttributePumpConfigurationAndControlEffectiveControlMode : public { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -47239,8 +46967,9 @@ class ReadPumpConfigurationAndControlCapacity : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCapacityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.Capacity response %@", [value description]); if (error != nil) { @@ -47265,9 +46994,10 @@ class SubscribeAttributePumpConfigurationAndControlCapacity : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -47307,8 +47037,9 @@ class ReadPumpConfigurationAndControlSpeed : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSpeedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.Speed response %@", [value description]); if (error != nil) { @@ -47333,9 +47064,10 @@ class SubscribeAttributePumpConfigurationAndControlSpeed : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -47375,8 +47107,9 @@ class ReadPumpConfigurationAndControlLifetimeRunningHours : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLifetimeRunningHoursWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.LifetimeRunningHours response %@", [value description]); if (error != nil) { @@ -47404,9 +47137,10 @@ class WritePumpConfigurationAndControlLifetimeRunningHours : public WriteAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000200) WriteAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -47441,9 +47175,10 @@ class SubscribeAttributePumpConfigurationAndControlLifetimeRunningHours : public { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -47483,8 +47218,9 @@ class ReadPumpConfigurationAndControlPower : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePowerWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.Power response %@", [value description]); if (error != nil) { @@ -47509,9 +47245,10 @@ class SubscribeAttributePumpConfigurationAndControlPower : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -47551,8 +47288,9 @@ class ReadPumpConfigurationAndControlLifetimeEnergyConsumed : public ReadAttribu ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLifetimeEnergyConsumedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.LifetimeEnergyConsumed response %@", [value description]); if (error != nil) { @@ -47580,9 +47318,10 @@ class WritePumpConfigurationAndControlLifetimeEnergyConsumed : public WriteAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000200) WriteAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -47618,9 +47357,10 @@ class SubscribeAttributePumpConfigurationAndControlLifetimeEnergyConsumed : publ { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -47660,8 +47400,9 @@ class ReadPumpConfigurationAndControlOperationMode : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOperationModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.OperationMode response %@", [value description]); if (error != nil) { @@ -47689,9 +47430,10 @@ class WritePumpConfigurationAndControlOperationMode : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000200) WriteAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -47725,9 +47467,10 @@ class SubscribeAttributePumpConfigurationAndControlOperationMode : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -47767,8 +47510,9 @@ class ReadPumpConfigurationAndControlControlMode : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeControlModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.ControlMode response %@", [value description]); if (error != nil) { @@ -47796,9 +47540,10 @@ class WritePumpConfigurationAndControlControlMode : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000200) WriteAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -47832,9 +47577,10 @@ class SubscribeAttributePumpConfigurationAndControlControlMode : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -47874,8 +47620,9 @@ class ReadPumpConfigurationAndControlGeneratedCommandList : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -47900,9 +47647,10 @@ class SubscribeAttributePumpConfigurationAndControlGeneratedCommandList : public { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -47942,8 +47690,9 @@ class ReadPumpConfigurationAndControlAcceptedCommandList : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -47968,9 +47717,10 @@ class SubscribeAttributePumpConfigurationAndControlAcceptedCommandList : public { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -48010,8 +47760,9 @@ class ReadPumpConfigurationAndControlAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.AttributeList response %@", [value description]); if (error != nil) { @@ -48036,9 +47787,10 @@ class SubscribeAttributePumpConfigurationAndControlAttributeList : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -48078,8 +47830,9 @@ class ReadPumpConfigurationAndControlFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.FeatureMap response %@", [value description]); if (error != nil) { @@ -48104,9 +47857,10 @@ class SubscribeAttributePumpConfigurationAndControlFeatureMap : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -48146,8 +47900,9 @@ class ReadPumpConfigurationAndControlClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PumpConfigurationAndControl.ClusterRevision response %@", [value description]); if (error != nil) { @@ -48172,9 +47927,10 @@ class SubscribeAttributePumpConfigurationAndControlClusterRevision : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000200) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -48283,9 +48039,9 @@ class ThermostatSetpointRaiseLower : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000201) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRThermostatClusterSetpointRaiseLowerParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -48334,9 +48090,9 @@ class ThermostatSetWeeklySchedule : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000201) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRThermostatClusterSetWeeklyScheduleParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -48406,9 +48162,9 @@ class ThermostatGetWeeklySchedule : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000201) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRThermostatClusterGetWeeklyScheduleParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -48454,9 +48210,9 @@ class ThermostatClearWeeklySchedule : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000201) command (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRThermostatClusterClearWeeklyScheduleParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -48498,9 +48254,9 @@ class ReadThermostatLocalTemperature : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLocalTemperatureWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.LocalTemperature response %@", [value description]); if (error != nil) { @@ -48525,10 +48281,10 @@ class SubscribeAttributeThermostatLocalTemperature : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -48568,9 +48324,9 @@ class ReadThermostatOutdoorTemperature : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOutdoorTemperatureWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.OutdoorTemperature response %@", [value description]); if (error != nil) { @@ -48595,10 +48351,10 @@ class SubscribeAttributeThermostatOutdoorTemperature : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -48638,9 +48394,9 @@ class ReadThermostatOccupancy : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOccupancyWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.Occupancy response %@", [value description]); if (error != nil) { @@ -48665,10 +48421,10 @@ class SubscribeAttributeThermostatOccupancy : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -48708,9 +48464,9 @@ class ReadThermostatAbsMinHeatSetpointLimit : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAbsMinHeatSetpointLimitWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.AbsMinHeatSetpointLimit response %@", [value description]); if (error != nil) { @@ -48735,10 +48491,10 @@ class SubscribeAttributeThermostatAbsMinHeatSetpointLimit : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -48778,9 +48534,9 @@ class ReadThermostatAbsMaxHeatSetpointLimit : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAbsMaxHeatSetpointLimitWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.AbsMaxHeatSetpointLimit response %@", [value description]); if (error != nil) { @@ -48805,10 +48561,10 @@ class SubscribeAttributeThermostatAbsMaxHeatSetpointLimit : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -48848,9 +48604,9 @@ class ReadThermostatAbsMinCoolSetpointLimit : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAbsMinCoolSetpointLimitWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.AbsMinCoolSetpointLimit response %@", [value description]); if (error != nil) { @@ -48875,10 +48631,10 @@ class SubscribeAttributeThermostatAbsMinCoolSetpointLimit : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -48918,9 +48674,9 @@ class ReadThermostatAbsMaxCoolSetpointLimit : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAbsMaxCoolSetpointLimitWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.AbsMaxCoolSetpointLimit response %@", [value description]); if (error != nil) { @@ -48945,10 +48701,10 @@ class SubscribeAttributeThermostatAbsMaxCoolSetpointLimit : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -48988,9 +48744,9 @@ class ReadThermostatPICoolingDemand : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePICoolingDemandWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.PICoolingDemand response %@", [value description]); if (error != nil) { @@ -49015,10 +48771,10 @@ class SubscribeAttributeThermostatPICoolingDemand : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -49058,9 +48814,9 @@ class ReadThermostatPIHeatingDemand : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePIHeatingDemandWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.PIHeatingDemand response %@", [value description]); if (error != nil) { @@ -49085,10 +48841,10 @@ class SubscribeAttributeThermostatPIHeatingDemand : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -49128,9 +48884,9 @@ class ReadThermostatHVACSystemTypeConfiguration : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeHVACSystemTypeConfigurationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.HVACSystemTypeConfiguration response %@", [value description]); if (error != nil) { @@ -49158,10 +48914,10 @@ class WriteThermostatHVACSystemTypeConfiguration : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -49196,10 +48952,10 @@ class SubscribeAttributeThermostatHVACSystemTypeConfiguration : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -49239,9 +48995,9 @@ class ReadThermostatLocalTemperatureCalibration : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLocalTemperatureCalibrationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.LocalTemperatureCalibration response %@", [value description]); if (error != nil) { @@ -49269,10 +49025,10 @@ class WriteThermostatLocalTemperatureCalibration : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -49307,10 +49063,10 @@ class SubscribeAttributeThermostatLocalTemperatureCalibration : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -49350,9 +49106,9 @@ class ReadThermostatOccupiedCoolingSetpoint : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOccupiedCoolingSetpointWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.OccupiedCoolingSetpoint response %@", [value description]); if (error != nil) { @@ -49380,10 +49136,10 @@ class WriteThermostatOccupiedCoolingSetpoint : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -49417,10 +49173,10 @@ class SubscribeAttributeThermostatOccupiedCoolingSetpoint : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -49460,9 +49216,9 @@ class ReadThermostatOccupiedHeatingSetpoint : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOccupiedHeatingSetpointWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.OccupiedHeatingSetpoint response %@", [value description]); if (error != nil) { @@ -49490,10 +49246,10 @@ class WriteThermostatOccupiedHeatingSetpoint : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -49527,10 +49283,10 @@ class SubscribeAttributeThermostatOccupiedHeatingSetpoint : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -49570,9 +49326,9 @@ class ReadThermostatUnoccupiedCoolingSetpoint : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeUnoccupiedCoolingSetpointWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.UnoccupiedCoolingSetpoint response %@", [value description]); if (error != nil) { @@ -49600,10 +49356,10 @@ class WriteThermostatUnoccupiedCoolingSetpoint : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -49638,10 +49394,10 @@ class SubscribeAttributeThermostatUnoccupiedCoolingSetpoint : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -49681,9 +49437,9 @@ class ReadThermostatUnoccupiedHeatingSetpoint : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeUnoccupiedHeatingSetpointWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.UnoccupiedHeatingSetpoint response %@", [value description]); if (error != nil) { @@ -49711,10 +49467,10 @@ class WriteThermostatUnoccupiedHeatingSetpoint : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -49749,10 +49505,10 @@ class SubscribeAttributeThermostatUnoccupiedHeatingSetpoint : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -49792,9 +49548,9 @@ class ReadThermostatMinHeatSetpointLimit : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinHeatSetpointLimitWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.MinHeatSetpointLimit response %@", [value description]); if (error != nil) { @@ -49822,10 +49578,10 @@ class WriteThermostatMinHeatSetpointLimit : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -49859,10 +49615,10 @@ class SubscribeAttributeThermostatMinHeatSetpointLimit : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -49902,9 +49658,9 @@ class ReadThermostatMaxHeatSetpointLimit : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxHeatSetpointLimitWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.MaxHeatSetpointLimit response %@", [value description]); if (error != nil) { @@ -49932,10 +49688,10 @@ class WriteThermostatMaxHeatSetpointLimit : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -49969,10 +49725,10 @@ class SubscribeAttributeThermostatMaxHeatSetpointLimit : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -50012,9 +49768,9 @@ class ReadThermostatMinCoolSetpointLimit : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinCoolSetpointLimitWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.MinCoolSetpointLimit response %@", [value description]); if (error != nil) { @@ -50042,10 +49798,10 @@ class WriteThermostatMinCoolSetpointLimit : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -50079,10 +49835,10 @@ class SubscribeAttributeThermostatMinCoolSetpointLimit : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -50122,9 +49878,9 @@ class ReadThermostatMaxCoolSetpointLimit : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000018) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxCoolSetpointLimitWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.MaxCoolSetpointLimit response %@", [value description]); if (error != nil) { @@ -50152,10 +49908,10 @@ class WriteThermostatMaxCoolSetpointLimit : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000018) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -50189,10 +49945,10 @@ class SubscribeAttributeThermostatMaxCoolSetpointLimit : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000018) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -50232,9 +49988,9 @@ class ReadThermostatMinSetpointDeadBand : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinSetpointDeadBandWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.MinSetpointDeadBand response %@", [value description]); if (error != nil) { @@ -50262,10 +50018,10 @@ class WriteThermostatMinSetpointDeadBand : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -50299,10 +50055,10 @@ class SubscribeAttributeThermostatMinSetpointDeadBand : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -50342,9 +50098,9 @@ class ReadThermostatRemoteSensing : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRemoteSensingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.RemoteSensing response %@", [value description]); if (error != nil) { @@ -50372,10 +50128,10 @@ class WriteThermostatRemoteSensing : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -50409,10 +50165,10 @@ class SubscribeAttributeThermostatRemoteSensing : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -50452,9 +50208,9 @@ class ReadThermostatControlSequenceOfOperation : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x0000001B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeControlSequenceOfOperationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.ControlSequenceOfOperation response %@", [value description]); if (error != nil) { @@ -50482,10 +50238,10 @@ class WriteThermostatControlSequenceOfOperation : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x0000001B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -50520,10 +50276,10 @@ class SubscribeAttributeThermostatControlSequenceOfOperation : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x0000001B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -50563,9 +50319,9 @@ class ReadThermostatSystemMode : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x0000001C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSystemModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.SystemMode response %@", [value description]); if (error != nil) { @@ -50593,10 +50349,10 @@ class WriteThermostatSystemMode : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x0000001C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -50630,10 +50386,10 @@ class SubscribeAttributeThermostatSystemMode : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x0000001C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -50673,9 +50429,9 @@ class ReadThermostatThermostatRunningMode : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x0000001E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeThermostatRunningModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.ThermostatRunningMode response %@", [value description]); if (error != nil) { @@ -50700,10 +50456,10 @@ class SubscribeAttributeThermostatThermostatRunningMode : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x0000001E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -50743,9 +50499,9 @@ class ReadThermostatStartOfWeek : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeStartOfWeekWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.StartOfWeek response %@", [value description]); if (error != nil) { @@ -50770,10 +50526,10 @@ class SubscribeAttributeThermostatStartOfWeek : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -50813,9 +50569,9 @@ class ReadThermostatNumberOfWeeklyTransitions : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNumberOfWeeklyTransitionsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.NumberOfWeeklyTransitions response %@", [value description]); if (error != nil) { @@ -50840,10 +50596,10 @@ class SubscribeAttributeThermostatNumberOfWeeklyTransitions : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -50883,9 +50639,9 @@ class ReadThermostatNumberOfDailyTransitions : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNumberOfDailyTransitionsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.NumberOfDailyTransitions response %@", [value description]); if (error != nil) { @@ -50910,10 +50666,10 @@ class SubscribeAttributeThermostatNumberOfDailyTransitions : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -50953,9 +50709,9 @@ class ReadThermostatTemperatureSetpointHold : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000023) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTemperatureSetpointHoldWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.TemperatureSetpointHold response %@", [value description]); if (error != nil) { @@ -50983,10 +50739,10 @@ class WriteThermostatTemperatureSetpointHold : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000023) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -51020,10 +50776,10 @@ class SubscribeAttributeThermostatTemperatureSetpointHold : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000023) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -51063,9 +50819,9 @@ class ReadThermostatTemperatureSetpointHoldDuration : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTemperatureSetpointHoldDurationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.TemperatureSetpointHoldDuration response %@", [value description]); @@ -51094,10 +50850,10 @@ class WriteThermostatTemperatureSetpointHoldDuration : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -51133,10 +50889,10 @@ class SubscribeAttributeThermostatTemperatureSetpointHoldDuration : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -51176,9 +50932,9 @@ class ReadThermostatThermostatProgrammingOperationMode : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeThermostatProgrammingOperationModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.ThermostatProgrammingOperationMode response %@", [value description]); @@ -51207,10 +50963,10 @@ class WriteThermostatThermostatProgrammingOperationMode : public WriteAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -51247,10 +51003,10 @@ class SubscribeAttributeThermostatThermostatProgrammingOperationMode : public Su { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -51290,9 +51046,9 @@ class ReadThermostatThermostatRunningState : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000029) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeThermostatRunningStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.ThermostatRunningState response %@", [value description]); if (error != nil) { @@ -51317,10 +51073,10 @@ class SubscribeAttributeThermostatThermostatRunningState : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000029) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -51360,9 +51116,9 @@ class ReadThermostatSetpointChangeSource : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSetpointChangeSourceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.SetpointChangeSource response %@", [value description]); if (error != nil) { @@ -51387,10 +51143,10 @@ class SubscribeAttributeThermostatSetpointChangeSource : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -51430,9 +51186,9 @@ class ReadThermostatSetpointChangeAmount : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSetpointChangeAmountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.SetpointChangeAmount response %@", [value description]); if (error != nil) { @@ -51457,10 +51213,10 @@ class SubscribeAttributeThermostatSetpointChangeAmount : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -51500,9 +51256,9 @@ class ReadThermostatSetpointChangeSourceTimestamp : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSetpointChangeSourceTimestampWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.SetpointChangeSourceTimestamp response %@", [value description]); if (error != nil) { @@ -51527,10 +51283,10 @@ class SubscribeAttributeThermostatSetpointChangeSourceTimestamp : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -51570,9 +51326,9 @@ class ReadThermostatOccupiedSetback : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000034) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOccupiedSetbackWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.OccupiedSetback response %@", [value description]); if (error != nil) { @@ -51600,10 +51356,10 @@ class WriteThermostatOccupiedSetback : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000034) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -51637,10 +51393,10 @@ class SubscribeAttributeThermostatOccupiedSetback : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000034) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -51680,9 +51436,9 @@ class ReadThermostatOccupiedSetbackMin : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000035) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOccupiedSetbackMinWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.OccupiedSetbackMin response %@", [value description]); if (error != nil) { @@ -51707,10 +51463,10 @@ class SubscribeAttributeThermostatOccupiedSetbackMin : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000035) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -51750,9 +51506,9 @@ class ReadThermostatOccupiedSetbackMax : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000036) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOccupiedSetbackMaxWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.OccupiedSetbackMax response %@", [value description]); if (error != nil) { @@ -51777,10 +51533,10 @@ class SubscribeAttributeThermostatOccupiedSetbackMax : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000036) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -51820,9 +51576,9 @@ class ReadThermostatUnoccupiedSetback : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000037) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeUnoccupiedSetbackWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.UnoccupiedSetback response %@", [value description]); if (error != nil) { @@ -51850,10 +51606,10 @@ class WriteThermostatUnoccupiedSetback : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000037) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -51887,10 +51643,10 @@ class SubscribeAttributeThermostatUnoccupiedSetback : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000037) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -51930,9 +51686,9 @@ class ReadThermostatUnoccupiedSetbackMin : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000038) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeUnoccupiedSetbackMinWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.UnoccupiedSetbackMin response %@", [value description]); if (error != nil) { @@ -51957,10 +51713,10 @@ class SubscribeAttributeThermostatUnoccupiedSetbackMin : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000038) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -52000,9 +51756,9 @@ class ReadThermostatUnoccupiedSetbackMax : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000039) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeUnoccupiedSetbackMaxWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.UnoccupiedSetbackMax response %@", [value description]); if (error != nil) { @@ -52027,10 +51783,10 @@ class SubscribeAttributeThermostatUnoccupiedSetbackMax : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000039) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -52070,9 +51826,9 @@ class ReadThermostatEmergencyHeatDelta : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x0000003A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeEmergencyHeatDeltaWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.EmergencyHeatDelta response %@", [value description]); if (error != nil) { @@ -52100,10 +51856,10 @@ class WriteThermostatEmergencyHeatDelta : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x0000003A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -52137,10 +51893,10 @@ class SubscribeAttributeThermostatEmergencyHeatDelta : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x0000003A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -52180,9 +51936,9 @@ class ReadThermostatACType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000040) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeACTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.ACType response %@", [value description]); if (error != nil) { @@ -52210,10 +51966,10 @@ class WriteThermostatACType : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000040) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -52247,10 +52003,10 @@ class SubscribeAttributeThermostatACType : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000040) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -52290,9 +52046,9 @@ class ReadThermostatACCapacity : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000041) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeACCapacityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.ACCapacity response %@", [value description]); if (error != nil) { @@ -52320,10 +52076,10 @@ class WriteThermostatACCapacity : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000041) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -52357,10 +52113,10 @@ class SubscribeAttributeThermostatACCapacity : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000041) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -52400,9 +52156,9 @@ class ReadThermostatACRefrigerantType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000042) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeACRefrigerantTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.ACRefrigerantType response %@", [value description]); if (error != nil) { @@ -52430,10 +52186,10 @@ class WriteThermostatACRefrigerantType : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000042) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -52467,10 +52223,10 @@ class SubscribeAttributeThermostatACRefrigerantType : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000042) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -52510,9 +52266,9 @@ class ReadThermostatACCompressorType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000043) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeACCompressorTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.ACCompressorType response %@", [value description]); if (error != nil) { @@ -52540,10 +52296,10 @@ class WriteThermostatACCompressorType : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000043) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -52577,10 +52333,10 @@ class SubscribeAttributeThermostatACCompressorType : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000043) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -52620,9 +52376,9 @@ class ReadThermostatACErrorCode : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000044) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeACErrorCodeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.ACErrorCode response %@", [value description]); if (error != nil) { @@ -52650,10 +52406,10 @@ class WriteThermostatACErrorCode : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000044) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -52687,10 +52443,10 @@ class SubscribeAttributeThermostatACErrorCode : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000044) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -52730,9 +52486,9 @@ class ReadThermostatACLouverPosition : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000045) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeACLouverPositionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.ACLouverPosition response %@", [value description]); if (error != nil) { @@ -52760,10 +52516,10 @@ class WriteThermostatACLouverPosition : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000045) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -52797,10 +52553,10 @@ class SubscribeAttributeThermostatACLouverPosition : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000045) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -52840,9 +52596,9 @@ class ReadThermostatACCoilTemperature : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000046) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeACCoilTemperatureWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.ACCoilTemperature response %@", [value description]); if (error != nil) { @@ -52867,10 +52623,10 @@ class SubscribeAttributeThermostatACCoilTemperature : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000046) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -52910,9 +52666,9 @@ class ReadThermostatACCapacityformat : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x00000047) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeACCapacityformatWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.ACCapacityformat response %@", [value description]); if (error != nil) { @@ -52940,10 +52696,10 @@ class WriteThermostatACCapacityformat : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) WriteAttribute (0x00000047) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -52977,10 +52733,10 @@ class SubscribeAttributeThermostatACCapacityformat : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x00000047) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -53020,9 +52776,9 @@ class ReadThermostatGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -53047,10 +52803,10 @@ class SubscribeAttributeThermostatGeneratedCommandList : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -53090,9 +52846,9 @@ class ReadThermostatAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -53117,10 +52873,10 @@ class SubscribeAttributeThermostatAcceptedCommandList : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -53160,9 +52916,9 @@ class ReadThermostatAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.AttributeList response %@", [value description]); if (error != nil) { @@ -53187,10 +52943,10 @@ class SubscribeAttributeThermostatAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -53230,9 +52986,9 @@ class ReadThermostatFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.FeatureMap response %@", [value description]); if (error != nil) { @@ -53257,10 +53013,10 @@ class SubscribeAttributeThermostatFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -53300,9 +53056,9 @@ class ReadThermostatClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Thermostat.ClusterRevision response %@", [value description]); if (error != nil) { @@ -53327,10 +53083,10 @@ class SubscribeAttributeThermostatClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000201) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -53396,9 +53152,9 @@ class ReadFanControlFanMode : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFanModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.FanMode response %@", [value description]); if (error != nil) { @@ -53426,10 +53182,10 @@ class WriteFanControlFanMode : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) WriteAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -53463,10 +53219,10 @@ class SubscribeAttributeFanControlFanMode : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -53506,9 +53262,9 @@ class ReadFanControlFanModeSequence : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFanModeSequenceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.FanModeSequence response %@", [value description]); if (error != nil) { @@ -53536,10 +53292,10 @@ class WriteFanControlFanModeSequence : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) WriteAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -53573,10 +53329,10 @@ class SubscribeAttributeFanControlFanModeSequence : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -53616,9 +53372,9 @@ class ReadFanControlPercentSetting : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePercentSettingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.PercentSetting response %@", [value description]); if (error != nil) { @@ -53646,10 +53402,10 @@ class WriteFanControlPercentSetting : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) WriteAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -53683,10 +53439,10 @@ class SubscribeAttributeFanControlPercentSetting : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -53726,9 +53482,9 @@ class ReadFanControlPercentCurrent : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePercentCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.PercentCurrent response %@", [value description]); if (error != nil) { @@ -53753,10 +53509,10 @@ class SubscribeAttributeFanControlPercentCurrent : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -53796,9 +53552,9 @@ class ReadFanControlSpeedMax : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSpeedMaxWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.SpeedMax response %@", [value description]); if (error != nil) { @@ -53823,10 +53579,10 @@ class SubscribeAttributeFanControlSpeedMax : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -53866,9 +53622,9 @@ class ReadFanControlSpeedSetting : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSpeedSettingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.SpeedSetting response %@", [value description]); if (error != nil) { @@ -53896,10 +53652,10 @@ class WriteFanControlSpeedSetting : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) WriteAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -53933,10 +53689,10 @@ class SubscribeAttributeFanControlSpeedSetting : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -53976,9 +53732,9 @@ class ReadFanControlSpeedCurrent : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSpeedCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.SpeedCurrent response %@", [value description]); if (error != nil) { @@ -54003,10 +53759,10 @@ class SubscribeAttributeFanControlSpeedCurrent : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -54046,9 +53802,9 @@ class ReadFanControlRockSupport : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRockSupportWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.RockSupport response %@", [value description]); if (error != nil) { @@ -54073,10 +53829,10 @@ class SubscribeAttributeFanControlRockSupport : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -54116,9 +53872,9 @@ class ReadFanControlRockSetting : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRockSettingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.RockSetting response %@", [value description]); if (error != nil) { @@ -54146,10 +53902,10 @@ class WriteFanControlRockSetting : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) WriteAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -54183,10 +53939,10 @@ class SubscribeAttributeFanControlRockSetting : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -54226,9 +53982,9 @@ class ReadFanControlWindSupport : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeWindSupportWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.WindSupport response %@", [value description]); if (error != nil) { @@ -54253,10 +54009,10 @@ class SubscribeAttributeFanControlWindSupport : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -54296,9 +54052,9 @@ class ReadFanControlWindSetting : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeWindSettingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.WindSetting response %@", [value description]); if (error != nil) { @@ -54326,10 +54082,10 @@ class WriteFanControlWindSetting : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) WriteAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -54363,10 +54119,10 @@ class SubscribeAttributeFanControlWindSetting : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -54406,9 +54162,9 @@ class ReadFanControlGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -54433,10 +54189,10 @@ class SubscribeAttributeFanControlGeneratedCommandList : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -54476,9 +54232,9 @@ class ReadFanControlAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -54503,10 +54259,10 @@ class SubscribeAttributeFanControlAcceptedCommandList : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -54546,9 +54302,9 @@ class ReadFanControlAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.AttributeList response %@", [value description]); if (error != nil) { @@ -54573,10 +54329,10 @@ class SubscribeAttributeFanControlAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -54616,9 +54372,9 @@ class ReadFanControlFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.FeatureMap response %@", [value description]); if (error != nil) { @@ -54643,10 +54399,10 @@ class SubscribeAttributeFanControlFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -54686,9 +54442,9 @@ class ReadFanControlClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FanControl.ClusterRevision response %@", [value description]); if (error != nil) { @@ -54713,10 +54469,10 @@ class SubscribeAttributeFanControlClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000202) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -54774,10 +54530,9 @@ class ReadThermostatUserInterfaceConfigurationTemperatureDisplayMode : public Re ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTemperatureDisplayModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThermostatUserInterfaceConfiguration.TemperatureDisplayMode response %@", [value description]); if (error != nil) { @@ -54805,11 +54560,10 @@ class WriteThermostatUserInterfaceConfigurationTemperatureDisplayMode : public W { ChipLogProgress(chipTool, "Sending cluster (0x00000204) WriteAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -54845,11 +54599,10 @@ class SubscribeAttributeThermostatUserInterfaceConfigurationTemperatureDisplayMo { ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -54889,10 +54642,9 @@ class ReadThermostatUserInterfaceConfigurationKeypadLockout : public ReadAttribu ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeKeypadLockoutWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThermostatUserInterfaceConfiguration.KeypadLockout response %@", [value description]); if (error != nil) { @@ -54920,11 +54672,10 @@ class WriteThermostatUserInterfaceConfigurationKeypadLockout : public WriteAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000204) WriteAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -54959,11 +54710,10 @@ class SubscribeAttributeThermostatUserInterfaceConfigurationKeypadLockout : publ { ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -55003,10 +54753,9 @@ class ReadThermostatUserInterfaceConfigurationScheduleProgrammingVisibility : pu ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeScheduleProgrammingVisibilityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThermostatUserInterfaceConfiguration.ScheduleProgrammingVisibility response %@", [value description]); if (error != nil) { @@ -55034,11 +54783,10 @@ class WriteThermostatUserInterfaceConfigurationScheduleProgrammingVisibility : p { ChipLogProgress(chipTool, "Sending cluster (0x00000204) WriteAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -55074,11 +54822,10 @@ class SubscribeAttributeThermostatUserInterfaceConfigurationScheduleProgrammingV { ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -55118,10 +54865,9 @@ class ReadThermostatUserInterfaceConfigurationGeneratedCommandList : public Read ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ThermostatUserInterfaceConfiguration.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -55146,11 +54892,10 @@ class SubscribeAttributeThermostatUserInterfaceConfigurationGeneratedCommandList { ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -55190,10 +54935,9 @@ class ReadThermostatUserInterfaceConfigurationAcceptedCommandList : public ReadA ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ThermostatUserInterfaceConfiguration.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -55218,11 +54962,10 @@ class SubscribeAttributeThermostatUserInterfaceConfigurationAcceptedCommandList { ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -55262,10 +55005,9 @@ class ReadThermostatUserInterfaceConfigurationAttributeList : public ReadAttribu ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ThermostatUserInterfaceConfiguration.AttributeList response %@", [value description]); if (error != nil) { @@ -55290,11 +55032,10 @@ class SubscribeAttributeThermostatUserInterfaceConfigurationAttributeList : publ { ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -55334,10 +55075,9 @@ class ReadThermostatUserInterfaceConfigurationFeatureMap : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThermostatUserInterfaceConfiguration.FeatureMap response %@", [value description]); if (error != nil) { @@ -55362,11 +55102,10 @@ class SubscribeAttributeThermostatUserInterfaceConfigurationFeatureMap : public { ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -55406,10 +55145,9 @@ class ReadThermostatUserInterfaceConfigurationClusterRevision : public ReadAttri ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ThermostatUserInterfaceConfiguration.ClusterRevision response %@", [value description]); if (error != nil) { @@ -55434,11 +55172,10 @@ class SubscribeAttributeThermostatUserInterfaceConfigurationClusterRevision : pu { ChipLogProgress(chipTool, "Sending cluster (0x00000204) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -55568,9 +55305,9 @@ class ColorControlMoveToHue : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterMoveToHueParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -55621,9 +55358,9 @@ class ColorControlMoveHue : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterMoveHueParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -55674,9 +55411,9 @@ class ColorControlStepHue : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterStepHueParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -55727,9 +55464,9 @@ class ColorControlMoveToSaturation : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterMoveToSaturationParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -55779,9 +55516,9 @@ class ColorControlMoveSaturation : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterMoveSaturationParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -55832,9 +55569,9 @@ class ColorControlStepSaturation : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterStepSaturationParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -55886,9 +55623,9 @@ class ColorControlMoveToHueAndSaturation : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterMoveToHueAndSaturationParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -55940,9 +55677,9 @@ class ColorControlMoveToColor : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterMoveToColorParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -55993,9 +55730,9 @@ class ColorControlMoveColor : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterMoveColorParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -56046,9 +55783,9 @@ class ColorControlStepColor : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterStepColorParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -56099,9 +55836,9 @@ class ColorControlMoveToColorTemperature : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterMoveToColorTemperatureParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -56152,9 +55889,9 @@ class ColorControlEnhancedMoveToHue : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000040) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterEnhancedMoveToHueParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -56205,9 +55942,9 @@ class ColorControlEnhancedMoveHue : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000041) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterEnhancedMoveHueParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -56258,9 +55995,9 @@ class ColorControlEnhancedStepHue : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000042) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterEnhancedStepHueParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -56312,9 +56049,9 @@ class ColorControlEnhancedMoveToHueAndSaturation : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000043) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterEnhancedMoveToHueAndSaturationParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -56368,9 +56105,9 @@ class ColorControlColorLoopSet : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000044) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterColorLoopSetParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -56421,9 +56158,9 @@ class ColorControlStopMoveStep : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x00000047) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterStopMoveStepParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -56473,9 +56210,9 @@ class ColorControlMoveColorTemperature : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x0000004B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterMoveColorTemperatureParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -56530,9 +56267,9 @@ class ColorControlStepColorTemperature : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000300) command (0x0000004C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRColorControlClusterStepColorTemperatureParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -56582,9 +56319,9 @@ class ReadColorControlCurrentHue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.CurrentHue response %@", [value description]); if (error != nil) { @@ -56609,10 +56346,10 @@ class SubscribeAttributeColorControlCurrentHue : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -56652,9 +56389,9 @@ class ReadColorControlCurrentSaturation : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.CurrentSaturation response %@", [value description]); if (error != nil) { @@ -56679,10 +56416,10 @@ class SubscribeAttributeColorControlCurrentSaturation : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -56722,9 +56459,9 @@ class ReadColorControlRemainingTime : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRemainingTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.RemainingTime response %@", [value description]); if (error != nil) { @@ -56749,10 +56486,10 @@ class SubscribeAttributeColorControlRemainingTime : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -56792,9 +56529,9 @@ class ReadColorControlCurrentX : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.CurrentX response %@", [value description]); if (error != nil) { @@ -56819,10 +56556,10 @@ class SubscribeAttributeColorControlCurrentX : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -56862,9 +56599,9 @@ class ReadColorControlCurrentY : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.CurrentY response %@", [value description]); if (error != nil) { @@ -56889,10 +56626,10 @@ class SubscribeAttributeColorControlCurrentY : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -56932,9 +56669,9 @@ class ReadColorControlDriftCompensation : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDriftCompensationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.DriftCompensation response %@", [value description]); if (error != nil) { @@ -56959,10 +56696,10 @@ class SubscribeAttributeColorControlDriftCompensation : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -57002,9 +56739,9 @@ class ReadColorControlCompensationText : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCompensationTextWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.CompensationText response %@", [value description]); if (error != nil) { @@ -57029,10 +56766,10 @@ class SubscribeAttributeColorControlCompensationText : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -57072,9 +56809,9 @@ class ReadColorControlColorTemperatureMireds : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorTemperatureMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorTemperatureMireds response %@", [value description]); if (error != nil) { @@ -57099,10 +56836,10 @@ class SubscribeAttributeColorControlColorTemperatureMireds : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -57142,9 +56879,9 @@ class ReadColorControlColorMode : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorMode response %@", [value description]); if (error != nil) { @@ -57169,10 +56906,10 @@ class SubscribeAttributeColorControlColorMode : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -57212,9 +56949,9 @@ class ReadColorControlOptions : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOptionsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Options response %@", [value description]); if (error != nil) { @@ -57242,10 +56979,10 @@ class WriteColorControlOptions : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) WriteAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -57279,10 +57016,10 @@ class SubscribeAttributeColorControlOptions : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -57322,9 +57059,9 @@ class ReadColorControlNumberOfPrimaries : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNumberOfPrimariesWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.NumberOfPrimaries response %@", [value description]); if (error != nil) { @@ -57349,10 +57086,10 @@ class SubscribeAttributeColorControlNumberOfPrimaries : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -57392,9 +57129,9 @@ class ReadColorControlPrimary1X : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary1XWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary1X response %@", [value description]); if (error != nil) { @@ -57419,10 +57156,10 @@ class SubscribeAttributeColorControlPrimary1X : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -57462,9 +57199,9 @@ class ReadColorControlPrimary1Y : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary1YWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary1Y response %@", [value description]); if (error != nil) { @@ -57489,10 +57226,10 @@ class SubscribeAttributeColorControlPrimary1Y : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -57532,9 +57269,9 @@ class ReadColorControlPrimary1Intensity : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary1IntensityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary1Intensity response %@", [value description]); if (error != nil) { @@ -57559,10 +57296,10 @@ class SubscribeAttributeColorControlPrimary1Intensity : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -57602,9 +57339,9 @@ class ReadColorControlPrimary2X : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary2XWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary2X response %@", [value description]); if (error != nil) { @@ -57629,10 +57366,10 @@ class SubscribeAttributeColorControlPrimary2X : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -57672,9 +57409,9 @@ class ReadColorControlPrimary2Y : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary2YWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary2Y response %@", [value description]); if (error != nil) { @@ -57699,10 +57436,10 @@ class SubscribeAttributeColorControlPrimary2Y : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -57742,9 +57479,9 @@ class ReadColorControlPrimary2Intensity : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary2IntensityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary2Intensity response %@", [value description]); if (error != nil) { @@ -57769,10 +57506,10 @@ class SubscribeAttributeColorControlPrimary2Intensity : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -57812,9 +57549,9 @@ class ReadColorControlPrimary3X : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary3XWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary3X response %@", [value description]); if (error != nil) { @@ -57839,10 +57576,10 @@ class SubscribeAttributeColorControlPrimary3X : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -57882,9 +57619,9 @@ class ReadColorControlPrimary3Y : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary3YWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary3Y response %@", [value description]); if (error != nil) { @@ -57909,10 +57646,10 @@ class SubscribeAttributeColorControlPrimary3Y : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -57952,9 +57689,9 @@ class ReadColorControlPrimary3Intensity : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000001B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary3IntensityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary3Intensity response %@", [value description]); if (error != nil) { @@ -57979,10 +57716,10 @@ class SubscribeAttributeColorControlPrimary3Intensity : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000001B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -58022,9 +57759,9 @@ class ReadColorControlPrimary4X : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary4XWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary4X response %@", [value description]); if (error != nil) { @@ -58049,10 +57786,10 @@ class SubscribeAttributeColorControlPrimary4X : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -58092,9 +57829,9 @@ class ReadColorControlPrimary4Y : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary4YWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary4Y response %@", [value description]); if (error != nil) { @@ -58119,10 +57856,10 @@ class SubscribeAttributeColorControlPrimary4Y : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -58162,9 +57899,9 @@ class ReadColorControlPrimary4Intensity : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary4IntensityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary4Intensity response %@", [value description]); if (error != nil) { @@ -58189,10 +57926,10 @@ class SubscribeAttributeColorControlPrimary4Intensity : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -58232,9 +57969,9 @@ class ReadColorControlPrimary5X : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary5XWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary5X response %@", [value description]); if (error != nil) { @@ -58259,10 +57996,10 @@ class SubscribeAttributeColorControlPrimary5X : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -58302,9 +58039,9 @@ class ReadColorControlPrimary5Y : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary5YWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary5Y response %@", [value description]); if (error != nil) { @@ -58329,10 +58066,10 @@ class SubscribeAttributeColorControlPrimary5Y : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -58372,9 +58109,9 @@ class ReadColorControlPrimary5Intensity : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000026) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary5IntensityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary5Intensity response %@", [value description]); if (error != nil) { @@ -58399,10 +58136,10 @@ class SubscribeAttributeColorControlPrimary5Intensity : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000026) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -58442,9 +58179,9 @@ class ReadColorControlPrimary6X : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000028) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary6XWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary6X response %@", [value description]); if (error != nil) { @@ -58469,10 +58206,10 @@ class SubscribeAttributeColorControlPrimary6X : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000028) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -58512,9 +58249,9 @@ class ReadColorControlPrimary6Y : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000029) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary6YWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary6Y response %@", [value description]); if (error != nil) { @@ -58539,10 +58276,10 @@ class SubscribeAttributeColorControlPrimary6Y : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000029) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -58582,9 +58319,9 @@ class ReadColorControlPrimary6Intensity : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000002A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePrimary6IntensityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.Primary6Intensity response %@", [value description]); if (error != nil) { @@ -58609,10 +58346,10 @@ class SubscribeAttributeColorControlPrimary6Intensity : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000002A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -58652,9 +58389,9 @@ class ReadColorControlWhitePointX : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeWhitePointXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.WhitePointX response %@", [value description]); if (error != nil) { @@ -58682,10 +58419,10 @@ class WriteColorControlWhitePointX : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) WriteAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -58719,10 +58456,10 @@ class SubscribeAttributeColorControlWhitePointX : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -58762,9 +58499,9 @@ class ReadColorControlWhitePointY : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeWhitePointYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.WhitePointY response %@", [value description]); if (error != nil) { @@ -58792,10 +58529,10 @@ class WriteColorControlWhitePointY : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) WriteAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -58829,10 +58566,10 @@ class SubscribeAttributeColorControlWhitePointY : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -58872,9 +58609,9 @@ class ReadColorControlColorPointRX : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorPointRXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorPointRX response %@", [value description]); if (error != nil) { @@ -58902,10 +58639,10 @@ class WriteColorControlColorPointRX : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) WriteAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -58939,10 +58676,10 @@ class SubscribeAttributeColorControlColorPointRX : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -58982,9 +58719,9 @@ class ReadColorControlColorPointRY : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000033) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorPointRYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorPointRY response %@", [value description]); if (error != nil) { @@ -59012,10 +58749,10 @@ class WriteColorControlColorPointRY : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) WriteAttribute (0x00000033) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -59049,10 +58786,10 @@ class SubscribeAttributeColorControlColorPointRY : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000033) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -59092,9 +58829,9 @@ class ReadColorControlColorPointRIntensity : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000034) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorPointRIntensityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorPointRIntensity response %@", [value description]); if (error != nil) { @@ -59122,10 +58859,10 @@ class WriteColorControlColorPointRIntensity : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) WriteAttribute (0x00000034) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -59159,10 +58896,10 @@ class SubscribeAttributeColorControlColorPointRIntensity : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000034) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -59202,9 +58939,9 @@ class ReadColorControlColorPointGX : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000036) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorPointGXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorPointGX response %@", [value description]); if (error != nil) { @@ -59232,10 +58969,10 @@ class WriteColorControlColorPointGX : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) WriteAttribute (0x00000036) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -59269,10 +59006,10 @@ class SubscribeAttributeColorControlColorPointGX : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000036) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -59312,9 +59049,9 @@ class ReadColorControlColorPointGY : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000037) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorPointGYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorPointGY response %@", [value description]); if (error != nil) { @@ -59342,10 +59079,10 @@ class WriteColorControlColorPointGY : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) WriteAttribute (0x00000037) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -59379,10 +59116,10 @@ class SubscribeAttributeColorControlColorPointGY : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000037) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -59422,9 +59159,9 @@ class ReadColorControlColorPointGIntensity : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00000038) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorPointGIntensityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorPointGIntensity response %@", [value description]); if (error != nil) { @@ -59452,10 +59189,10 @@ class WriteColorControlColorPointGIntensity : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) WriteAttribute (0x00000038) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -59489,10 +59226,10 @@ class SubscribeAttributeColorControlColorPointGIntensity : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00000038) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -59532,9 +59269,9 @@ class ReadColorControlColorPointBX : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000003A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorPointBXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorPointBX response %@", [value description]); if (error != nil) { @@ -59562,10 +59299,10 @@ class WriteColorControlColorPointBX : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) WriteAttribute (0x0000003A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -59599,10 +59336,10 @@ class SubscribeAttributeColorControlColorPointBX : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000003A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -59642,9 +59379,9 @@ class ReadColorControlColorPointBY : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000003B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorPointBYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorPointBY response %@", [value description]); if (error != nil) { @@ -59672,10 +59409,10 @@ class WriteColorControlColorPointBY : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) WriteAttribute (0x0000003B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -59709,10 +59446,10 @@ class SubscribeAttributeColorControlColorPointBY : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000003B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -59752,9 +59489,9 @@ class ReadColorControlColorPointBIntensity : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000003C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorPointBIntensityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorPointBIntensity response %@", [value description]); if (error != nil) { @@ -59782,10 +59519,10 @@ class WriteColorControlColorPointBIntensity : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) WriteAttribute (0x0000003C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -59819,10 +59556,10 @@ class SubscribeAttributeColorControlColorPointBIntensity : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000003C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -59862,9 +59599,9 @@ class ReadColorControlEnhancedCurrentHue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00004000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeEnhancedCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.EnhancedCurrentHue response %@", [value description]); if (error != nil) { @@ -59889,10 +59626,10 @@ class SubscribeAttributeColorControlEnhancedCurrentHue : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00004000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -59932,9 +59669,9 @@ class ReadColorControlEnhancedColorMode : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00004001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeEnhancedColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.EnhancedColorMode response %@", [value description]); if (error != nil) { @@ -59959,10 +59696,10 @@ class SubscribeAttributeColorControlEnhancedColorMode : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00004001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -60002,9 +59739,9 @@ class ReadColorControlColorLoopActive : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00004002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorLoopActiveWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorLoopActive response %@", [value description]); if (error != nil) { @@ -60029,10 +59766,10 @@ class SubscribeAttributeColorControlColorLoopActive : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00004002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -60072,9 +59809,9 @@ class ReadColorControlColorLoopDirection : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00004003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorLoopDirectionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorLoopDirection response %@", [value description]); if (error != nil) { @@ -60099,10 +59836,10 @@ class SubscribeAttributeColorControlColorLoopDirection : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00004003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -60142,9 +59879,9 @@ class ReadColorControlColorLoopTime : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00004004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorLoopTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorLoopTime response %@", [value description]); if (error != nil) { @@ -60169,10 +59906,10 @@ class SubscribeAttributeColorControlColorLoopTime : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00004004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -60212,9 +59949,9 @@ class ReadColorControlColorLoopStartEnhancedHue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00004005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorLoopStartEnhancedHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorLoopStartEnhancedHue response %@", [value description]); if (error != nil) { @@ -60239,10 +59976,10 @@ class SubscribeAttributeColorControlColorLoopStartEnhancedHue : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00004005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -60282,9 +60019,9 @@ class ReadColorControlColorLoopStoredEnhancedHue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00004006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorLoopStoredEnhancedHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorLoopStoredEnhancedHue response %@", [value description]); if (error != nil) { @@ -60309,10 +60046,10 @@ class SubscribeAttributeColorControlColorLoopStoredEnhancedHue : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00004006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -60352,9 +60089,9 @@ class ReadColorControlColorCapabilities : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000400A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorCapabilitiesWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorCapabilities response %@", [value description]); if (error != nil) { @@ -60379,10 +60116,10 @@ class SubscribeAttributeColorControlColorCapabilities : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000400A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -60422,9 +60159,9 @@ class ReadColorControlColorTempPhysicalMinMireds : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000400B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorTempPhysicalMinMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorTempPhysicalMinMireds response %@", [value description]); if (error != nil) { @@ -60449,10 +60186,10 @@ class SubscribeAttributeColorControlColorTempPhysicalMinMireds : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000400B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -60492,9 +60229,9 @@ class ReadColorControlColorTempPhysicalMaxMireds : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000400C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeColorTempPhysicalMaxMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ColorTempPhysicalMaxMireds response %@", [value description]); if (error != nil) { @@ -60519,10 +60256,10 @@ class SubscribeAttributeColorControlColorTempPhysicalMaxMireds : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000400C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -60562,9 +60299,9 @@ class ReadColorControlCoupleColorTempToLevelMinMireds : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000400D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCoupleColorTempToLevelMinMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.CoupleColorTempToLevelMinMireds response %@", [value description]); @@ -60590,10 +60327,10 @@ class SubscribeAttributeColorControlCoupleColorTempToLevelMinMireds : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000400D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -60633,9 +60370,9 @@ class ReadColorControlStartUpColorTemperatureMireds : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x00004010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeStartUpColorTemperatureMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.StartUpColorTemperatureMireds response %@", [value description]); if (error != nil) { @@ -60663,10 +60400,10 @@ class WriteColorControlStartUpColorTemperatureMireds : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) WriteAttribute (0x00004010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -60702,10 +60439,10 @@ class SubscribeAttributeColorControlStartUpColorTemperatureMireds : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x00004010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -60745,9 +60482,9 @@ class ReadColorControlGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -60772,10 +60509,10 @@ class SubscribeAttributeColorControlGeneratedCommandList : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -60815,9 +60552,9 @@ class ReadColorControlAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -60842,10 +60579,10 @@ class SubscribeAttributeColorControlAcceptedCommandList : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -60885,9 +60622,9 @@ class ReadColorControlAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.AttributeList response %@", [value description]); if (error != nil) { @@ -60912,10 +60649,10 @@ class SubscribeAttributeColorControlAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -60955,9 +60692,9 @@ class ReadColorControlFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.FeatureMap response %@", [value description]); if (error != nil) { @@ -60982,10 +60719,10 @@ class SubscribeAttributeColorControlFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -61025,9 +60762,9 @@ class ReadColorControlClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ColorControl.ClusterRevision response %@", [value description]); if (error != nil) { @@ -61052,10 +60789,10 @@ class SubscribeAttributeColorControlClusterRevision : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000300) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -61124,9 +60861,9 @@ class ReadBallastConfigurationPhysicalMinLevel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePhysicalMinLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.PhysicalMinLevel response %@", [value description]); if (error != nil) { @@ -61151,10 +60888,10 @@ class SubscribeAttributeBallastConfigurationPhysicalMinLevel : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -61194,9 +60931,9 @@ class ReadBallastConfigurationPhysicalMaxLevel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePhysicalMaxLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.PhysicalMaxLevel response %@", [value description]); if (error != nil) { @@ -61221,10 +60958,10 @@ class SubscribeAttributeBallastConfigurationPhysicalMaxLevel : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -61264,9 +61001,9 @@ class ReadBallastConfigurationBallastStatus : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBallastStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.BallastStatus response %@", [value description]); if (error != nil) { @@ -61291,10 +61028,10 @@ class SubscribeAttributeBallastConfigurationBallastStatus : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -61334,9 +61071,9 @@ class ReadBallastConfigurationMinLevel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.MinLevel response %@", [value description]); if (error != nil) { @@ -61364,10 +61101,10 @@ class WriteBallastConfigurationMinLevel : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000301) WriteAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -61401,10 +61138,10 @@ class SubscribeAttributeBallastConfigurationMinLevel : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -61444,9 +61181,9 @@ class ReadBallastConfigurationMaxLevel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.MaxLevel response %@", [value description]); if (error != nil) { @@ -61474,10 +61211,10 @@ class WriteBallastConfigurationMaxLevel : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000301) WriteAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -61511,10 +61248,10 @@ class SubscribeAttributeBallastConfigurationMaxLevel : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -61554,9 +61291,9 @@ class ReadBallastConfigurationIntrinsicBalanceFactor : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeIntrinsicBalanceFactorWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.IntrinsicBalanceFactor response %@", [value description]); if (error != nil) { @@ -61584,10 +61321,10 @@ class WriteBallastConfigurationIntrinsicBalanceFactor : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000301) WriteAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -61622,10 +61359,10 @@ class SubscribeAttributeBallastConfigurationIntrinsicBalanceFactor : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -61665,9 +61402,9 @@ class ReadBallastConfigurationBallastFactorAdjustment : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBallastFactorAdjustmentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.BallastFactorAdjustment response %@", [value description]); if (error != nil) { @@ -61695,10 +61432,10 @@ class WriteBallastConfigurationBallastFactorAdjustment : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000301) WriteAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -61733,10 +61470,10 @@ class SubscribeAttributeBallastConfigurationBallastFactorAdjustment : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -61776,9 +61513,9 @@ class ReadBallastConfigurationLampQuantity : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLampQuantityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.LampQuantity response %@", [value description]); if (error != nil) { @@ -61803,10 +61540,10 @@ class SubscribeAttributeBallastConfigurationLampQuantity : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -61846,9 +61583,9 @@ class ReadBallastConfigurationLampType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLampTypeWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.LampType response %@", [value description]); if (error != nil) { @@ -61876,10 +61613,10 @@ class WriteBallastConfigurationLampType : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000301) WriteAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -61915,10 +61652,10 @@ class SubscribeAttributeBallastConfigurationLampType : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -61958,9 +61695,9 @@ class ReadBallastConfigurationLampManufacturer : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLampManufacturerWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.LampManufacturer response %@", [value description]); if (error != nil) { @@ -61988,10 +61725,10 @@ class WriteBallastConfigurationLampManufacturer : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000301) WriteAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -62027,10 +61764,10 @@ class SubscribeAttributeBallastConfigurationLampManufacturer : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -62070,9 +61807,9 @@ class ReadBallastConfigurationLampRatedHours : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLampRatedHoursWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.LampRatedHours response %@", [value description]); if (error != nil) { @@ -62100,10 +61837,10 @@ class WriteBallastConfigurationLampRatedHours : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000301) WriteAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -62137,10 +61874,10 @@ class SubscribeAttributeBallastConfigurationLampRatedHours : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -62180,9 +61917,9 @@ class ReadBallastConfigurationLampBurnHours : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x00000033) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLampBurnHoursWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.LampBurnHours response %@", [value description]); if (error != nil) { @@ -62210,10 +61947,10 @@ class WriteBallastConfigurationLampBurnHours : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000301) WriteAttribute (0x00000033) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -62247,10 +61984,10 @@ class SubscribeAttributeBallastConfigurationLampBurnHours : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x00000033) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -62290,9 +62027,9 @@ class ReadBallastConfigurationLampAlarmMode : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x00000034) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLampAlarmModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.LampAlarmMode response %@", [value description]); if (error != nil) { @@ -62320,10 +62057,10 @@ class WriteBallastConfigurationLampAlarmMode : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000301) WriteAttribute (0x00000034) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -62357,10 +62094,10 @@ class SubscribeAttributeBallastConfigurationLampAlarmMode : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x00000034) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -62400,9 +62137,9 @@ class ReadBallastConfigurationLampBurnHoursTripPoint : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x00000035) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLampBurnHoursTripPointWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.LampBurnHoursTripPoint response %@", [value description]); if (error != nil) { @@ -62430,10 +62167,10 @@ class WriteBallastConfigurationLampBurnHoursTripPoint : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000301) WriteAttribute (0x00000035) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -62468,10 +62205,10 @@ class SubscribeAttributeBallastConfigurationLampBurnHoursTripPoint : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x00000035) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -62511,9 +62248,9 @@ class ReadBallastConfigurationGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -62538,10 +62275,10 @@ class SubscribeAttributeBallastConfigurationGeneratedCommandList : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -62581,9 +62318,9 @@ class ReadBallastConfigurationAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -62608,10 +62345,10 @@ class SubscribeAttributeBallastConfigurationAcceptedCommandList : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -62651,9 +62388,9 @@ class ReadBallastConfigurationAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.AttributeList response %@", [value description]); if (error != nil) { @@ -62678,10 +62415,10 @@ class SubscribeAttributeBallastConfigurationAttributeList : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -62721,9 +62458,9 @@ class ReadBallastConfigurationFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.FeatureMap response %@", [value description]); if (error != nil) { @@ -62748,10 +62485,10 @@ class SubscribeAttributeBallastConfigurationFeatureMap : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -62791,9 +62528,9 @@ class ReadBallastConfigurationClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"BallastConfiguration.ClusterRevision response %@", [value description]); if (error != nil) { @@ -62818,10 +62555,10 @@ class SubscribeAttributeBallastConfigurationClusterRevision : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000301) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterBallastConfiguration * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterBallastConfiguration alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -62881,8 +62618,9 @@ class ReadIlluminanceMeasurementMeasuredValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"IlluminanceMeasurement.MeasuredValue response %@", [value description]); if (error != nil) { @@ -62907,9 +62645,10 @@ class SubscribeAttributeIlluminanceMeasurementMeasuredValue : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -62949,8 +62688,9 @@ class ReadIlluminanceMeasurementMinMeasuredValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"IlluminanceMeasurement.MinMeasuredValue response %@", [value description]); if (error != nil) { @@ -62975,9 +62715,10 @@ class SubscribeAttributeIlluminanceMeasurementMinMeasuredValue : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -63017,8 +62758,9 @@ class ReadIlluminanceMeasurementMaxMeasuredValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"IlluminanceMeasurement.MaxMeasuredValue response %@", [value description]); if (error != nil) { @@ -63043,9 +62785,10 @@ class SubscribeAttributeIlluminanceMeasurementMaxMeasuredValue : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -63085,8 +62828,9 @@ class ReadIlluminanceMeasurementTolerance : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeToleranceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"IlluminanceMeasurement.Tolerance response %@", [value description]); if (error != nil) { @@ -63111,9 +62855,10 @@ class SubscribeAttributeIlluminanceMeasurementTolerance : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -63153,8 +62898,9 @@ class ReadIlluminanceMeasurementLightSensorType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLightSensorTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"IlluminanceMeasurement.LightSensorType response %@", [value description]); if (error != nil) { @@ -63179,9 +62925,10 @@ class SubscribeAttributeIlluminanceMeasurementLightSensorType : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -63221,8 +62968,9 @@ class ReadIlluminanceMeasurementGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"IlluminanceMeasurement.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -63247,9 +62995,10 @@ class SubscribeAttributeIlluminanceMeasurementGeneratedCommandList : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -63289,8 +63038,9 @@ class ReadIlluminanceMeasurementAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"IlluminanceMeasurement.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -63315,9 +63065,10 @@ class SubscribeAttributeIlluminanceMeasurementAcceptedCommandList : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -63357,8 +63108,9 @@ class ReadIlluminanceMeasurementAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"IlluminanceMeasurement.AttributeList response %@", [value description]); if (error != nil) { @@ -63383,9 +63135,10 @@ class SubscribeAttributeIlluminanceMeasurementAttributeList : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -63425,8 +63178,9 @@ class ReadIlluminanceMeasurementFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"IlluminanceMeasurement.FeatureMap response %@", [value description]); if (error != nil) { @@ -63451,9 +63205,10 @@ class SubscribeAttributeIlluminanceMeasurementFeatureMap : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -63493,8 +63248,9 @@ class ReadIlluminanceMeasurementClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"IlluminanceMeasurement.ClusterRevision response %@", [value description]); if (error != nil) { @@ -63519,9 +63275,10 @@ class SubscribeAttributeIlluminanceMeasurementClusterRevision : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000400) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -63580,8 +63337,9 @@ class ReadTemperatureMeasurementMeasuredValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"TemperatureMeasurement.MeasuredValue response %@", [value description]); if (error != nil) { @@ -63606,9 +63364,10 @@ class SubscribeAttributeTemperatureMeasurementMeasuredValue : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -63648,8 +63407,9 @@ class ReadTemperatureMeasurementMinMeasuredValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"TemperatureMeasurement.MinMeasuredValue response %@", [value description]); if (error != nil) { @@ -63674,9 +63434,10 @@ class SubscribeAttributeTemperatureMeasurementMinMeasuredValue : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -63716,8 +63477,9 @@ class ReadTemperatureMeasurementMaxMeasuredValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"TemperatureMeasurement.MaxMeasuredValue response %@", [value description]); if (error != nil) { @@ -63742,9 +63504,10 @@ class SubscribeAttributeTemperatureMeasurementMaxMeasuredValue : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -63784,8 +63547,9 @@ class ReadTemperatureMeasurementTolerance : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeToleranceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"TemperatureMeasurement.Tolerance response %@", [value description]); if (error != nil) { @@ -63810,9 +63574,10 @@ class SubscribeAttributeTemperatureMeasurementTolerance : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -63852,8 +63617,9 @@ class ReadTemperatureMeasurementGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"TemperatureMeasurement.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -63878,9 +63644,10 @@ class SubscribeAttributeTemperatureMeasurementGeneratedCommandList : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -63920,8 +63687,9 @@ class ReadTemperatureMeasurementAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"TemperatureMeasurement.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -63946,9 +63714,10 @@ class SubscribeAttributeTemperatureMeasurementAcceptedCommandList : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -63988,8 +63757,9 @@ class ReadTemperatureMeasurementAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"TemperatureMeasurement.AttributeList response %@", [value description]); if (error != nil) { @@ -64014,9 +63784,10 @@ class SubscribeAttributeTemperatureMeasurementAttributeList : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -64056,8 +63827,9 @@ class ReadTemperatureMeasurementFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"TemperatureMeasurement.FeatureMap response %@", [value description]); if (error != nil) { @@ -64082,9 +63854,10 @@ class SubscribeAttributeTemperatureMeasurementFeatureMap : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -64124,8 +63897,9 @@ class ReadTemperatureMeasurementClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"TemperatureMeasurement.ClusterRevision response %@", [value description]); if (error != nil) { @@ -64150,9 +63924,10 @@ class SubscribeAttributeTemperatureMeasurementClusterRevision : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000402) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -64216,9 +63991,9 @@ class ReadPressureMeasurementMeasuredValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PressureMeasurement.MeasuredValue response %@", [value description]); if (error != nil) { @@ -64243,10 +64018,10 @@ class SubscribeAttributePressureMeasurementMeasuredValue : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -64286,9 +64061,9 @@ class ReadPressureMeasurementMinMeasuredValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PressureMeasurement.MinMeasuredValue response %@", [value description]); if (error != nil) { @@ -64313,10 +64088,10 @@ class SubscribeAttributePressureMeasurementMinMeasuredValue : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -64356,9 +64131,9 @@ class ReadPressureMeasurementMaxMeasuredValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PressureMeasurement.MaxMeasuredValue response %@", [value description]); if (error != nil) { @@ -64383,10 +64158,10 @@ class SubscribeAttributePressureMeasurementMaxMeasuredValue : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -64426,9 +64201,9 @@ class ReadPressureMeasurementTolerance : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeToleranceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PressureMeasurement.Tolerance response %@", [value description]); if (error != nil) { @@ -64453,10 +64228,10 @@ class SubscribeAttributePressureMeasurementTolerance : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -64496,9 +64271,9 @@ class ReadPressureMeasurementScaledValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReadAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeScaledValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PressureMeasurement.ScaledValue response %@", [value description]); if (error != nil) { @@ -64523,10 +64298,10 @@ class SubscribeAttributePressureMeasurementScaledValue : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReportAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -64566,9 +64341,9 @@ class ReadPressureMeasurementMinScaledValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReadAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinScaledValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PressureMeasurement.MinScaledValue response %@", [value description]); if (error != nil) { @@ -64593,10 +64368,10 @@ class SubscribeAttributePressureMeasurementMinScaledValue : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReportAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -64636,9 +64411,9 @@ class ReadPressureMeasurementMaxScaledValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReadAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxScaledValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PressureMeasurement.MaxScaledValue response %@", [value description]); if (error != nil) { @@ -64663,10 +64438,10 @@ class SubscribeAttributePressureMeasurementMaxScaledValue : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReportAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -64706,9 +64481,9 @@ class ReadPressureMeasurementScaledTolerance : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReadAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeScaledToleranceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PressureMeasurement.ScaledTolerance response %@", [value description]); if (error != nil) { @@ -64733,10 +64508,10 @@ class SubscribeAttributePressureMeasurementScaledTolerance : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReportAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -64776,9 +64551,9 @@ class ReadPressureMeasurementScale : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReadAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeScaleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PressureMeasurement.Scale response %@", [value description]); if (error != nil) { @@ -64803,10 +64578,10 @@ class SubscribeAttributePressureMeasurementScale : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReportAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -64846,9 +64621,9 @@ class ReadPressureMeasurementGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PressureMeasurement.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -64873,10 +64648,10 @@ class SubscribeAttributePressureMeasurementGeneratedCommandList : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -64916,9 +64691,9 @@ class ReadPressureMeasurementAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PressureMeasurement.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -64943,10 +64718,10 @@ class SubscribeAttributePressureMeasurementAcceptedCommandList : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -64986,9 +64761,9 @@ class ReadPressureMeasurementAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"PressureMeasurement.AttributeList response %@", [value description]); if (error != nil) { @@ -65013,10 +64788,10 @@ class SubscribeAttributePressureMeasurementAttributeList : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -65056,9 +64831,9 @@ class ReadPressureMeasurementFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PressureMeasurement.FeatureMap response %@", [value description]); if (error != nil) { @@ -65083,10 +64858,10 @@ class SubscribeAttributePressureMeasurementFeatureMap : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -65126,9 +64901,9 @@ class ReadPressureMeasurementClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"PressureMeasurement.ClusterRevision response %@", [value description]); if (error != nil) { @@ -65153,10 +64928,10 @@ class SubscribeAttributePressureMeasurementClusterRevision : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000403) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -65215,9 +64990,9 @@ class ReadFlowMeasurementMeasuredValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FlowMeasurement.MeasuredValue response %@", [value description]); if (error != nil) { @@ -65242,10 +65017,10 @@ class SubscribeAttributeFlowMeasurementMeasuredValue : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -65285,9 +65060,9 @@ class ReadFlowMeasurementMinMeasuredValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FlowMeasurement.MinMeasuredValue response %@", [value description]); if (error != nil) { @@ -65312,10 +65087,10 @@ class SubscribeAttributeFlowMeasurementMinMeasuredValue : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -65355,9 +65130,9 @@ class ReadFlowMeasurementMaxMeasuredValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FlowMeasurement.MaxMeasuredValue response %@", [value description]); if (error != nil) { @@ -65382,10 +65157,10 @@ class SubscribeAttributeFlowMeasurementMaxMeasuredValue : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -65425,9 +65200,9 @@ class ReadFlowMeasurementTolerance : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeToleranceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FlowMeasurement.Tolerance response %@", [value description]); if (error != nil) { @@ -65452,10 +65227,10 @@ class SubscribeAttributeFlowMeasurementTolerance : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -65495,9 +65270,9 @@ class ReadFlowMeasurementGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"FlowMeasurement.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -65522,10 +65297,10 @@ class SubscribeAttributeFlowMeasurementGeneratedCommandList : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -65565,9 +65340,9 @@ class ReadFlowMeasurementAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"FlowMeasurement.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -65592,10 +65367,10 @@ class SubscribeAttributeFlowMeasurementAcceptedCommandList : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -65635,9 +65410,9 @@ class ReadFlowMeasurementAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"FlowMeasurement.AttributeList response %@", [value description]); if (error != nil) { @@ -65662,10 +65437,10 @@ class SubscribeAttributeFlowMeasurementAttributeList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -65705,9 +65480,9 @@ class ReadFlowMeasurementFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FlowMeasurement.FeatureMap response %@", [value description]); if (error != nil) { @@ -65732,10 +65507,10 @@ class SubscribeAttributeFlowMeasurementFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -65775,9 +65550,9 @@ class ReadFlowMeasurementClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"FlowMeasurement.ClusterRevision response %@", [value description]); if (error != nil) { @@ -65802,10 +65577,10 @@ class SubscribeAttributeFlowMeasurementClusterRevision : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000404) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -65864,8 +65639,9 @@ class ReadRelativeHumidityMeasurementMeasuredValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"RelativeHumidityMeasurement.MeasuredValue response %@", [value description]); if (error != nil) { @@ -65890,9 +65666,10 @@ class SubscribeAttributeRelativeHumidityMeasurementMeasuredValue : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -65932,8 +65709,9 @@ class ReadRelativeHumidityMeasurementMinMeasuredValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMinMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"RelativeHumidityMeasurement.MinMeasuredValue response %@", [value description]); if (error != nil) { @@ -65958,9 +65736,10 @@ class SubscribeAttributeRelativeHumidityMeasurementMinMeasuredValue : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -66000,8 +65779,9 @@ class ReadRelativeHumidityMeasurementMaxMeasuredValue : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMaxMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"RelativeHumidityMeasurement.MaxMeasuredValue response %@", [value description]); if (error != nil) { @@ -66026,9 +65806,10 @@ class SubscribeAttributeRelativeHumidityMeasurementMaxMeasuredValue : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -66068,8 +65849,9 @@ class ReadRelativeHumidityMeasurementTolerance : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeToleranceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"RelativeHumidityMeasurement.Tolerance response %@", [value description]); if (error != nil) { @@ -66094,9 +65876,10 @@ class SubscribeAttributeRelativeHumidityMeasurementTolerance : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -66136,8 +65919,9 @@ class ReadRelativeHumidityMeasurementGeneratedCommandList : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"RelativeHumidityMeasurement.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -66162,9 +65946,10 @@ class SubscribeAttributeRelativeHumidityMeasurementGeneratedCommandList : public { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -66204,8 +65989,9 @@ class ReadRelativeHumidityMeasurementAcceptedCommandList : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"RelativeHumidityMeasurement.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -66230,9 +66016,10 @@ class SubscribeAttributeRelativeHumidityMeasurementAcceptedCommandList : public { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -66272,8 +66059,9 @@ class ReadRelativeHumidityMeasurementAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"RelativeHumidityMeasurement.AttributeList response %@", [value description]); if (error != nil) { @@ -66298,9 +66086,10 @@ class SubscribeAttributeRelativeHumidityMeasurementAttributeList : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -66340,8 +66129,9 @@ class ReadRelativeHumidityMeasurementFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"RelativeHumidityMeasurement.FeatureMap response %@", [value description]); if (error != nil) { @@ -66366,9 +66156,10 @@ class SubscribeAttributeRelativeHumidityMeasurementFeatureMap : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -66408,8 +66199,9 @@ class ReadRelativeHumidityMeasurementClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"RelativeHumidityMeasurement.ClusterRevision response %@", [value description]); if (error != nil) { @@ -66434,9 +66226,10 @@ class SubscribeAttributeRelativeHumidityMeasurementClusterRevision : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000405) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -66503,9 +66296,9 @@ class ReadOccupancySensingOccupancy : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOccupancyWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OccupancySensing.Occupancy response %@", [value description]); if (error != nil) { @@ -66530,10 +66323,10 @@ class SubscribeAttributeOccupancySensingOccupancy : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -66573,9 +66366,9 @@ class ReadOccupancySensingOccupancySensorType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOccupancySensorTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OccupancySensing.OccupancySensorType response %@", [value description]); if (error != nil) { @@ -66600,10 +66393,10 @@ class SubscribeAttributeOccupancySensingOccupancySensorType : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -66643,9 +66436,9 @@ class ReadOccupancySensingOccupancySensorTypeBitmap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOccupancySensorTypeBitmapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OccupancySensing.OccupancySensorTypeBitmap response %@", [value description]); if (error != nil) { @@ -66670,10 +66463,10 @@ class SubscribeAttributeOccupancySensingOccupancySensorTypeBitmap : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -66713,13 +66506,13 @@ class ReadOccupancySensingPirOccupiedToUnoccupiedDelay : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - [cluster readAttributePirOccupiedToUnoccupiedDelayWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OccupancySensing.PirOccupiedToUnoccupiedDelay response %@", [value description]); + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + [cluster readAttributePIROccupiedToUnoccupiedDelayWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { + NSLog(@"OccupancySensing.PIROccupiedToUnoccupiedDelay response %@", [value description]); if (error != nil) { - LogNSError("OccupancySensing PirOccupiedToUnoccupiedDelay read Error", error); + LogNSError("OccupancySensing PIROccupiedToUnoccupiedDelay read Error", error); } SetCommandExitStatus(error); }]; @@ -66743,21 +66536,21 @@ class WriteOccupancySensingPirOccupiedToUnoccupiedDelay : public WriteAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000406) WriteAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; NSNumber * _Nonnull value = [NSNumber numberWithUnsignedShort:mValue]; [cluster - writeAttributePirOccupiedToUnoccupiedDelayWithValue:value + writeAttributePIROccupiedToUnoccupiedDelayWithValue:value params:params completion:^(NSError * _Nullable error) { if (error != nil) { - LogNSError("OccupancySensing PirOccupiedToUnoccupiedDelay write Error", + LogNSError("OccupancySensing PIROccupiedToUnoccupiedDelay write Error", error); } SetCommandExitStatus(error); @@ -66782,10 +66575,10 @@ class SubscribeAttributeOccupancySensingPirOccupiedToUnoccupiedDelay : public Su { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -66795,12 +66588,12 @@ class SubscribeAttributeOccupancySensingPirOccupiedToUnoccupiedDelay : public Su if (mAutoResubscribe.HasValue()) { params.resubscribeIfLost = mAutoResubscribe.Value(); } - [cluster subscribeAttributePirOccupiedToUnoccupiedDelayWithParams:params + [cluster subscribeAttributePIROccupiedToUnoccupiedDelayWithParams:params subscriptionEstablished:^() { mSubscriptionEstablished = YES; } reportHandler:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OccupancySensing.PirOccupiedToUnoccupiedDelay response %@", [value description]); + NSLog(@"OccupancySensing.PIROccupiedToUnoccupiedDelay response %@", [value description]); SetCommandExitStatus(error); }]; @@ -66825,13 +66618,13 @@ class ReadOccupancySensingPirUnoccupiedToOccupiedDelay : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - [cluster readAttributePirUnoccupiedToOccupiedDelayWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OccupancySensing.PirUnoccupiedToOccupiedDelay response %@", [value description]); + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + [cluster readAttributePIRUnoccupiedToOccupiedDelayWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { + NSLog(@"OccupancySensing.PIRUnoccupiedToOccupiedDelay response %@", [value description]); if (error != nil) { - LogNSError("OccupancySensing PirUnoccupiedToOccupiedDelay read Error", error); + LogNSError("OccupancySensing PIRUnoccupiedToOccupiedDelay read Error", error); } SetCommandExitStatus(error); }]; @@ -66855,21 +66648,21 @@ class WriteOccupancySensingPirUnoccupiedToOccupiedDelay : public WriteAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000406) WriteAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; NSNumber * _Nonnull value = [NSNumber numberWithUnsignedShort:mValue]; [cluster - writeAttributePirUnoccupiedToOccupiedDelayWithValue:value + writeAttributePIRUnoccupiedToOccupiedDelayWithValue:value params:params completion:^(NSError * _Nullable error) { if (error != nil) { - LogNSError("OccupancySensing PirUnoccupiedToOccupiedDelay write Error", + LogNSError("OccupancySensing PIRUnoccupiedToOccupiedDelay write Error", error); } SetCommandExitStatus(error); @@ -66894,10 +66687,10 @@ class SubscribeAttributeOccupancySensingPirUnoccupiedToOccupiedDelay : public Su { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -66907,12 +66700,12 @@ class SubscribeAttributeOccupancySensingPirUnoccupiedToOccupiedDelay : public Su if (mAutoResubscribe.HasValue()) { params.resubscribeIfLost = mAutoResubscribe.Value(); } - [cluster subscribeAttributePirUnoccupiedToOccupiedDelayWithParams:params + [cluster subscribeAttributePIRUnoccupiedToOccupiedDelayWithParams:params subscriptionEstablished:^() { mSubscriptionEstablished = YES; } reportHandler:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OccupancySensing.PirUnoccupiedToOccupiedDelay response %@", [value description]); + NSLog(@"OccupancySensing.PIRUnoccupiedToOccupiedDelay response %@", [value description]); SetCommandExitStatus(error); }]; @@ -66937,14 +66730,14 @@ class ReadOccupancySensingPirUnoccupiedToOccupiedThreshold : public ReadAttribut ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster - readAttributePirUnoccupiedToOccupiedThresholdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OccupancySensing.PirUnoccupiedToOccupiedThreshold response %@", [value description]); + readAttributePIRUnoccupiedToOccupiedThresholdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { + NSLog(@"OccupancySensing.PIRUnoccupiedToOccupiedThreshold response %@", [value description]); if (error != nil) { - LogNSError("OccupancySensing PirUnoccupiedToOccupiedThreshold read Error", error); + LogNSError("OccupancySensing PIRUnoccupiedToOccupiedThreshold read Error", error); } SetCommandExitStatus(error); }]; @@ -66968,21 +66761,21 @@ class WriteOccupancySensingPirUnoccupiedToOccupiedThreshold : public WriteAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000406) WriteAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; NSNumber * _Nonnull value = [NSNumber numberWithUnsignedChar:mValue]; - [cluster writeAttributePirUnoccupiedToOccupiedThresholdWithValue:value + [cluster writeAttributePIRUnoccupiedToOccupiedThresholdWithValue:value params:params completion:^(NSError * _Nullable error) { if (error != nil) { LogNSError("OccupancySensing " - "PirUnoccupiedToOccupiedThreshold write Error", + "PIRUnoccupiedToOccupiedThreshold write Error", error); } SetCommandExitStatus(error); @@ -67007,10 +66800,10 @@ class SubscribeAttributeOccupancySensingPirUnoccupiedToOccupiedThreshold : publi { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -67020,12 +66813,12 @@ class SubscribeAttributeOccupancySensingPirUnoccupiedToOccupiedThreshold : publi if (mAutoResubscribe.HasValue()) { params.resubscribeIfLost = mAutoResubscribe.Value(); } - [cluster subscribeAttributePirUnoccupiedToOccupiedThresholdWithParams:params + [cluster subscribeAttributePIRUnoccupiedToOccupiedThresholdWithParams:params subscriptionEstablished:^() { mSubscriptionEstablished = YES; } reportHandler:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"OccupancySensing.PirUnoccupiedToOccupiedThreshold response %@", [value description]); + NSLog(@"OccupancySensing.PIRUnoccupiedToOccupiedThreshold response %@", [value description]); SetCommandExitStatus(error); }]; @@ -67050,9 +66843,9 @@ class ReadOccupancySensingUltrasonicOccupiedToUnoccupiedDelay : public ReadAttri ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeUltrasonicOccupiedToUnoccupiedDelayWithCompletion:^( NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OccupancySensing.UltrasonicOccupiedToUnoccupiedDelay response %@", [value description]); @@ -67081,10 +66874,10 @@ class WriteOccupancySensingUltrasonicOccupiedToUnoccupiedDelay : public WriteAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000406) WriteAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -67121,10 +66914,10 @@ class SubscribeAttributeOccupancySensingUltrasonicOccupiedToUnoccupiedDelay : pu { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -67164,9 +66957,9 @@ class ReadOccupancySensingUltrasonicUnoccupiedToOccupiedDelay : public ReadAttri ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeUltrasonicUnoccupiedToOccupiedDelayWithCompletion:^( NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OccupancySensing.UltrasonicUnoccupiedToOccupiedDelay response %@", [value description]); @@ -67195,10 +66988,10 @@ class WriteOccupancySensingUltrasonicUnoccupiedToOccupiedDelay : public WriteAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000406) WriteAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -67235,10 +67028,10 @@ class SubscribeAttributeOccupancySensingUltrasonicUnoccupiedToOccupiedDelay : pu { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -67278,9 +67071,9 @@ class ReadOccupancySensingUltrasonicUnoccupiedToOccupiedThreshold : public ReadA ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeUltrasonicUnoccupiedToOccupiedThresholdWithCompletion:^( NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OccupancySensing.UltrasonicUnoccupiedToOccupiedThreshold response %@", [value description]); @@ -67309,10 +67102,10 @@ class WriteOccupancySensingUltrasonicUnoccupiedToOccupiedThreshold : public Writ { ChipLogProgress(chipTool, "Sending cluster (0x00000406) WriteAttribute (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -67350,10 +67143,10 @@ class SubscribeAttributeOccupancySensingUltrasonicUnoccupiedToOccupiedThreshold { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -67393,9 +67186,9 @@ class ReadOccupancySensingPhysicalContactOccupiedToUnoccupiedDelay : public Read ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePhysicalContactOccupiedToUnoccupiedDelayWithCompletion:^( NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OccupancySensing.PhysicalContactOccupiedToUnoccupiedDelay response %@", [value description]); @@ -67424,10 +67217,10 @@ class WriteOccupancySensingPhysicalContactOccupiedToUnoccupiedDelay : public Wri { ChipLogProgress(chipTool, "Sending cluster (0x00000406) WriteAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -67465,10 +67258,10 @@ class SubscribeAttributeOccupancySensingPhysicalContactOccupiedToUnoccupiedDelay { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -67508,9 +67301,9 @@ class ReadOccupancySensingPhysicalContactUnoccupiedToOccupiedDelay : public Read ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePhysicalContactUnoccupiedToOccupiedDelayWithCompletion:^( NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OccupancySensing.PhysicalContactUnoccupiedToOccupiedDelay response %@", [value description]); @@ -67539,10 +67332,10 @@ class WriteOccupancySensingPhysicalContactUnoccupiedToOccupiedDelay : public Wri { ChipLogProgress(chipTool, "Sending cluster (0x00000406) WriteAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -67580,10 +67373,10 @@ class SubscribeAttributeOccupancySensingPhysicalContactUnoccupiedToOccupiedDelay { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -67623,9 +67416,9 @@ class ReadOccupancySensingPhysicalContactUnoccupiedToOccupiedThreshold : public ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePhysicalContactUnoccupiedToOccupiedThresholdWithCompletion:^( NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OccupancySensing.PhysicalContactUnoccupiedToOccupiedThreshold response %@", [value description]); @@ -67654,10 +67447,10 @@ class WriteOccupancySensingPhysicalContactUnoccupiedToOccupiedThreshold : public { ChipLogProgress(chipTool, "Sending cluster (0x00000406) WriteAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -67694,10 +67487,10 @@ class SubscribeAttributeOccupancySensingPhysicalContactUnoccupiedToOccupiedThres { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -67737,9 +67530,9 @@ class ReadOccupancySensingGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"OccupancySensing.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -67764,10 +67557,10 @@ class SubscribeAttributeOccupancySensingGeneratedCommandList : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -67807,9 +67600,9 @@ class ReadOccupancySensingAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"OccupancySensing.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -67834,10 +67627,10 @@ class SubscribeAttributeOccupancySensingAcceptedCommandList : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -67877,9 +67670,9 @@ class ReadOccupancySensingAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"OccupancySensing.AttributeList response %@", [value description]); if (error != nil) { @@ -67904,10 +67697,10 @@ class SubscribeAttributeOccupancySensingAttributeList : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -67947,9 +67740,9 @@ class ReadOccupancySensingFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OccupancySensing.FeatureMap response %@", [value description]); if (error != nil) { @@ -67974,10 +67767,10 @@ class SubscribeAttributeOccupancySensingFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -68017,9 +67810,9 @@ class ReadOccupancySensingClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"OccupancySensing.ClusterRevision response %@", [value description]); if (error != nil) { @@ -68044,10 +67837,10 @@ class SubscribeAttributeOccupancySensingClusterRevision : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000406) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -68103,13 +67896,13 @@ class ReadWakeOnLanMACAddress : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000503) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMACAddressWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { - NSLog(@"WakeOnLan.MACAddress response %@", [value description]); + NSLog(@"WakeOnLAN.MACAddress response %@", [value description]); if (error != nil) { - LogNSError("WakeOnLan MACAddress read Error", error); + LogNSError("WakeOnLAN MACAddress read Error", error); } SetCommandExitStatus(error); }]; @@ -68130,10 +67923,10 @@ class SubscribeAttributeWakeOnLanMACAddress : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000503) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -68148,7 +67941,7 @@ class SubscribeAttributeWakeOnLanMACAddress : public SubscribeAttribute { mSubscriptionEstablished = YES; } reportHandler:^(NSString * _Nullable value, NSError * _Nullable error) { - NSLog(@"WakeOnLan.MACAddress response %@", [value description]); + NSLog(@"WakeOnLAN.MACAddress response %@", [value description]); SetCommandExitStatus(error); }]; @@ -68173,13 +67966,13 @@ class ReadWakeOnLanGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000503) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"WakeOnLan.GeneratedCommandList response %@", [value description]); + NSLog(@"WakeOnLAN.GeneratedCommandList response %@", [value description]); if (error != nil) { - LogNSError("WakeOnLan GeneratedCommandList read Error", error); + LogNSError("WakeOnLAN GeneratedCommandList read Error", error); } SetCommandExitStatus(error); }]; @@ -68200,10 +67993,10 @@ class SubscribeAttributeWakeOnLanGeneratedCommandList : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000503) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -68218,7 +68011,7 @@ class SubscribeAttributeWakeOnLanGeneratedCommandList : public SubscribeAttribut mSubscriptionEstablished = YES; } reportHandler:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"WakeOnLan.GeneratedCommandList response %@", [value description]); + NSLog(@"WakeOnLAN.GeneratedCommandList response %@", [value description]); SetCommandExitStatus(error); }]; @@ -68243,13 +68036,13 @@ class ReadWakeOnLanAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000503) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"WakeOnLan.AcceptedCommandList response %@", [value description]); + NSLog(@"WakeOnLAN.AcceptedCommandList response %@", [value description]); if (error != nil) { - LogNSError("WakeOnLan AcceptedCommandList read Error", error); + LogNSError("WakeOnLAN AcceptedCommandList read Error", error); } SetCommandExitStatus(error); }]; @@ -68270,10 +68063,10 @@ class SubscribeAttributeWakeOnLanAcceptedCommandList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000503) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -68288,7 +68081,7 @@ class SubscribeAttributeWakeOnLanAcceptedCommandList : public SubscribeAttribute mSubscriptionEstablished = YES; } reportHandler:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"WakeOnLan.AcceptedCommandList response %@", [value description]); + NSLog(@"WakeOnLAN.AcceptedCommandList response %@", [value description]); SetCommandExitStatus(error); }]; @@ -68313,13 +68106,13 @@ class ReadWakeOnLanAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000503) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"WakeOnLan.AttributeList response %@", [value description]); + NSLog(@"WakeOnLAN.AttributeList response %@", [value description]); if (error != nil) { - LogNSError("WakeOnLan AttributeList read Error", error); + LogNSError("WakeOnLAN AttributeList read Error", error); } SetCommandExitStatus(error); }]; @@ -68340,10 +68133,10 @@ class SubscribeAttributeWakeOnLanAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000503) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -68358,7 +68151,7 @@ class SubscribeAttributeWakeOnLanAttributeList : public SubscribeAttribute { mSubscriptionEstablished = YES; } reportHandler:^(NSArray * _Nullable value, NSError * _Nullable error) { - NSLog(@"WakeOnLan.AttributeList response %@", [value description]); + NSLog(@"WakeOnLAN.AttributeList response %@", [value description]); SetCommandExitStatus(error); }]; @@ -68383,13 +68176,13 @@ class ReadWakeOnLanFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000503) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"WakeOnLan.FeatureMap response %@", [value description]); + NSLog(@"WakeOnLAN.FeatureMap response %@", [value description]); if (error != nil) { - LogNSError("WakeOnLan FeatureMap read Error", error); + LogNSError("WakeOnLAN FeatureMap read Error", error); } SetCommandExitStatus(error); }]; @@ -68410,10 +68203,10 @@ class SubscribeAttributeWakeOnLanFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000503) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -68428,7 +68221,7 @@ class SubscribeAttributeWakeOnLanFeatureMap : public SubscribeAttribute { mSubscriptionEstablished = YES; } reportHandler:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"WakeOnLan.FeatureMap response %@", [value description]); + NSLog(@"WakeOnLAN.FeatureMap response %@", [value description]); SetCommandExitStatus(error); }]; @@ -68453,13 +68246,13 @@ class ReadWakeOnLanClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000503) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"WakeOnLan.ClusterRevision response %@", [value description]); + NSLog(@"WakeOnLAN.ClusterRevision response %@", [value description]); if (error != nil) { - LogNSError("WakeOnLan ClusterRevision read Error", error); + LogNSError("WakeOnLAN ClusterRevision read Error", error); } SetCommandExitStatus(error); }]; @@ -68480,10 +68273,10 @@ class SubscribeAttributeWakeOnLanClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000503) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -68498,7 +68291,7 @@ class SubscribeAttributeWakeOnLanClusterRevision : public SubscribeAttribute { mSubscriptionEstablished = YES; } reportHandler:^(NSNumber * _Nullable value, NSError * _Nullable error) { - NSLog(@"WakeOnLan.ClusterRevision response %@", [value description]); + NSLog(@"WakeOnLAN.ClusterRevision response %@", [value description]); SetCommandExitStatus(error); }]; @@ -68544,9 +68337,7 @@ class ChannelChangeChannel : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000504) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRChannelClusterChangeChannelParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -68595,9 +68386,7 @@ class ChannelChangeChannelByNumber : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000504) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRChannelClusterChangeChannelByNumberParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -68642,9 +68431,7 @@ class ChannelSkipChannel : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000504) command (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRChannelClusterSkipChannelParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -68688,9 +68475,7 @@ class ReadChannelChannelList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeChannelListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Channel.ChannelList response %@", [value description]); if (error != nil) { @@ -68715,10 +68500,8 @@ class SubscribeAttributeChannelChannelList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -68758,9 +68541,7 @@ class ReadChannelLineup : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeLineupWithCompletion:^(MTRChannelClusterLineupInfo * _Nullable value, NSError * _Nullable error) { NSLog(@"Channel.Lineup response %@", [value description]); if (error != nil) { @@ -68785,10 +68566,8 @@ class SubscribeAttributeChannelLineup : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -68828,9 +68607,7 @@ class ReadChannelCurrentChannel : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeCurrentChannelWithCompletion:^(MTRChannelClusterChannelInfo * _Nullable value, NSError * _Nullable error) { NSLog(@"Channel.CurrentChannel response %@", [value description]); @@ -68856,10 +68633,8 @@ class SubscribeAttributeChannelCurrentChannel : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -68899,9 +68674,7 @@ class ReadChannelGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Channel.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -68926,10 +68699,8 @@ class SubscribeAttributeChannelGeneratedCommandList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -68969,9 +68740,7 @@ class ReadChannelAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Channel.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -68996,10 +68765,8 @@ class SubscribeAttributeChannelAcceptedCommandList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -69039,9 +68806,7 @@ class ReadChannelAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"Channel.AttributeList response %@", [value description]); if (error != nil) { @@ -69066,10 +68831,8 @@ class SubscribeAttributeChannelAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -69109,9 +68872,7 @@ class ReadChannelFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Channel.FeatureMap response %@", [value description]); if (error != nil) { @@ -69136,10 +68897,8 @@ class SubscribeAttributeChannelFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -69179,9 +68938,7 @@ class ReadChannelClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"Channel.ClusterRevision response %@", [value description]); if (error != nil) { @@ -69206,10 +68963,8 @@ class SubscribeAttributeChannelClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000504) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -69268,9 +69023,9 @@ class TargetNavigatorNavigateTarget : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000505) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRTargetNavigatorClusterNavigateTargetParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -69323,9 +69078,9 @@ class ReadTargetNavigatorTargetList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000505) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTargetListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"TargetNavigator.TargetList response %@", [value description]); if (error != nil) { @@ -69350,10 +69105,10 @@ class SubscribeAttributeTargetNavigatorTargetList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000505) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -69393,9 +69148,9 @@ class ReadTargetNavigatorCurrentTarget : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000505) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentTargetWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"TargetNavigator.CurrentTarget response %@", [value description]); if (error != nil) { @@ -69420,10 +69175,10 @@ class SubscribeAttributeTargetNavigatorCurrentTarget : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000505) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -69463,9 +69218,9 @@ class ReadTargetNavigatorGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000505) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"TargetNavigator.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -69490,10 +69245,10 @@ class SubscribeAttributeTargetNavigatorGeneratedCommandList : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000505) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -69533,9 +69288,9 @@ class ReadTargetNavigatorAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000505) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"TargetNavigator.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -69560,10 +69315,10 @@ class SubscribeAttributeTargetNavigatorAcceptedCommandList : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000505) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -69603,9 +69358,9 @@ class ReadTargetNavigatorAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000505) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"TargetNavigator.AttributeList response %@", [value description]); if (error != nil) { @@ -69630,10 +69385,10 @@ class SubscribeAttributeTargetNavigatorAttributeList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000505) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -69673,9 +69428,9 @@ class ReadTargetNavigatorFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000505) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"TargetNavigator.FeatureMap response %@", [value description]); if (error != nil) { @@ -69700,10 +69455,10 @@ class SubscribeAttributeTargetNavigatorFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000505) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -69743,9 +69498,9 @@ class ReadTargetNavigatorClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000505) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"TargetNavigator.ClusterRevision response %@", [value description]); if (error != nil) { @@ -69770,10 +69525,10 @@ class SubscribeAttributeTargetNavigatorClusterRevision : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000505) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -69845,9 +69600,9 @@ class MediaPlaybackPlay : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000506) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRMediaPlaybackClusterPlayParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -69889,9 +69644,9 @@ class MediaPlaybackPause : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000506) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRMediaPlaybackClusterPauseParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -69934,9 +69689,9 @@ class MediaPlaybackStopPlayback : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000506) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRMediaPlaybackClusterStopPlaybackParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -69979,9 +69734,9 @@ class MediaPlaybackStartOver : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000506) command (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRMediaPlaybackClusterStartOverParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -70024,9 +69779,9 @@ class MediaPlaybackPrevious : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000506) command (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRMediaPlaybackClusterPreviousParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -70069,9 +69824,9 @@ class MediaPlaybackNext : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000506) command (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRMediaPlaybackClusterNextParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -70113,9 +69868,9 @@ class MediaPlaybackRewind : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000506) command (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRMediaPlaybackClusterRewindParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -70158,9 +69913,9 @@ class MediaPlaybackFastForward : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000506) command (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRMediaPlaybackClusterFastForwardParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -70204,9 +69959,9 @@ class MediaPlaybackSkipForward : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000506) command (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRMediaPlaybackClusterSkipForwardParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -70252,9 +70007,9 @@ class MediaPlaybackSkipBackward : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000506) command (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRMediaPlaybackClusterSkipBackwardParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -70300,9 +70055,9 @@ class MediaPlaybackSeek : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000506) command (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRMediaPlaybackClusterSeekParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -70347,9 +70102,9 @@ class ReadMediaPlaybackCurrentState : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaPlayback.CurrentState response %@", [value description]); if (error != nil) { @@ -70374,10 +70129,10 @@ class SubscribeAttributeMediaPlaybackCurrentState : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -70417,9 +70172,9 @@ class ReadMediaPlaybackStartTime : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeStartTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaPlayback.StartTime response %@", [value description]); if (error != nil) { @@ -70444,10 +70199,10 @@ class SubscribeAttributeMediaPlaybackStartTime : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -70487,9 +70242,9 @@ class ReadMediaPlaybackDuration : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDurationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaPlayback.Duration response %@", [value description]); if (error != nil) { @@ -70514,10 +70269,10 @@ class SubscribeAttributeMediaPlaybackDuration : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -70557,9 +70312,9 @@ class ReadMediaPlaybackSampledPosition : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSampledPositionWithCompletion:^( MTRMediaPlaybackClusterPlaybackPosition * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaPlayback.SampledPosition response %@", [value description]); @@ -70585,10 +70340,10 @@ class SubscribeAttributeMediaPlaybackSampledPosition : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -70628,9 +70383,9 @@ class ReadMediaPlaybackPlaybackSpeed : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePlaybackSpeedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaPlayback.PlaybackSpeed response %@", [value description]); if (error != nil) { @@ -70655,10 +70410,10 @@ class SubscribeAttributeMediaPlaybackPlaybackSpeed : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -70698,9 +70453,9 @@ class ReadMediaPlaybackSeekRangeEnd : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSeekRangeEndWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaPlayback.SeekRangeEnd response %@", [value description]); if (error != nil) { @@ -70725,10 +70480,10 @@ class SubscribeAttributeMediaPlaybackSeekRangeEnd : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -70768,9 +70523,9 @@ class ReadMediaPlaybackSeekRangeStart : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSeekRangeStartWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaPlayback.SeekRangeStart response %@", [value description]); if (error != nil) { @@ -70795,10 +70550,10 @@ class SubscribeAttributeMediaPlaybackSeekRangeStart : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -70838,9 +70593,9 @@ class ReadMediaPlaybackGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaPlayback.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -70865,10 +70620,10 @@ class SubscribeAttributeMediaPlaybackGeneratedCommandList : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -70908,9 +70663,9 @@ class ReadMediaPlaybackAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaPlayback.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -70935,10 +70690,10 @@ class SubscribeAttributeMediaPlaybackAcceptedCommandList : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -70978,9 +70733,9 @@ class ReadMediaPlaybackAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaPlayback.AttributeList response %@", [value description]); if (error != nil) { @@ -71005,10 +70760,10 @@ class SubscribeAttributeMediaPlaybackAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -71048,9 +70803,9 @@ class ReadMediaPlaybackFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaPlayback.FeatureMap response %@", [value description]); if (error != nil) { @@ -71075,10 +70830,10 @@ class SubscribeAttributeMediaPlaybackFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -71118,9 +70873,9 @@ class ReadMediaPlaybackClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaPlayback.ClusterRevision response %@", [value description]); if (error != nil) { @@ -71145,10 +70900,10 @@ class SubscribeAttributeMediaPlaybackClusterRevision : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000506) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -71209,9 +70964,9 @@ class MediaInputSelectInput : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000507) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRMediaInputClusterSelectInputParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -71254,9 +71009,9 @@ class MediaInputShowInputStatus : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000507) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRMediaInputClusterShowInputStatusParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -71297,9 +71052,9 @@ class MediaInputHideInputStatus : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000507) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRMediaInputClusterHideInputStatusParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -71342,9 +71097,9 @@ class MediaInputRenameInput : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000507) command (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRMediaInputClusterRenameInputParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -71391,9 +71146,9 @@ class ReadMediaInputInputList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000507) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInputListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaInput.InputList response %@", [value description]); if (error != nil) { @@ -71418,10 +71173,10 @@ class SubscribeAttributeMediaInputInputList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000507) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -71461,9 +71216,9 @@ class ReadMediaInputCurrentInput : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000507) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentInputWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaInput.CurrentInput response %@", [value description]); if (error != nil) { @@ -71488,10 +71243,10 @@ class SubscribeAttributeMediaInputCurrentInput : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000507) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -71531,9 +71286,9 @@ class ReadMediaInputGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000507) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaInput.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -71558,10 +71313,10 @@ class SubscribeAttributeMediaInputGeneratedCommandList : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000507) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -71601,9 +71356,9 @@ class ReadMediaInputAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000507) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaInput.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -71628,10 +71383,10 @@ class SubscribeAttributeMediaInputAcceptedCommandList : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x00000507) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -71671,9 +71426,9 @@ class ReadMediaInputAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000507) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaInput.AttributeList response %@", [value description]); if (error != nil) { @@ -71698,10 +71453,10 @@ class SubscribeAttributeMediaInputAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000507) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -71741,9 +71496,9 @@ class ReadMediaInputFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000507) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaInput.FeatureMap response %@", [value description]); if (error != nil) { @@ -71768,10 +71523,10 @@ class SubscribeAttributeMediaInputFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000507) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -71811,9 +71566,9 @@ class ReadMediaInputClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000507) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"MediaInput.ClusterRevision response %@", [value description]); if (error != nil) { @@ -71838,10 +71593,10 @@ class SubscribeAttributeMediaInputClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000507) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -71896,9 +71651,7 @@ class LowPowerSleep : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000508) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; __auto_type * params = [[MTRLowPowerClusterSleepParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -71940,9 +71693,7 @@ class ReadLowPowerGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000508) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"LowPower.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -71967,10 +71718,8 @@ class SubscribeAttributeLowPowerGeneratedCommandList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000508) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -72010,9 +71759,7 @@ class ReadLowPowerAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000508) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"LowPower.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -72037,10 +71784,8 @@ class SubscribeAttributeLowPowerAcceptedCommandList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000508) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -72080,9 +71825,7 @@ class ReadLowPowerAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000508) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"LowPower.AttributeList response %@", [value description]); if (error != nil) { @@ -72107,10 +71850,8 @@ class SubscribeAttributeLowPowerAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000508) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -72150,9 +71891,7 @@ class ReadLowPowerFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000508) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LowPower.FeatureMap response %@", [value description]); if (error != nil) { @@ -72177,10 +71916,8 @@ class SubscribeAttributeLowPowerFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000508) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -72220,9 +71957,7 @@ class ReadLowPowerClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000508) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"LowPower.ClusterRevision response %@", [value description]); if (error != nil) { @@ -72247,10 +71982,8 @@ class SubscribeAttributeLowPowerClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000508) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -72306,9 +72039,9 @@ class KeypadInputSendKey : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000509) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRKeypadInputClusterSendKeyParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -72353,9 +72086,9 @@ class ReadKeypadInputGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000509) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"KeypadInput.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -72380,10 +72113,10 @@ class SubscribeAttributeKeypadInputGeneratedCommandList : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000509) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -72423,9 +72156,9 @@ class ReadKeypadInputAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000509) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"KeypadInput.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -72450,10 +72183,10 @@ class SubscribeAttributeKeypadInputAcceptedCommandList : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000509) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -72493,9 +72226,9 @@ class ReadKeypadInputAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000509) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"KeypadInput.AttributeList response %@", [value description]); if (error != nil) { @@ -72520,10 +72253,10 @@ class SubscribeAttributeKeypadInputAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000509) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -72563,9 +72296,9 @@ class ReadKeypadInputFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000509) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"KeypadInput.FeatureMap response %@", [value description]); if (error != nil) { @@ -72590,10 +72323,10 @@ class SubscribeAttributeKeypadInputFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000509) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -72633,9 +72366,9 @@ class ReadKeypadInputClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000509) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"KeypadInput.ClusterRevision response %@", [value description]); if (error != nil) { @@ -72660,10 +72393,10 @@ class SubscribeAttributeKeypadInputClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000509) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -72725,9 +72458,9 @@ class ContentLauncherLaunchContent : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRContentLauncherClusterLaunchContentParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -72817,9 +72550,9 @@ class ContentLauncherLaunchURL : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRContentLauncherClusterLaunchURLParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -73050,9 +72783,9 @@ class ReadContentLauncherAcceptHeader : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptHeaderWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ContentLauncher.AcceptHeader response %@", [value description]); if (error != nil) { @@ -73077,10 +72810,10 @@ class SubscribeAttributeContentLauncherAcceptHeader : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -73120,9 +72853,9 @@ class ReadContentLauncherSupportedStreamingProtocols : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeSupportedStreamingProtocolsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ContentLauncher.SupportedStreamingProtocols response %@", [value description]); if (error != nil) { @@ -73150,10 +72883,10 @@ class WriteContentLauncherSupportedStreamingProtocols : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) WriteAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -73189,10 +72922,10 @@ class SubscribeAttributeContentLauncherSupportedStreamingProtocols : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -73232,9 +72965,9 @@ class ReadContentLauncherGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ContentLauncher.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -73259,10 +72992,10 @@ class SubscribeAttributeContentLauncherGeneratedCommandList : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -73302,9 +73035,9 @@ class ReadContentLauncherAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ContentLauncher.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -73329,10 +73062,10 @@ class SubscribeAttributeContentLauncherAcceptedCommandList : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -73372,9 +73105,9 @@ class ReadContentLauncherAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ContentLauncher.AttributeList response %@", [value description]); if (error != nil) { @@ -73399,10 +73132,10 @@ class SubscribeAttributeContentLauncherAttributeList : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -73442,9 +73175,9 @@ class ReadContentLauncherFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ContentLauncher.FeatureMap response %@", [value description]); if (error != nil) { @@ -73469,10 +73202,10 @@ class SubscribeAttributeContentLauncherFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -73512,9 +73245,9 @@ class ReadContentLauncherClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ContentLauncher.ClusterRevision response %@", [value description]); if (error != nil) { @@ -73539,10 +73272,10 @@ class SubscribeAttributeContentLauncherClusterRevision : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x0000050A) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -73601,9 +73334,9 @@ class AudioOutputSelectOutput : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRAudioOutputClusterSelectOutputParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -73648,9 +73381,9 @@ class AudioOutputRenameOutput : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRAudioOutputClusterRenameOutputParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -73697,9 +73430,9 @@ class ReadAudioOutputOutputList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOutputListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"AudioOutput.OutputList response %@", [value description]); if (error != nil) { @@ -73724,10 +73457,10 @@ class SubscribeAttributeAudioOutputOutputList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -73767,9 +73500,9 @@ class ReadAudioOutputCurrentOutput : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentOutputWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"AudioOutput.CurrentOutput response %@", [value description]); if (error != nil) { @@ -73794,10 +73527,10 @@ class SubscribeAttributeAudioOutputCurrentOutput : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -73837,9 +73570,9 @@ class ReadAudioOutputGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"AudioOutput.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -73864,10 +73597,10 @@ class SubscribeAttributeAudioOutputGeneratedCommandList : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -73907,9 +73640,9 @@ class ReadAudioOutputAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"AudioOutput.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -73934,10 +73667,10 @@ class SubscribeAttributeAudioOutputAcceptedCommandList : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -73977,9 +73710,9 @@ class ReadAudioOutputAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"AudioOutput.AttributeList response %@", [value description]); if (error != nil) { @@ -74004,10 +73737,10 @@ class SubscribeAttributeAudioOutputAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -74047,9 +73780,9 @@ class ReadAudioOutputFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"AudioOutput.FeatureMap response %@", [value description]); if (error != nil) { @@ -74074,10 +73807,10 @@ class SubscribeAttributeAudioOutputFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -74117,9 +73850,9 @@ class ReadAudioOutputClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"AudioOutput.ClusterRevision response %@", [value description]); if (error != nil) { @@ -74144,10 +73877,10 @@ class SubscribeAttributeAudioOutputClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000050B) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -74209,9 +73942,9 @@ class ApplicationLauncherLaunchApp : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRApplicationLauncherClusterLaunchAppParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -74268,9 +74001,9 @@ class ApplicationLauncherStopApp : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRApplicationLauncherClusterStopAppParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -74322,9 +74055,9 @@ class ApplicationLauncherHideApp : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRApplicationLauncherClusterHideAppParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -74375,9 +74108,9 @@ class ReadApplicationLauncherCatalogList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCatalogListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationLauncher.CatalogList response %@", [value description]); if (error != nil) { @@ -74402,10 +74135,10 @@ class SubscribeAttributeApplicationLauncherCatalogList : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -74445,9 +74178,9 @@ class ReadApplicationLauncherCurrentApp : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentAppWithCompletion:^( MTRApplicationLauncherClusterApplicationEP * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationLauncher.CurrentApp response %@", [value description]); @@ -74477,10 +74210,10 @@ class WriteApplicationLauncherCurrentApp : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) WriteAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -74531,10 +74264,10 @@ class SubscribeAttributeApplicationLauncherCurrentApp : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -74574,9 +74307,9 @@ class ReadApplicationLauncherGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationLauncher.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -74601,10 +74334,10 @@ class SubscribeAttributeApplicationLauncherGeneratedCommandList : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -74644,9 +74377,9 @@ class ReadApplicationLauncherAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationLauncher.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -74671,10 +74404,10 @@ class SubscribeAttributeApplicationLauncherAcceptedCommandList : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -74714,9 +74447,9 @@ class ReadApplicationLauncherAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationLauncher.AttributeList response %@", [value description]); if (error != nil) { @@ -74741,10 +74474,10 @@ class SubscribeAttributeApplicationLauncherAttributeList : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -74784,9 +74517,9 @@ class ReadApplicationLauncherFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationLauncher.FeatureMap response %@", [value description]); if (error != nil) { @@ -74811,10 +74544,10 @@ class SubscribeAttributeApplicationLauncherFeatureMap : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -74854,9 +74587,9 @@ class ReadApplicationLauncherClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationLauncher.ClusterRevision response %@", [value description]); if (error != nil) { @@ -74881,10 +74614,10 @@ class SubscribeAttributeApplicationLauncherClusterRevision : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x0000050C) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -74947,9 +74680,9 @@ class ReadApplicationBasicVendorName : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeVendorNameWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationBasic.VendorName response %@", [value description]); if (error != nil) { @@ -74974,10 +74707,10 @@ class SubscribeAttributeApplicationBasicVendorName : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -75017,9 +74750,9 @@ class ReadApplicationBasicVendorID : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeVendorIDWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationBasic.VendorID response %@", [value description]); if (error != nil) { @@ -75044,10 +74777,10 @@ class SubscribeAttributeApplicationBasicVendorID : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -75087,9 +74820,9 @@ class ReadApplicationBasicApplicationName : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeApplicationNameWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationBasic.ApplicationName response %@", [value description]); if (error != nil) { @@ -75114,10 +74847,10 @@ class SubscribeAttributeApplicationBasicApplicationName : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -75157,9 +74890,9 @@ class ReadApplicationBasicProductID : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeProductIDWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationBasic.ProductID response %@", [value description]); if (error != nil) { @@ -75184,10 +74917,10 @@ class SubscribeAttributeApplicationBasicProductID : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -75227,9 +74960,9 @@ class ReadApplicationBasicApplication : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeApplicationWithCompletion:^( MTRApplicationBasicClusterApplicationBasicApplication * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationBasic.Application response %@", [value description]); @@ -75255,10 +74988,10 @@ class SubscribeAttributeApplicationBasicApplication : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -75298,9 +75031,9 @@ class ReadApplicationBasicStatus : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationBasic.Status response %@", [value description]); if (error != nil) { @@ -75325,10 +75058,10 @@ class SubscribeAttributeApplicationBasicStatus : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -75368,9 +75101,9 @@ class ReadApplicationBasicApplicationVersion : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeApplicationVersionWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationBasic.ApplicationVersion response %@", [value description]); if (error != nil) { @@ -75395,10 +75128,10 @@ class SubscribeAttributeApplicationBasicApplicationVersion : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -75438,9 +75171,9 @@ class ReadApplicationBasicAllowedVendorList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAllowedVendorListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationBasic.AllowedVendorList response %@", [value description]); if (error != nil) { @@ -75465,10 +75198,10 @@ class SubscribeAttributeApplicationBasicAllowedVendorList : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -75508,9 +75241,9 @@ class ReadApplicationBasicGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationBasic.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -75535,10 +75268,10 @@ class SubscribeAttributeApplicationBasicGeneratedCommandList : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -75578,9 +75311,9 @@ class ReadApplicationBasicAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationBasic.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -75605,10 +75338,10 @@ class SubscribeAttributeApplicationBasicAcceptedCommandList : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -75648,9 +75381,9 @@ class ReadApplicationBasicAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationBasic.AttributeList response %@", [value description]); if (error != nil) { @@ -75675,10 +75408,10 @@ class SubscribeAttributeApplicationBasicAttributeList : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -75718,9 +75451,9 @@ class ReadApplicationBasicFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationBasic.FeatureMap response %@", [value description]); if (error != nil) { @@ -75745,10 +75478,10 @@ class SubscribeAttributeApplicationBasicFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -75788,9 +75521,9 @@ class ReadApplicationBasicClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ApplicationBasic.ClusterRevision response %@", [value description]); if (error != nil) { @@ -75815,10 +75548,10 @@ class SubscribeAttributeApplicationBasicClusterRevision : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x0000050D) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -75876,9 +75609,9 @@ class AccountLoginGetSetupPIN : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000050E) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRAccountLoginClusterGetSetupPINParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -75927,9 +75660,9 @@ class AccountLoginLogin : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000050E) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRAccountLoginClusterLoginParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -75977,9 +75710,9 @@ class AccountLoginLogout : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x0000050E) command (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRAccountLoginClusterLogoutParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -76021,9 +75754,9 @@ class ReadAccountLoginGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050E) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"AccountLogin.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -76048,10 +75781,10 @@ class SubscribeAttributeAccountLoginGeneratedCommandList : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x0000050E) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -76091,9 +75824,9 @@ class ReadAccountLoginAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050E) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"AccountLogin.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -76118,10 +75851,10 @@ class SubscribeAttributeAccountLoginAcceptedCommandList : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x0000050E) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -76161,9 +75894,9 @@ class ReadAccountLoginAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050E) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"AccountLogin.AttributeList response %@", [value description]); if (error != nil) { @@ -76188,10 +75921,10 @@ class SubscribeAttributeAccountLoginAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000050E) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -76231,9 +75964,9 @@ class ReadAccountLoginFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050E) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"AccountLogin.FeatureMap response %@", [value description]); if (error != nil) { @@ -76258,10 +75991,10 @@ class SubscribeAttributeAccountLoginFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x0000050E) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -76301,9 +76034,9 @@ class ReadAccountLoginClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050E) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"AccountLogin.ClusterRevision response %@", [value description]); if (error != nil) { @@ -76328,10 +76061,10 @@ class SubscribeAttributeAccountLoginClusterRevision : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x0000050E) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -76515,9 +76248,9 @@ class ElectricalMeasurementGetProfileInfoCommand : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRElectricalMeasurementClusterGetProfileInfoCommandParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -76561,9 +76294,9 @@ class ElectricalMeasurementGetMeasurementProfileCommand : public ClusterCommand ChipLogProgress(chipTool, "Sending cluster (0x00000B04) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRElectricalMeasurementClusterGetMeasurementProfileCommandParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -76609,9 +76342,9 @@ class ReadElectricalMeasurementMeasurementType : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasurementTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.MeasurementType response %@", [value description]); if (error != nil) { @@ -76636,10 +76369,10 @@ class SubscribeAttributeElectricalMeasurementMeasurementType : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -76679,9 +76412,9 @@ class ReadElectricalMeasurementDcVoltage : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000100) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDcVoltageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.DcVoltage response %@", [value description]); if (error != nil) { @@ -76706,10 +76439,10 @@ class SubscribeAttributeElectricalMeasurementDcVoltage : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000100) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -76749,9 +76482,9 @@ class ReadElectricalMeasurementDcVoltageMin : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000101) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDcVoltageMinWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.DcVoltageMin response %@", [value description]); if (error != nil) { @@ -76776,10 +76509,10 @@ class SubscribeAttributeElectricalMeasurementDcVoltageMin : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000101) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -76819,9 +76552,9 @@ class ReadElectricalMeasurementDcVoltageMax : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000102) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDcVoltageMaxWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.DcVoltageMax response %@", [value description]); if (error != nil) { @@ -76846,10 +76579,10 @@ class SubscribeAttributeElectricalMeasurementDcVoltageMax : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000102) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -76889,9 +76622,9 @@ class ReadElectricalMeasurementDcCurrent : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000103) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDcCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.DcCurrent response %@", [value description]); if (error != nil) { @@ -76916,10 +76649,10 @@ class SubscribeAttributeElectricalMeasurementDcCurrent : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000103) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -76959,9 +76692,9 @@ class ReadElectricalMeasurementDcCurrentMin : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000104) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDcCurrentMinWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.DcCurrentMin response %@", [value description]); if (error != nil) { @@ -76986,10 +76719,10 @@ class SubscribeAttributeElectricalMeasurementDcCurrentMin : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000104) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -77029,9 +76762,9 @@ class ReadElectricalMeasurementDcCurrentMax : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000105) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDcCurrentMaxWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.DcCurrentMax response %@", [value description]); if (error != nil) { @@ -77056,10 +76789,10 @@ class SubscribeAttributeElectricalMeasurementDcCurrentMax : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000105) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -77099,9 +76832,9 @@ class ReadElectricalMeasurementDcPower : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000106) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDcPowerWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.DcPower response %@", [value description]); if (error != nil) { @@ -77126,10 +76859,10 @@ class SubscribeAttributeElectricalMeasurementDcPower : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000106) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -77169,9 +76902,9 @@ class ReadElectricalMeasurementDcPowerMin : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000107) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDcPowerMinWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.DcPowerMin response %@", [value description]); if (error != nil) { @@ -77196,10 +76929,10 @@ class SubscribeAttributeElectricalMeasurementDcPowerMin : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000107) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -77239,9 +76972,9 @@ class ReadElectricalMeasurementDcPowerMax : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000108) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDcPowerMaxWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.DcPowerMax response %@", [value description]); if (error != nil) { @@ -77266,10 +76999,10 @@ class SubscribeAttributeElectricalMeasurementDcPowerMax : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000108) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -77309,9 +77042,9 @@ class ReadElectricalMeasurementDcVoltageMultiplier : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000200) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDcVoltageMultiplierWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.DcVoltageMultiplier response %@", [value description]); if (error != nil) { @@ -77336,10 +77069,10 @@ class SubscribeAttributeElectricalMeasurementDcVoltageMultiplier : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000200) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -77379,9 +77112,9 @@ class ReadElectricalMeasurementDcVoltageDivisor : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000201) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDcVoltageDivisorWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.DcVoltageDivisor response %@", [value description]); if (error != nil) { @@ -77406,10 +77139,10 @@ class SubscribeAttributeElectricalMeasurementDcVoltageDivisor : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000201) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -77449,9 +77182,9 @@ class ReadElectricalMeasurementDcCurrentMultiplier : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000202) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDcCurrentMultiplierWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.DcCurrentMultiplier response %@", [value description]); if (error != nil) { @@ -77476,10 +77209,10 @@ class SubscribeAttributeElectricalMeasurementDcCurrentMultiplier : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000202) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -77519,9 +77252,9 @@ class ReadElectricalMeasurementDcCurrentDivisor : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000203) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDcCurrentDivisorWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.DcCurrentDivisor response %@", [value description]); if (error != nil) { @@ -77546,10 +77279,10 @@ class SubscribeAttributeElectricalMeasurementDcCurrentDivisor : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000203) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -77589,9 +77322,9 @@ class ReadElectricalMeasurementDcPowerMultiplier : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000204) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDcPowerMultiplierWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.DcPowerMultiplier response %@", [value description]); if (error != nil) { @@ -77616,10 +77349,10 @@ class SubscribeAttributeElectricalMeasurementDcPowerMultiplier : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000204) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -77659,9 +77392,9 @@ class ReadElectricalMeasurementDcPowerDivisor : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000205) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeDcPowerDivisorWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.DcPowerDivisor response %@", [value description]); if (error != nil) { @@ -77686,10 +77419,10 @@ class SubscribeAttributeElectricalMeasurementDcPowerDivisor : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000205) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -77729,9 +77462,9 @@ class ReadElectricalMeasurementAcFrequency : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000300) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcFrequencyWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcFrequency response %@", [value description]); if (error != nil) { @@ -77756,10 +77489,10 @@ class SubscribeAttributeElectricalMeasurementAcFrequency : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000300) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -77799,9 +77532,9 @@ class ReadElectricalMeasurementAcFrequencyMin : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000301) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcFrequencyMinWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcFrequencyMin response %@", [value description]); if (error != nil) { @@ -77826,10 +77559,10 @@ class SubscribeAttributeElectricalMeasurementAcFrequencyMin : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000301) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -77869,9 +77602,9 @@ class ReadElectricalMeasurementAcFrequencyMax : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000302) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcFrequencyMaxWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcFrequencyMax response %@", [value description]); if (error != nil) { @@ -77896,10 +77629,10 @@ class SubscribeAttributeElectricalMeasurementAcFrequencyMax : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000302) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -77939,9 +77672,9 @@ class ReadElectricalMeasurementNeutralCurrent : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000303) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNeutralCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.NeutralCurrent response %@", [value description]); if (error != nil) { @@ -77966,10 +77699,10 @@ class SubscribeAttributeElectricalMeasurementNeutralCurrent : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000303) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -78009,9 +77742,9 @@ class ReadElectricalMeasurementTotalActivePower : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000304) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTotalActivePowerWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.TotalActivePower response %@", [value description]); if (error != nil) { @@ -78036,10 +77769,10 @@ class SubscribeAttributeElectricalMeasurementTotalActivePower : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000304) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -78079,9 +77812,9 @@ class ReadElectricalMeasurementTotalReactivePower : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000305) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTotalReactivePowerWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.TotalReactivePower response %@", [value description]); if (error != nil) { @@ -78106,10 +77839,10 @@ class SubscribeAttributeElectricalMeasurementTotalReactivePower : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000305) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -78149,9 +77882,9 @@ class ReadElectricalMeasurementTotalApparentPower : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000306) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTotalApparentPowerWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.TotalApparentPower response %@", [value description]); if (error != nil) { @@ -78176,10 +77909,10 @@ class SubscribeAttributeElectricalMeasurementTotalApparentPower : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000306) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -78219,9 +77952,9 @@ class ReadElectricalMeasurementMeasured1stHarmonicCurrent : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000307) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasured1stHarmonicCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.Measured1stHarmonicCurrent response %@", [value description]); if (error != nil) { @@ -78246,10 +77979,10 @@ class SubscribeAttributeElectricalMeasurementMeasured1stHarmonicCurrent : public { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000307) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -78289,9 +78022,9 @@ class ReadElectricalMeasurementMeasured3rdHarmonicCurrent : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000308) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasured3rdHarmonicCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.Measured3rdHarmonicCurrent response %@", [value description]); if (error != nil) { @@ -78316,10 +78049,10 @@ class SubscribeAttributeElectricalMeasurementMeasured3rdHarmonicCurrent : public { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000308) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -78359,9 +78092,9 @@ class ReadElectricalMeasurementMeasured5thHarmonicCurrent : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000309) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasured5thHarmonicCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.Measured5thHarmonicCurrent response %@", [value description]); if (error != nil) { @@ -78386,10 +78119,10 @@ class SubscribeAttributeElectricalMeasurementMeasured5thHarmonicCurrent : public { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000309) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -78429,9 +78162,9 @@ class ReadElectricalMeasurementMeasured7thHarmonicCurrent : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000030A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasured7thHarmonicCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.Measured7thHarmonicCurrent response %@", [value description]); if (error != nil) { @@ -78456,10 +78189,10 @@ class SubscribeAttributeElectricalMeasurementMeasured7thHarmonicCurrent : public { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000030A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -78499,9 +78232,9 @@ class ReadElectricalMeasurementMeasured9thHarmonicCurrent : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000030B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasured9thHarmonicCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.Measured9thHarmonicCurrent response %@", [value description]); if (error != nil) { @@ -78526,10 +78259,10 @@ class SubscribeAttributeElectricalMeasurementMeasured9thHarmonicCurrent : public { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000030B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -78569,9 +78302,9 @@ class ReadElectricalMeasurementMeasured11thHarmonicCurrent : public ReadAttribut ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000030C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasured11thHarmonicCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.Measured11thHarmonicCurrent response %@", [value description]); if (error != nil) { @@ -78596,10 +78329,10 @@ class SubscribeAttributeElectricalMeasurementMeasured11thHarmonicCurrent : publi { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000030C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -78639,9 +78372,9 @@ class ReadElectricalMeasurementMeasuredPhase1stHarmonicCurrent : public ReadAttr ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000030D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasuredPhase1stHarmonicCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.MeasuredPhase1stHarmonicCurrent response %@", [value description]); @@ -78667,10 +78400,10 @@ class SubscribeAttributeElectricalMeasurementMeasuredPhase1stHarmonicCurrent : p { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000030D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -78710,9 +78443,9 @@ class ReadElectricalMeasurementMeasuredPhase3rdHarmonicCurrent : public ReadAttr ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000030E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasuredPhase3rdHarmonicCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.MeasuredPhase3rdHarmonicCurrent response %@", [value description]); @@ -78738,10 +78471,10 @@ class SubscribeAttributeElectricalMeasurementMeasuredPhase3rdHarmonicCurrent : p { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000030E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -78781,9 +78514,9 @@ class ReadElectricalMeasurementMeasuredPhase5thHarmonicCurrent : public ReadAttr ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000030F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasuredPhase5thHarmonicCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.MeasuredPhase5thHarmonicCurrent response %@", [value description]); @@ -78809,10 +78542,10 @@ class SubscribeAttributeElectricalMeasurementMeasuredPhase5thHarmonicCurrent : p { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000030F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -78852,9 +78585,9 @@ class ReadElectricalMeasurementMeasuredPhase7thHarmonicCurrent : public ReadAttr ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000310) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasuredPhase7thHarmonicCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.MeasuredPhase7thHarmonicCurrent response %@", [value description]); @@ -78880,10 +78613,10 @@ class SubscribeAttributeElectricalMeasurementMeasuredPhase7thHarmonicCurrent : p { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000310) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -78923,9 +78656,9 @@ class ReadElectricalMeasurementMeasuredPhase9thHarmonicCurrent : public ReadAttr ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000311) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasuredPhase9thHarmonicCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.MeasuredPhase9thHarmonicCurrent response %@", [value description]); @@ -78951,10 +78684,10 @@ class SubscribeAttributeElectricalMeasurementMeasuredPhase9thHarmonicCurrent : p { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000311) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -78994,9 +78727,9 @@ class ReadElectricalMeasurementMeasuredPhase11thHarmonicCurrent : public ReadAtt ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000312) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeMeasuredPhase11thHarmonicCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.MeasuredPhase11thHarmonicCurrent response %@", [value description]); @@ -79022,10 +78755,10 @@ class SubscribeAttributeElectricalMeasurementMeasuredPhase11thHarmonicCurrent : { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000312) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -79065,9 +78798,9 @@ class ReadElectricalMeasurementAcFrequencyMultiplier : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000400) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcFrequencyMultiplierWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcFrequencyMultiplier response %@", [value description]); if (error != nil) { @@ -79092,10 +78825,10 @@ class SubscribeAttributeElectricalMeasurementAcFrequencyMultiplier : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000400) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -79135,9 +78868,9 @@ class ReadElectricalMeasurementAcFrequencyDivisor : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000401) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcFrequencyDivisorWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcFrequencyDivisor response %@", [value description]); if (error != nil) { @@ -79162,10 +78895,10 @@ class SubscribeAttributeElectricalMeasurementAcFrequencyDivisor : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000401) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -79205,9 +78938,9 @@ class ReadElectricalMeasurementPowerMultiplier : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000402) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePowerMultiplierWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.PowerMultiplier response %@", [value description]); if (error != nil) { @@ -79232,10 +78965,10 @@ class SubscribeAttributeElectricalMeasurementPowerMultiplier : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000402) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -79275,9 +79008,9 @@ class ReadElectricalMeasurementPowerDivisor : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000403) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePowerDivisorWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.PowerDivisor response %@", [value description]); if (error != nil) { @@ -79302,10 +79035,10 @@ class SubscribeAttributeElectricalMeasurementPowerDivisor : public SubscribeAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000403) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -79345,9 +79078,9 @@ class ReadElectricalMeasurementHarmonicCurrentMultiplier : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000404) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeHarmonicCurrentMultiplierWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.HarmonicCurrentMultiplier response %@", [value description]); if (error != nil) { @@ -79372,10 +79105,10 @@ class SubscribeAttributeElectricalMeasurementHarmonicCurrentMultiplier : public { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000404) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -79415,9 +79148,9 @@ class ReadElectricalMeasurementPhaseHarmonicCurrentMultiplier : public ReadAttri ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000405) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePhaseHarmonicCurrentMultiplierWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.PhaseHarmonicCurrentMultiplier response %@", [value description]); @@ -79443,10 +79176,10 @@ class SubscribeAttributeElectricalMeasurementPhaseHarmonicCurrentMultiplier : pu { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000405) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -79486,9 +79219,9 @@ class ReadElectricalMeasurementInstantaneousVoltage : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000500) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInstantaneousVoltageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.InstantaneousVoltage response %@", [value description]); if (error != nil) { @@ -79513,10 +79246,10 @@ class SubscribeAttributeElectricalMeasurementInstantaneousVoltage : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000500) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -79556,9 +79289,9 @@ class ReadElectricalMeasurementInstantaneousLineCurrent : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000501) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInstantaneousLineCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.InstantaneousLineCurrent response %@", [value description]); if (error != nil) { @@ -79583,10 +79316,10 @@ class SubscribeAttributeElectricalMeasurementInstantaneousLineCurrent : public S { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000501) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -79626,9 +79359,9 @@ class ReadElectricalMeasurementInstantaneousActiveCurrent : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000502) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInstantaneousActiveCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.InstantaneousActiveCurrent response %@", [value description]); if (error != nil) { @@ -79653,10 +79386,10 @@ class SubscribeAttributeElectricalMeasurementInstantaneousActiveCurrent : public { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000502) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -79696,9 +79429,9 @@ class ReadElectricalMeasurementInstantaneousReactiveCurrent : public ReadAttribu ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000503) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInstantaneousReactiveCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.InstantaneousReactiveCurrent response %@", [value description]); if (error != nil) { @@ -79723,10 +79456,10 @@ class SubscribeAttributeElectricalMeasurementInstantaneousReactiveCurrent : publ { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000503) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -79766,9 +79499,9 @@ class ReadElectricalMeasurementInstantaneousPower : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000504) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInstantaneousPowerWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.InstantaneousPower response %@", [value description]); if (error != nil) { @@ -79793,10 +79526,10 @@ class SubscribeAttributeElectricalMeasurementInstantaneousPower : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000504) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -79836,9 +79569,9 @@ class ReadElectricalMeasurementRmsVoltage : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000505) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltage response %@", [value description]); if (error != nil) { @@ -79863,10 +79596,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltage : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000505) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -79906,9 +79639,9 @@ class ReadElectricalMeasurementRmsVoltageMin : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000506) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltageMinWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltageMin response %@", [value description]); if (error != nil) { @@ -79933,10 +79666,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltageMin : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000506) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -79976,9 +79709,9 @@ class ReadElectricalMeasurementRmsVoltageMax : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000507) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltageMaxWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltageMax response %@", [value description]); if (error != nil) { @@ -80003,10 +79736,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltageMax : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000507) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -80046,9 +79779,9 @@ class ReadElectricalMeasurementRmsCurrent : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000508) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsCurrent response %@", [value description]); if (error != nil) { @@ -80073,10 +79806,10 @@ class SubscribeAttributeElectricalMeasurementRmsCurrent : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000508) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -80116,9 +79849,9 @@ class ReadElectricalMeasurementRmsCurrentMin : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000509) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsCurrentMinWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsCurrentMin response %@", [value description]); if (error != nil) { @@ -80143,10 +79876,10 @@ class SubscribeAttributeElectricalMeasurementRmsCurrentMin : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000509) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -80186,9 +79919,9 @@ class ReadElectricalMeasurementRmsCurrentMax : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000050A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsCurrentMaxWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsCurrentMax response %@", [value description]); if (error != nil) { @@ -80213,10 +79946,10 @@ class SubscribeAttributeElectricalMeasurementRmsCurrentMax : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000050A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -80256,9 +79989,9 @@ class ReadElectricalMeasurementActivePower : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000050B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActivePowerWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ActivePower response %@", [value description]); if (error != nil) { @@ -80283,10 +80016,10 @@ class SubscribeAttributeElectricalMeasurementActivePower : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000050B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -80326,9 +80059,9 @@ class ReadElectricalMeasurementActivePowerMin : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000050C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActivePowerMinWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ActivePowerMin response %@", [value description]); if (error != nil) { @@ -80353,10 +80086,10 @@ class SubscribeAttributeElectricalMeasurementActivePowerMin : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000050C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -80396,9 +80129,9 @@ class ReadElectricalMeasurementActivePowerMax : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000050D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActivePowerMaxWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ActivePowerMax response %@", [value description]); if (error != nil) { @@ -80423,10 +80156,10 @@ class SubscribeAttributeElectricalMeasurementActivePowerMax : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000050D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -80466,9 +80199,9 @@ class ReadElectricalMeasurementReactivePower : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000050E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeReactivePowerWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ReactivePower response %@", [value description]); if (error != nil) { @@ -80493,10 +80226,10 @@ class SubscribeAttributeElectricalMeasurementReactivePower : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000050E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -80536,9 +80269,9 @@ class ReadElectricalMeasurementApparentPower : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000050F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeApparentPowerWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ApparentPower response %@", [value description]); if (error != nil) { @@ -80563,10 +80296,10 @@ class SubscribeAttributeElectricalMeasurementApparentPower : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000050F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -80606,9 +80339,9 @@ class ReadElectricalMeasurementPowerFactor : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000510) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePowerFactorWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.PowerFactor response %@", [value description]); if (error != nil) { @@ -80633,10 +80366,10 @@ class SubscribeAttributeElectricalMeasurementPowerFactor : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000510) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -80676,9 +80409,9 @@ class ReadElectricalMeasurementAverageRmsVoltageMeasurementPeriod : public ReadA ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000511) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAverageRmsVoltageMeasurementPeriodWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AverageRmsVoltageMeasurementPeriod response %@", [value description]); @@ -80707,10 +80440,10 @@ class WriteElectricalMeasurementAverageRmsVoltageMeasurementPeriod : public Writ { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) WriteAttribute (0x00000511) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -80746,10 +80479,10 @@ class SubscribeAttributeElectricalMeasurementAverageRmsVoltageMeasurementPeriod { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000511) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -80789,9 +80522,9 @@ class ReadElectricalMeasurementAverageRmsUnderVoltageCounter : public ReadAttrib ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000513) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAverageRmsUnderVoltageCounterWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AverageRmsUnderVoltageCounter response %@", [value description]); if (error != nil) { @@ -80819,10 +80552,10 @@ class WriteElectricalMeasurementAverageRmsUnderVoltageCounter : public WriteAttr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) WriteAttribute (0x00000513) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -80859,10 +80592,10 @@ class SubscribeAttributeElectricalMeasurementAverageRmsUnderVoltageCounter : pub { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000513) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -80902,9 +80635,9 @@ class ReadElectricalMeasurementRmsExtremeOverVoltagePeriod : public ReadAttribut ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000514) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsExtremeOverVoltagePeriodWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsExtremeOverVoltagePeriod response %@", [value description]); if (error != nil) { @@ -80932,10 +80665,10 @@ class WriteElectricalMeasurementRmsExtremeOverVoltagePeriod : public WriteAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) WriteAttribute (0x00000514) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -80972,10 +80705,10 @@ class SubscribeAttributeElectricalMeasurementRmsExtremeOverVoltagePeriod : publi { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000514) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -81015,9 +80748,9 @@ class ReadElectricalMeasurementRmsExtremeUnderVoltagePeriod : public ReadAttribu ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000515) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsExtremeUnderVoltagePeriodWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsExtremeUnderVoltagePeriod response %@", [value description]); if (error != nil) { @@ -81045,10 +80778,10 @@ class WriteElectricalMeasurementRmsExtremeUnderVoltagePeriod : public WriteAttri { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) WriteAttribute (0x00000515) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -81085,10 +80818,10 @@ class SubscribeAttributeElectricalMeasurementRmsExtremeUnderVoltagePeriod : publ { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000515) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -81128,9 +80861,9 @@ class ReadElectricalMeasurementRmsVoltageSagPeriod : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000516) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltageSagPeriodWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltageSagPeriod response %@", [value description]); if (error != nil) { @@ -81158,10 +80891,10 @@ class WriteElectricalMeasurementRmsVoltageSagPeriod : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) WriteAttribute (0x00000516) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -81195,10 +80928,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltageSagPeriod : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000516) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -81238,9 +80971,9 @@ class ReadElectricalMeasurementRmsVoltageSwellPeriod : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000517) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltageSwellPeriodWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltageSwellPeriod response %@", [value description]); if (error != nil) { @@ -81268,10 +81001,10 @@ class WriteElectricalMeasurementRmsVoltageSwellPeriod : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) WriteAttribute (0x00000517) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -81306,10 +81039,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltageSwellPeriod : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000517) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -81349,9 +81082,9 @@ class ReadElectricalMeasurementAcVoltageMultiplier : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000600) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcVoltageMultiplierWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcVoltageMultiplier response %@", [value description]); if (error != nil) { @@ -81376,10 +81109,10 @@ class SubscribeAttributeElectricalMeasurementAcVoltageMultiplier : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000600) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -81419,9 +81152,9 @@ class ReadElectricalMeasurementAcVoltageDivisor : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000601) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcVoltageDivisorWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcVoltageDivisor response %@", [value description]); if (error != nil) { @@ -81446,10 +81179,10 @@ class SubscribeAttributeElectricalMeasurementAcVoltageDivisor : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000601) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -81489,9 +81222,9 @@ class ReadElectricalMeasurementAcCurrentMultiplier : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000602) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcCurrentMultiplierWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcCurrentMultiplier response %@", [value description]); if (error != nil) { @@ -81516,10 +81249,10 @@ class SubscribeAttributeElectricalMeasurementAcCurrentMultiplier : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000602) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -81559,9 +81292,9 @@ class ReadElectricalMeasurementAcCurrentDivisor : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000603) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcCurrentDivisorWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcCurrentDivisor response %@", [value description]); if (error != nil) { @@ -81586,10 +81319,10 @@ class SubscribeAttributeElectricalMeasurementAcCurrentDivisor : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000603) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -81629,9 +81362,9 @@ class ReadElectricalMeasurementAcPowerMultiplier : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000604) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcPowerMultiplierWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcPowerMultiplier response %@", [value description]); if (error != nil) { @@ -81656,10 +81389,10 @@ class SubscribeAttributeElectricalMeasurementAcPowerMultiplier : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000604) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -81699,9 +81432,9 @@ class ReadElectricalMeasurementAcPowerDivisor : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000605) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcPowerDivisorWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcPowerDivisor response %@", [value description]); if (error != nil) { @@ -81726,10 +81459,10 @@ class SubscribeAttributeElectricalMeasurementAcPowerDivisor : public SubscribeAt { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000605) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -81769,9 +81502,9 @@ class ReadElectricalMeasurementOverloadAlarmsMask : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000700) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOverloadAlarmsMaskWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.OverloadAlarmsMask response %@", [value description]); if (error != nil) { @@ -81799,10 +81532,10 @@ class WriteElectricalMeasurementOverloadAlarmsMask : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) WriteAttribute (0x00000700) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -81836,10 +81569,10 @@ class SubscribeAttributeElectricalMeasurementOverloadAlarmsMask : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000700) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -81879,9 +81612,9 @@ class ReadElectricalMeasurementVoltageOverload : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000701) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeVoltageOverloadWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.VoltageOverload response %@", [value description]); if (error != nil) { @@ -81906,10 +81639,10 @@ class SubscribeAttributeElectricalMeasurementVoltageOverload : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000701) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -81949,9 +81682,9 @@ class ReadElectricalMeasurementCurrentOverload : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000702) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCurrentOverloadWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.CurrentOverload response %@", [value description]); if (error != nil) { @@ -81976,10 +81709,10 @@ class SubscribeAttributeElectricalMeasurementCurrentOverload : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000702) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -82019,9 +81752,9 @@ class ReadElectricalMeasurementAcOverloadAlarmsMask : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000800) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcOverloadAlarmsMaskWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcOverloadAlarmsMask response %@", [value description]); if (error != nil) { @@ -82049,10 +81782,10 @@ class WriteElectricalMeasurementAcOverloadAlarmsMask : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) WriteAttribute (0x00000800) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -82087,10 +81820,10 @@ class SubscribeAttributeElectricalMeasurementAcOverloadAlarmsMask : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000800) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -82130,9 +81863,9 @@ class ReadElectricalMeasurementAcVoltageOverload : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000801) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcVoltageOverloadWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcVoltageOverload response %@", [value description]); if (error != nil) { @@ -82157,10 +81890,10 @@ class SubscribeAttributeElectricalMeasurementAcVoltageOverload : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000801) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -82200,9 +81933,9 @@ class ReadElectricalMeasurementAcCurrentOverload : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000802) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcCurrentOverloadWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcCurrentOverload response %@", [value description]); if (error != nil) { @@ -82227,10 +81960,10 @@ class SubscribeAttributeElectricalMeasurementAcCurrentOverload : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000802) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -82270,9 +82003,9 @@ class ReadElectricalMeasurementAcActivePowerOverload : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000803) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcActivePowerOverloadWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcActivePowerOverload response %@", [value description]); if (error != nil) { @@ -82297,10 +82030,10 @@ class SubscribeAttributeElectricalMeasurementAcActivePowerOverload : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000803) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -82340,9 +82073,9 @@ class ReadElectricalMeasurementAcReactivePowerOverload : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000804) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcReactivePowerOverloadWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcReactivePowerOverload response %@", [value description]); if (error != nil) { @@ -82367,10 +82100,10 @@ class SubscribeAttributeElectricalMeasurementAcReactivePowerOverload : public Su { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000804) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -82410,9 +82143,9 @@ class ReadElectricalMeasurementAverageRmsOverVoltage : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000805) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAverageRmsOverVoltageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AverageRmsOverVoltage response %@", [value description]); if (error != nil) { @@ -82437,10 +82170,10 @@ class SubscribeAttributeElectricalMeasurementAverageRmsOverVoltage : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000805) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -82480,9 +82213,9 @@ class ReadElectricalMeasurementAverageRmsUnderVoltage : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000806) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAverageRmsUnderVoltageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AverageRmsUnderVoltage response %@", [value description]); if (error != nil) { @@ -82507,10 +82240,10 @@ class SubscribeAttributeElectricalMeasurementAverageRmsUnderVoltage : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000806) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -82550,9 +82283,9 @@ class ReadElectricalMeasurementRmsExtremeOverVoltage : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000807) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsExtremeOverVoltageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsExtremeOverVoltage response %@", [value description]); if (error != nil) { @@ -82577,10 +82310,10 @@ class SubscribeAttributeElectricalMeasurementRmsExtremeOverVoltage : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000807) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -82620,9 +82353,9 @@ class ReadElectricalMeasurementRmsExtremeUnderVoltage : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000808) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsExtremeUnderVoltageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsExtremeUnderVoltage response %@", [value description]); if (error != nil) { @@ -82647,10 +82380,10 @@ class SubscribeAttributeElectricalMeasurementRmsExtremeUnderVoltage : public Sub { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000808) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -82690,9 +82423,9 @@ class ReadElectricalMeasurementRmsVoltageSag : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000809) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltageSagWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltageSag response %@", [value description]); if (error != nil) { @@ -82717,10 +82450,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltageSag : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000809) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -82760,9 +82493,9 @@ class ReadElectricalMeasurementRmsVoltageSwell : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000080A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltageSwellWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltageSwell response %@", [value description]); if (error != nil) { @@ -82787,10 +82520,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltageSwell : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000080A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -82830,9 +82563,9 @@ class ReadElectricalMeasurementLineCurrentPhaseB : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000901) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLineCurrentPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.LineCurrentPhaseB response %@", [value description]); if (error != nil) { @@ -82857,10 +82590,10 @@ class SubscribeAttributeElectricalMeasurementLineCurrentPhaseB : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000901) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -82900,9 +82633,9 @@ class ReadElectricalMeasurementActiveCurrentPhaseB : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000902) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActiveCurrentPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ActiveCurrentPhaseB response %@", [value description]); if (error != nil) { @@ -82927,10 +82660,10 @@ class SubscribeAttributeElectricalMeasurementActiveCurrentPhaseB : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000902) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -82970,9 +82703,9 @@ class ReadElectricalMeasurementReactiveCurrentPhaseB : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000903) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeReactiveCurrentPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ReactiveCurrentPhaseB response %@", [value description]); if (error != nil) { @@ -82997,10 +82730,10 @@ class SubscribeAttributeElectricalMeasurementReactiveCurrentPhaseB : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000903) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -83040,9 +82773,9 @@ class ReadElectricalMeasurementRmsVoltagePhaseB : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000905) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltagePhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltagePhaseB response %@", [value description]); if (error != nil) { @@ -83067,10 +82800,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltagePhaseB : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000905) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -83110,9 +82843,9 @@ class ReadElectricalMeasurementRmsVoltageMinPhaseB : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000906) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltageMinPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltageMinPhaseB response %@", [value description]); if (error != nil) { @@ -83137,10 +82870,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltageMinPhaseB : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000906) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -83180,9 +82913,9 @@ class ReadElectricalMeasurementRmsVoltageMaxPhaseB : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000907) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltageMaxPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltageMaxPhaseB response %@", [value description]); if (error != nil) { @@ -83207,10 +82940,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltageMaxPhaseB : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000907) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -83250,9 +82983,9 @@ class ReadElectricalMeasurementRmsCurrentPhaseB : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000908) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsCurrentPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsCurrentPhaseB response %@", [value description]); if (error != nil) { @@ -83277,10 +83010,10 @@ class SubscribeAttributeElectricalMeasurementRmsCurrentPhaseB : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000908) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -83320,9 +83053,9 @@ class ReadElectricalMeasurementRmsCurrentMinPhaseB : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000909) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsCurrentMinPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsCurrentMinPhaseB response %@", [value description]); if (error != nil) { @@ -83347,10 +83080,10 @@ class SubscribeAttributeElectricalMeasurementRmsCurrentMinPhaseB : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000909) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -83390,9 +83123,9 @@ class ReadElectricalMeasurementRmsCurrentMaxPhaseB : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000090A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsCurrentMaxPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsCurrentMaxPhaseB response %@", [value description]); if (error != nil) { @@ -83417,10 +83150,10 @@ class SubscribeAttributeElectricalMeasurementRmsCurrentMaxPhaseB : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000090A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -83460,9 +83193,9 @@ class ReadElectricalMeasurementActivePowerPhaseB : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000090B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActivePowerPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ActivePowerPhaseB response %@", [value description]); if (error != nil) { @@ -83487,10 +83220,10 @@ class SubscribeAttributeElectricalMeasurementActivePowerPhaseB : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000090B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -83530,9 +83263,9 @@ class ReadElectricalMeasurementActivePowerMinPhaseB : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000090C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActivePowerMinPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ActivePowerMinPhaseB response %@", [value description]); if (error != nil) { @@ -83557,10 +83290,10 @@ class SubscribeAttributeElectricalMeasurementActivePowerMinPhaseB : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000090C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -83600,9 +83333,9 @@ class ReadElectricalMeasurementActivePowerMaxPhaseB : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000090D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActivePowerMaxPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ActivePowerMaxPhaseB response %@", [value description]); if (error != nil) { @@ -83627,10 +83360,10 @@ class SubscribeAttributeElectricalMeasurementActivePowerMaxPhaseB : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000090D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -83670,9 +83403,9 @@ class ReadElectricalMeasurementReactivePowerPhaseB : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000090E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeReactivePowerPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ReactivePowerPhaseB response %@", [value description]); if (error != nil) { @@ -83697,10 +83430,10 @@ class SubscribeAttributeElectricalMeasurementReactivePowerPhaseB : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000090E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -83740,9 +83473,9 @@ class ReadElectricalMeasurementApparentPowerPhaseB : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000090F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeApparentPowerPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ApparentPowerPhaseB response %@", [value description]); if (error != nil) { @@ -83767,10 +83500,10 @@ class SubscribeAttributeElectricalMeasurementApparentPowerPhaseB : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000090F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -83810,9 +83543,9 @@ class ReadElectricalMeasurementPowerFactorPhaseB : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000910) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePowerFactorPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.PowerFactorPhaseB response %@", [value description]); if (error != nil) { @@ -83837,10 +83570,10 @@ class SubscribeAttributeElectricalMeasurementPowerFactorPhaseB : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000910) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -83880,9 +83613,9 @@ class ReadElectricalMeasurementAverageRmsVoltageMeasurementPeriodPhaseB : public ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000911) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAverageRmsVoltageMeasurementPeriodPhaseBWithCompletion:^( NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AverageRmsVoltageMeasurementPeriodPhaseB response %@", [value description]); @@ -83908,10 +83641,10 @@ class SubscribeAttributeElectricalMeasurementAverageRmsVoltageMeasurementPeriodP { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000911) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -83951,9 +83684,9 @@ class ReadElectricalMeasurementAverageRmsOverVoltageCounterPhaseB : public ReadA ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000912) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAverageRmsOverVoltageCounterPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AverageRmsOverVoltageCounterPhaseB response %@", [value description]); @@ -83979,10 +83712,10 @@ class SubscribeAttributeElectricalMeasurementAverageRmsOverVoltageCounterPhaseB { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000912) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -84022,9 +83755,9 @@ class ReadElectricalMeasurementAverageRmsUnderVoltageCounterPhaseB : public Read ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000913) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAverageRmsUnderVoltageCounterPhaseBWithCompletion:^( NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AverageRmsUnderVoltageCounterPhaseB response %@", [value description]); @@ -84050,10 +83783,10 @@ class SubscribeAttributeElectricalMeasurementAverageRmsUnderVoltageCounterPhaseB { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000913) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -84093,9 +83826,9 @@ class ReadElectricalMeasurementRmsExtremeOverVoltagePeriodPhaseB : public ReadAt ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000914) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsExtremeOverVoltagePeriodPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsExtremeOverVoltagePeriodPhaseB response %@", [value description]); @@ -84121,10 +83854,10 @@ class SubscribeAttributeElectricalMeasurementRmsExtremeOverVoltagePeriodPhaseB : { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000914) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -84164,9 +83897,9 @@ class ReadElectricalMeasurementRmsExtremeUnderVoltagePeriodPhaseB : public ReadA ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000915) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsExtremeUnderVoltagePeriodPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsExtremeUnderVoltagePeriodPhaseB response %@", [value description]); @@ -84192,10 +83925,10 @@ class SubscribeAttributeElectricalMeasurementRmsExtremeUnderVoltagePeriodPhaseB { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000915) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -84235,9 +83968,9 @@ class ReadElectricalMeasurementRmsVoltageSagPeriodPhaseB : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000916) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltageSagPeriodPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltageSagPeriodPhaseB response %@", [value description]); if (error != nil) { @@ -84262,10 +83995,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltageSagPeriodPhaseB : public { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000916) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -84305,9 +84038,9 @@ class ReadElectricalMeasurementRmsVoltageSwellPeriodPhaseB : public ReadAttribut ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000917) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltageSwellPeriodPhaseBWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltageSwellPeriodPhaseB response %@", [value description]); if (error != nil) { @@ -84332,10 +84065,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltageSwellPeriodPhaseB : publi { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000917) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -84375,9 +84108,9 @@ class ReadElectricalMeasurementLineCurrentPhaseC : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A01) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLineCurrentPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.LineCurrentPhaseC response %@", [value description]); if (error != nil) { @@ -84402,10 +84135,10 @@ class SubscribeAttributeElectricalMeasurementLineCurrentPhaseC : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A01) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -84445,9 +84178,9 @@ class ReadElectricalMeasurementActiveCurrentPhaseC : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A02) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActiveCurrentPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ActiveCurrentPhaseC response %@", [value description]); if (error != nil) { @@ -84472,10 +84205,10 @@ class SubscribeAttributeElectricalMeasurementActiveCurrentPhaseC : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A02) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -84515,9 +84248,9 @@ class ReadElectricalMeasurementReactiveCurrentPhaseC : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A03) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeReactiveCurrentPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ReactiveCurrentPhaseC response %@", [value description]); if (error != nil) { @@ -84542,10 +84275,10 @@ class SubscribeAttributeElectricalMeasurementReactiveCurrentPhaseC : public Subs { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A03) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -84585,9 +84318,9 @@ class ReadElectricalMeasurementRmsVoltagePhaseC : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A05) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltagePhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltagePhaseC response %@", [value description]); if (error != nil) { @@ -84612,10 +84345,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltagePhaseC : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A05) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -84655,9 +84388,9 @@ class ReadElectricalMeasurementRmsVoltageMinPhaseC : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A06) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltageMinPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltageMinPhaseC response %@", [value description]); if (error != nil) { @@ -84682,10 +84415,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltageMinPhaseC : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A06) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -84725,9 +84458,9 @@ class ReadElectricalMeasurementRmsVoltageMaxPhaseC : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A07) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltageMaxPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltageMaxPhaseC response %@", [value description]); if (error != nil) { @@ -84752,10 +84485,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltageMaxPhaseC : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A07) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -84795,9 +84528,9 @@ class ReadElectricalMeasurementRmsCurrentPhaseC : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A08) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsCurrentPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsCurrentPhaseC response %@", [value description]); if (error != nil) { @@ -84822,10 +84555,10 @@ class SubscribeAttributeElectricalMeasurementRmsCurrentPhaseC : public Subscribe { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A08) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -84865,9 +84598,9 @@ class ReadElectricalMeasurementRmsCurrentMinPhaseC : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A09) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsCurrentMinPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsCurrentMinPhaseC response %@", [value description]); if (error != nil) { @@ -84892,10 +84625,10 @@ class SubscribeAttributeElectricalMeasurementRmsCurrentMinPhaseC : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A09) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -84935,9 +84668,9 @@ class ReadElectricalMeasurementRmsCurrentMaxPhaseC : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A0A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsCurrentMaxPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsCurrentMaxPhaseC response %@", [value description]); if (error != nil) { @@ -84962,10 +84695,10 @@ class SubscribeAttributeElectricalMeasurementRmsCurrentMaxPhaseC : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A0A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -85005,9 +84738,9 @@ class ReadElectricalMeasurementActivePowerPhaseC : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A0B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActivePowerPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ActivePowerPhaseC response %@", [value description]); if (error != nil) { @@ -85032,10 +84765,10 @@ class SubscribeAttributeElectricalMeasurementActivePowerPhaseC : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A0B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -85075,9 +84808,9 @@ class ReadElectricalMeasurementActivePowerMinPhaseC : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A0C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActivePowerMinPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ActivePowerMinPhaseC response %@", [value description]); if (error != nil) { @@ -85102,10 +84835,10 @@ class SubscribeAttributeElectricalMeasurementActivePowerMinPhaseC : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A0C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -85145,9 +84878,9 @@ class ReadElectricalMeasurementActivePowerMaxPhaseC : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A0D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeActivePowerMaxPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ActivePowerMaxPhaseC response %@", [value description]); if (error != nil) { @@ -85172,10 +84905,10 @@ class SubscribeAttributeElectricalMeasurementActivePowerMaxPhaseC : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A0D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -85215,9 +84948,9 @@ class ReadElectricalMeasurementReactivePowerPhaseC : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A0E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeReactivePowerPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ReactivePowerPhaseC response %@", [value description]); if (error != nil) { @@ -85242,10 +84975,10 @@ class SubscribeAttributeElectricalMeasurementReactivePowerPhaseC : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A0E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -85285,9 +85018,9 @@ class ReadElectricalMeasurementApparentPowerPhaseC : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A0F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeApparentPowerPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ApparentPowerPhaseC response %@", [value description]); if (error != nil) { @@ -85312,10 +85045,10 @@ class SubscribeAttributeElectricalMeasurementApparentPowerPhaseC : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A0F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -85355,9 +85088,9 @@ class ReadElectricalMeasurementPowerFactorPhaseC : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A10) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributePowerFactorPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.PowerFactorPhaseC response %@", [value description]); if (error != nil) { @@ -85382,10 +85115,10 @@ class SubscribeAttributeElectricalMeasurementPowerFactorPhaseC : public Subscrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A10) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -85425,9 +85158,9 @@ class ReadElectricalMeasurementAverageRmsVoltageMeasurementPeriodPhaseC : public ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A11) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAverageRmsVoltageMeasurementPeriodPhaseCWithCompletion:^( NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AverageRmsVoltageMeasurementPeriodPhaseC response %@", [value description]); @@ -85453,10 +85186,10 @@ class SubscribeAttributeElectricalMeasurementAverageRmsVoltageMeasurementPeriodP { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A11) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -85496,9 +85229,9 @@ class ReadElectricalMeasurementAverageRmsOverVoltageCounterPhaseC : public ReadA ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A12) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAverageRmsOverVoltageCounterPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AverageRmsOverVoltageCounterPhaseC response %@", [value description]); @@ -85524,10 +85257,10 @@ class SubscribeAttributeElectricalMeasurementAverageRmsOverVoltageCounterPhaseC { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A12) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -85567,9 +85300,9 @@ class ReadElectricalMeasurementAverageRmsUnderVoltageCounterPhaseC : public Read ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A13) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAverageRmsUnderVoltageCounterPhaseCWithCompletion:^( NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AverageRmsUnderVoltageCounterPhaseC response %@", [value description]); @@ -85595,10 +85328,10 @@ class SubscribeAttributeElectricalMeasurementAverageRmsUnderVoltageCounterPhaseC { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A13) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -85638,9 +85371,9 @@ class ReadElectricalMeasurementRmsExtremeOverVoltagePeriodPhaseC : public ReadAt ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A14) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsExtremeOverVoltagePeriodPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsExtremeOverVoltagePeriodPhaseC response %@", [value description]); @@ -85666,10 +85399,10 @@ class SubscribeAttributeElectricalMeasurementRmsExtremeOverVoltagePeriodPhaseC : { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A14) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -85709,9 +85442,9 @@ class ReadElectricalMeasurementRmsExtremeUnderVoltagePeriodPhaseC : public ReadA ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A15) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsExtremeUnderVoltagePeriodPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsExtremeUnderVoltagePeriodPhaseC response %@", [value description]); @@ -85737,10 +85470,10 @@ class SubscribeAttributeElectricalMeasurementRmsExtremeUnderVoltagePeriodPhaseC { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A15) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -85780,9 +85513,9 @@ class ReadElectricalMeasurementRmsVoltageSagPeriodPhaseC : public ReadAttribute ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A16) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltageSagPeriodPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltageSagPeriodPhaseC response %@", [value description]); if (error != nil) { @@ -85807,10 +85540,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltageSagPeriodPhaseC : public { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A16) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -85850,9 +85583,9 @@ class ReadElectricalMeasurementRmsVoltageSwellPeriodPhaseC : public ReadAttribut ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x00000A17) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRmsVoltageSwellPeriodPhaseCWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.RmsVoltageSwellPeriodPhaseC response %@", [value description]); if (error != nil) { @@ -85877,10 +85610,10 @@ class SubscribeAttributeElectricalMeasurementRmsVoltageSwellPeriodPhaseC : publi { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x00000A17) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -85920,9 +85653,9 @@ class ReadElectricalMeasurementGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -85947,10 +85680,10 @@ class SubscribeAttributeElectricalMeasurementGeneratedCommandList : public Subsc { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -85990,9 +85723,9 @@ class ReadElectricalMeasurementAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -86017,10 +85750,10 @@ class SubscribeAttributeElectricalMeasurementAcceptedCommandList : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -86060,9 +85793,9 @@ class ReadElectricalMeasurementAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.AttributeList response %@", [value description]); if (error != nil) { @@ -86087,10 +85820,10 @@ class SubscribeAttributeElectricalMeasurementAttributeList : public SubscribeAtt { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -86130,9 +85863,9 @@ class ReadElectricalMeasurementFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.FeatureMap response %@", [value description]); if (error != nil) { @@ -86157,10 +85890,10 @@ class SubscribeAttributeElectricalMeasurementFeatureMap : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -86200,9 +85933,9 @@ class ReadElectricalMeasurementClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"ElectricalMeasurement.ClusterRevision response %@", [value description]); if (error != nil) { @@ -86227,10 +85960,10 @@ class SubscribeAttributeElectricalMeasurementClusterRevision : public SubscribeA { ChipLogProgress(chipTool, "Sending cluster (0x00000B04) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterElectricalMeasurement * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterElectricalMeasurement alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -86390,9 +86123,9 @@ class UnitTestingTest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -86433,9 +86166,9 @@ class UnitTestingTestNotHandled : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestNotHandledParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -86476,9 +86209,9 @@ class UnitTestingTestSpecific : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestSpecificParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -86521,9 +86254,9 @@ class UnitTestingTestUnknownCommand : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestUnknownCommandParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -86566,9 +86299,9 @@ class UnitTestingTestAddArguments : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestAddArgumentsParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -86615,9 +86348,9 @@ class UnitTestingTestSimpleArgumentRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestSimpleArgumentRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -86672,9 +86405,9 @@ class UnitTestingTestStructArrayArgumentRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestStructArrayArgumentRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -86835,9 +86568,9 @@ class UnitTestingTestStructArgumentRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestStructArgumentRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -86895,9 +86628,9 @@ class UnitTestingTestNestedStructArgumentRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestNestedStructArgumentRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -86958,9 +86691,9 @@ class UnitTestingTestListStructArgumentRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestListStructArgumentRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -87027,9 +86760,9 @@ class UnitTestingTestListInt8UArgumentRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestListInt8UArgumentRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -87085,9 +86818,9 @@ class UnitTestingTestNestedStructListArgumentRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestNestedStructListArgumentRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -87194,9 +86927,9 @@ class UnitTestingTestListNestedStructListArgumentRequest : public ClusterCommand ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestListNestedStructListArgumentRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -87313,9 +87046,9 @@ class UnitTestingTestListInt8UReverseRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x0000000D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestListInt8UReverseRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -87372,9 +87105,9 @@ class UnitTestingTestEnumsRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x0000000E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestEnumsRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -87421,9 +87154,9 @@ class UnitTestingTestNullableOptionalRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestNullableOptionalRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -87495,9 +87228,9 @@ class UnitTestingTestComplexNullableOptionalRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestComplexNullableOptionalRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -87703,9 +87436,9 @@ class UnitTestingSimpleStructEchoRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterSimpleStructEchoRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -87761,9 +87494,9 @@ class UnitTestingTimedInvokeRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTimedInvokeRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -87805,9 +87538,9 @@ class UnitTestingTestSimpleOptionalArgumentRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestSimpleOptionalArgumentRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -87857,9 +87590,9 @@ class UnitTestingTestEmitTestEventRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestEmitTestEventRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -87907,9 +87640,9 @@ class UnitTestingTestEmitTestFabricScopedEventRequest : public ClusterCommand { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) command (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; __auto_type * params = [[MTRUnitTestingClusterTestEmitTestFabricScopedEventRequestParams alloc] init]; params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; @@ -87957,9 +87690,9 @@ class ReadUnitTestingBoolean : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Boolean response %@", [value description]); if (error != nil) { @@ -87987,10 +87720,10 @@ class WriteUnitTestingBoolean : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -88024,10 +87757,10 @@ class SubscribeAttributeUnitTestingBoolean : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -88067,9 +87800,9 @@ class ReadUnitTestingBitmap8 : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBitmap8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Bitmap8 response %@", [value description]); if (error != nil) { @@ -88097,10 +87830,10 @@ class WriteUnitTestingBitmap8 : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -88134,10 +87867,10 @@ class SubscribeAttributeUnitTestingBitmap8 : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -88177,9 +87910,9 @@ class ReadUnitTestingBitmap16 : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBitmap16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Bitmap16 response %@", [value description]); if (error != nil) { @@ -88207,10 +87940,10 @@ class WriteUnitTestingBitmap16 : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -88244,10 +87977,10 @@ class SubscribeAttributeUnitTestingBitmap16 : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -88287,9 +88020,9 @@ class ReadUnitTestingBitmap32 : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Bitmap32 response %@", [value description]); if (error != nil) { @@ -88317,10 +88050,10 @@ class WriteUnitTestingBitmap32 : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -88354,10 +88087,10 @@ class SubscribeAttributeUnitTestingBitmap32 : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -88397,9 +88130,9 @@ class ReadUnitTestingBitmap64 : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeBitmap64WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Bitmap64 response %@", [value description]); if (error != nil) { @@ -88427,10 +88160,10 @@ class WriteUnitTestingBitmap64 : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -88464,10 +88197,10 @@ class SubscribeAttributeUnitTestingBitmap64 : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -88507,9 +88240,9 @@ class ReadUnitTestingInt8u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int8u response %@", [value description]); if (error != nil) { @@ -88537,10 +88270,10 @@ class WriteUnitTestingInt8u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -88574,10 +88307,10 @@ class SubscribeAttributeUnitTestingInt8u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -88617,9 +88350,9 @@ class ReadUnitTestingInt16u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int16u response %@", [value description]); if (error != nil) { @@ -88647,10 +88380,10 @@ class WriteUnitTestingInt16u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -88684,10 +88417,10 @@ class SubscribeAttributeUnitTestingInt16u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -88727,9 +88460,9 @@ class ReadUnitTestingInt24u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt24uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int24u response %@", [value description]); if (error != nil) { @@ -88757,10 +88490,10 @@ class WriteUnitTestingInt24u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -88794,10 +88527,10 @@ class SubscribeAttributeUnitTestingInt24u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -88837,9 +88570,9 @@ class ReadUnitTestingInt32u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int32u response %@", [value description]); if (error != nil) { @@ -88867,10 +88600,10 @@ class WriteUnitTestingInt32u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -88904,10 +88637,10 @@ class SubscribeAttributeUnitTestingInt32u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -88947,9 +88680,9 @@ class ReadUnitTestingInt40u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt40uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int40u response %@", [value description]); if (error != nil) { @@ -88977,10 +88710,10 @@ class WriteUnitTestingInt40u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -89014,10 +88747,10 @@ class SubscribeAttributeUnitTestingInt40u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -89057,9 +88790,9 @@ class ReadUnitTestingInt48u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt48uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int48u response %@", [value description]); if (error != nil) { @@ -89087,10 +88820,10 @@ class WriteUnitTestingInt48u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -89124,10 +88857,10 @@ class SubscribeAttributeUnitTestingInt48u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000000A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -89167,9 +88900,9 @@ class ReadUnitTestingInt56u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt56uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int56u response %@", [value description]); if (error != nil) { @@ -89197,10 +88930,10 @@ class WriteUnitTestingInt56u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -89234,10 +88967,10 @@ class SubscribeAttributeUnitTestingInt56u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000000B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -89277,9 +89010,9 @@ class ReadUnitTestingInt64u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int64u response %@", [value description]); if (error != nil) { @@ -89307,10 +89040,10 @@ class WriteUnitTestingInt64u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -89344,10 +89077,10 @@ class SubscribeAttributeUnitTestingInt64u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000000C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -89387,9 +89120,9 @@ class ReadUnitTestingInt8s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000000D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int8s response %@", [value description]); if (error != nil) { @@ -89417,10 +89150,10 @@ class WriteUnitTestingInt8s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000000D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -89454,10 +89187,10 @@ class SubscribeAttributeUnitTestingInt8s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000000D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -89497,9 +89230,9 @@ class ReadUnitTestingInt16s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000000E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int16s response %@", [value description]); if (error != nil) { @@ -89527,10 +89260,10 @@ class WriteUnitTestingInt16s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000000E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -89564,10 +89297,10 @@ class SubscribeAttributeUnitTestingInt16s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000000E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -89607,9 +89340,9 @@ class ReadUnitTestingInt24s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt24sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int24s response %@", [value description]); if (error != nil) { @@ -89637,10 +89370,10 @@ class WriteUnitTestingInt24s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -89674,10 +89407,10 @@ class SubscribeAttributeUnitTestingInt24s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000000F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -89717,9 +89450,9 @@ class ReadUnitTestingInt32s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int32s response %@", [value description]); if (error != nil) { @@ -89747,10 +89480,10 @@ class WriteUnitTestingInt32s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -89784,10 +89517,10 @@ class SubscribeAttributeUnitTestingInt32s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -89827,9 +89560,9 @@ class ReadUnitTestingInt40s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt40sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int40s response %@", [value description]); if (error != nil) { @@ -89857,10 +89590,10 @@ class WriteUnitTestingInt40s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -89894,10 +89627,10 @@ class SubscribeAttributeUnitTestingInt40s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -89937,9 +89670,9 @@ class ReadUnitTestingInt48s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt48sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int48s response %@", [value description]); if (error != nil) { @@ -89967,10 +89700,10 @@ class WriteUnitTestingInt48s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -90004,10 +89737,10 @@ class SubscribeAttributeUnitTestingInt48s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -90047,9 +89780,9 @@ class ReadUnitTestingInt56s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt56sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int56s response %@", [value description]); if (error != nil) { @@ -90077,10 +89810,10 @@ class WriteUnitTestingInt56s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -90114,10 +89847,10 @@ class SubscribeAttributeUnitTestingInt56s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -90157,9 +89890,9 @@ class ReadUnitTestingInt64s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Int64s response %@", [value description]); if (error != nil) { @@ -90187,10 +89920,10 @@ class WriteUnitTestingInt64s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -90224,10 +89957,10 @@ class SubscribeAttributeUnitTestingInt64s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -90267,9 +90000,9 @@ class ReadUnitTestingEnum8 : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeEnum8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Enum8 response %@", [value description]); if (error != nil) { @@ -90297,10 +90030,10 @@ class WriteUnitTestingEnum8 : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -90334,10 +90067,10 @@ class SubscribeAttributeUnitTestingEnum8 : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -90377,9 +90110,9 @@ class ReadUnitTestingEnum16 : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeEnum16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Enum16 response %@", [value description]); if (error != nil) { @@ -90407,10 +90140,10 @@ class WriteUnitTestingEnum16 : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -90444,10 +90177,10 @@ class SubscribeAttributeUnitTestingEnum16 : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -90487,9 +90220,9 @@ class ReadUnitTestingFloatSingle : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFloatSingleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.FloatSingle response %@", [value description]); if (error != nil) { @@ -90517,10 +90250,10 @@ class WriteUnitTestingFloatSingle : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -90554,10 +90287,10 @@ class SubscribeAttributeUnitTestingFloatSingle : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -90597,9 +90330,9 @@ class ReadUnitTestingFloatDouble : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000018) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFloatDoubleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.FloatDouble response %@", [value description]); if (error != nil) { @@ -90627,10 +90360,10 @@ class WriteUnitTestingFloatDouble : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000018) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -90664,10 +90397,10 @@ class SubscribeAttributeUnitTestingFloatDouble : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000018) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -90707,9 +90440,9 @@ class ReadUnitTestingOctetString : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.OctetString response %@", [value description]); if (error != nil) { @@ -90737,10 +90470,10 @@ class WriteUnitTestingOctetString : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -90774,10 +90507,10 @@ class SubscribeAttributeUnitTestingOctetString : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -90817,9 +90550,9 @@ class ReadUnitTestingListInt8u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeListInt8uWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.ListInt8u response %@", [value description]); if (error != nil) { @@ -90848,10 +90581,10 @@ class WriteUnitTestingListInt8u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -90895,10 +90628,10 @@ class SubscribeAttributeUnitTestingListInt8u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000001A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -90938,9 +90671,9 @@ class ReadUnitTestingListOctetString : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000001B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeListOctetStringWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.ListOctetString response %@", [value description]); if (error != nil) { @@ -90969,10 +90702,10 @@ class WriteUnitTestingListOctetString : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000001B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -91016,10 +90749,10 @@ class SubscribeAttributeUnitTestingListOctetString : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000001B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -91059,9 +90792,9 @@ class ReadUnitTestingListStructOctetString : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000001C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeListStructOctetStringWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.ListStructOctetString response %@", [value description]); if (error != nil) { @@ -91090,10 +90823,10 @@ class WriteUnitTestingListStructOctetString : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000001C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -91140,10 +90873,10 @@ class SubscribeAttributeUnitTestingListStructOctetString : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000001C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -91183,9 +90916,9 @@ class ReadUnitTestingLongOctetString : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000001D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLongOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.LongOctetString response %@", [value description]); if (error != nil) { @@ -91213,10 +90946,10 @@ class WriteUnitTestingLongOctetString : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000001D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -91250,10 +90983,10 @@ class SubscribeAttributeUnitTestingLongOctetString : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000001D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -91293,9 +91026,9 @@ class ReadUnitTestingCharString : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000001E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.CharString response %@", [value description]); if (error != nil) { @@ -91323,10 +91056,10 @@ class WriteUnitTestingCharString : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000001E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -91362,10 +91095,10 @@ class SubscribeAttributeUnitTestingCharString : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000001E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -91405,9 +91138,9 @@ class ReadUnitTestingLongCharString : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000001F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeLongCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.LongCharString response %@", [value description]); if (error != nil) { @@ -91435,10 +91168,10 @@ class WriteUnitTestingLongCharString : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000001F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -91474,10 +91207,10 @@ class SubscribeAttributeUnitTestingLongCharString : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000001F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -91517,9 +91250,9 @@ class ReadUnitTestingEpochUs : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeEpochUsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.EpochUs response %@", [value description]); if (error != nil) { @@ -91547,10 +91280,10 @@ class WriteUnitTestingEpochUs : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -91584,10 +91317,10 @@ class SubscribeAttributeUnitTestingEpochUs : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000020) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -91627,9 +91360,9 @@ class ReadUnitTestingEpochS : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeEpochSWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.EpochS response %@", [value description]); if (error != nil) { @@ -91657,10 +91390,10 @@ class WriteUnitTestingEpochS : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -91694,10 +91427,10 @@ class SubscribeAttributeUnitTestingEpochS : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000021) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -91737,9 +91470,9 @@ class ReadUnitTestingVendorId : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeVendorIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.VendorId response %@", [value description]); if (error != nil) { @@ -91767,10 +91500,10 @@ class WriteUnitTestingVendorId : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -91804,10 +91537,10 @@ class SubscribeAttributeUnitTestingVendorId : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000022) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -91847,9 +91580,9 @@ class ReadUnitTestingListNullablesAndOptionalsStruct : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000023) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeListNullablesAndOptionalsStructWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.ListNullablesAndOptionalsStruct response %@", [value description]); @@ -91879,10 +91612,10 @@ class WriteUnitTestingListNullablesAndOptionalsStruct : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000023) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -92081,10 +91814,10 @@ class SubscribeAttributeUnitTestingListNullablesAndOptionalsStruct : public Subs { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000023) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -92124,9 +91857,9 @@ class ReadUnitTestingEnumAttr : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeEnumAttrWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.EnumAttr response %@", [value description]); if (error != nil) { @@ -92154,10 +91887,10 @@ class WriteUnitTestingEnumAttr : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -92191,10 +91924,10 @@ class SubscribeAttributeUnitTestingEnumAttr : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -92234,9 +91967,9 @@ class ReadUnitTestingStructAttr : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeStructAttrWithCompletion:^( MTRUnitTestingClusterSimpleStruct * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.StructAttr response %@", [value description]); @@ -92266,10 +91999,10 @@ class WriteUnitTestingStructAttr : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -92313,10 +92046,10 @@ class SubscribeAttributeUnitTestingStructAttr : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -92356,9 +92089,9 @@ class ReadUnitTestingRangeRestrictedInt8u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000026) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRangeRestrictedInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.RangeRestrictedInt8u response %@", [value description]); if (error != nil) { @@ -92386,10 +92119,10 @@ class WriteUnitTestingRangeRestrictedInt8u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000026) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -92423,10 +92156,10 @@ class SubscribeAttributeUnitTestingRangeRestrictedInt8u : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000026) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -92466,9 +92199,9 @@ class ReadUnitTestingRangeRestrictedInt8s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000027) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRangeRestrictedInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.RangeRestrictedInt8s response %@", [value description]); if (error != nil) { @@ -92496,10 +92229,10 @@ class WriteUnitTestingRangeRestrictedInt8s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000027) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -92533,10 +92266,10 @@ class SubscribeAttributeUnitTestingRangeRestrictedInt8s : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000027) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -92576,9 +92309,9 @@ class ReadUnitTestingRangeRestrictedInt16u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000028) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRangeRestrictedInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.RangeRestrictedInt16u response %@", [value description]); if (error != nil) { @@ -92606,10 +92339,10 @@ class WriteUnitTestingRangeRestrictedInt16u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000028) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -92643,10 +92376,10 @@ class SubscribeAttributeUnitTestingRangeRestrictedInt16u : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000028) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -92686,9 +92419,9 @@ class ReadUnitTestingRangeRestrictedInt16s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000029) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeRangeRestrictedInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.RangeRestrictedInt16s response %@", [value description]); if (error != nil) { @@ -92716,10 +92449,10 @@ class WriteUnitTestingRangeRestrictedInt16s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000029) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -92753,10 +92486,10 @@ class SubscribeAttributeUnitTestingRangeRestrictedInt16s : public SubscribeAttri { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000029) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -92796,9 +92529,9 @@ class ReadUnitTestingListLongOctetString : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000002A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeListLongOctetStringWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.ListLongOctetString response %@", [value description]); if (error != nil) { @@ -92827,10 +92560,10 @@ class WriteUnitTestingListLongOctetString : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000002A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -92874,10 +92607,10 @@ class SubscribeAttributeUnitTestingListLongOctetString : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000002A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -92917,10 +92650,10 @@ class ReadUnitTestingListFabricScoped : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000002B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRReadParams alloc] init]; if (mFabricFiltered.HasValue()) { params.filterByFabric = mFabricFiltered.Value(); } @@ -92953,10 +92686,10 @@ class WriteUnitTestingListFabricScoped : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000002B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -93050,10 +92783,10 @@ class SubscribeAttributeUnitTestingListFabricScoped : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000002B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -93093,9 +92826,9 @@ class ReadUnitTestingTimedWriteBoolean : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeTimedWriteBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.TimedWriteBoolean response %@", [value description]); if (error != nil) { @@ -93123,10 +92856,10 @@ class WriteUnitTestingTimedWriteBoolean : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -93160,10 +92893,10 @@ class SubscribeAttributeUnitTestingTimedWriteBoolean : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000030) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -93203,9 +92936,9 @@ class ReadUnitTestingGeneralErrorBoolean : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneralErrorBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.GeneralErrorBoolean response %@", [value description]); if (error != nil) { @@ -93233,10 +92966,10 @@ class WriteUnitTestingGeneralErrorBoolean : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -93270,10 +93003,10 @@ class SubscribeAttributeUnitTestingGeneralErrorBoolean : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000031) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -93313,9 +93046,9 @@ class ReadUnitTestingClusterErrorBoolean : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterErrorBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.ClusterErrorBoolean response %@", [value description]); if (error != nil) { @@ -93343,10 +93076,10 @@ class WriteUnitTestingClusterErrorBoolean : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -93380,10 +93113,10 @@ class SubscribeAttributeUnitTestingClusterErrorBoolean : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00000032) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -93423,9 +93156,9 @@ class ReadUnitTestingUnsupported : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x000000FF) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeUnsupportedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.Unsupported response %@", [value description]); if (error != nil) { @@ -93453,10 +93186,10 @@ class WriteUnitTestingUnsupported : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x000000FF) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -93490,10 +93223,10 @@ class SubscribeAttributeUnitTestingUnsupported : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x000000FF) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -93533,9 +93266,9 @@ class ReadUnitTestingNullableBoolean : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableBoolean response %@", [value description]); if (error != nil) { @@ -93563,10 +93296,10 @@ class WriteUnitTestingNullableBoolean : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -93600,10 +93333,10 @@ class SubscribeAttributeUnitTestingNullableBoolean : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004000) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -93643,9 +93376,9 @@ class ReadUnitTestingNullableBitmap8 : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableBitmap8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableBitmap8 response %@", [value description]); if (error != nil) { @@ -93673,10 +93406,10 @@ class WriteUnitTestingNullableBitmap8 : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -93710,10 +93443,10 @@ class SubscribeAttributeUnitTestingNullableBitmap8 : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004001) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -93753,9 +93486,9 @@ class ReadUnitTestingNullableBitmap16 : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableBitmap16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableBitmap16 response %@", [value description]); if (error != nil) { @@ -93783,10 +93516,10 @@ class WriteUnitTestingNullableBitmap16 : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -93820,10 +93553,10 @@ class SubscribeAttributeUnitTestingNullableBitmap16 : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004002) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -93863,9 +93596,9 @@ class ReadUnitTestingNullableBitmap32 : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableBitmap32 response %@", [value description]); if (error != nil) { @@ -93893,10 +93626,10 @@ class WriteUnitTestingNullableBitmap32 : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -93930,10 +93663,10 @@ class SubscribeAttributeUnitTestingNullableBitmap32 : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004003) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -93973,9 +93706,9 @@ class ReadUnitTestingNullableBitmap64 : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableBitmap64WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableBitmap64 response %@", [value description]); if (error != nil) { @@ -94003,10 +93736,10 @@ class WriteUnitTestingNullableBitmap64 : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -94040,10 +93773,10 @@ class SubscribeAttributeUnitTestingNullableBitmap64 : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004004) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -94083,9 +93816,9 @@ class ReadUnitTestingNullableInt8u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt8u response %@", [value description]); if (error != nil) { @@ -94113,10 +93846,10 @@ class WriteUnitTestingNullableInt8u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -94150,10 +93883,10 @@ class SubscribeAttributeUnitTestingNullableInt8u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004005) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -94193,9 +93926,9 @@ class ReadUnitTestingNullableInt16u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt16u response %@", [value description]); if (error != nil) { @@ -94223,10 +93956,10 @@ class WriteUnitTestingNullableInt16u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -94260,10 +93993,10 @@ class SubscribeAttributeUnitTestingNullableInt16u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004006) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -94303,9 +94036,9 @@ class ReadUnitTestingNullableInt24u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt24uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt24u response %@", [value description]); if (error != nil) { @@ -94333,10 +94066,10 @@ class WriteUnitTestingNullableInt24u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -94370,10 +94103,10 @@ class SubscribeAttributeUnitTestingNullableInt24u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004007) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -94413,9 +94146,9 @@ class ReadUnitTestingNullableInt32u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt32u response %@", [value description]); if (error != nil) { @@ -94443,10 +94176,10 @@ class WriteUnitTestingNullableInt32u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -94480,10 +94213,10 @@ class SubscribeAttributeUnitTestingNullableInt32u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004008) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -94523,9 +94256,9 @@ class ReadUnitTestingNullableInt40u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt40uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt40u response %@", [value description]); if (error != nil) { @@ -94553,10 +94286,10 @@ class WriteUnitTestingNullableInt40u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -94590,10 +94323,10 @@ class SubscribeAttributeUnitTestingNullableInt40u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004009) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -94633,9 +94366,9 @@ class ReadUnitTestingNullableInt48u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000400A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt48uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt48u response %@", [value description]); if (error != nil) { @@ -94663,10 +94396,10 @@ class WriteUnitTestingNullableInt48u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000400A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -94700,10 +94433,10 @@ class SubscribeAttributeUnitTestingNullableInt48u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000400A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -94743,9 +94476,9 @@ class ReadUnitTestingNullableInt56u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000400B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt56uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt56u response %@", [value description]); if (error != nil) { @@ -94773,10 +94506,10 @@ class WriteUnitTestingNullableInt56u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000400B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -94810,10 +94543,10 @@ class SubscribeAttributeUnitTestingNullableInt56u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000400B) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -94853,9 +94586,9 @@ class ReadUnitTestingNullableInt64u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000400C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt64u response %@", [value description]); if (error != nil) { @@ -94883,10 +94616,10 @@ class WriteUnitTestingNullableInt64u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000400C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -94920,10 +94653,10 @@ class SubscribeAttributeUnitTestingNullableInt64u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000400C) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -94963,9 +94696,9 @@ class ReadUnitTestingNullableInt8s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000400D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt8s response %@", [value description]); if (error != nil) { @@ -94993,10 +94726,10 @@ class WriteUnitTestingNullableInt8s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000400D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -95030,10 +94763,10 @@ class SubscribeAttributeUnitTestingNullableInt8s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000400D) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -95073,9 +94806,9 @@ class ReadUnitTestingNullableInt16s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000400E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt16s response %@", [value description]); if (error != nil) { @@ -95103,10 +94836,10 @@ class WriteUnitTestingNullableInt16s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000400E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -95140,10 +94873,10 @@ class SubscribeAttributeUnitTestingNullableInt16s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000400E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -95183,9 +94916,9 @@ class ReadUnitTestingNullableInt24s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000400F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt24sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt24s response %@", [value description]); if (error != nil) { @@ -95213,10 +94946,10 @@ class WriteUnitTestingNullableInt24s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000400F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -95250,10 +94983,10 @@ class SubscribeAttributeUnitTestingNullableInt24s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000400F) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -95293,9 +95026,9 @@ class ReadUnitTestingNullableInt32s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt32s response %@", [value description]); if (error != nil) { @@ -95323,10 +95056,10 @@ class WriteUnitTestingNullableInt32s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -95360,10 +95093,10 @@ class SubscribeAttributeUnitTestingNullableInt32s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004010) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -95403,9 +95136,9 @@ class ReadUnitTestingNullableInt40s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt40sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt40s response %@", [value description]); if (error != nil) { @@ -95433,10 +95166,10 @@ class WriteUnitTestingNullableInt40s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -95470,10 +95203,10 @@ class SubscribeAttributeUnitTestingNullableInt40s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004011) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -95513,9 +95246,9 @@ class ReadUnitTestingNullableInt48s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt48sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt48s response %@", [value description]); if (error != nil) { @@ -95543,10 +95276,10 @@ class WriteUnitTestingNullableInt48s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -95580,10 +95313,10 @@ class SubscribeAttributeUnitTestingNullableInt48s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004012) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -95623,9 +95356,9 @@ class ReadUnitTestingNullableInt56s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt56sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt56s response %@", [value description]); if (error != nil) { @@ -95653,10 +95386,10 @@ class WriteUnitTestingNullableInt56s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -95690,10 +95423,10 @@ class SubscribeAttributeUnitTestingNullableInt56s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004013) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -95733,9 +95466,9 @@ class ReadUnitTestingNullableInt64s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableInt64s response %@", [value description]); if (error != nil) { @@ -95763,10 +95496,10 @@ class WriteUnitTestingNullableInt64s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -95800,10 +95533,10 @@ class SubscribeAttributeUnitTestingNullableInt64s : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004014) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -95843,9 +95576,9 @@ class ReadUnitTestingNullableEnum8 : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableEnum8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableEnum8 response %@", [value description]); if (error != nil) { @@ -95873,10 +95606,10 @@ class WriteUnitTestingNullableEnum8 : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -95910,10 +95643,10 @@ class SubscribeAttributeUnitTestingNullableEnum8 : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004015) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -95953,9 +95686,9 @@ class ReadUnitTestingNullableEnum16 : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableEnum16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableEnum16 response %@", [value description]); if (error != nil) { @@ -95983,10 +95716,10 @@ class WriteUnitTestingNullableEnum16 : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -96020,10 +95753,10 @@ class SubscribeAttributeUnitTestingNullableEnum16 : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004016) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -96063,9 +95796,9 @@ class ReadUnitTestingNullableFloatSingle : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableFloatSingleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableFloatSingle response %@", [value description]); if (error != nil) { @@ -96093,10 +95826,10 @@ class WriteUnitTestingNullableFloatSingle : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -96130,10 +95863,10 @@ class SubscribeAttributeUnitTestingNullableFloatSingle : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004017) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -96173,9 +95906,9 @@ class ReadUnitTestingNullableFloatDouble : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004018) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableFloatDoubleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableFloatDouble response %@", [value description]); if (error != nil) { @@ -96203,10 +95936,10 @@ class WriteUnitTestingNullableFloatDouble : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004018) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -96240,10 +95973,10 @@ class SubscribeAttributeUnitTestingNullableFloatDouble : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004018) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -96283,9 +96016,9 @@ class ReadUnitTestingNullableOctetString : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableOctetString response %@", [value description]); if (error != nil) { @@ -96313,10 +96046,10 @@ class WriteUnitTestingNullableOctetString : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -96350,10 +96083,10 @@ class SubscribeAttributeUnitTestingNullableOctetString : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004019) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -96393,9 +96126,9 @@ class ReadUnitTestingNullableCharString : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000401E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableCharString response %@", [value description]); if (error != nil) { @@ -96423,10 +96156,10 @@ class WriteUnitTestingNullableCharString : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000401E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -96462,10 +96195,10 @@ class SubscribeAttributeUnitTestingNullableCharString : public SubscribeAttribut { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000401E) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -96505,9 +96238,9 @@ class ReadUnitTestingNullableEnumAttr : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableEnumAttrWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableEnumAttr response %@", [value description]); if (error != nil) { @@ -96535,10 +96268,10 @@ class WriteUnitTestingNullableEnumAttr : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -96572,10 +96305,10 @@ class SubscribeAttributeUnitTestingNullableEnumAttr : public SubscribeAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004024) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -96615,9 +96348,9 @@ class ReadUnitTestingNullableStruct : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableStructWithCompletion:^( MTRUnitTestingClusterSimpleStruct * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableStruct response %@", [value description]); @@ -96647,10 +96380,10 @@ class WriteUnitTestingNullableStruct : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -96700,10 +96433,10 @@ class SubscribeAttributeUnitTestingNullableStruct : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004025) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -96743,9 +96476,9 @@ class ReadUnitTestingNullableRangeRestrictedInt8u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004026) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableRangeRestrictedInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableRangeRestrictedInt8u response %@", [value description]); if (error != nil) { @@ -96773,10 +96506,10 @@ class WriteUnitTestingNullableRangeRestrictedInt8u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004026) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -96811,10 +96544,10 @@ class SubscribeAttributeUnitTestingNullableRangeRestrictedInt8u : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004026) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -96854,9 +96587,9 @@ class ReadUnitTestingNullableRangeRestrictedInt8s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004027) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableRangeRestrictedInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableRangeRestrictedInt8s response %@", [value description]); if (error != nil) { @@ -96884,10 +96617,10 @@ class WriteUnitTestingNullableRangeRestrictedInt8s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004027) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -96922,10 +96655,10 @@ class SubscribeAttributeUnitTestingNullableRangeRestrictedInt8s : public Subscri { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004027) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -96965,9 +96698,9 @@ class ReadUnitTestingNullableRangeRestrictedInt16u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004028) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableRangeRestrictedInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableRangeRestrictedInt16u response %@", [value description]); if (error != nil) { @@ -96995,10 +96728,10 @@ class WriteUnitTestingNullableRangeRestrictedInt16u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004028) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -97034,10 +96767,10 @@ class SubscribeAttributeUnitTestingNullableRangeRestrictedInt16u : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004028) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -97077,9 +96810,9 @@ class ReadUnitTestingNullableRangeRestrictedInt16s : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x00004029) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeNullableRangeRestrictedInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.NullableRangeRestrictedInt16s response %@", [value description]); if (error != nil) { @@ -97107,10 +96840,10 @@ class WriteUnitTestingNullableRangeRestrictedInt16s : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x00004029) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -97146,10 +96879,10 @@ class SubscribeAttributeUnitTestingNullableRangeRestrictedInt16s : public Subscr { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x00004029) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -97189,9 +96922,9 @@ class ReadUnitTestingWriteOnlyInt8u : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000402A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeWriteOnlyInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.WriteOnlyInt8u response %@", [value description]); if (error != nil) { @@ -97219,10 +96952,10 @@ class WriteUnitTestingWriteOnlyInt8u : public WriteAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) WriteAttribute (0x0000402A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRWriteParams * params = [[MTRWriteParams alloc] init]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRWriteParams alloc] init]; params.timedWriteTimeout = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; params.dataVersion = mDataVersion.HasValue() ? [NSNumber numberWithUnsignedInt:mDataVersion.Value()] : nil; @@ -97256,10 +96989,10 @@ class SubscribeAttributeUnitTestingWriteOnlyInt8u : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000402A) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -97299,9 +97032,9 @@ class ReadUnitTestingGeneratedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.GeneratedCommandList response %@", [value description]); if (error != nil) { @@ -97326,10 +97059,10 @@ class SubscribeAttributeUnitTestingGeneratedCommandList : public SubscribeAttrib { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000FFF8) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -97369,9 +97102,9 @@ class ReadUnitTestingAcceptedCommandList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.AcceptedCommandList response %@", [value description]); if (error != nil) { @@ -97396,10 +97129,10 @@ class SubscribeAttributeUnitTestingAcceptedCommandList : public SubscribeAttribu { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000FFF9) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -97439,9 +97172,9 @@ class ReadUnitTestingAttributeList : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.AttributeList response %@", [value description]); if (error != nil) { @@ -97466,10 +97199,10 @@ class SubscribeAttributeUnitTestingAttributeList : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000FFFB) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -97509,9 +97242,9 @@ class ReadUnitTestingFeatureMap : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.FeatureMap response %@", [value description]); if (error != nil) { @@ -97536,10 +97269,10 @@ class SubscribeAttributeUnitTestingFeatureMap : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000FFFC) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } @@ -97579,9 +97312,9 @@ class ReadUnitTestingClusterRevision : public ReadAttribute { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReadAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable error) { NSLog(@"UnitTesting.ClusterRevision response %@", [value description]); if (error != nil) { @@ -97606,10 +97339,10 @@ class SubscribeAttributeUnitTestingClusterRevision : public SubscribeAttribute { { ChipLogProgress(chipTool, "Sending cluster (0xFFF1FC05) ReportAttribute (0x0000FFFD) on endpoint %u", endpointId); dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(endpointId) - queue:callbackQueue]; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device + endpointID:@(endpointId) + queue:callbackQueue]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(mMinInterval) maxInterval:@(mMaxInterval)]; if (mKeepSubscriptions.HasValue()) { params.replaceExistingSubscriptions = !mKeepSubscriptions.Value(); } diff --git a/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h b/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h index 2b90c663601ca8..af4c59a07376d9 100644 --- a/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h +++ b/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h @@ -21,6 +21,7 @@ #if CONFIG_ENABLE_YAML_TESTS +#include #include #include #include @@ -39,8 +40,10 @@ class TestList : public Command { printf("Test_TC_ACL_1_1\n"); printf("Test_TC_ACL_2_1\n"); printf("Test_TC_ACL_2_2\n"); + printf("Test_TC_ACL_2_3\n"); printf("Test_TC_BOOL_1_1\n"); printf("Test_TC_BOOL_2_1\n"); + printf("Test_TC_BRBINFO_1_1\n"); printf("Test_TC_ACT_1_1\n"); printf("Test_TC_BIND_1_1\n"); printf("Test_TC_CC_1_1\n"); @@ -102,6 +105,7 @@ class TestList : public Command { printf("Test_TC_APBSC_1_10\n"); printf("Test_TC_CONTENTLAUNCHER_1_11\n"); printf("Test_TC_ALOGIN_1_12\n"); + printf("Test_TC_ALOGIN_12_1\n"); printf("Test_TC_LOWPOWER_2_1\n"); printf("Test_TC_KEYPADINPUT_3_2\n"); printf("Test_TC_KEYPADINPUT_3_3\n"); @@ -111,6 +115,7 @@ class TestList : public Command { printf("Test_TC_MEDIAINPUT_3_11\n"); printf("Test_TC_MEDIAINPUT_3_12\n"); printf("Test_TC_MEDIAINPUT_3_13\n"); + printf("Test_TC_WAKEONLAN_4_1\n"); printf("Test_TC_CHANNEL_5_1\n"); printf("Test_TC_CHANNEL_5_2\n"); printf("Test_TC_CHANNEL_5_3\n"); @@ -225,6 +230,7 @@ class TestList : public Command { printf("Test_TC_DRLK_2_3\n"); printf("Test_TC_DRLK_2_4\n"); printf("Test_TC_DRLK_2_5\n"); + printf("Test_TC_DRLK_2_6\n"); printf("Test_TC_DRLK_2_7\n"); printf("Test_TC_DRLK_2_9\n"); printf("TestGroupsCluster\n"); @@ -481,6 +487,7 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestWaitForCommissionee_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -488,10 +495,9 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestWriteEntries_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -588,7 +594,7 @@ class TestAccessControlCluster : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Write entries Error: %@", err); @@ -602,15 +608,14 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestVerify_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; - [cluster readAttributeAclWithParams:params + [cluster readAttributeACLWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { NSLog(@"Verify Error: %@", err); @@ -897,10 +902,9 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestWriteEntriesEmptyLists_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -928,7 +932,7 @@ class TestAccessControlCluster : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Write entries empty lists Error: %@", err); @@ -942,15 +946,14 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestVerify_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; - [cluster readAttributeAclWithParams:params + [cluster readAttributeACLWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { NSLog(@"Verify Error: %@", err); @@ -989,10 +992,9 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestWriteEntryInvalidPrivilege_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -1014,7 +1016,7 @@ class TestAccessControlCluster : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Write entry invalid privilege Error: %@", err); @@ -1031,15 +1033,14 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestVerify_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; - [cluster readAttributeAclWithParams:params + [cluster readAttributeACLWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { NSLog(@"Verify Error: %@", err); @@ -1068,10 +1069,9 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestWriteEntryInvalidAuthMode_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -1093,7 +1093,7 @@ class TestAccessControlCluster : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Write entry invalid auth mode Error: %@", err); @@ -1110,15 +1110,14 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestVerify_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; - [cluster readAttributeAclWithParams:params + [cluster readAttributeACLWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { NSLog(@"Verify Error: %@", err); @@ -1147,10 +1146,9 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestWriteEntryInvalidSubject_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -1176,7 +1174,7 @@ class TestAccessControlCluster : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Write entry invalid subject Error: %@", err); @@ -1193,15 +1191,14 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestVerify_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; - [cluster readAttributeAclWithParams:params + [cluster readAttributeACLWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { NSLog(@"Verify Error: %@", err); @@ -1230,10 +1227,9 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestWriteEntryInvalidTarget_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -1263,7 +1259,7 @@ class TestAccessControlCluster : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Write entry invalid target Error: %@", err); @@ -1280,15 +1276,14 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestVerify_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; - [cluster readAttributeAclWithParams:params + [cluster readAttributeACLWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { NSLog(@"Verify Error: %@", err); @@ -1317,10 +1312,9 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestWriteEntryTooManySubjects_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -1365,7 +1359,7 @@ class TestAccessControlCluster : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Write entry too many subjects Error: %@", err); @@ -1382,15 +1376,14 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestVerify_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; - [cluster readAttributeAclWithParams:params + [cluster readAttributeACLWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { NSLog(@"Verify Error: %@", err); @@ -1419,10 +1412,9 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestWriteEntryTooManyTargets_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -1547,7 +1539,7 @@ class TestAccessControlCluster : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Write entry too many targets Error: %@", err); @@ -1564,15 +1556,14 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestVerify_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; - [cluster readAttributeAclWithParams:params + [cluster readAttributeACLWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { NSLog(@"Verify Error: %@", err); @@ -1601,10 +1592,9 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestWriteTooManyEntries_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -1733,7 +1723,7 @@ class TestAccessControlCluster : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Write too many entries Error: %@", err); @@ -1750,15 +1740,14 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestVerify_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; - [cluster readAttributeAclWithParams:params + [cluster readAttributeACLWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { NSLog(@"Verify Error: %@", err); @@ -2045,10 +2034,9 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestRestoreAcl_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -2063,7 +2051,7 @@ class TestAccessControlCluster : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Restore ACL Error: %@", err); @@ -2077,15 +2065,14 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestVerify_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; - [cluster readAttributeAclWithParams:params + [cluster readAttributeACLWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { NSLog(@"Verify Error: %@", err); @@ -2114,10 +2101,9 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestValidateResourceMinimaSubjectsPerAccessControlEntry_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSubjectsPerAccessControlEntryWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -2135,10 +2121,9 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestValidateResourceMinimaTargetsPerAccessControlEntry_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetsPerAccessControlEntryWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -2156,10 +2141,9 @@ class TestAccessControlCluster : public TestCommandBridge { CHIP_ERROR TestValidateResourceMinimaAccessControlEntriesPerFabric_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAccessControlEntriesPerFabricWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -2300,6 +2284,7 @@ class Test_TC_ACL_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -2307,10 +2292,9 @@ class Test_TC_ACL_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsClusterRevisionAttributeFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -2332,10 +2316,9 @@ class Test_TC_ACL_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureMapAttributeFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -2357,10 +2340,9 @@ class Test_TC_ACL_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAttributeListAttributeFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -2387,10 +2369,9 @@ class Test_TC_ACL_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeExtensionInAttributeList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -2409,10 +2390,9 @@ class Test_TC_ACL_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAcceptedCommandListAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -2434,10 +2414,9 @@ class Test_TC_ACL_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsGeneratedCommandListAttributeFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -2569,6 +2548,7 @@ class Test_TC_ACL_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -2576,10 +2556,9 @@ class Test_TC_ACL_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsSubjectsPerAccessControlEntryAttributeFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSubjectsPerAccessControlEntryWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -2599,10 +2578,9 @@ class Test_TC_ACL_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTargetsPerAccessControlEntryAttributeFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetsPerAccessControlEntryWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -2622,10 +2600,9 @@ class Test_TC_ACL_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAccessControlEntriesPerFabricAttributeFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAccessControlEntriesPerFabricWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -2742,6 +2719,7 @@ class Test_TC_ACL_2_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -2749,10 +2727,9 @@ class Test_TC_ACL_2_2 : public TestCommandBridge { CHIP_ERROR TestTh1ReadsDutDescriptorClusterServerListAttributeFromEndpoint0_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeServerListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -2771,6 +2748,7 @@ class Test_TC_ACL_2_2 : public TestCommandBridge { CHIP_ERROR TestTh1ReadsDutDescriptorClusterServerListAttributeFromEveryEndpointExcept0_2() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Factory Reset the DUT and enter 'y' after successgarbage: not in length on purpose", 49); @@ -2780,21 +2758,31 @@ class Test_TC_ACL_2_2 : public TestCommandBridge { } }; -class Test_TC_BOOL_1_1 : public TestCommandBridge { +class Test_TC_ACL_2_3 : public TestCommandBridge { public: // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced - Test_TC_BOOL_1_1() - : TestCommandBridge("Test_TC_BOOL_1_1") + Test_TC_ACL_2_3() + : TestCommandBridge("Test_TC_ACL_2_3") , mTestIndex(0) { AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); AddArgument("cluster", &mCluster); AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("D_OK_EMPTY", &mDOkEmpty); + AddArgument("D_OK_SINGLE", &mDOkSingle); + AddArgument("D_OK_FULL", &mDOkFull); + AddArgument("D_BAD_LENGTH", &mDBadLength); + AddArgument("D_BAD_STRUCT", &mDBadStruct); + AddArgument("D_BAD_LIST", &mDBadList); + AddArgument("D_BAD_ELEM", &mDBadElem); + AddArgument("D_BAD_OVERFLOW", &mDBadOverflow); + AddArgument("D_BAD_UNDERFLOW", &mDBadUnderflow); + AddArgument("D_BAD_NONE", &mDBadNone); AddArgument("timeout", 0, UINT16_MAX, &mTimeout); } // NOLINTEND(clang-analyzer-nullability.NullPassedToNonnull) - ~Test_TC_BOOL_1_1() {} + ~Test_TC_ACL_2_3() {} /////////// TestCommand Interface ///////// void NextTest() override @@ -2802,11 +2790,11 @@ class Test_TC_BOOL_1_1 : public TestCommandBridge { CHIP_ERROR err = CHIP_NO_ERROR; if (0 == mTestIndex) { - ChipLogProgress(chipTool, " **** Test Start: Test_TC_BOOL_1_1\n"); + ChipLogProgress(chipTool, " **** Test Start: Test_TC_ACL_2_3\n"); } if (mTestCount == mTestIndex) { - ChipLogProgress(chipTool, " **** Test Complete: Test_TC_BOOL_1_1\n"); + ChipLogProgress(chipTool, " **** Test Complete: Test_TC_ACL_2_3\n"); SetCommandExitStatus(CHIP_NO_ERROR); return; } @@ -2823,393 +2811,2204 @@ class Test_TC_BOOL_1_1 : public TestCommandBridge { err = TestWaitForTheCommissionedDeviceToBeRetrieved_0(); break; case 1: - ChipLogProgress(chipTool, " ***** Test Step 1 : read the global attribute: ClusterRevision\n"); - err = TestReadTheGlobalAttributeClusterRevision_1(); - break; - case 2: - ChipLogProgress(chipTool, " ***** Test Step 2 : Read the global attribute: FeatureMap\n"); - err = TestReadTheGlobalAttributeFeatureMap_2(); - break; - case 3: - ChipLogProgress(chipTool, " ***** Test Step 3 : Read the global attribute: AttributeList\n"); - err = TestReadTheGlobalAttributeAttributeList_3(); - break; - case 4: - ChipLogProgress(chipTool, " ***** Test Step 4 : Read the global attribute: AcceptedCommandList\n"); - err = TestReadTheGlobalAttributeAcceptedCommandList_4(); - break; - case 5: - ChipLogProgress(chipTool, " ***** Test Step 5 : Read the global attribute: GeneratedCommandList\n"); - err = TestReadTheGlobalAttributeGeneratedCommandList_5(); - break; - } - - if (CHIP_NO_ERROR != err) { - ChipLogError(chipTool, " ***** Test Failure: %s\n", chip::ErrorStr(err)); - SetCommandExitStatus(err); - } - } - - void OnStatusUpdate(const chip::app::StatusIB & status) override - { - switch (mTestIndex - 1) { - case 0: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); - break; - case 1: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + ChipLogProgress(chipTool, + " ***** Test Step 1 : TH1 reads DUT Endpoint 0 OperationalCredentials cluster CurrentFabricIndex attribute\n"); + err = TestTh1ReadsDutEndpoint0OperationalCredentialsClusterCurrentFabricIndexAttribute_1(); break; case 2: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + ChipLogProgress(chipTool, " ***** Test Step 2 : TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; + } + err = TestTh1ReadsDutEndpoint0AccessControlClusterExtensionAttribute_2(); break; case 3: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + ChipLogProgress(chipTool, + " ***** Test Step 3 : TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1. struct: Data field: D_OK_EMPTY : 1718\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; + } + err = TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1StructDataFieldDOkEmpty1718_3(); break; case 4: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + ChipLogProgress(chipTool, " ***** Test Step 4 : TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; + } + err = TestTh1ReadsDutEndpoint0AccessControlClusterExtensionAttribute_4(); break; case 5: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + ChipLogProgress(chipTool, + " ***** Test Step 5 : TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1.struct Data field: D_OK_SINGLE " + ":17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E672061732" + "0612063686172737472696E670018\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; + } + err = TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1structDataFieldDOkSingle17d00000f1ff01003d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e670018_5(); break; - } - - // Go on to the next test. - ContinueOnChipMainThread(CHIP_NO_ERROR); - } - - chip::System::Clock::Timeout GetWaitDuration() const override - { - return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); - } - -private: - std::atomic_uint16_t mTestIndex; - const uint16_t mTestCount = 6; - - chip::Optional mNodeId; - chip::Optional mCluster; - chip::Optional mEndpoint; - chip::Optional mTimeout; - - CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() - { - chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; - value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; - return WaitForCommissionee("alpha", value); - } - - CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() - { - MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; - VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - - [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { - NSLog(@"read the global attribute: ClusterRevision Error: %@", err); - - VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - - { - id actualValue = value; - VerifyOrReturn(CheckValue("ClusterRevision", actualValue, 1U)); + case 6: + ChipLogProgress(chipTool, " ***** Test Step 6 : TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; } - - VerifyOrReturn(CheckConstraintType("clusterRevision", "int16u", "int16u")); - NextTest(); - }]; - - return CHIP_NO_ERROR; - } - - CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() - { - MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; - VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - - [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { - NSLog(@"Read the global attribute: FeatureMap Error: %@", err); - - VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - - { - id actualValue = value; - VerifyOrReturn(CheckValue("FeatureMap", actualValue, 0UL)); + err = TestTh1ReadsDutEndpoint0AccessControlClusterExtensionAttribute_6(); + break; + case 7: + ChipLogProgress(chipTool, + " ***** Test Step 7 : TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1.struct Data field: D_OK_FULL " + ":17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E672061732" + "0612063686172737472696E6700D00000F1FF02003148656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656" + "E7420616761696E2E2E2E2E2E0018\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; } - - VerifyOrReturn(CheckConstraintType("featureMap", "bitmap32", "bitmap32")); - NextTest(); - }]; - - return CHIP_NO_ERROR; - } - - CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() - { - MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; - VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - - [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"Read the global attribute: AttributeList Error: %@", err); - - VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - - VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 0UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 65528UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 65529UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 65531UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 65532UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 65533UL)); - - NextTest(); - }]; - - return CHIP_NO_ERROR; - } - - CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_4() - { - MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; - VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - - [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"Read the global attribute: AcceptedCommandList Error: %@", err); - - VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - - { - id actualValue = value; - VerifyOrReturn(CheckValue("AcceptedCommandList", [actualValue count], static_cast(0))); + err = TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1structDataFieldDOkFull17d00000f1ff01003d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e6700d00000f1ff02003148656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e7420616761696e2e2e2e2e2e0018_7(); + break; + case 8: + ChipLogProgress(chipTool, " ***** Test Step 8 : TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; } - - VerifyOrReturn(CheckConstraintType("acceptedCommandList", "list", "list")); - NextTest(); - }]; - - return CHIP_NO_ERROR; - } - - CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_5() - { - MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; - VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - - [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"Read the global attribute: GeneratedCommandList Error: %@", err); - - VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - - { - id actualValue = value; - VerifyOrReturn(CheckValue("GeneratedCommandList", [actualValue count], static_cast(0))); + err = TestTh1ReadsDutEndpoint0AccessControlClusterExtensionAttribute_8(); + break; + case 9: + ChipLogProgress(chipTool, + " ***** Test Step 9 : TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1 .struct Data field: D_BAD_LENGTH " + ":17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E672061732" + "0612063686172737472696E6700D00000F1FF02003248656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656" + "E7420616761696E2E2E2E2E2E2E0018\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; } - - VerifyOrReturn(CheckConstraintType("generatedCommandList", "list", "list")); - NextTest(); - }]; - - return CHIP_NO_ERROR; - } -}; - -class Test_TC_BOOL_2_1 : public TestCommandBridge { -public: - // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced - Test_TC_BOOL_2_1() - : TestCommandBridge("Test_TC_BOOL_2_1") - , mTestIndex(0) - { - AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); - AddArgument("cluster", &mCluster); - AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); - AddArgument("timeout", 0, UINT16_MAX, &mTimeout); - } - // NOLINTEND(clang-analyzer-nullability.NullPassedToNonnull) - - ~Test_TC_BOOL_2_1() {} - - /////////// TestCommand Interface ///////// - void NextTest() override - { - CHIP_ERROR err = CHIP_NO_ERROR; - - if (0 == mTestIndex) { - ChipLogProgress(chipTool, " **** Test Start: Test_TC_BOOL_2_1\n"); - } - - if (mTestCount == mTestIndex) { - ChipLogProgress(chipTool, " **** Test Complete: Test_TC_BOOL_2_1\n"); - SetCommandExitStatus(CHIP_NO_ERROR); - return; - } - - Wait(); - - // Ensure we increment mTestIndex before we start running the relevant - // command. That way if we lose the timeslice after we send the message - // but before our function call returns, we won't end up with an - // incorrect mTestIndex value observed when we get the response. - switch (mTestIndex++) { - case 0: - ChipLogProgress(chipTool, " ***** Test Step 0 : Wait for the commissioned device to be retrieved\n"); - err = TestWaitForTheCommissionedDeviceToBeRetrieved_0(); + err = TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1structDataFieldDBadLength17d00000f1ff01003d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e6700d00000f1ff02003248656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e7420616761696e2e2e2e2e2e2e0018_9(); break; - case 1: - ChipLogProgress(chipTool, " ***** Test Step 1 : Read mandatory non-global attribute: StateValue\n"); - if (ShouldSkip("BOOL.S.A0000")) { + case 10: + ChipLogProgress(chipTool, + " ***** Test Step 10 : TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1. struct Data field: D_BAD_STRUCT : 1518\n"); + if (ShouldSkip("ACL.S.A0001")) { NextTest(); return; } - err = TestReadMandatoryNonGlobalAttributeStateValue_1(); + err = TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1StructDataFieldDBadStruct1518_10(); break; - } - - if (CHIP_NO_ERROR != err) { - ChipLogError(chipTool, " ***** Test Failure: %s\n", chip::ErrorStr(err)); - SetCommandExitStatus(err); - } - } - - void OnStatusUpdate(const chip::app::StatusIB & status) override - { - switch (mTestIndex - 1) { - case 0: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + case 11: + ChipLogProgress(chipTool, + " ***** Test Step 11 : TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1. struct Data field: D_BAD_LIST " + ":3701D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617" + "320612063686172737472696E670018\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; + } + err = TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1StructDataFieldDBadList3701d00000f1ff01003d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e670018_11(); break; - case 1: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + case 12: + ChipLogProgress(chipTool, + " ***** Test Step 12 : TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1. struct Data field: D_BAD_ELEM " + ":17103D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E672061732061206368617" + "2737472696E670018\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; + } + err = TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1StructDataFieldDBadElem17103d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e670018_12(); break; - } - - // Go on to the next test. - ContinueOnChipMainThread(CHIP_NO_ERROR); - } - - chip::System::Clock::Timeout GetWaitDuration() const override - { - return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); - } - -private: - std::atomic_uint16_t mTestIndex; - const uint16_t mTestCount = 2; - - chip::Optional mNodeId; - chip::Optional mCluster; - chip::Optional mEndpoint; - chip::Optional mTimeout; - - CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() - { - chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; - value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; - return WaitForCommissionee("alpha", value); - } - - CHIP_ERROR TestReadMandatoryNonGlobalAttributeStateValue_1() - { - MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBooleanState * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; - VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - - [cluster readAttributeStateValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { - NSLog(@"Read mandatory non-global attribute: StateValue Error: %@", err); - - VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - - VerifyOrReturn(CheckConstraintType("stateValue", "boolean", "boolean")); - NextTest(); - }]; - - return CHIP_NO_ERROR; - } -}; - -class Test_TC_ACT_1_1 : public TestCommandBridge { -public: - // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced - Test_TC_ACT_1_1() - : TestCommandBridge("Test_TC_ACT_1_1") - , mTestIndex(0) - { - AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); - AddArgument("cluster", &mCluster); - AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); - AddArgument("timeout", 0, UINT16_MAX, &mTimeout); - } - // NOLINTEND(clang-analyzer-nullability.NullPassedToNonnull) - - ~Test_TC_ACT_1_1() {} - - /////////// TestCommand Interface ///////// - void NextTest() override - { - CHIP_ERROR err = CHIP_NO_ERROR; - - if (0 == mTestIndex) { - ChipLogProgress(chipTool, " **** Test Start: Test_TC_ACT_1_1\n"); - } - - if (mTestCount == mTestIndex) { - ChipLogProgress(chipTool, " **** Test Complete: Test_TC_ACT_1_1\n"); - SetCommandExitStatus(CHIP_NO_ERROR); - return; - } - - Wait(); - - // Ensure we increment mTestIndex before we start running the relevant - // command. That way if we lose the timeslice after we send the message - // but before our function call returns, we won't end up with an - // incorrect mTestIndex value observed when we get the response. - switch (mTestIndex++) { - case 0: - ChipLogProgress(chipTool, " ***** Test Step 0 : Wait for the commissioned device to be retrieved\n"); - err = TestWaitForTheCommissionedDeviceToBeRetrieved_0(); + case 13: + ChipLogProgress(chipTool, + " ***** Test Step 13 : TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1 .struct Data field: D_BAD_OVERFLOW : " + "17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320" + "612063686172737472696E670018FF\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; + } + err = TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1structDataFieldDBadOverflow17d00000f1ff01003d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e670018ff_13(); break; - case 1: - ChipLogProgress(chipTool, " ***** Test Step 1 : Read the global attribute: ClusterRevision\n"); - err = TestReadTheGlobalAttributeClusterRevision_1(); + case 14: + ChipLogProgress(chipTool, + " ***** Test Step 14 : TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1. struct Data field: D_BAD_UNDERFLOW " + ":17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E672061732" + "0612063686172737472696E6700\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; + } + err = TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1StructDataFieldDBadUnderflow17d00000f1ff01003d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e6700_14(); break; - case 2: - ChipLogProgress(chipTool, " ***** Test Step 2 : Read the global attribute: FeatureMap\n"); - err = TestReadTheGlobalAttributeFeatureMap_2(); + case 15: + ChipLogProgress(chipTool, + " ***** Test Step 15 : TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 1 element 1.struct Data field: D_BAD_NONE\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; + } + err = TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1structDataFieldDBadNone_15(); break; - case 3: - ChipLogProgress(chipTool, " ***** Test Step 3 : Read the global attribute: AttributeList\n"); - err = TestReadTheGlobalAttributeAttributeList_3(); + case 16: + ChipLogProgress(chipTool, + " ***** Test Step 16 : TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + "AccessControlExtensionStruct containing 2 elements . value is list of AccessControlExtensionStruct containing 2 " + "elements . first element contains Data field: D_OK_EMPTY 1718 . second element contains Data field: D_OK_SINGLE " + "17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C6976696E6720617320" + "612063686172737472696E670018\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; + } + err = TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining2ElementsValueIsListOfAccessControlExtensionStructContaining2ElementsFirstElementContainsDataFieldDOkEmpty1718SecondElementContainsDataFieldDOkSingle17d00000f1ff01003d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e670018_16(); break; - case 4: - ChipLogProgress(chipTool, " ***** Test Step 4 : Read the optional attribute(SetupURL) in AttributeList\n"); - if (ShouldSkip("ACT.S.A0002")) { + case 17: + ChipLogProgress(chipTool, " ***** Test Step 17 : TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute\n"); + if (ShouldSkip("ACL.S.A0001")) { NextTest(); return; } - err = TestReadTheOptionalAttributeSetupURLInAttributeList_4(); + err = TestTh1ReadsDutEndpoint0AccessControlClusterExtensionAttribute_17(); break; - case 5: - ChipLogProgress(chipTool, " ***** Test Step 5 : Read the global attribute: AcceptedCommandList\n"); - err = TestReadTheGlobalAttributeAcceptedCommandList_5(); + case 18: + ChipLogProgress(chipTool, + " ***** Test Step 18 : TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is an empty " + "list\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; + } + err = TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsAnEmptyList_18(); break; - case 6: - ChipLogProgress(chipTool, " ***** Test Step 6 : Read the global attribute: GeneratedCommandList\n"); - err = TestReadTheGlobalAttributeGeneratedCommandList_6(); + case 19: + ChipLogProgress(chipTool, " ***** Test Step 19 : TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute\n"); + if (ShouldSkip("ACL.S.A0001")) { + NextTest(); + return; + } + err = TestTh1ReadsDutEndpoint0AccessControlClusterExtensionAttribute_19(); + break; + } + + if (CHIP_NO_ERROR != err) { + ChipLogError(chipTool, " ***** Test Failure: %s\n", chip::ErrorStr(err)); + SetCommandExitStatus(err); + } + } + + void OnStatusUpdate(const chip::app::StatusIB & status) override + { + switch (mTestIndex - 1) { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 4: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 5: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 6: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 7: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 8: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 9: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 10: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 11: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 12: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 13: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 14: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 15: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 16: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + break; + case 17: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 18: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 19: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + } + + // Go on to the next test. + ContinueOnChipMainThread(CHIP_NO_ERROR); + } + + chip::System::Clock::Timeout GetWaitDuration() const override + { + return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); + } + +private: + std::atomic_uint16_t mTestIndex; + const uint16_t mTestCount = 20; + + chip::Optional mNodeId; + chip::Optional mCluster; + chip::Optional mEndpoint; + chip::Optional mDOkEmpty; + chip::Optional mDOkSingle; + chip::Optional mDOkFull; + chip::Optional mDBadLength; + chip::Optional mDBadStruct; + chip::Optional mDBadList; + chip::Optional mDBadElem; + chip::Optional mDBadOverflow; + chip::Optional mDBadUnderflow; + chip::Optional mDBadNone; + chip::Optional mTimeout; + + CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() + { + + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee("alpha", value); + } + NSNumber * _Nonnull CurrentFabricIndex; + + CHIP_ERROR TestTh1ReadsDutEndpoint0OperationalCredentialsClusterCurrentFabricIndexAttribute_1() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeCurrentFabricIndexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH1 reads DUT Endpoint 0 OperationalCredentials cluster CurrentFabricIndex attribute Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + CurrentFabricIndex = value; + } + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestTh1ReadsDutEndpoint0AccessControlClusterExtensionAttribute_2() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRReadParams alloc] init]; + params.filterByFabric = true; + [cluster + readAttributeExtensionWithParams:params + completion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("Extension", [actualValue count], static_cast(0))); + } + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR + TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1StructDataFieldDOkEmpty1718_3() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + id extensionArgument; + { + NSMutableArray * temp_0 = [[NSMutableArray alloc] init]; + temp_0[0] = [[MTRAccessControlClusterExtensionEntry alloc] init]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).data = mDOkEmpty.HasValue() + ? [NSData dataWithBytes:mDOkEmpty.Value().data() length:mDOkEmpty.Value().size()] + : [[NSData alloc] initWithBytes:"\x17\x18" length:2]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).fabricIndex = [CurrentFabricIndex copy]; + + extensionArgument = temp_0; + } + [cluster writeAttributeExtensionWithValue:extensionArgument + completion:^(NSError * _Nullable err) { + NSLog(@"TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is " + @"list of AccessControlExtensionStruct containing 1 element 1. struct: Data " + @"field: D_OK_EMPTY : 1718 Error: %@", + err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestTh1ReadsDutEndpoint0AccessControlClusterExtensionAttribute_4() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRReadParams alloc] init]; + params.filterByFabric = true; + [cluster + readAttributeExtensionWithParams:params + completion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("Extension", [actualValue count], static_cast(1))); + VerifyOrReturn(CheckValueAsString( + "Data", ((MTRAccessControlClusterExtensionEntry *) actualValue[0]).data, + mDOkEmpty.HasValue() ? [NSData dataWithBytes:mDOkEmpty.Value().data() + length:mDOkEmpty.Value().size()] + : [[NSData alloc] initWithBytes:"\x17\x18" length:2] + + )); + VerifyOrReturn(CheckValue("FabricIndex", + ((MTRAccessControlClusterExtensionEntry *) actualValue[0]).fabricIndex, + CurrentFabricIndex)); + } + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR + TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1structDataFieldDOkSingle17d00000f1ff01003d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e670018_5() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + id extensionArgument; + { + NSMutableArray * temp_0 = [[NSMutableArray alloc] init]; + temp_0[0] = [[MTRAccessControlClusterExtensionEntry alloc] init]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).data = mDOkSingle.HasValue() + ? [NSData dataWithBytes:mDOkSingle.Value().data() length:mDOkSingle.Value().size()] + : [[NSData alloc] + initWithBytes:"\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54\x68" + "\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x6C" + "\x69\x76\x69\x6E\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00\x18" + length:71]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).fabricIndex = [CurrentFabricIndex copy]; + + extensionArgument = temp_0; + } + [cluster + writeAttributeExtensionWithValue:extensionArgument + completion:^(NSError * _Nullable err) { + NSLog( + @"TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + @"AccessControlExtensionStruct containing 1 element 1.struct Data field: D_OK_SINGLE " + @":17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D" + @"656E74206C6976696E6720617320612063686172737472696E670018 Error: %@", + err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestTh1ReadsDutEndpoint0AccessControlClusterExtensionAttribute_6() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRReadParams alloc] init]; + params.filterByFabric = true; + [cluster + readAttributeExtensionWithParams:params + completion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("Extension", [actualValue count], static_cast(1))); + VerifyOrReturn(CheckValueAsString( + "Data", ((MTRAccessControlClusterExtensionEntry *) actualValue[0]).data, + mDOkSingle.HasValue() + ? [NSData dataWithBytes:mDOkSingle.Value().data() + length:mDOkSingle.Value().size()] + : [[NSData alloc] + initWithBytes: + "\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72" + "\x6C\x64\x2E\x20\x54\x68\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67" + "\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x6C\x69\x76\x69\x6E\x67\x20" + "\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00\x18" + length:71] + + )); + VerifyOrReturn(CheckValue("FabricIndex", + ((MTRAccessControlClusterExtensionEntry *) actualValue[0]).fabricIndex, + CurrentFabricIndex)); + } + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR + TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1structDataFieldDOkFull17d00000f1ff01003d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e6700d00000f1ff02003148656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e7420616761696e2e2e2e2e2e0018_7() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + id extensionArgument; + { + NSMutableArray * temp_0 = [[NSMutableArray alloc] init]; + temp_0[0] = [[MTRAccessControlClusterExtensionEntry alloc] init]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).data = mDOkFull.HasValue() + ? [NSData dataWithBytes:mDOkFull.Value().data() length:mDOkFull.Value().size()] + : [[NSData alloc] + initWithBytes: + "\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54\x68\x69\x73" + "\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x6C\x69\x76\x69\x6E" + "\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00\xD0\x00\x00\xF1\xFF\x02\x00\x31" + "\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54\x68\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E" + "\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x61\x67\x61\x69\x6E\x2E\x2E\x2E\x2E\x2E\x00\x18" + length:128]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).fabricIndex = [CurrentFabricIndex copy]; + + extensionArgument = temp_0; + } + [cluster + writeAttributeExtensionWithValue:extensionArgument + completion:^(NSError * _Nullable err) { + NSLog(@"TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list " + @"of AccessControlExtensionStruct containing 1 element 1.struct Data field: D_OK_FULL " + @":17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C65" + @"6D656E74206C6976696E6720617320612063686172737472696E6700D00000F1FF02003148656C6C6F205" + @"76F726C642E205468697320697320612073696E676C6520656C656D656E7420616761696E2E2E2E2E2E00" + @"18 Error: %@", + err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestTh1ReadsDutEndpoint0AccessControlClusterExtensionAttribute_8() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRReadParams alloc] init]; + params.filterByFabric = true; + [cluster + readAttributeExtensionWithParams:params + completion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("Extension", [actualValue count], static_cast(1))); + VerifyOrReturn(CheckValueAsString( + "Data", ((MTRAccessControlClusterExtensionEntry *) actualValue[0]).data, + mDOkFull.HasValue() + ? [NSData dataWithBytes:mDOkFull.Value().data() length:mDOkFull.Value().size()] + : [[NSData alloc] + initWithBytes: + "\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72" + "\x6C\x64\x2E\x20\x54\x68\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67" + "\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x6C\x69\x76\x69\x6E\x67\x20" + "\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00\xD0\x00" + "\x00\xF1\xFF\x02\x00\x31\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E" + "\x20\x54\x68\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20" + "\x65\x6C\x65\x6D\x65\x6E\x74\x20\x61\x67\x61\x69\x6E\x2E\x2E\x2E\x2E\x2E" + "\x00\x18" + length:128] + + )); + VerifyOrReturn(CheckValue("FabricIndex", + ((MTRAccessControlClusterExtensionEntry *) actualValue[0]).fabricIndex, + CurrentFabricIndex)); + } + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR + TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1structDataFieldDBadLength17d00000f1ff01003d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e6700d00000f1ff02003248656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e7420616761696e2e2e2e2e2e2e0018_9() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + id extensionArgument; + { + NSMutableArray * temp_0 = [[NSMutableArray alloc] init]; + temp_0[0] = [[MTRAccessControlClusterExtensionEntry alloc] init]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).data = mDBadLength.HasValue() + ? [NSData dataWithBytes:mDBadLength.Value().data() length:mDBadLength.Value().size()] + : [[NSData alloc] + initWithBytes: + "\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54\x68\x69\x73" + "\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x6C\x69\x76\x69\x6E" + "\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00\xD0\x00\x00\xF1\xFF\x02\x00\x32" + "\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54\x68\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E" + "\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x61\x67\x61\x69\x6E\x2E\x2E\x2E\x2E\x2E\x2E\x00\x18" + length:129]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).fabricIndex = [CurrentFabricIndex copy]; + + extensionArgument = temp_0; + } + [cluster + writeAttributeExtensionWithValue:extensionArgument + completion:^(NSError * _Nullable err) { + NSLog( + @"TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + @"AccessControlExtensionStruct containing 1 element 1 .struct Data field: D_BAD_LENGTH " + @":17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D" + @"656E74206C6976696E6720617320612063686172737472696E6700D00000F1FF02003248656C6C6F20576F7" + @"26C642E205468697320697320612073696E676C6520656C656D656E7420616761696E2E2E2E2E2E2E0018 " + @"Error: %@", + err); + + VerifyOrReturn(CheckValue("status", + err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code + : EMBER_ZCL_STATUS_FAILURE) + : 0, + EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR + TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1StructDataFieldDBadStruct1518_10() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + id extensionArgument; + { + NSMutableArray * temp_0 = [[NSMutableArray alloc] init]; + temp_0[0] = [[MTRAccessControlClusterExtensionEntry alloc] init]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).data = mDBadStruct.HasValue() + ? [NSData dataWithBytes:mDBadStruct.Value().data() length:mDBadStruct.Value().size()] + : [[NSData alloc] initWithBytes:"\x15\x18" length:2]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).fabricIndex = [CurrentFabricIndex copy]; + + extensionArgument = temp_0; + } + [cluster + writeAttributeExtensionWithValue:extensionArgument + completion:^(NSError * _Nullable err) { + NSLog(@"TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list " + @"of AccessControlExtensionStruct containing 1 element 1. struct Data field: " + @"D_BAD_STRUCT : 1518 Error: %@", + err); + + VerifyOrReturn(CheckValue("status", + err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code + : EMBER_ZCL_STATUS_FAILURE) + : 0, + EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR + TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1StructDataFieldDBadList3701d00000f1ff01003d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e670018_11() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + id extensionArgument; + { + NSMutableArray * temp_0 = [[NSMutableArray alloc] init]; + temp_0[0] = [[MTRAccessControlClusterExtensionEntry alloc] init]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).data = mDBadList.HasValue() + ? [NSData dataWithBytes:mDBadList.Value().data() length:mDBadList.Value().size()] + : [[NSData alloc] + initWithBytes:"\x37\x01\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54" + "\x68\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20" + "\x6C\x69\x76\x69\x6E\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00\x18" + length:72]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).fabricIndex = [CurrentFabricIndex copy]; + + extensionArgument = temp_0; + } + [cluster + writeAttributeExtensionWithValue:extensionArgument + completion:^(NSError * _Nullable err) { + NSLog( + @"TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + @"AccessControlExtensionStruct containing 1 element 1. struct Data field: D_BAD_LIST " + @":3701D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C65" + @"6D656E74206C6976696E6720617320612063686172737472696E670018 Error: %@", + err); + + VerifyOrReturn(CheckValue("status", + err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code + : EMBER_ZCL_STATUS_FAILURE) + : 0, + EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR + TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1StructDataFieldDBadElem17103d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e670018_12() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + id extensionArgument; + { + NSMutableArray * temp_0 = [[NSMutableArray alloc] init]; + temp_0[0] = [[MTRAccessControlClusterExtensionEntry alloc] init]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).data = mDBadElem.HasValue() + ? [NSData dataWithBytes:mDBadElem.Value().data() length:mDBadElem.Value().size()] + : [[NSData alloc] + initWithBytes:"\x17\x10\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54\x68\x69\x73\x20\x69\x73\x20" + "\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x6C\x69\x76\x69\x6E\x67\x20" + "\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00\x18" + length:65]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).fabricIndex = [CurrentFabricIndex copy]; + + extensionArgument = temp_0; + } + [cluster + writeAttributeExtensionWithValue:extensionArgument + completion:^(NSError * _Nullable err) { + NSLog( + @"TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list of " + @"AccessControlExtensionStruct containing 1 element 1. struct Data field: D_BAD_ELEM " + @":17103D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656D656E74206C69" + @"76696E6720617320612063686172737472696E670018 Error: %@", + err); + + VerifyOrReturn(CheckValue("status", + err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code + : EMBER_ZCL_STATUS_FAILURE) + : 0, + EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR + TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1structDataFieldDBadOverflow17d00000f1ff01003d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e670018ff_13() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + id extensionArgument; + { + NSMutableArray * temp_0 = [[NSMutableArray alloc] init]; + temp_0[0] = [[MTRAccessControlClusterExtensionEntry alloc] init]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).data = mDBadOverflow.HasValue() + ? [NSData dataWithBytes:mDBadOverflow.Value().data() length:mDBadOverflow.Value().size()] + : [[NSData alloc] + initWithBytes:"\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54\x68" + "\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x6C" + "\x69\x76\x69\x6E\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00\x18\xFF" + length:72]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).fabricIndex = [CurrentFabricIndex copy]; + + extensionArgument = temp_0; + } + [cluster + writeAttributeExtensionWithValue:extensionArgument + completion:^(NSError * _Nullable err) { + NSLog(@"TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list " + @"of AccessControlExtensionStruct containing 1 element 1 .struct Data field: " + @"D_BAD_OVERFLOW : " + @"17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656" + @"D656E74206C6976696E6720617320612063686172737472696E670018FF Error: %@", + err); + + VerifyOrReturn(CheckValue("status", + err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code + : EMBER_ZCL_STATUS_FAILURE) + : 0, + EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR + TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1StructDataFieldDBadUnderflow17d00000f1ff01003d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e6700_14() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + id extensionArgument; + { + NSMutableArray * temp_0 = [[NSMutableArray alloc] init]; + temp_0[0] = [[MTRAccessControlClusterExtensionEntry alloc] init]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).data = mDBadUnderflow.HasValue() + ? [NSData dataWithBytes:mDBadUnderflow.Value().data() length:mDBadUnderflow.Value().size()] + : [[NSData alloc] + initWithBytes:"\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54\x68" + "\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x6C" + "\x69\x76\x69\x6E\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00" + length:70]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).fabricIndex = [CurrentFabricIndex copy]; + + extensionArgument = temp_0; + } + [cluster + writeAttributeExtensionWithValue:extensionArgument + completion:^(NSError * _Nullable err) { + NSLog(@"TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list " + @"of AccessControlExtensionStruct containing 1 element 1. struct Data field: " + @"D_BAD_UNDERFLOW " + @":17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C65" + @"6D656E74206C6976696E6720617320612063686172737472696E6700 Error: %@", + err); + + VerifyOrReturn(CheckValue("status", + err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code + : EMBER_ZCL_STATUS_FAILURE) + : 0, + EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR + TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining1Element1structDataFieldDBadNone_15() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + id extensionArgument; + { + NSMutableArray * temp_0 = [[NSMutableArray alloc] init]; + temp_0[0] = [[MTRAccessControlClusterExtensionEntry alloc] init]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).data = mDBadNone.HasValue() + ? [NSData dataWithBytes:mDBadNone.Value().data() length:mDBadNone.Value().size()] + : [[NSData alloc] initWithBytes:"" length:0]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).fabricIndex = [CurrentFabricIndex copy]; + + extensionArgument = temp_0; + } + [cluster + writeAttributeExtensionWithValue:extensionArgument + completion:^(NSError * _Nullable err) { + NSLog(@"TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list " + @"of AccessControlExtensionStruct containing 1 element 1.struct Data field: D_BAD_NONE " + @"Error: %@", + err); + + VerifyOrReturn(CheckValue("status", + err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code + : EMBER_ZCL_STATUS_FAILURE) + : 0, + EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR + TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsListOfAccessControlExtensionStructContaining2ElementsValueIsListOfAccessControlExtensionStructContaining2ElementsFirstElementContainsDataFieldDOkEmpty1718SecondElementContainsDataFieldDOkSingle17d00000f1ff01003d48656c6c6f20576f726c642e205468697320697320612073696e676c6520656c656d656e74206c6976696e6720617320612063686172737472696e670018_16() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + id extensionArgument; + { + NSMutableArray * temp_0 = [[NSMutableArray alloc] init]; + temp_0[0] = [[MTRAccessControlClusterExtensionEntry alloc] init]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).data = mDOkEmpty.HasValue() + ? [NSData dataWithBytes:mDOkEmpty.Value().data() length:mDOkEmpty.Value().size()] + : [[NSData alloc] initWithBytes:"\x17\x18" length:2]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[0]).fabricIndex = [CurrentFabricIndex copy]; + + temp_0[1] = [[MTRAccessControlClusterExtensionEntry alloc] init]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[1]).data = mDOkSingle.HasValue() + ? [NSData dataWithBytes:mDOkSingle.Value().data() length:mDOkSingle.Value().size()] + : [[NSData alloc] + initWithBytes:"\x17\xD0\x00\x00\xF1\xFF\x01\x00\x3D\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64\x2E\x20\x54\x68" + "\x69\x73\x20\x69\x73\x20\x61\x20\x73\x69\x6E\x67\x6C\x65\x20\x65\x6C\x65\x6D\x65\x6E\x74\x20\x6C" + "\x69\x76\x69\x6E\x67\x20\x61\x73\x20\x61\x20\x63\x68\x61\x72\x73\x74\x72\x69\x6E\x67\x00\x18" + length:71]; + ((MTRAccessControlClusterExtensionEntry *) temp_0[1]).fabricIndex = [CurrentFabricIndex copy]; + + extensionArgument = temp_0; + } + [cluster + writeAttributeExtensionWithValue:extensionArgument + completion:^(NSError * _Nullable err) { + NSLog(@"TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is list " + @"of AccessControlExtensionStruct containing 2 elements . value is list of " + @"AccessControlExtensionStruct containing 2 elements . first element contains Data " + @"field: D_OK_EMPTY 1718 . second element contains Data field: D_OK_SINGLE " + @"17D00000F1FF01003D48656C6C6F20576F726C642E205468697320697320612073696E676C6520656C656" + @"D656E74206C6976696E6720617320612063686172737472696E670018 Error: %@", + err); + + VerifyOrReturn(CheckValue("status", + err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code + : EMBER_ZCL_STATUS_FAILURE) + : 0, + EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestTh1ReadsDutEndpoint0AccessControlClusterExtensionAttribute_17() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRReadParams alloc] init]; + params.filterByFabric = true; + [cluster + readAttributeExtensionWithParams:params + completion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("Extension", [actualValue count], static_cast(1))); + VerifyOrReturn(CheckValueAsString( + "Data", ((MTRAccessControlClusterExtensionEntry *) actualValue[0]).data, + mDOkEmpty.HasValue() ? [NSData dataWithBytes:mDOkEmpty.Value().data() + length:mDOkEmpty.Value().size()] + : [[NSData alloc] initWithBytes:"\x17\x18" length:2] + + )); + VerifyOrReturn(CheckValue("FabricIndex", + ((MTRAccessControlClusterExtensionEntry *) actualValue[0]).fabricIndex, + CurrentFabricIndex)); + } + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestTh1WritesDutEndpoint0AccessControlClusterExtensionAttributeValueIsAnEmptyList_18() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + id extensionArgument; + { + NSMutableArray * temp_0 = [[NSMutableArray alloc] init]; + extensionArgument = temp_0; + } + [cluster writeAttributeExtensionWithValue:extensionArgument + completion:^(NSError * _Nullable err) { + NSLog(@"TH1 writes DUT Endpoint 0 AccessControl cluster Extension attribute, value is " + @"an empty list Error: %@", + err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestTh1ReadsDutEndpoint0AccessControlClusterExtensionAttribute_19() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRReadParams alloc] init]; + params.filterByFabric = true; + [cluster + readAttributeExtensionWithParams:params + completion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH1 reads DUT Endpoint 0 AccessControl cluster Extension attribute Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("Extension", [actualValue count], static_cast(0))); + } + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } +}; + +class Test_TC_BOOL_1_1 : public TestCommandBridge { +public: + // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced + Test_TC_BOOL_1_1() + : TestCommandBridge("Test_TC_BOOL_1_1") + , mTestIndex(0) + { + AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); + AddArgument("cluster", &mCluster); + AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("timeout", 0, UINT16_MAX, &mTimeout); + } + // NOLINTEND(clang-analyzer-nullability.NullPassedToNonnull) + + ~Test_TC_BOOL_1_1() {} + + /////////// TestCommand Interface ///////// + void NextTest() override + { + CHIP_ERROR err = CHIP_NO_ERROR; + + if (0 == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Start: Test_TC_BOOL_1_1\n"); + } + + if (mTestCount == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Complete: Test_TC_BOOL_1_1\n"); + SetCommandExitStatus(CHIP_NO_ERROR); + return; + } + + Wait(); + + // Ensure we increment mTestIndex before we start running the relevant + // command. That way if we lose the timeslice after we send the message + // but before our function call returns, we won't end up with an + // incorrect mTestIndex value observed when we get the response. + switch (mTestIndex++) { + case 0: + ChipLogProgress(chipTool, " ***** Test Step 0 : Wait for the commissioned device to be retrieved\n"); + err = TestWaitForTheCommissionedDeviceToBeRetrieved_0(); + break; + case 1: + ChipLogProgress(chipTool, " ***** Test Step 1 : read the global attribute: ClusterRevision\n"); + err = TestReadTheGlobalAttributeClusterRevision_1(); + break; + case 2: + ChipLogProgress(chipTool, " ***** Test Step 2 : Read the global attribute: FeatureMap\n"); + err = TestReadTheGlobalAttributeFeatureMap_2(); + break; + case 3: + ChipLogProgress(chipTool, " ***** Test Step 3 : Read the global attribute: AttributeList\n"); + err = TestReadTheGlobalAttributeAttributeList_3(); + break; + case 4: + ChipLogProgress(chipTool, " ***** Test Step 4 : Read the global attribute: AcceptedCommandList\n"); + err = TestReadTheGlobalAttributeAcceptedCommandList_4(); + break; + case 5: + ChipLogProgress(chipTool, " ***** Test Step 5 : Read the global attribute: GeneratedCommandList\n"); + err = TestReadTheGlobalAttributeGeneratedCommandList_5(); + break; + } + + if (CHIP_NO_ERROR != err) { + ChipLogError(chipTool, " ***** Test Failure: %s\n", chip::ErrorStr(err)); + SetCommandExitStatus(err); + } + } + + void OnStatusUpdate(const chip::app::StatusIB & status) override + { + switch (mTestIndex - 1) { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 4: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 5: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + } + + // Go on to the next test. + ContinueOnChipMainThread(CHIP_NO_ERROR); + } + + chip::System::Clock::Timeout GetWaitDuration() const override + { + return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); + } + +private: + std::atomic_uint16_t mTestIndex; + const uint16_t mTestCount = 6; + + chip::Optional mNodeId; + chip::Optional mCluster; + chip::Optional mEndpoint; + chip::Optional mTimeout; + + CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() + { + + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee("alpha", value); + } + + CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"read the global attribute: ClusterRevision Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("ClusterRevision", actualValue, 1U)); + } + + VerifyOrReturn(CheckConstraintType("clusterRevision", "int16u", "int16u")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read the global attribute: FeatureMap Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("FeatureMap", actualValue, 0UL)); + } + + VerifyOrReturn(CheckConstraintType("featureMap", "bitmap32", "bitmap32")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read the global attribute: AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 0UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65528UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65529UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65531UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65532UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65533UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_4() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read the global attribute: AcceptedCommandList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("AcceptedCommandList", [actualValue count], static_cast(0))); + } + + VerifyOrReturn(CheckConstraintType("acceptedCommandList", "list", "list")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_5() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read the global attribute: GeneratedCommandList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("GeneratedCommandList", [actualValue count], static_cast(0))); + } + + VerifyOrReturn(CheckConstraintType("generatedCommandList", "list", "list")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } +}; + +class Test_TC_BOOL_2_1 : public TestCommandBridge { +public: + // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced + Test_TC_BOOL_2_1() + : TestCommandBridge("Test_TC_BOOL_2_1") + , mTestIndex(0) + { + AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); + AddArgument("cluster", &mCluster); + AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("timeout", 0, UINT16_MAX, &mTimeout); + } + // NOLINTEND(clang-analyzer-nullability.NullPassedToNonnull) + + ~Test_TC_BOOL_2_1() {} + + /////////// TestCommand Interface ///////// + void NextTest() override + { + CHIP_ERROR err = CHIP_NO_ERROR; + + if (0 == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Start: Test_TC_BOOL_2_1\n"); + } + + if (mTestCount == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Complete: Test_TC_BOOL_2_1\n"); + SetCommandExitStatus(CHIP_NO_ERROR); + return; + } + + Wait(); + + // Ensure we increment mTestIndex before we start running the relevant + // command. That way if we lose the timeslice after we send the message + // but before our function call returns, we won't end up with an + // incorrect mTestIndex value observed when we get the response. + switch (mTestIndex++) { + case 0: + ChipLogProgress(chipTool, " ***** Test Step 0 : Wait for the commissioned device to be retrieved\n"); + err = TestWaitForTheCommissionedDeviceToBeRetrieved_0(); + break; + case 1: + ChipLogProgress(chipTool, " ***** Test Step 1 : Read mandatory non-global attribute: StateValue\n"); + if (ShouldSkip("BOOL.S.A0000")) { + NextTest(); + return; + } + err = TestReadMandatoryNonGlobalAttributeStateValue_1(); + break; + } + + if (CHIP_NO_ERROR != err) { + ChipLogError(chipTool, " ***** Test Failure: %s\n", chip::ErrorStr(err)); + SetCommandExitStatus(err); + } + } + + void OnStatusUpdate(const chip::app::StatusIB & status) override + { + switch (mTestIndex - 1) { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + } + + // Go on to the next test. + ContinueOnChipMainThread(CHIP_NO_ERROR); + } + + chip::System::Clock::Timeout GetWaitDuration() const override + { + return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); + } + +private: + std::atomic_uint16_t mTestIndex; + const uint16_t mTestCount = 2; + + chip::Optional mNodeId; + chip::Optional mCluster; + chip::Optional mEndpoint; + chip::Optional mTimeout; + + CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() + { + + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee("alpha", value); + } + + CHIP_ERROR TestReadMandatoryNonGlobalAttributeStateValue_1() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBooleanState alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeStateValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read mandatory non-global attribute: StateValue Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("stateValue", "boolean", "boolean")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } +}; + +class Test_TC_BRBINFO_1_1 : public TestCommandBridge { +public: + // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced + Test_TC_BRBINFO_1_1() + : TestCommandBridge("Test_TC_BRBINFO_1_1") + , mTestIndex(0) + { + AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); + AddArgument("cluster", &mCluster); + AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("timeout", 0, UINT16_MAX, &mTimeout); + } + // NOLINTEND(clang-analyzer-nullability.NullPassedToNonnull) + + ~Test_TC_BRBINFO_1_1() {} + + /////////// TestCommand Interface ///////// + void NextTest() override + { + CHIP_ERROR err = CHIP_NO_ERROR; + + if (0 == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Start: Test_TC_BRBINFO_1_1\n"); + } + + if (mTestCount == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Complete: Test_TC_BRBINFO_1_1\n"); + SetCommandExitStatus(CHIP_NO_ERROR); + return; + } + + Wait(); + + // Ensure we increment mTestIndex before we start running the relevant + // command. That way if we lose the timeslice after we send the message + // but before our function call returns, we won't end up with an + // incorrect mTestIndex value observed when we get the response. + switch (mTestIndex++) { + case 0: + ChipLogProgress(chipTool, " ***** Test Step 0 : Wait for the commissioned device to be retrieved\n"); + err = TestWaitForTheCommissionedDeviceToBeRetrieved_0(); + break; + case 1: + ChipLogProgress(chipTool, " ***** Test Step 1 : TH reads the ClusterRevision from DUT\n"); + err = TestThReadsTheClusterRevisionFromDut_1(); + break; + case 2: + ChipLogProgress(chipTool, " ***** Test Step 2 : TH reads the FeatureMap from DUT\n"); + err = TestThReadsTheFeatureMapFromDut_2(); + break; + case 3: + ChipLogProgress(chipTool, " ***** Test Step 3 : TH reads AttributeList from DUT\n"); + err = TestThReadsAttributeListFromDut_3(); + break; + case 4: + ChipLogProgress(chipTool, " ***** Test Step 4 : TH reads optional attribute(VendorName) in AttributeList\n"); + if (ShouldSkip("BRBINFO.S.A0001")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeVendorNameInAttributeList_4(); + break; + case 5: + ChipLogProgress(chipTool, " ***** Test Step 5 : TH reads optional attribute(VendorID) in AttributeList\n"); + if (ShouldSkip("BRBINFO.S.A0002")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeVendorIDInAttributeList_5(); + break; + case 6: + ChipLogProgress(chipTool, " ***** Test Step 6 : TH reads optional attribute(ProductName) in AttributeList\n"); + if (ShouldSkip("BRBINFO.S.A0003")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeProductNameInAttributeList_6(); + break; + case 7: + ChipLogProgress(chipTool, " ***** Test Step 7 : TH reads optional attribute(NodeLabel) in AttributeList\n"); + if (ShouldSkip("BRBINFO.S.A0005")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeNodeLabelInAttributeList_7(); + break; + case 8: + ChipLogProgress(chipTool, " ***** Test Step 8 : TH reads optional attribute(HardwareVersion) in AttributeList\n"); + if (ShouldSkip("BRBINFO.S.A0007")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeHardwareVersionInAttributeList_8(); + break; + case 9: + ChipLogProgress(chipTool, " ***** Test Step 9 : TH reads optional attribute(HardwareVersionString) in AttributeList\n"); + if (ShouldSkip("BRBINFO.S.A0008")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeHardwareVersionStringInAttributeList_9(); + break; + case 10: + ChipLogProgress(chipTool, " ***** Test Step 10 : TH reads optional attribute(SoftwareVersion) in AttributeList\n"); + if (ShouldSkip("BRBINFO.S.A0009")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeSoftwareVersionInAttributeList_10(); + break; + case 11: + ChipLogProgress( + chipTool, " ***** Test Step 11 : TH reads optional attribute(SoftwareVersionString) in AttributeList\n"); + if (ShouldSkip("BRBINFO.S.A000a")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeSoftwareVersionStringInAttributeList_11(); + break; + case 12: + ChipLogProgress(chipTool, " ***** Test Step 12 : TH reads optional attribute(ManufacturingDate) in AttributeList\n"); + if (ShouldSkip("BRBINFO.S.A000b")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeManufacturingDateInAttributeList_12(); + break; + case 13: + ChipLogProgress(chipTool, " ***** Test Step 13 : TH reads optional attribute(PartNumber) in AttributeList\n"); + if (ShouldSkip("BRBINFO.S.A000c")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributePartNumberInAttributeList_13(); + break; + case 14: + ChipLogProgress(chipTool, " ***** Test Step 14 : TH reads optional attribute(ProductURL) in AttributeList\n"); + if (ShouldSkip("BRBINFO.S.A000d")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeProductURLInAttributeList_14(); + break; + case 15: + ChipLogProgress(chipTool, " ***** Test Step 15 : TH reads optional attribute(ProductLabel) in AttributeList\n"); + if (ShouldSkip("BRBINFO.S.A000e")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeProductLabelInAttributeList_15(); + break; + case 16: + ChipLogProgress(chipTool, " ***** Test Step 16 : TH reads optional attribute(SerialNumber) in AttributeList\n"); + if (ShouldSkip("BRBINFO.S.A000f")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeSerialNumberInAttributeList_16(); + break; + case 17: + ChipLogProgress(chipTool, " ***** Test Step 17 : TH reads optional attribute(UniqueID) in AttributeList\n"); + if (ShouldSkip("BRBINFO.S.A0012")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeUniqueIDInAttributeList_17(); + break; + case 18: + ChipLogProgress(chipTool, " ***** Test Step 18 : TH1 reads AcceptedCommandList from DUT\n"); + err = TestTh1ReadsAcceptedCommandListFromDut_18(); + break; + case 19: + ChipLogProgress(chipTool, " ***** Test Step 19 : TH1 reads GeneratedCommandList from DUT\n"); + err = TestTh1ReadsGeneratedCommandListFromDut_19(); + break; + } + + if (CHIP_NO_ERROR != err) { + ChipLogError(chipTool, " ***** Test Failure: %s\n", chip::ErrorStr(err)); + SetCommandExitStatus(err); + } + } + + void OnStatusUpdate(const chip::app::StatusIB & status) override + { + switch (mTestIndex - 1) { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 4: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 5: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 6: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 7: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 8: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 9: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 10: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 11: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 12: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 13: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 14: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 15: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 16: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 17: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 18: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 19: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + } + + // Go on to the next test. + ContinueOnChipMainThread(CHIP_NO_ERROR); + } + + chip::System::Clock::Timeout GetWaitDuration() const override + { + return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); + } + +private: + std::atomic_uint16_t mTestIndex; + const uint16_t mTestCount = 20; + + chip::Optional mNodeId; + chip::Optional mCluster; + chip::Optional mEndpoint; + chip::Optional mTimeout; + + CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() + { + + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee("alpha", value); + } + + CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads the ClusterRevision from DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("ClusterRevision", actualValue, 1U)); + } + + VerifyOrReturn(CheckConstraintType("clusterRevision", "int16u", "int16u")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads the FeatureMap from DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("FeatureMap", actualValue, 0UL)); + } + + VerifyOrReturn(CheckConstraintType("featureMap", "bitmap32", "bitmap32")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsAttributeListFromDut_3() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads AttributeList from DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 17UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65528UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65529UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65531UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65532UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65533UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeVendorNameInAttributeList_4() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(VendorName) in AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 1UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeVendorIDInAttributeList_5() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(VendorID) in AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 2UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeProductNameInAttributeList_6() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(ProductName) in AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 3UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeNodeLabelInAttributeList_7() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(NodeLabel) in AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 5UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeHardwareVersionInAttributeList_8() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(HardwareVersion) in AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 7UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeHardwareVersionStringInAttributeList_9() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(HardwareVersionString) in AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 8UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeSoftwareVersionInAttributeList_10() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(SoftwareVersion) in AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 9UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeSoftwareVersionStringInAttributeList_11() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(SoftwareVersionString) in AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 10UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeManufacturingDateInAttributeList_12() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(ManufacturingDate) in AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 11UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributePartNumberInAttributeList_13() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(PartNumber) in AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 12UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeProductURLInAttributeList_14() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(ProductURL) in AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 13UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeProductLabelInAttributeList_15() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(ProductLabel) in AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 14UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeSerialNumberInAttributeList_16() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(SerialNumber) in AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 15UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeUniqueIDInAttributeList_17() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(UniqueID) in AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 18UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestTh1ReadsAcceptedCommandListFromDut_18() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH1 reads AcceptedCommandList from DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("AcceptedCommandList", [actualValue count], static_cast(0))); + } + + VerifyOrReturn(CheckConstraintType("acceptedCommandList", "list", "list")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestTh1ReadsGeneratedCommandListFromDut_19() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBridgedDeviceBasic alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH1 reads GeneratedCommandList from DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("GeneratedCommandList", [actualValue count], static_cast(0))); + } + + VerifyOrReturn(CheckConstraintType("generatedCommandList", "list", "list")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } +}; + +class Test_TC_ACT_1_1 : public TestCommandBridge { +public: + // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced + Test_TC_ACT_1_1() + : TestCommandBridge("Test_TC_ACT_1_1") + , mTestIndex(0) + { + AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); + AddArgument("cluster", &mCluster); + AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("timeout", 0, UINT16_MAX, &mTimeout); + } + // NOLINTEND(clang-analyzer-nullability.NullPassedToNonnull) + + ~Test_TC_ACT_1_1() {} + + /////////// TestCommand Interface ///////// + void NextTest() override + { + CHIP_ERROR err = CHIP_NO_ERROR; + + if (0 == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Start: Test_TC_ACT_1_1\n"); + } + + if (mTestCount == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Complete: Test_TC_ACT_1_1\n"); + SetCommandExitStatus(CHIP_NO_ERROR); + return; + } + + Wait(); + + // Ensure we increment mTestIndex before we start running the relevant + // command. That way if we lose the timeslice after we send the message + // but before our function call returns, we won't end up with an + // incorrect mTestIndex value observed when we get the response. + switch (mTestIndex++) { + case 0: + ChipLogProgress(chipTool, " ***** Test Step 0 : Wait for the commissioned device to be retrieved\n"); + err = TestWaitForTheCommissionedDeviceToBeRetrieved_0(); + break; + case 1: + ChipLogProgress(chipTool, " ***** Test Step 1 : Read the global attribute: ClusterRevision\n"); + err = TestReadTheGlobalAttributeClusterRevision_1(); + break; + case 2: + ChipLogProgress(chipTool, " ***** Test Step 2 : Read the global attribute: FeatureMap\n"); + err = TestReadTheGlobalAttributeFeatureMap_2(); + break; + case 3: + ChipLogProgress(chipTool, " ***** Test Step 3 : Read the global attribute: AttributeList\n"); + err = TestReadTheGlobalAttributeAttributeList_3(); + break; + case 4: + ChipLogProgress(chipTool, " ***** Test Step 4 : Read the optional attribute(SetupURL) in AttributeList\n"); + if (ShouldSkip("ACT.S.A0002")) { + NextTest(); + return; + } + err = TestReadTheOptionalAttributeSetupURLInAttributeList_4(); + break; + case 5: + ChipLogProgress(chipTool, " ***** Test Step 5 : Read the global attribute: AcceptedCommandList\n"); + err = TestReadTheGlobalAttributeAcceptedCommandList_5(); + break; + case 6: + ChipLogProgress(chipTool, " ***** Test Step 6 : Read the global attribute: GeneratedCommandList\n"); + err = TestReadTheGlobalAttributeGeneratedCommandList_6(); break; } @@ -3265,6 +5064,7 @@ class Test_TC_ACT_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -3272,10 +5072,9 @@ class Test_TC_ACT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -3297,10 +5096,9 @@ class Test_TC_ACT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -3322,10 +5120,9 @@ class Test_TC_ACT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -3350,10 +5147,9 @@ class Test_TC_ACT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeSetupURLInAttributeList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -3372,10 +5168,9 @@ class Test_TC_ACT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -3393,10 +5188,9 @@ class Test_TC_ACT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterActions * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterActions alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -3530,6 +5324,7 @@ class Test_TC_BIND_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -3537,10 +5332,9 @@ class Test_TC_BIND_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -3562,10 +5356,9 @@ class Test_TC_BIND_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -3587,10 +5380,9 @@ class Test_TC_BIND_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAttributeListFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -3614,10 +5406,9 @@ class Test_TC_BIND_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAcceptedCommandListFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -3639,10 +5430,9 @@ class Test_TC_BIND_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsGeneratedCommandListFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4248,6 +6038,7 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -4255,10 +6046,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -4280,10 +6070,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -4305,10 +6094,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenCcsf00hsEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -4325,10 +6113,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenCCSF01EHueEnsureFeaturemapHasTheCorrectBitSet_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -4345,10 +6132,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenCcsf02clEnsureFeaturemapHasTheCorrectBitSet_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -4365,10 +6151,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenCcsf03xyEnsureFeaturemapHasTheCorrectBitSet_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -4385,10 +6170,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenCcsf04ctEnsureFeaturemapHasTheCorrectBitSet_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -4405,10 +6189,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4435,10 +6218,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeCurrentHueInAttributeList_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4457,10 +6239,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeCurrentSaturationInAttributeList_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4479,10 +6260,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeRemainingTimeInAttributeList_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4501,10 +6281,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeCurrentXInAttributeList_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4523,10 +6302,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeCurrentYInAttributeList_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4545,10 +6323,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeDriftCompensationInAttributeList_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4567,10 +6344,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeCompensationTextInAttributeList_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4589,10 +6365,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeColorTemperatureMiredsInAttributeList_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4611,10 +6386,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeEnhancedCurrentHueInAttributeList_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4633,10 +6407,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeColorLoopActiveInAttributeList_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4655,10 +6428,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeColorLoopDirectionInAttributeList_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4677,10 +6449,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeColorLoopTimeInAttributeList_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4699,10 +6470,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeColorLoopStartEnhancedHueInAttributeList_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4721,10 +6491,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeColorLoopStoredEnhancedHueInAttributeList_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4743,10 +6512,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeColorTempPhysicalMinMiredsInAttributeList_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4765,10 +6533,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeColorTempPhysicalMaxMiredsInAttributeList_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4787,10 +6554,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeCoupleColorTempToLevelMinMiredsInAttributeList_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4809,10 +6575,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeStartUpColorTemperatureMiredsInAttributeList_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4831,10 +6596,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandMoveToHueInAcceptedCommandList_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4853,10 +6617,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandMoveHueInAcceptedCommandList_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4875,10 +6638,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandStepHueInAcceptedCommandList_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4897,10 +6659,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandMoveToSaturationInAcceptedCommandList_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4919,10 +6680,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandMoveSaturationInAcceptedCommandList_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4941,10 +6701,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandStepSaturationInAcceptedCommandList_32() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4963,10 +6722,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandMoveToHueAndSaturationInAcceptedCommandList_33() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -4985,10 +6743,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandMoveToColorInAcceptedCommandList_34() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -5007,10 +6764,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandMoveColorInAcceptedCommandList_35() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -5029,10 +6785,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandStepColorInAcceptedCommandList_36() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -5051,10 +6806,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandMoveToColorTemperatureInAcceptedCommandList_37() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -5073,10 +6827,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandEnhancedMoveToHueInAcceptedCommandList_38() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -5095,10 +6848,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandEnhancedMoveHueInAcceptedCommandList_39() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -5117,10 +6869,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandEnhancedStepHueInAcceptedCommandList_40() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -5139,10 +6890,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandEnhancedMoveToHueAndSaturationInAcceptedCommandList_41() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -5161,10 +6911,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandColorLoopSetInAcceptedCommandList_42() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -5183,10 +6932,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandStopMoveStepInAcceptedCommandList_43() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -5205,10 +6953,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandMoveColorTemperatureInAcceptedCommandList_44() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -5227,10 +6974,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandStepColorTemperatureInAcceptedCommandList_45() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -5249,10 +6995,9 @@ class Test_TC_CC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_46() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -5967,6 +7712,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -5974,10 +7720,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -5997,10 +7742,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6020,10 +7764,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsRemainingTimeAttributeFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRemainingTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6043,10 +7786,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6066,10 +7808,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6089,10 +7830,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsDriftCompensationAttributeFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeDriftCompensationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6112,10 +7852,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCompensationTextAttributeFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCompensationTextWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -6133,10 +7872,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorTemperatureMiredsAttributeFromDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorTemperatureMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6156,10 +7894,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorModeAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6179,10 +7916,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionsAttributeFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOptionsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6202,10 +7938,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedCurrentHueAttributeFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6225,10 +7960,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedColorModeAttributeFromDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6248,10 +7982,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorLoopActiveAttributeFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorLoopActiveWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6271,10 +8004,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorLoopDirectionAttributeFromDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorLoopDirectionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6294,10 +8026,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorLoopTimeAttributeFromDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorLoopTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6317,10 +8048,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorLoopStartEnhancedHueAttributeFromDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorLoopStartEnhancedHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6340,10 +8070,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorLoopStoredEnhancedHueAttributeFromDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorLoopStoredEnhancedHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6364,10 +8093,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestSavingForComparisionInStep19ReadsFeatureMapAttributeFromDut_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6387,10 +8115,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorCapabilitiesAttributeFromDut_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorCapabilitiesWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6415,10 +8142,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorTempPhysicalMinMiredsAttributeFromDut_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorTempPhysicalMinMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6438,10 +8164,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorTempPhysicalMaxMiredsAttributeFromDut_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorTempPhysicalMaxMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6461,10 +8186,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCoupleColorTempToLevelMinMiredsAttributeFromDut_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCoupleColorTempToLevelMinMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6485,10 +8209,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsStartUpColorTemperatureMiredsAttributeFromDut_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeStartUpColorTemperatureMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6512,10 +8235,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsNumberOfPrimariesAttributeFromDut_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNumberOfPrimariesWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6539,6 +8261,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary1XAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint16Min0Max0xfeffIfNumberOfPrimariesIs1OrMore_25() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6549,6 +8272,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary1YAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint16Min0Max0xfeffIfNumberOfPrimariesIs1OrMore_26() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6559,6 +8283,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary1IntensityAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint8IfNumberOfPrimariesIs1OrMore_27() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6569,6 +8294,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary2XAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint16Min0Max0xfeffIfNumberOfPrimariesIs2OrMore_28() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6579,6 +8305,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary2YAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint16Min0Max0xfeffIfNumberOfPrimariesIs2OrMore_29() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6589,6 +8316,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary2IntensityAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint8IfNumberOfPrimariesIs2OrMore_30() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6599,6 +8327,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary3XAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint16Min0Max0xfeffIfNumberOfPrimariesIs3OrMore_31() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6609,6 +8338,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary3YAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint16Min0Max0xfeffIfNumberOfPrimariesIs3OrMore_32() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6619,6 +8349,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary3IntensityAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint8IfNumberOfPrimariesIs3OrMore_33() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6629,6 +8360,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary4XAttributeFromDutVerifyThatTheDutResponseContainsAnUint16Min0Max0xfeffIfNumberOfPrimariesIs4OrMore_34() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6639,6 +8371,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary4YAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint16Min0Max0xfeffIfNumberOfPrimariesIs4OrMore_35() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6649,6 +8382,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary4IntensityAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint8IfNumberOfPrimariesIs4OrMore_36() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6659,6 +8393,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary5XAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint16Min0Max0xfeffIfNumberOfPrimariesIs5OrMore_37() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6669,6 +8404,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary5YAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint16Min0Max0xfeffIfNumberOfPrimariesIs5OrMore_38() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6679,6 +8415,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary5IntensityAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint8IfNumberOfPrimariesIs5OrMore_39() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6689,6 +8426,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary6XAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint16Min0Max0xfeffIfNumberOfPrimariesIs6OrMore_40() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6699,6 +8437,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary6YAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint16Min0Max0xfeffIfNumberOfPrimariesIs6OrMore_41() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6709,6 +8448,7 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsPrimary6IntensityAttributeFromDutAndVerifyThatTheDutResponseContainsAnUint8IfNumberOfPrimariesIs6OrMore_42() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -6718,10 +8458,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsWhitePointXAttributeFromDut_43() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWhitePointXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6741,10 +8480,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsWhitePointYAttributeFromDut_44() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWhitePointYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6764,10 +8502,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorPointRXAttributeFromDut_45() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorPointRXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6787,10 +8524,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorPointRYAttributeFromDut_46() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorPointRYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6810,10 +8546,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorPointRIntensityAttributeFromDut_47() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorPointRIntensityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6836,10 +8571,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorPointGXAttributeFromDut_48() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorPointGXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6859,10 +8593,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorPointGYAttributeFromDut_49() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorPointGYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6882,10 +8615,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorPointGIntensityAttributeFromDut_50() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorPointGIntensityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6908,10 +8640,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorPointBXAttributeFromDut_51() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorPointBXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6931,10 +8662,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorPointBYAttributeFromDut_52() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorPointBYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -6954,10 +8684,9 @@ class Test_TC_CC_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorPointBIntensityAttributeFromDut_53() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorPointBIntensityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -7355,6 +9084,7 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -7362,10 +9092,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -7384,8 +9113,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -7401,10 +9131,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToHueCommandToDutWithHue200Direction0x00ShortestDistanceAndTransitionTime0Immediately_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToHueParams alloc] init]; @@ -7429,6 +9158,7 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestWait100ms_4() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -7436,10 +9166,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveHueCommandToDutWithMoveMode0x01UpAndRate5UnitsS_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveHueParams alloc] init]; @@ -7461,6 +9190,7 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestWait10s_6() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -7468,10 +9198,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -7490,6 +9219,7 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestWait10s_8() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -7497,10 +9227,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -7519,6 +9248,7 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestWait10s_10() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -7526,10 +9256,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveHueCommandToDutWithMoveMode0x00StopAndRate5UnitsS_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveHueParams alloc] init]; @@ -7551,10 +9280,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -7573,6 +9301,7 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestWait2s_13() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 2000UL; return WaitForMs("alpha", value); @@ -7580,10 +9309,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -7602,10 +9330,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToHueCommandToDutWithHue60Direction0x00ShortestDistanceAndTransitionTime0Immediately_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToHueParams alloc] init]; @@ -7630,6 +9357,7 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestWait100ms_16() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -7637,10 +9365,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveHueCommandToDutWithMoveMode0x03DownAndRate5UnitsS_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveHueParams alloc] init]; @@ -7662,6 +9389,7 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestWait10s_18() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -7669,10 +9397,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -7691,6 +9418,7 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestWait10s_20() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -7698,10 +9426,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -7720,6 +9447,7 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestWait10s_22() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -7727,10 +9455,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveHueCommandToDutWithMoveMode0x00StopAndRate5UnitsS_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveHueParams alloc] init]; @@ -7752,10 +9479,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -7774,6 +9500,7 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestWait2s_25() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 2000UL; return WaitForMs("alpha", value); @@ -7781,10 +9508,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -7803,10 +9529,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThReadsColorModeAttributeFromDut_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -7830,10 +9555,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedColorModeAttributeFromDut_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -7857,8 +9581,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestTurnOffLightThatWeTurnedOn_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -7874,8 +9599,9 @@ class Test_TC_CC_3_2 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -8213,6 +9939,7 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -8220,10 +9947,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -8242,8 +9968,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -8259,10 +9986,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToHueCommandToDutWithHue200Direction0x00ShortestDistanceAndTransitionTime0Immediately_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToHueParams alloc] init]; @@ -8287,6 +10013,7 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestWait100ms_4() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -8294,10 +10021,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestThSendsStepHueCommandToDutWithStepMode0x01UpStepSize60AndTransitionTime20020s_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterStepHueParams alloc] init]; @@ -8322,6 +10048,7 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_6() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -8329,10 +10056,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -8351,6 +10077,7 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_8() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -8358,10 +10085,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -8380,6 +10106,7 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestWait5s_10() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -8387,10 +10114,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -8409,10 +10135,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToHueCommandToDutWithHue50Direction0x00ShortestDistanceAndTransitionTime0Immediately_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToHueParams alloc] init]; @@ -8437,6 +10162,7 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestWait100ms_13() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -8444,10 +10170,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestThSendsStepHueCommandToDutWithStepMode0x03DownStepSize60AndTransitionTime20020s_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterStepHueParams alloc] init]; @@ -8472,6 +10197,7 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_15() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -8479,10 +10205,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -8501,6 +10226,7 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_17() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -8508,10 +10234,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -8530,6 +10255,7 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestWait5s_19() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -8537,10 +10263,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -8559,10 +10284,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestThReadsColorModeAttributeFromDut_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -8586,10 +10310,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedColorModeAttributeFromDut_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -8613,8 +10336,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestTurnOffLightThatWeTurnedOn_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -8630,8 +10354,9 @@ class Test_TC_CC_3_3 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -8901,6 +10626,7 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -8908,10 +10634,9 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -8930,8 +10655,9 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -8947,10 +10673,9 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToSaturationCommandToDutWithSaturation60AndTransitionTime0Immediately_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToSaturationParams alloc] init]; @@ -8974,6 +10699,7 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestWait100ms_4() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -8981,10 +10707,9 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToSaturationCommandToDutWithSaturation120AndTransitionTime30030s_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToSaturationParams alloc] init]; @@ -9008,6 +10733,7 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestWait10s_6() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -9015,10 +10741,9 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -9037,6 +10762,7 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestWait10s_8() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -9044,10 +10770,9 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -9066,6 +10791,7 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestWait10s_10() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -9073,10 +10799,9 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -9095,6 +10820,7 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestWait5s_12() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -9102,10 +10828,9 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -9124,10 +10849,9 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorModeAttributeFromDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -9151,10 +10875,9 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedColorModeAttributeFromDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -9178,8 +10901,9 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestTurnOffLightThatWeTurnedOn_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -9195,8 +10919,9 @@ class Test_TC_CC_4_1 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -9623,6 +11348,7 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -9630,10 +11356,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -9652,8 +11377,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -9669,10 +11395,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToSaturationCommandToDutWithSaturation150AndTransitionTime0Immediately_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToSaturationParams alloc] init]; @@ -9696,6 +11421,7 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestWait100ms_4() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -9703,10 +11429,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveSaturationCommandToDutWithMoveMode0x01UpAndRate5UnitsS_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveSaturationParams alloc] init]; @@ -9731,6 +11456,7 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestWait10s_6() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -9738,10 +11464,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -9760,6 +11485,7 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestWait10s_8() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -9767,10 +11493,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -9789,6 +11514,7 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestWait5s_10() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -9796,10 +11522,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -9818,10 +11543,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToSaturationCommandToDutWithSaturation120AndTransitionTime0Immediately_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToSaturationParams alloc] init]; @@ -9845,6 +11569,7 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestWait100ms_13() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -9852,10 +11577,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveSaturationCommandToDutWithMoveMode0x03DownAndRate5UnitsS_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveSaturationParams alloc] init]; @@ -9879,6 +11603,7 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestWait10s_15() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -9886,10 +11611,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -9908,6 +11632,7 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestWait10s_17() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -9915,10 +11640,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -9937,6 +11661,7 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestWait10s_19() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -9944,10 +11669,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -9966,10 +11690,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToSaturationCommandToDutWithSaturation150AndTransitionTime0Immediately_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToSaturationParams alloc] init]; @@ -9993,6 +11716,7 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestWait100ms_22() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -10000,10 +11724,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveSaturationCommandToDutWithMoveMode0x01UpAndRate5UnitsS_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveSaturationParams alloc] init]; @@ -10028,6 +11751,7 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestWait10s_24() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -10035,10 +11759,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -10057,10 +11780,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveSaturationCommandToDutWithMoveMode0x00StopAndRate5UnitsS_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveSaturationParams alloc] init]; @@ -10084,10 +11806,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -10106,6 +11827,7 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestWait2s_28() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 2000UL; return WaitForMs("alpha", value); @@ -10113,10 +11835,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -10135,10 +11856,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThReadsColorModeAttributeFromDut_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -10162,10 +11882,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedColorModeAttributeFromDut_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -10189,8 +11908,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestTurnOffLightThatWeTurnedOn_32() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -10206,8 +11926,9 @@ class Test_TC_CC_4_2 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_33() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -10607,6 +12328,7 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -10614,10 +12336,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -10636,8 +12357,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -10653,10 +12375,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToSaturationCommandToDutWithSaturation200AndTransitionTime0Immediately_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToSaturationParams alloc] init]; @@ -10680,6 +12401,7 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestWait100ms_4() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -10687,10 +12409,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThSendsStepSaturationCommandToDutWithStepMode0x01UpStepSize40AndTransitionTime20020s_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterStepSaturationParams alloc] init]; @@ -10715,6 +12436,7 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_6() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -10722,10 +12444,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -10744,6 +12465,7 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_8() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -10751,10 +12473,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -10773,6 +12494,7 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestWait5s_10() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -10780,10 +12502,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -10802,10 +12523,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThSendsStepSaturationCommandToDutWithStepMode0x01UpStepSize20AndTransitionTime10010s_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterStepSaturationParams alloc] init]; @@ -10830,6 +12550,7 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_13() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -10837,10 +12558,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -10859,10 +12579,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToSaturationCommandToDutWithSaturation50AndTransitionTime0Immediately_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToSaturationParams alloc] init]; @@ -10886,6 +12605,7 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestWait100ms_16() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -10893,10 +12613,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThSendsStepSaturationCommandToDutWithStepMode0x03DownStepSize40AndTransitionTime20020s_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterStepSaturationParams alloc] init]; @@ -10921,6 +12640,7 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_18() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -10928,10 +12648,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -10950,6 +12669,7 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_20() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -10957,10 +12677,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -10979,6 +12698,7 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestWait5s_22() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -10986,10 +12706,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -11008,10 +12727,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThSendsStepSaturationCommandToDutWithStepMode0x03DownStepSize20AndTransitionTime10010S_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterStepSaturationParams alloc] init]; @@ -11036,6 +12754,7 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_25() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -11043,10 +12762,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -11067,10 +12785,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThReadsColorModeAttributeFromDut_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -11094,10 +12811,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedColorModeAttributeFromDut_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -11121,8 +12837,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestTurnOffLightThatWeTurnedOn_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -11138,8 +12855,9 @@ class Test_TC_CC_4_3 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -11445,6 +13163,7 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -11452,10 +13171,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -11474,8 +13192,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -11491,10 +13210,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToHueAndSaturationCommandToDutWithHue200Saturation50AndTransitionTime0Immediately_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToHueAndSaturationParams alloc] init]; @@ -11519,6 +13237,7 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestWait100ms_4() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -11526,10 +13245,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -11548,10 +13266,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -11570,10 +13287,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToHueAndSaturationCommandToDutWithHue160Saturation80AndTransitionTime20020s_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToHueAndSaturationParams alloc] init]; @@ -11598,6 +13314,7 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestWait10s_8() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -11605,10 +13322,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -11627,10 +13343,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -11649,6 +13364,7 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestWait10s_11() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -11656,10 +13372,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -11678,10 +13393,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -11701,6 +13415,7 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestWait5s_14() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -11708,10 +13423,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentHueAttributeFromDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -11730,10 +13444,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -11752,10 +13465,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestThReadsColorModeAttributeFromDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -11779,10 +13491,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedColorModeAttributeFromDut_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -11806,8 +13517,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestTurnOffLightThatWeTurnedOn_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -11823,8 +13535,9 @@ class Test_TC_CC_4_4 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -12532,6 +14245,7 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -12539,10 +14253,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -12561,8 +14274,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -12578,10 +14292,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToColorCommandToDutWithColorX327680x8000ColorY196600x4CCCTransitionTime0Immediate_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToColorParams alloc] init]; @@ -12606,6 +14319,7 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestWait100ms_4() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -12613,10 +14327,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -12635,10 +14348,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -12657,10 +14369,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToColorCommandToDutWithColorX131070x3333ColorY131070x3333TransitionTime20020s_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToColorParams alloc] init]; @@ -12685,6 +14396,7 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestWait10s_8() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -12692,10 +14404,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -12714,10 +14425,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -12736,6 +14446,7 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestWait10s_11() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -12743,10 +14454,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -12765,10 +14475,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -12787,6 +14496,7 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestWait5s_14() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -12794,10 +14504,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -12816,10 +14525,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -12838,10 +14546,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -12860,10 +14567,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadOptionsAttribute_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOptionsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -12884,8 +14590,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -12901,10 +14608,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveToColorCommandToTheDutWithColorX327680x8000X05PurpleColorY196600x4CCCY03TransitionTime0Immediate_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToColorParams alloc] init]; @@ -12929,6 +14635,7 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestWait100ms_21() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -12936,10 +14643,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -12958,10 +14664,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -12980,8 +14685,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOffCommandToDut_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -12997,10 +14703,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToColorCommandToDutWithColorX131070x3333ColorY131070x3333TransitionTime0Immediate_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToColorParams alloc] init]; @@ -13025,6 +14730,7 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestWait100ms_26() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -13032,10 +14738,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13056,10 +14761,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13080,10 +14784,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToColorCommandToDutWithColorX131070x3333ColorY327680x8000TransitionTime0Immediate_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToColorParams alloc] init]; @@ -13108,6 +14811,7 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestWait100ms_30() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -13115,10 +14819,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13139,10 +14842,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_32() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13163,10 +14865,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToColorCommandToDutWithColorX262140x6666ColorY327680x8000TransitionTime0Immediate_33() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToColorParams alloc] init]; @@ -13191,6 +14892,7 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestWait100ms_34() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -13198,10 +14900,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_35() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13220,10 +14921,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_36() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13242,10 +14942,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThWrites1ToTheOptionsAttribute_37() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -13264,10 +14963,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadOptionsAttribute_38() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOptionsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13288,8 +14986,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_39() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -13305,10 +15004,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToColorCommandToDutWithColorX327680x8000ColorY196600x4CCCTransitionTime0Immediate_40() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToColorParams alloc] init]; @@ -13333,6 +15031,7 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestWait100ms_41() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -13340,10 +15039,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_42() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13362,10 +15060,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_43() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13384,8 +15081,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOffCommandToDut_44() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -13401,10 +15099,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToColorCommandToDutWithColorX131070x3333ColorY131070x3333TransitionTime0Immediate_45() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToColorParams alloc] init]; @@ -13429,6 +15126,7 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestWait100ms_46() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -13436,10 +15134,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_47() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13458,10 +15155,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_48() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13480,10 +15176,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToColorCommandToDutWithColorX131070x3333ColorY327680x8000TransitionTime0Immediate_49() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToColorParams alloc] init]; @@ -13508,6 +15203,7 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestWait100ms_50() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -13515,10 +15211,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_51() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13539,10 +15234,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_52() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13563,10 +15257,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToColorCommandToDutWithColorX262140x6666ColorY327680x8000TransitionTime0Immediate_53() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToColorParams alloc] init]; @@ -13591,6 +15284,7 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestWait100ms_54() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -13598,10 +15292,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_55() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13620,10 +15313,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_56() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13642,10 +15334,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorModeAttributeFromDut_57() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13669,10 +15360,9 @@ class Test_TC_CC_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedColorModeAttributeFromDut_58() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -13990,6 +15680,7 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -13997,10 +15688,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -14019,8 +15709,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -14036,10 +15727,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToColorCommandToDutWithColorX33000ColorY26000TransitionTime0Immediate_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToColorParams alloc] init]; @@ -14064,6 +15754,7 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestWait100ms_4() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -14071,10 +15762,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveColorCommandToDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveColorParams alloc] init]; @@ -14096,6 +15786,7 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestWait10s_6() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -14103,10 +15794,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14125,10 +15815,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14147,6 +15836,7 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestWait10s_9() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -14154,10 +15844,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14176,10 +15865,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14198,6 +15886,7 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestWait10s_12() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -14206,10 +15895,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14232,10 +15920,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14257,10 +15944,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestThSendsStopMoveStepCommandToDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterStopMoveStepParams alloc] init]; @@ -14280,10 +15966,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14302,10 +15987,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14324,10 +16008,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestThReadsColorModeAttributeFromDut_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14351,10 +16034,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedColorModeAttributeFromDut_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14378,8 +16060,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestTurnOffLightThatWeTurnedOn_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -14395,8 +16078,9 @@ class Test_TC_CC_5_2 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14680,6 +16364,7 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -14687,10 +16372,9 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -14709,8 +16393,9 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -14726,10 +16411,9 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToColorCommandToDutWithColorX33000ColorY20000TransitionTime0Immediate_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToColorParams alloc] init]; @@ -14754,6 +16438,7 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestWait100ms_4() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -14761,10 +16446,9 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestThSendsStepColorCommandToDutWithStepX20000StepY6000TransitionTime20020s_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterStepColorParams alloc] init]; @@ -14789,6 +16473,7 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_6() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -14796,10 +16481,9 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14818,10 +16502,9 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14840,6 +16523,7 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_9() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -14847,10 +16531,9 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14869,10 +16552,9 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14891,6 +16573,7 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestWait5s_12() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -14898,10 +16581,9 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentXAttributeFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentXWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14920,10 +16602,9 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentYAttributeFromDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentYWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14942,10 +16623,9 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestThReadsColorModeAttributeFromDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14969,10 +16649,9 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedColorModeAttributeFromDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -14996,8 +16675,9 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestTurnOffLightThatWeTurnedOn_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -15013,8 +16693,9 @@ class Test_TC_CC_5_3 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -15316,6 +16997,7 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -15323,10 +17005,9 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -15345,8 +17026,9 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -15363,10 +17045,9 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorTempPhysicalMinMiredsAttributeFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorTempPhysicalMinMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -15390,10 +17071,9 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorTempPhysicalMaxMiredsAttributeFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorTempPhysicalMaxMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -15416,10 +17096,9 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorTemperatureMiredsAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorTemperatureMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -15441,10 +17120,9 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToColorTemperatureCommandToDutWithColorTemperatureMireds310AndTransitionTime0Immediately_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToColorTemperatureParams alloc] init]; @@ -15468,6 +17146,7 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestWait100ms_7() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -15475,10 +17154,9 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestThSendsMoveToColorTemperaturCommandToDutWithColorTemperatureMireds250AndTransitionTime30030s_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterMoveToColorTemperatureParams alloc] init]; @@ -15502,6 +17180,7 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestWait10s_9() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -15509,10 +17188,9 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorTemperatureMiredsAttributeFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorTemperatureMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -15531,6 +17209,7 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestWait10s_11() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -15538,10 +17217,9 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorTemperatureMiredsAttributeFromDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorTemperatureMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -15560,6 +17238,7 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestWait10s_13() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -15567,10 +17246,9 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorTemperatureMiredsAttributeFromDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorTemperatureMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -15589,6 +17267,7 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestWait5s_15() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -15596,10 +17275,9 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorTemperatureMiredsAttributeFromDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorTemperatureMiredsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -15618,10 +17296,9 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestThReadsColorModeAttributeFromDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -15645,10 +17322,9 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedColorModeAttributeFromDut_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -15672,8 +17348,9 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestTurnOffLightThatWeTurnedOn_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -15689,8 +17366,9 @@ class Test_TC_CC_6_1 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -16064,6 +17742,7 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -16071,10 +17750,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -16093,8 +17771,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -16111,10 +17790,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThSendsEnhancedMoveToHueCommandToDutWithEnhancedHue6000Direction0x00ShortestDistanceAndTransitionTime0Immediately_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterEnhancedMoveToHueParams alloc] init]; @@ -16139,6 +17817,7 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestWait100ms_4() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -16146,10 +17825,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThSendsEnhancedStepHueCommandToDutWithStepMode0x01UpStepSize6000AndTransitionTime30030s_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterEnhancedStepHueParams alloc] init]; @@ -16174,6 +17852,7 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_6() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -16181,10 +17860,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedCurrentHueAttributeFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -16203,6 +17881,7 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_8() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -16210,10 +17889,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedCurrentHueAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -16232,6 +17910,7 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_10() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -16239,10 +17918,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedCurrentHueAttributeFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -16261,6 +17939,7 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestWait5s_12() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -16268,10 +17947,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedCurrentHueAttributeFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -16291,10 +17969,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThSendsEnhancedMoveToHueCommandToDutWithEnhancedHue12000Direction0x00ShortestDistanceAndTransitionTime0Immediately_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterEnhancedMoveToHueParams alloc] init]; @@ -16319,6 +17996,7 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestWait100ms_15() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -16326,10 +18004,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThSendsEnhancedStepHueCommandToDutWithStepMode0x03DownStepSize6000AndTransitionTime30030s_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterEnhancedStepHueParams alloc] init]; @@ -16354,6 +18031,7 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_17() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -16361,10 +18039,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedCurrentHueAttributeFromDut_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -16383,6 +18060,7 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_19() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -16390,10 +18068,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedCurrentHueAttributeFromDut_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -16412,6 +18089,7 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestWait10s_21() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -16419,10 +18097,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedCurrentHueAttributeFromDut_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -16441,6 +18118,7 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestWait5s_23() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -16448,10 +18126,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedCurrentHueAttributeFromDut_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -16470,10 +18147,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThReadsColorModeAttributeFromDut_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -16497,10 +18173,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedColorModeAttributeFromDut_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -16524,8 +18199,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestTurnOffLightThatWeTurnedOn_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -16541,8 +18217,9 @@ class Test_TC_CC_7_3 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -16848,6 +18525,7 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -16855,10 +18533,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -16877,8 +18554,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -16895,10 +18573,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestThSendsEnhancedMoveToHueAndSaturationCommandToDutWithEnhancedHue20000Saturation50AndTransitionTime0Immediately_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterEnhancedMoveToHueAndSaturationParams alloc] init]; @@ -16925,6 +18602,7 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestWait100ms_4() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -16932,10 +18610,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedCurrentHueAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -16954,10 +18631,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -16976,10 +18652,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestThSendsEnhancedMoveToHueAndSaturationCommandToDutWithEnhancedHue16000Saturation80AndTransitionTime20020s_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRColorControlClusterEnhancedMoveToHueAndSaturationParams alloc] init]; @@ -17004,6 +18679,7 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestWait10s_8() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -17011,10 +18687,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedCurrentHueAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -17034,10 +18709,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -17056,6 +18730,7 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestWait10s_11() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -17063,10 +18738,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedCurrentHueAttributeFromDut_12() { - MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -17086,10 +18760,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -17108,6 +18781,7 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestWait5s_14() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -17115,10 +18789,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedCurrentHueAttributeFromDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedCurrentHueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -17139,10 +18812,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentSaturationAttributeFromDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentSaturationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -17163,10 +18835,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestThReadsColorModeAttributeFromDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -17190,10 +18861,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestThReadsEnhancedColorModeAttributeFromDut_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterColorControl * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterColorControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnhancedColorModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -17217,8 +18887,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestTurnOffLightThatWeTurnedOn_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -17234,8 +18905,9 @@ class Test_TC_CC_7_4 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -17368,6 +19040,7 @@ class Test_TC_OPCREDS_1_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -17375,9 +19048,11 @@ class Test_TC_OPCREDS_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -17399,9 +19074,11 @@ class Test_TC_OPCREDS_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -17423,9 +19100,11 @@ class Test_TC_OPCREDS_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsAttributeListFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -17452,52 +19131,565 @@ class Test_TC_OPCREDS_1_2 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsAcceptedCommandListFromDut_4() + CHIP_ERROR TestThReadsAcceptedCommandListFromDut_4() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads AcceptedCommandList from DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("acceptedCommandList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 0UL)); + VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 2UL)); + VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 4UL)); + VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 6UL)); + VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 7UL)); + VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 9UL)); + VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 10UL)); + VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 11UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsGeneratedCommandListFromDut_5() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads GeneratedCommandList from DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("generatedCommandList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("generatedCommandList", value, 1UL)); + VerifyOrReturn(CheckConstraintContains("generatedCommandList", value, 3UL)); + VerifyOrReturn(CheckConstraintContains("generatedCommandList", value, 5UL)); + VerifyOrReturn(CheckConstraintContains("generatedCommandList", value, 8UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } +}; + +class Test_TC_BINFO_1_1 : public TestCommandBridge { +public: + // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced + Test_TC_BINFO_1_1() + : TestCommandBridge("Test_TC_BINFO_1_1") + , mTestIndex(0) + { + AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); + AddArgument("cluster", &mCluster); + AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("timeout", 0, UINT16_MAX, &mTimeout); + } + // NOLINTEND(clang-analyzer-nullability.NullPassedToNonnull) + + ~Test_TC_BINFO_1_1() {} + + /////////// TestCommand Interface ///////// + void NextTest() override + { + CHIP_ERROR err = CHIP_NO_ERROR; + + if (0 == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Start: Test_TC_BINFO_1_1\n"); + } + + if (mTestCount == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Complete: Test_TC_BINFO_1_1\n"); + SetCommandExitStatus(CHIP_NO_ERROR); + return; + } + + Wait(); + + // Ensure we increment mTestIndex before we start running the relevant + // command. That way if we lose the timeslice after we send the message + // but before our function call returns, we won't end up with an + // incorrect mTestIndex value observed when we get the response. + switch (mTestIndex++) { + case 0: + ChipLogProgress(chipTool, " ***** Test Step 0 : Wait for the commissioned device to be retrieved\n"); + err = TestWaitForTheCommissionedDeviceToBeRetrieved_0(); + break; + case 1: + ChipLogProgress(chipTool, " ***** Test Step 1 : TH reads the ClusterRevision from DUT\n"); + err = TestThReadsTheClusterRevisionFromDut_1(); + break; + case 2: + ChipLogProgress(chipTool, " ***** Test Step 2 : TH reads the FeatureMap from DUT\n"); + err = TestThReadsTheFeatureMapFromDut_2(); + break; + case 3: + ChipLogProgress(chipTool, " ***** Test Step 3 : TH reads AttributeList from DUT\n"); + err = TestThReadsAttributeListFromDut_3(); + break; + case 4: + ChipLogProgress(chipTool, " ***** Test Step 4 : TH reads optional attribute(ManufacturingDate) in attributeList\n"); + if (ShouldSkip("BINFO.S.A000b")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeManufacturingDateInAttributeList_4(); + break; + case 5: + ChipLogProgress(chipTool, " ***** Test Step 5 : TH reads optional attribute(PartNumber) in attributeList\n"); + if (ShouldSkip("BINFO.S.A000c")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributePartNumberInAttributeList_5(); + break; + case 6: + ChipLogProgress(chipTool, " ***** Test Step 6 : TH reads optional attribute(ProductURL) in attributeList\n"); + if (ShouldSkip("BINFO.S.A000d")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeProductURLInAttributeList_6(); + break; + case 7: + ChipLogProgress(chipTool, " ***** Test Step 7 : TH reads optional attribute(ProductLabel) in attributeList\n"); + if (ShouldSkip("BINFO.S.A000e")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeProductLabelInAttributeList_7(); + break; + case 8: + ChipLogProgress(chipTool, " ***** Test Step 8 : TH reads optional attribute(SerialNumber) in attributeList\n"); + if (ShouldSkip("BINFO.S.A000f")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeSerialNumberInAttributeList_8(); + break; + case 9: + ChipLogProgress(chipTool, " ***** Test Step 9 : TH reads optional attribute(LocalConfigDisabled) in attributeList\n"); + if (ShouldSkip("BINFO.S.A0010")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeLocalConfigDisabledInAttributeList_9(); + break; + case 10: + ChipLogProgress(chipTool, " ***** Test Step 10 : TH reads optional attribute(Reachable) in attributeList\n"); + if (ShouldSkip("BINFO.S.A0011")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeReachableInAttributeList_10(); + break; + case 11: + ChipLogProgress(chipTool, " ***** Test Step 11 : TH reads optional attribute(UniqueID) in attributeList\n"); + if (ShouldSkip("BINFO.S.A0012")) { + NextTest(); + return; + } + err = TestThReadsOptionalAttributeUniqueIDInAttributeList_11(); + break; + case 12: + ChipLogProgress(chipTool, " ***** Test Step 12 : TH1 reads AcceptedCommandList from DUT\n"); + err = TestTh1ReadsAcceptedCommandListFromDut_12(); + break; + case 13: + ChipLogProgress(chipTool, " ***** Test Step 13 : TH1 reads GeneratedCommandList from DUT\n"); + err = TestTh1ReadsGeneratedCommandListFromDut_13(); + break; + } + + if (CHIP_NO_ERROR != err) { + ChipLogError(chipTool, " ***** Test Failure: %s\n", chip::ErrorStr(err)); + SetCommandExitStatus(err); + } + } + + void OnStatusUpdate(const chip::app::StatusIB & status) override + { + switch (mTestIndex - 1) { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 4: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 5: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 6: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 7: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 8: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 9: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 10: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 11: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 12: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 13: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + } + + // Go on to the next test. + ContinueOnChipMainThread(CHIP_NO_ERROR); + } + + chip::System::Clock::Timeout GetWaitDuration() const override + { + return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); + } + +private: + std::atomic_uint16_t mTestIndex; + const uint16_t mTestCount = 14; + + chip::Optional mNodeId; + chip::Optional mCluster; + chip::Optional mEndpoint; + chip::Optional mTimeout; + + CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() + { + + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee("alpha", value); + } + + CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads the ClusterRevision from DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("ClusterRevision", actualValue, 1U)); + } + + VerifyOrReturn(CheckConstraintType("clusterRevision", "int16u", "int16u")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads the FeatureMap from DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("FeatureMap", actualValue, 0UL)); + } + + VerifyOrReturn(CheckConstraintType("featureMap", "bitmap32", "bitmap32")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsAttributeListFromDut_3() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads AttributeList from DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 0UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 1UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 2UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 3UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 4UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 5UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 6UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 7UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 8UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 9UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 10UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 19UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65528UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65529UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65531UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65532UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65533UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeManufacturingDateInAttributeList_4() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(ManufacturingDate) in attributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 11UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributePartNumberInAttributeList_5() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(PartNumber) in attributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 12UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeProductURLInAttributeList_6() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(ProductURL) in attributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 13UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeProductLabelInAttributeList_7() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(ProductLabel) in attributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 14UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeSerialNumberInAttributeList_8() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(SerialNumber) in attributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 15UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeLocalConfigDisabledInAttributeList_9() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(LocalConfigDisabled) in attributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 16UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeReachableInAttributeList_10() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(Reachable) in attributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 17UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsOptionalAttributeUniqueIDInAttributeList_11() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads optional attribute(UniqueID) in attributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 18UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestTh1ReadsAcceptedCommandListFromDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH reads AcceptedCommandList from DUT Error: %@", err); + NSLog(@"TH1 reads AcceptedCommandList from DUT Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - VerifyOrReturn(CheckConstraintType("acceptedCommandList", "list", "list")); - VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 0UL)); - VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 2UL)); - VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 4UL)); - VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 6UL)); - VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 7UL)); - VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 9UL)); - VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 10UL)); - VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 11UL)); + { + id actualValue = value; + VerifyOrReturn(CheckValue("AcceptedCommandList", [actualValue count], static_cast(0))); + } + VerifyOrReturn(CheckConstraintType("acceptedCommandList", "list", "list")); NextTest(); }]; return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsGeneratedCommandListFromDut_5() + CHIP_ERROR TestTh1ReadsGeneratedCommandListFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH reads GeneratedCommandList from DUT Error: %@", err); + NSLog(@"TH1 reads GeneratedCommandList from DUT Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - VerifyOrReturn(CheckConstraintType("generatedCommandList", "list", "list")); - VerifyOrReturn(CheckConstraintContains("generatedCommandList", value, 1UL)); - VerifyOrReturn(CheckConstraintContains("generatedCommandList", value, 3UL)); - VerifyOrReturn(CheckConstraintContains("generatedCommandList", value, 5UL)); - VerifyOrReturn(CheckConstraintContains("generatedCommandList", value, 8UL)); + { + id actualValue = value; + VerifyOrReturn(CheckValue("GeneratedCommandList", [actualValue count], static_cast(0))); + } + VerifyOrReturn(CheckConstraintType("generatedCommandList", "list", "list")); NextTest(); }]; @@ -17505,11 +19697,11 @@ class Test_TC_OPCREDS_1_2 : public TestCommandBridge { } }; -class Test_TC_BINFO_1_1 : public TestCommandBridge { +class Test_TC_CNET_1_3 : public TestCommandBridge { public: // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced - Test_TC_BINFO_1_1() - : TestCommandBridge("Test_TC_BINFO_1_1") + Test_TC_CNET_1_3() + : TestCommandBridge("Test_TC_CNET_1_3") , mTestIndex(0) { AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); @@ -17519,7 +19711,7 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { } // NOLINTEND(clang-analyzer-nullability.NullPassedToNonnull) - ~Test_TC_BINFO_1_1() {} + ~Test_TC_CNET_1_3() {} /////////// TestCommand Interface ///////// void NextTest() override @@ -17527,11 +19719,11 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { CHIP_ERROR err = CHIP_NO_ERROR; if (0 == mTestIndex) { - ChipLogProgress(chipTool, " **** Test Start: Test_TC_BINFO_1_1\n"); + ChipLogProgress(chipTool, " **** Test Start: Test_TC_CNET_1_3\n"); } if (mTestCount == mTestIndex) { - ChipLogProgress(chipTool, " **** Test Complete: Test_TC_BINFO_1_1\n"); + ChipLogProgress(chipTool, " **** Test Complete: Test_TC_CNET_1_3\n"); SetCommandExitStatus(CHIP_NO_ERROR); return; } @@ -17548,88 +19740,128 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { err = TestWaitForTheCommissionedDeviceToBeRetrieved_0(); break; case 1: - ChipLogProgress(chipTool, " ***** Test Step 1 : TH reads the ClusterRevision from DUT\n"); - err = TestThReadsTheClusterRevisionFromDut_1(); + ChipLogProgress(chipTool, " ***** Test Step 1 : Read the global attribute: ClusterRevision\n"); + err = TestReadTheGlobalAttributeClusterRevision_1(); break; case 2: - ChipLogProgress(chipTool, " ***** Test Step 2 : TH reads the FeatureMap from DUT\n"); - err = TestThReadsTheFeatureMapFromDut_2(); + ChipLogProgress(chipTool, " ***** Test Step 2 : Read the global attribute: FeatureMap\n"); + if (ShouldSkip(" !CNET.S.F00 && !CNET.S.F01 && !CNET.S.F02 ")) { + NextTest(); + return; + } + err = TestReadTheGlobalAttributeFeatureMap_2(); break; case 3: - ChipLogProgress(chipTool, " ***** Test Step 3 : TH reads AttributeList from DUT\n"); - err = TestThReadsAttributeListFromDut_3(); + ChipLogProgress(chipTool, " ***** Test Step 3 : Read the global attribute: FeatureMap when CNET.S.F00 is set\n"); + if (ShouldSkip("CNET.S.F00")) { + NextTest(); + return; + } + err = TestReadTheGlobalAttributeFeatureMapWhenCnetsf00IsSet_3(); break; case 4: - ChipLogProgress(chipTool, " ***** Test Step 4 : TH reads optional attribute(ManufacturingDate) in attributeList\n"); - if (ShouldSkip("BINFO.S.A000b")) { + ChipLogProgress(chipTool, " ***** Test Step 4 : Read the global attribute: FeatureMap when CNET.S.F01 is set\n"); + if (ShouldSkip("CNET.S.F01")) { NextTest(); return; } - err = TestThReadsOptionalAttributeManufacturingDateInAttributeList_4(); + err = TestReadTheGlobalAttributeFeatureMapWhenCnetsf01IsSet_4(); break; case 5: - ChipLogProgress(chipTool, " ***** Test Step 5 : TH reads optional attribute(PartNumber) in attributeList\n"); - if (ShouldSkip("BINFO.S.A000c")) { + ChipLogProgress(chipTool, " ***** Test Step 5 : Read the global attribute: FeatureMap when CNET.S.F02 is set\n"); + if (ShouldSkip("CNET.S.F02")) { NextTest(); return; } - err = TestThReadsOptionalAttributePartNumberInAttributeList_5(); + err = TestReadTheGlobalAttributeFeatureMapWhenCnetsf02IsSet_5(); break; case 6: - ChipLogProgress(chipTool, " ***** Test Step 6 : TH reads optional attribute(ProductURL) in attributeList\n"); - if (ShouldSkip("BINFO.S.A000d")) { - NextTest(); - return; - } - err = TestThReadsOptionalAttributeProductURLInAttributeList_6(); + ChipLogProgress(chipTool, " ***** Test Step 6 : Read the global attribute: AttributeList\n"); + err = TestReadTheGlobalAttributeAttributeList_6(); break; case 7: - ChipLogProgress(chipTool, " ***** Test Step 7 : TH reads optional attribute(ProductLabel) in attributeList\n"); - if (ShouldSkip("BINFO.S.A000e")) { + ChipLogProgress(chipTool, + " ***** Test Step 7 : Read mandatory attributes in AttributeList if CNET.S.F00(WI)/CNET.S.F01(TH)/CNET.S.F02(ET) " + "is true\n"); + if (ShouldSkip("CNET.S.F00 || CNET.S.F01 || CNET.S.F02")) { NextTest(); return; } - err = TestThReadsOptionalAttributeProductLabelInAttributeList_7(); + err = TestReadMandatoryAttributesInAttributeListIfCnetsf00wiCnetsf01thCnetsf02etIsTrue_7(); break; case 8: - ChipLogProgress(chipTool, " ***** Test Step 8 : TH reads optional attribute(SerialNumber) in attributeList\n"); - if (ShouldSkip("BINFO.S.A000f")) { + ChipLogProgress(chipTool, " ***** Test Step 8 : Read the optional attribute(ScanMaxTimeSeconds): AttributeList\n"); + if (ShouldSkip("CNET.S.A0002")) { NextTest(); return; } - err = TestThReadsOptionalAttributeSerialNumberInAttributeList_8(); + err = TestReadTheOptionalAttributeScanMaxTimeSecondsAttributeList_8(); break; case 9: - ChipLogProgress(chipTool, " ***** Test Step 9 : TH reads optional attribute(LocalConfigDisabled) in attributeList\n"); - if (ShouldSkip("BINFO.S.A0010")) { + ChipLogProgress(chipTool, " ***** Test Step 9 : Reading optional attribute(ConnectMaxTimeSeconds) in AttributeList\n"); + if (ShouldSkip("CNET.S.A0003")) { NextTest(); return; } - err = TestThReadsOptionalAttributeLocalConfigDisabledInAttributeList_9(); + err = TestReadingOptionalAttributeConnectMaxTimeSecondsInAttributeList_9(); break; case 10: - ChipLogProgress(chipTool, " ***** Test Step 10 : TH reads optional attribute(Reachable) in attributeList\n"); - if (ShouldSkip("BINFO.S.A0011")) { + ChipLogProgress(chipTool, + " ***** Test Step 10 : Read AcceptedCommandList If DUT supports Wi-Fi/Thread related features " + "CNET.S.F00(WI),CNET.S.F01(TH)\n"); + if (ShouldSkip("CNET.S.F00 || CNET.S.F01")) { NextTest(); return; } - err = TestThReadsOptionalAttributeReachableInAttributeList_10(); + err = TestReadAcceptedCommandListIfDutSupportsWiFiThreadRelatedFeaturesCnetsf00wicnetsf01th_10(); break; case 11: - ChipLogProgress(chipTool, " ***** Test Step 11 : TH reads optional attribute(UniqueID) in attributeList\n"); - if (ShouldSkip("BINFO.S.A0012")) { + ChipLogProgress(chipTool, + " ***** Test Step 11 : Read AcceptedCommandList If DUT supports Wi-Fi related features (CNET.S.F00(WI) is true)\n"); + if (ShouldSkip("CNET.S.F00")) { NextTest(); return; } - err = TestThReadsOptionalAttributeUniqueIDInAttributeList_11(); + err = TestReadAcceptedCommandListIfDutSupportsWiFiRelatedFeaturesCnetsf00wiIsTrue_11(); break; case 12: - ChipLogProgress(chipTool, " ***** Test Step 12 : TH1 reads AcceptedCommandList from DUT\n"); - err = TestTh1ReadsAcceptedCommandListFromDut_12(); + ChipLogProgress(chipTool, + " ***** Test Step 12 : Read AcceptedCommandList If DUT supports Thread related features(CNET.S.F01(TH) is true)\n"); + if (ShouldSkip("CNET.S.F01")) { + NextTest(); + return; + } + err = TestReadAcceptedCommandListIfDutSupportsThreadRelatedFeaturesCNETSF01THIsTrue_12(); break; case 13: - ChipLogProgress(chipTool, " ***** Test Step 13 : TH1 reads GeneratedCommandList from DUT\n"); - err = TestTh1ReadsGeneratedCommandListFromDut_13(); + ChipLogProgress(chipTool, + " ***** Test Step 13 : Read AcceptedCommandList If DUT supports Ethernet related features(CNET.S.F02(TH) is " + "true)\n"); + if (ShouldSkip("CNET.S.F02")) { + NextTest(); + return; + } + err = TestReadAcceptedCommandListIfDutSupportsEthernetRelatedFeaturesCNETSF02THIsTrue_13(); + break; + case 14: + ChipLogProgress(chipTool, + " ***** Test Step 14 : Read the GeneratedCommandList If DUT supports Wi-Fi/Thread related features(CNET.S.F00(WI) " + "or CNET.S.F01(TH) is true)\n"); + if (ShouldSkip("CNET.S.F00 || CNET.S.F01")) { + NextTest(); + return; + } + err = TestReadTheGeneratedCommandListIfDutSupportsWiFiThreadRelatedFeaturesCNETSF00WIOrCnetsf01thIsTrue_14(); + break; + case 15: + ChipLogProgress(chipTool, + " ***** Test Step 15 : Read the GeneratedCommandList If DUT supports Ethernet related features(CNET.S.F02(ET) must " + "be true)\n"); + if (ShouldSkip("CNET.S.F02")) { + NextTest(); + return; + } + err = TestReadTheGeneratedCommandListIfDutSupportsEthernetRelatedFeaturesCNETSF02ETMustBeTrue_15(); break; } @@ -17684,6 +19916,12 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { case 13: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; + case 14: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 15: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; } // Go on to the next test. @@ -17697,7 +19935,7 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { private: std::atomic_uint16_t mTestIndex; - const uint16_t mTestCount = 14; + const uint16_t mTestCount = 16; chip::Optional mNodeId; chip::Optional mCluster; @@ -17706,19 +19944,23 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); } - CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() + CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH reads the ClusterRevision from DUT Error: %@", err); + NSLog(@"Read the global attribute: ClusterRevision Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); @@ -17734,14 +19976,17 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() + CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH reads the FeatureMap from DUT Error: %@", err); + NSLog(@"Read the global attribute: FeatureMap Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); @@ -17750,42 +19995,30 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { VerifyOrReturn(CheckValue("FeatureMap", actualValue, 0UL)); } - VerifyOrReturn(CheckConstraintType("featureMap", "bitmap32", "bitmap32")); NextTest(); }]; return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsAttributeListFromDut_3() + CHIP_ERROR TestReadTheGlobalAttributeFeatureMapWhenCnetsf00IsSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH reads AttributeList from DUT Error: %@", err); + [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read the global attribute: FeatureMap when CNET.S.F00 is set Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 0UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 1UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 2UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 3UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 4UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 5UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 6UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 7UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 8UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 9UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 10UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 19UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 65528UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 65529UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 65531UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 65532UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 65533UL)); + { + id actualValue = value; + VerifyOrReturn(CheckValue("FeatureMap", actualValue, 1UL)); + } NextTest(); }]; @@ -17793,19 +20026,24 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeManufacturingDateInAttributeList_4() + CHIP_ERROR TestReadTheGlobalAttributeFeatureMapWhenCnetsf01IsSet_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH reads optional attribute(ManufacturingDate) in attributeList Error: %@", err); + [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read the global attribute: FeatureMap when CNET.S.F01 is set Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 11UL)); + { + id actualValue = value; + VerifyOrReturn(CheckValue("FeatureMap", actualValue, 2UL)); + } NextTest(); }]; @@ -17813,19 +20051,24 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributePartNumberInAttributeList_5() + CHIP_ERROR TestReadTheGlobalAttributeFeatureMapWhenCnetsf02IsSet_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH reads optional attribute(PartNumber) in attributeList Error: %@", err); + [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read the global attribute: FeatureMap when CNET.S.F02 is set Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 12UL)); + { + id actualValue = value; + VerifyOrReturn(CheckValue("FeatureMap", actualValue, 4UL)); + } NextTest(); }]; @@ -17833,19 +20076,26 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeProductURLInAttributeList_6() + CHIP_ERROR TestReadTheGlobalAttributeAttributeList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH reads optional attribute(ProductURL) in attributeList Error: %@", err); + NSLog(@"Read the global attribute: AttributeList Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 13UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65528UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65529UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65531UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65532UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65533UL)); NextTest(); }]; @@ -17853,19 +20103,28 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeProductLabelInAttributeList_7() + CHIP_ERROR TestReadMandatoryAttributesInAttributeListIfCnetsf00wiCnetsf01thCnetsf02etIsTrue_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH reads optional attribute(ProductLabel) in attributeList Error: %@", err); + NSLog(@"Read mandatory attributes in AttributeList if CNET.S.F00(WI)/CNET.S.F01(TH)/CNET.S.F02(ET) is true Error: %@", + err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 14UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 0UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 1UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 4UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 5UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 6UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 7UL)); NextTest(); }]; @@ -17873,19 +20132,22 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeSerialNumberInAttributeList_8() + CHIP_ERROR TestReadTheOptionalAttributeScanMaxTimeSecondsAttributeList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH reads optional attribute(SerialNumber) in attributeList Error: %@", err); + NSLog(@"Read the optional attribute(ScanMaxTimeSeconds): AttributeList Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 15UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 2UL)); NextTest(); }]; @@ -17893,19 +20155,22 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeLocalConfigDisabledInAttributeList_9() + CHIP_ERROR TestReadingOptionalAttributeConnectMaxTimeSecondsInAttributeList_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH reads optional attribute(LocalConfigDisabled) in attributeList Error: %@", err); + NSLog(@"Reading optional attribute(ConnectMaxTimeSeconds) in AttributeList Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 16UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 3UL)); NextTest(); }]; @@ -17913,19 +20178,26 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeReachableInAttributeList_10() + CHIP_ERROR TestReadAcceptedCommandListIfDutSupportsWiFiThreadRelatedFeaturesCnetsf00wicnetsf01th_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH reads optional attribute(Reachable) in attributeList Error: %@", err); + [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read AcceptedCommandList If DUT supports Wi-Fi/Thread related features CNET.S.F00(WI),CNET.S.F01(TH) Error: %@", + err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 17UL)); + VerifyOrReturn(CheckConstraintType("acceptedCommandList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 0UL)); + VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 4UL)); + VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 6UL)); + VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 8UL)); NextTest(); }]; @@ -17933,19 +20205,22 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeUniqueIDInAttributeList_11() + CHIP_ERROR TestReadAcceptedCommandListIfDutSupportsWiFiRelatedFeaturesCnetsf00wiIsTrue_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH reads optional attribute(UniqueID) in attributeList Error: %@", err); + [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read AcceptedCommandList If DUT supports Wi-Fi related features (CNET.S.F00(WI) is true) Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 18UL)); + VerifyOrReturn(CheckConstraintType("acceptedCommandList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 2UL)); NextTest(); }]; @@ -17953,14 +20228,40 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestTh1ReadsAcceptedCommandListFromDut_12() + CHIP_ERROR TestReadAcceptedCommandListIfDutSupportsThreadRelatedFeaturesCNETSF01THIsTrue_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH1 reads AcceptedCommandList from DUT Error: %@", err); + NSLog(@"Read AcceptedCommandList If DUT supports Thread related features(CNET.S.F01(TH) is true) Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("acceptedCommandList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 3UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestReadAcceptedCommandListIfDutSupportsEthernetRelatedFeaturesCNETSF02THIsTrue_13() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read AcceptedCommandList If DUT supports Ethernet related features(CNET.S.F02(TH) is true) Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); @@ -17969,21 +20270,51 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { VerifyOrReturn(CheckValue("AcceptedCommandList", [actualValue count], static_cast(0))); } - VerifyOrReturn(CheckConstraintType("acceptedCommandList", "list", "list")); NextTest(); }]; return CHIP_NO_ERROR; } - CHIP_ERROR TestTh1ReadsGeneratedCommandListFromDut_13() + CHIP_ERROR TestReadTheGeneratedCommandListIfDutSupportsWiFiThreadRelatedFeaturesCNETSF00WIOrCnetsf01thIsTrue_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH1 reads GeneratedCommandList from DUT Error: %@", err); + NSLog(@"Read the GeneratedCommandList If DUT supports Wi-Fi/Thread related features(CNET.S.F00(WI) or CNET.S.F01(TH) " + @"is true) Error: %@", + err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("generatedCommandList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("generatedCommandList", value, 1UL)); + VerifyOrReturn(CheckConstraintContains("generatedCommandList", value, 5UL)); + VerifyOrReturn(CheckConstraintContains("generatedCommandList", value, 7UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestReadTheGeneratedCommandListIfDutSupportsEthernetRelatedFeaturesCNETSF02ETMustBeTrue_15() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterNetworkCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read the GeneratedCommandList If DUT supports Ethernet related features(CNET.S.F02(ET) must be true) Error: %@", + err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); @@ -17992,7 +20323,6 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { VerifyOrReturn(CheckValue("GeneratedCommandList", [actualValue count], static_cast(0))); } - VerifyOrReturn(CheckConstraintType("generatedCommandList", "list", "list")); NextTest(); }]; @@ -18000,11 +20330,11 @@ class Test_TC_BINFO_1_1 : public TestCommandBridge { } }; -class Test_TC_CNET_1_3 : public TestCommandBridge { +class Test_TC_DESC_1_1 : public TestCommandBridge { public: // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced - Test_TC_CNET_1_3() - : TestCommandBridge("Test_TC_CNET_1_3") + Test_TC_DESC_1_1() + : TestCommandBridge("Test_TC_DESC_1_1") , mTestIndex(0) { AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); @@ -18014,7 +20344,7 @@ class Test_TC_CNET_1_3 : public TestCommandBridge { } // NOLINTEND(clang-analyzer-nullability.NullPassedToNonnull) - ~Test_TC_CNET_1_3() {} + ~Test_TC_DESC_1_1() {} /////////// TestCommand Interface ///////// void NextTest() override @@ -18022,11 +20352,11 @@ class Test_TC_CNET_1_3 : public TestCommandBridge { CHIP_ERROR err = CHIP_NO_ERROR; if (0 == mTestIndex) { - ChipLogProgress(chipTool, " **** Test Start: Test_TC_CNET_1_3\n"); + ChipLogProgress(chipTool, " **** Test Start: Test_TC_DESC_1_1\n"); } if (mTestCount == mTestIndex) { - ChipLogProgress(chipTool, " **** Test Complete: Test_TC_CNET_1_3\n"); + ChipLogProgress(chipTool, " **** Test Complete: Test_TC_DESC_1_1\n"); SetCommandExitStatus(CHIP_NO_ERROR); return; } @@ -18038,6 +20368,30 @@ class Test_TC_CNET_1_3 : public TestCommandBridge { // but before our function call returns, we won't end up with an // incorrect mTestIndex value observed when we get the response. switch (mTestIndex++) { + case 0: + ChipLogProgress(chipTool, " ***** Test Step 0 : Wait for the commissioned device to be retrieved\n"); + err = TestWaitForTheCommissionedDeviceToBeRetrieved_0(); + break; + case 1: + ChipLogProgress(chipTool, " ***** Test Step 1 : Read the global attribute: ClusterRevision\n"); + err = TestReadTheGlobalAttributeClusterRevision_1(); + break; + case 2: + ChipLogProgress(chipTool, " ***** Test Step 2 : Read the global attribute: FeatureMap\n"); + err = TestReadTheGlobalAttributeFeatureMap_2(); + break; + case 3: + ChipLogProgress(chipTool, " ***** Test Step 3 : Read the global attribute: AttributeList\n"); + err = TestReadTheGlobalAttributeAttributeList_3(); + break; + case 4: + ChipLogProgress(chipTool, " ***** Test Step 4 : Read the global attribute: AcceptedCommandList\n"); + err = TestReadTheGlobalAttributeAcceptedCommandList_4(); + break; + case 5: + ChipLogProgress(chipTool, " ***** Test Step 5 : Read the global attribute: GeneratedCommandList\n"); + err = TestReadTheGlobalAttributeGeneratedCommandList_5(); + break; } if (CHIP_NO_ERROR != err) { @@ -18049,6 +20403,24 @@ class Test_TC_CNET_1_3 : public TestCommandBridge { void OnStatusUpdate(const chip::app::StatusIB & status) override { switch (mTestIndex - 1) { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 4: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 5: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; } // Go on to the next test. @@ -18062,19 +20434,152 @@ class Test_TC_CNET_1_3 : public TestCommandBridge { private: std::atomic_uint16_t mTestIndex; - const uint16_t mTestCount = 0; + const uint16_t mTestCount = 6; chip::Optional mNodeId; chip::Optional mCluster; chip::Optional mEndpoint; chip::Optional mTimeout; + + CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() + { + + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee("alpha", value); + } + + CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read the global attribute: ClusterRevision Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("ClusterRevision", actualValue, 1U)); + } + + VerifyOrReturn(CheckConstraintType("clusterRevision", "int16u", "int16u")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read the global attribute: FeatureMap Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("FeatureMap", actualValue, 0UL)); + } + + VerifyOrReturn(CheckConstraintType("featureMap", "bitmap32", "bitmap32")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read the global attribute: AttributeList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 0UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 1UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 2UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 3UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65528UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65529UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65531UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65532UL)); + VerifyOrReturn(CheckConstraintContains("attributeList", value, 65533UL)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_4() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read the global attribute: AcceptedCommandList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("AcceptedCommandList", [actualValue count], static_cast(0))); + } + + VerifyOrReturn(CheckConstraintType("acceptedCommandList", "list", "list")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_5() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { + NSLog(@"Read the global attribute: GeneratedCommandList Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = value; + VerifyOrReturn(CheckValue("GeneratedCommandList", [actualValue count], static_cast(0))); + } + + VerifyOrReturn(CheckConstraintType("generatedCommandList", "list", "list")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } }; -class Test_TC_DESC_1_1 : public TestCommandBridge { +class Test_TC_DLOG_1_1 : public TestCommandBridge { public: // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced - Test_TC_DESC_1_1() - : TestCommandBridge("Test_TC_DESC_1_1") + Test_TC_DLOG_1_1() + : TestCommandBridge("Test_TC_DLOG_1_1") , mTestIndex(0) { AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); @@ -18084,7 +20589,7 @@ class Test_TC_DESC_1_1 : public TestCommandBridge { } // NOLINTEND(clang-analyzer-nullability.NullPassedToNonnull) - ~Test_TC_DESC_1_1() {} + ~Test_TC_DLOG_1_1() {} /////////// TestCommand Interface ///////// void NextTest() override @@ -18092,11 +20597,11 @@ class Test_TC_DESC_1_1 : public TestCommandBridge { CHIP_ERROR err = CHIP_NO_ERROR; if (0 == mTestIndex) { - ChipLogProgress(chipTool, " **** Test Start: Test_TC_DESC_1_1\n"); + ChipLogProgress(chipTool, " **** Test Start: Test_TC_DLOG_1_1\n"); } if (mTestCount == mTestIndex) { - ChipLogProgress(chipTool, " **** Test Complete: Test_TC_DESC_1_1\n"); + ChipLogProgress(chipTool, " **** Test Complete: Test_TC_DLOG_1_1\n"); SetCommandExitStatus(CHIP_NO_ERROR); return; } @@ -18113,24 +20618,24 @@ class Test_TC_DESC_1_1 : public TestCommandBridge { err = TestWaitForTheCommissionedDeviceToBeRetrieved_0(); break; case 1: - ChipLogProgress(chipTool, " ***** Test Step 1 : Read the global attribute: ClusterRevision\n"); - err = TestReadTheGlobalAttributeClusterRevision_1(); + ChipLogProgress(chipTool, " ***** Test Step 1 : TH reads the ClusterRevision from DUT\n"); + err = TestThReadsTheClusterRevisionFromDut_1(); break; case 2: - ChipLogProgress(chipTool, " ***** Test Step 2 : Read the global attribute: FeatureMap\n"); - err = TestReadTheGlobalAttributeFeatureMap_2(); + ChipLogProgress(chipTool, " ***** Test Step 2 : TH reads the FeatureMap from DUT\n"); + err = TestThReadsTheFeatureMapFromDut_2(); break; case 3: - ChipLogProgress(chipTool, " ***** Test Step 3 : Read the global attribute: AttributeList\n"); - err = TestReadTheGlobalAttributeAttributeList_3(); + ChipLogProgress(chipTool, " ***** Test Step 3 : TH reads AttributeList from DUT\n"); + err = TestThReadsAttributeListFromDut_3(); break; case 4: - ChipLogProgress(chipTool, " ***** Test Step 4 : Read the global attribute: AcceptedCommandList\n"); - err = TestReadTheGlobalAttributeAcceptedCommandList_4(); + ChipLogProgress(chipTool, " ***** Test Step 4 : TH reads AcceptedCommandList from DUT\n"); + err = TestThReadsAcceptedCommandListFromDut_4(); break; case 5: - ChipLogProgress(chipTool, " ***** Test Step 5 : Read the global attribute: GeneratedCommandList\n"); - err = TestReadTheGlobalAttributeGeneratedCommandList_5(); + ChipLogProgress(chipTool, " ***** Test Step 5 : TH reads GeneratedCommandList from DUT\n"); + err = TestThReadsGeneratedCommandListFromDut_5(); break; } @@ -18183,255 +20688,7 @@ class Test_TC_DESC_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { - chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; - value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; - return WaitForCommissionee("alpha", value); - } - - CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() - { - MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; - VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - - [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { - NSLog(@"Read the global attribute: ClusterRevision Error: %@", err); - - VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - - { - id actualValue = value; - VerifyOrReturn(CheckValue("ClusterRevision", actualValue, 1U)); - } - - VerifyOrReturn(CheckConstraintType("clusterRevision", "int16u", "int16u")); - NextTest(); - }]; - - return CHIP_NO_ERROR; - } - - CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() - { - MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; - VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - - [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { - NSLog(@"Read the global attribute: FeatureMap Error: %@", err); - - VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - - { - id actualValue = value; - VerifyOrReturn(CheckValue("FeatureMap", actualValue, 0UL)); - } - - VerifyOrReturn(CheckConstraintType("featureMap", "bitmap32", "bitmap32")); - NextTest(); - }]; - - return CHIP_NO_ERROR; - } - - CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() - { - MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; - VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - - [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"Read the global attribute: AttributeList Error: %@", err); - - VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - - VerifyOrReturn(CheckConstraintType("attributeList", "list", "list")); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 0UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 1UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 2UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 3UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 65528UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 65529UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 65531UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 65532UL)); - VerifyOrReturn(CheckConstraintContains("attributeList", value, 65533UL)); - NextTest(); - }]; - - return CHIP_NO_ERROR; - } - - CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_4() - { - MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; - VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - - [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"Read the global attribute: AcceptedCommandList Error: %@", err); - - VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - - { - id actualValue = value; - VerifyOrReturn(CheckValue("AcceptedCommandList", [actualValue count], static_cast(0))); - } - - VerifyOrReturn(CheckConstraintType("acceptedCommandList", "list", "list")); - NextTest(); - }]; - - return CHIP_NO_ERROR; - } - - CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_5() - { - MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; - VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - - [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"Read the global attribute: GeneratedCommandList Error: %@", err); - - VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - - { - id actualValue = value; - VerifyOrReturn(CheckValue("GeneratedCommandList", [actualValue count], static_cast(0))); - } - - VerifyOrReturn(CheckConstraintType("generatedCommandList", "list", "list")); - NextTest(); - }]; - - return CHIP_NO_ERROR; - } -}; - -class Test_TC_DLOG_1_1 : public TestCommandBridge { -public: - // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced - Test_TC_DLOG_1_1() - : TestCommandBridge("Test_TC_DLOG_1_1") - , mTestIndex(0) - { - AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); - AddArgument("cluster", &mCluster); - AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); - AddArgument("timeout", 0, UINT16_MAX, &mTimeout); - } - // NOLINTEND(clang-analyzer-nullability.NullPassedToNonnull) - - ~Test_TC_DLOG_1_1() {} - - /////////// TestCommand Interface ///////// - void NextTest() override - { - CHIP_ERROR err = CHIP_NO_ERROR; - - if (0 == mTestIndex) { - ChipLogProgress(chipTool, " **** Test Start: Test_TC_DLOG_1_1\n"); - } - - if (mTestCount == mTestIndex) { - ChipLogProgress(chipTool, " **** Test Complete: Test_TC_DLOG_1_1\n"); - SetCommandExitStatus(CHIP_NO_ERROR); - return; - } - - Wait(); - - // Ensure we increment mTestIndex before we start running the relevant - // command. That way if we lose the timeslice after we send the message - // but before our function call returns, we won't end up with an - // incorrect mTestIndex value observed when we get the response. - switch (mTestIndex++) { - case 0: - ChipLogProgress(chipTool, " ***** Test Step 0 : Wait for the commissioned device to be retrieved\n"); - err = TestWaitForTheCommissionedDeviceToBeRetrieved_0(); - break; - case 1: - ChipLogProgress(chipTool, " ***** Test Step 1 : TH reads the ClusterRevision from DUT\n"); - err = TestThReadsTheClusterRevisionFromDut_1(); - break; - case 2: - ChipLogProgress(chipTool, " ***** Test Step 2 : TH reads the FeatureMap from DUT\n"); - err = TestThReadsTheFeatureMapFromDut_2(); - break; - case 3: - ChipLogProgress(chipTool, " ***** Test Step 3 : TH reads AttributeList from DUT\n"); - err = TestThReadsAttributeListFromDut_3(); - break; - case 4: - ChipLogProgress(chipTool, " ***** Test Step 4 : TH reads AcceptedCommandList from DUT\n"); - err = TestThReadsAcceptedCommandListFromDut_4(); - break; - case 5: - ChipLogProgress(chipTool, " ***** Test Step 5 : TH reads GeneratedCommandList from DUT\n"); - err = TestThReadsGeneratedCommandListFromDut_5(); - break; - } - - if (CHIP_NO_ERROR != err) { - ChipLogError(chipTool, " ***** Test Failure: %s\n", chip::ErrorStr(err)); - SetCommandExitStatus(err); - } - } - - void OnStatusUpdate(const chip::app::StatusIB & status) override - { - switch (mTestIndex - 1) { - case 0: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); - break; - case 1: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); - break; - case 2: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); - break; - case 3: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); - break; - case 4: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); - break; - case 5: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); - break; - } - - // Go on to the next test. - ContinueOnChipMainThread(CHIP_NO_ERROR); - } - - chip::System::Clock::Timeout GetWaitDuration() const override - { - return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); - } - -private: - std::atomic_uint16_t mTestIndex; - const uint16_t mTestCount = 6; - - chip::Optional mNodeId; - chip::Optional mCluster; - chip::Optional mEndpoint; - chip::Optional mTimeout; - - CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() - { chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -18439,10 +20696,9 @@ class Test_TC_DLOG_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -18464,10 +20720,9 @@ class Test_TC_DLOG_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -18489,10 +20744,9 @@ class Test_TC_DLOG_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAttributeListFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -18515,10 +20769,9 @@ class Test_TC_DLOG_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAcceptedCommandListFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -18541,10 +20794,9 @@ class Test_TC_DLOG_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsGeneratedCommandListFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDiagnosticLogs * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDiagnosticLogs alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -18829,6 +21081,7 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -18836,9 +21089,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -18860,9 +21115,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -18884,9 +21141,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDgethsf00EnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -18903,9 +21162,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDgethsf01EnsureFeaturemapHasTheCorrectBitSet_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -18922,9 +21183,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAttributeListFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -18947,9 +21210,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributePHYRateInAttributeList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -18968,9 +21233,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeFullDuplexInAttributeList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -18989,9 +21256,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributePacketRxCountAndFeatureDependentDGETHSF00PKTCNTInAttributeList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -19012,9 +21281,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributePacketRxCountAndFeatureDependentDGETHSF00PKTCNTInAttributeList_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -19035,9 +21306,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributePacketRxCountAndFeatureDependentDGETHSF01ERRCNTInAttributeList_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -19058,9 +21331,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributePacketRxCountAndFeatureDependentDGETHSF01ERRCNTInAttributeList_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -19081,9 +21356,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributePacketRxCountAndFeatureDependentDGETHSF01ERRCNTInAttributeList_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -19104,9 +21381,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeCarrierDetectInAttributeList_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -19125,9 +21404,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTimeSinceResetInAttributeList_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -19146,9 +21427,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAcceptedCommandListFromDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -19167,9 +21450,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAcceptedCommandListFromDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -19191,9 +21476,11 @@ class Test_TC_DGETH_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsGeneratedCommandListFromDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -19482,6 +21769,7 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -19489,9 +21777,11 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadPHYRateAttributeConstraints_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePHYRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -19514,9 +21804,11 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadFullDuplexAttributeConstraints_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFullDuplexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -19537,9 +21829,11 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadPacketRxCountAttributeConstraints_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePacketRxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -19556,6 +21850,7 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadPacketRxCountValueFromDutAndVerifyTheNumberOfPacketsReceivedOnEthernetNetworkInterface_4() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -19565,9 +21860,11 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadPacketTxCountAttributeConstraints_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePacketTxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -19584,6 +21881,7 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadPacketTxCountValueFromDutAndVerifyTheNumberOfPacketsReceivedOnEthernetNetworkInterface_6() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -19593,9 +21891,11 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTxErrCountAttributeConstraints_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTxErrCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -19613,6 +21913,7 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTxErrCountValueFromDutAndVerifyValueIndicatesTheNumberOfFailedPacketTransmissionOnEthernetNetworkInterface_8() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -19622,9 +21923,11 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadCollisionCountAttributeConstraints_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCollisionCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -19642,6 +21945,7 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadCollisionCountValueFromDutAndVerifyValueIndicatesTheNumberOfCollisionOccurredWhileTransmittingPacketsOnEthernetNetworkInterface_10() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -19651,9 +21955,11 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadOverrunCountAttributeConstraints_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOverrunCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -19671,6 +21977,7 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadOverrunCountValueFromDutAndVerifyValueIndicatesTheNumberOfPacketsDroppedDueToLackOfBufferMemoryOnEthernetNetworkInterface_12() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -19680,9 +21987,11 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadCarrierDetectAttributeConstraints_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCarrierDetectWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -19704,6 +22013,7 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadCarrierDetectValueFromDutAndVerifyValueIndicatesThePresenceOfCarrierDetectControlSignalOnEthernetNetworkInterface_14() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -19713,9 +22023,11 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTimeSinceResetAttributeConstraints_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTimeSinceResetWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -19732,6 +22044,7 @@ class Test_TC_DGETH_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTimeSinceResetValueFromDutAndVerifyTheValueIndicatesTheDurationOfTimeInMinutes_16() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -20049,6 +22362,7 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -20056,9 +22370,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsPHYRateAttributeFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePHYRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20081,9 +22397,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsPHYRateAttributeFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePHYRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20106,9 +22424,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsPHYRateAttributeFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePHYRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20131,9 +22451,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsPHYRateAttributeFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePHYRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20156,9 +22478,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsPHYRateAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePHYRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20181,9 +22505,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsPHYRateAttributeFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePHYRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20206,9 +22532,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsPHYRateAttributeFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePHYRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20231,9 +22559,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsPHYRateAttributeFromDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePHYRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20256,9 +22586,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsPHYRateAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePHYRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20281,9 +22613,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsPHYRateAttributeFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePHYRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20307,9 +22641,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsPacketRxCountAttributeValueFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePacketRxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20330,9 +22666,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsPacketTxCountAttributeValueFromDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePacketTxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20353,9 +22691,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTxErrCountAttributeValueFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTxErrCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20376,9 +22716,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCollisionCountAttributeValueFromDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCollisionCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20399,9 +22741,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsOverrunCountAttributeValueFromDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOverrunCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20421,9 +22765,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestSendsResetCountsCommand_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster resetCountsWithCompletion:^(NSError * _Nullable err) { @@ -20439,9 +22785,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsPacketRxCountAttributeValueFromDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePacketRxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20459,9 +22807,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsPacketTxCountAttributeValueFromDut_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePacketTxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20479,9 +22829,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTxErrCountAttributeValueFromDut_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTxErrCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20499,9 +22851,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsCollisionCountAttributeValueFromDut_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCollisionCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20519,9 +22873,11 @@ class Test_TC_DGETH_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsOverrunCountAttributeValueFromDut_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterEthernetNetworkDiagnostics * cluster = - [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterEthernetNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOverrunCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20662,6 +23018,7 @@ class Test_TC_FLW_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -20669,10 +23026,9 @@ class Test_TC_FLW_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20694,10 +23050,9 @@ class Test_TC_FLW_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20719,10 +23074,9 @@ class Test_TC_FLW_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -20748,10 +23102,9 @@ class Test_TC_FLW_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeToleranceInAttributeList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -20770,10 +23123,9 @@ class Test_TC_FLW_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -20795,10 +23147,9 @@ class Test_TC_FLW_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -20941,6 +23292,7 @@ class Test_TC_FLW_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -20948,10 +23300,9 @@ class Test_TC_FLW_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeMinMeasuredValue_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -20974,10 +23325,9 @@ class Test_TC_FLW_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeMaxMeasuredValue_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -21000,10 +23350,9 @@ class Test_TC_FLW_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeMeasuredValue_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -21026,10 +23375,9 @@ class Test_TC_FLW_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFromTheDutTheToleranceAttribute_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFlowMeasurement * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFlowMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeToleranceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -21161,6 +23509,7 @@ class Test_TC_FLABEL_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -21168,10 +23517,9 @@ class Test_TC_FLABEL_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -21193,10 +23541,9 @@ class Test_TC_FLABEL_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -21218,10 +23565,9 @@ class Test_TC_FLABEL_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAttributeListFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -21245,10 +23591,9 @@ class Test_TC_FLABEL_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAcceptedCommandListFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -21270,10 +23615,9 @@ class Test_TC_FLABEL_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsGeneratedCommandListFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFixedLabel * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFixedLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -21407,6 +23751,7 @@ class Test_TC_CGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -21414,10 +23759,11 @@ class Test_TC_CGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -21439,10 +23785,11 @@ class Test_TC_CGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -21464,10 +23811,11 @@ class Test_TC_CGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -21495,10 +23843,11 @@ class Test_TC_CGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -21519,10 +23868,11 @@ class Test_TC_CGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -21700,6 +24050,7 @@ class Test_TC_CGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -21707,10 +24058,11 @@ class Test_TC_CGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestTh1ReadsTheBreadCrumbAttributeFromTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBreadcrumbWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -21727,10 +24079,11 @@ class Test_TC_CGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestTh1WritesTheBreadCrumbAttributeAs1ToTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id breadcrumbArgument; @@ -21749,10 +24102,11 @@ class Test_TC_CGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestTh1ReadsTheBreadCrumbAttributeFromTheDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBreadcrumbWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -21773,10 +24127,11 @@ class Test_TC_CGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestTh1ReadsTheRegulatoryConfigAttributeFromTheDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRegulatoryConfigWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -21795,10 +24150,11 @@ class Test_TC_CGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestTh1ReadsTheLocationCapabilityAttributeFromTheDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLocationCapabilityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -21818,10 +24174,11 @@ class Test_TC_CGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestTh1ReadsBasicCommissioningInfoAttributeFromDutAndVerifyThatTheBasicCommissioningInfoAttributeHasTheFollowingFieldFailSafeExpiryLengthSecondsFieldValueIsWithinADurationRangeOf0To65535_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBasicCommissioningInfoWithCompletion:^( @@ -21841,10 +24198,11 @@ class Test_TC_CGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestTh1ReadsSupportsConcurrentConnectionAttributeFromTheDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSupportsConcurrentConnectionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -22039,6 +24397,7 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -22046,10 +24405,11 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -22071,10 +24431,11 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -22096,10 +24457,11 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -22125,10 +24487,11 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadOptionalAttributeUpTimeInAttributeList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -22147,10 +24510,11 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadOptionalAttributeTotalOperationalHoursInAttributeList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -22169,10 +24533,11 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadOptionalAttributeBootReasonInAttributeList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -22191,10 +24556,11 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadOptionalAttributeActiveHardwareFaultsInAttributeList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -22213,10 +24579,11 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadOptionalAttributeActiveRadioFaultsInAttributeList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -22235,10 +24602,11 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadOptionalAttributeActiveNetworkFaultsInAttributeList_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -22257,10 +24625,11 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -22279,10 +24648,11 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -22562,6 +24932,7 @@ class Test_TC_DGGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -22569,10 +24940,11 @@ class Test_TC_DGGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsNetworkInterfacesStructureAttributeFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNetworkInterfacesWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -22589,10 +24961,11 @@ class Test_TC_DGGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsARebootCountAttributeValueFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRebootCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -22612,12 +24985,14 @@ class Test_TC_DGGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestRebootTargetDevice_3() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestRebootTargetDeviceDUT_4() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please reboot the DUT and enter 'y' after DUT startsgarbage: not in length on purpose", 52); @@ -22628,12 +25003,14 @@ class Test_TC_DGGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestRebootTargetDevice_5() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestRebootTargetDeviceDUT_6() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please reboot the DUT and enter 'y' after DUT startsgarbage: not in length on purpose", 52); @@ -22644,6 +25021,7 @@ class Test_TC_DGGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_7() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -22651,10 +25029,11 @@ class Test_TC_DGGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestDutRebootsAndThReadsAUpTimeAttributeValueOfDutSinceSomeArbitraryStartTimeOfDutRebooting_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeUpTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -22673,10 +25052,11 @@ class Test_TC_DGGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsATotalOperationalHoursAttributeValueFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTotalOperationalHoursWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -22696,12 +25076,14 @@ class Test_TC_DGGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestRebootTargetDevice_10() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestRebootTargetDeviceDUT_11() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please reboot the DUT and enter 'y' after DUT startsgarbage: not in length on purpose", 52); @@ -22712,6 +25094,7 @@ class Test_TC_DGGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_12() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -22719,10 +25102,11 @@ class Test_TC_DGGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsBootReasonAttributeValueFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralDiagnostics * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBootReasonsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -22741,6 +25125,7 @@ class Test_TC_DGGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsActiveHardwareFaultsAttributeValueFromDut_14() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -22750,6 +25135,7 @@ class Test_TC_DGGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsActiveRadioFaultsAttributeValueFromDut_15() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -22759,6 +25145,7 @@ class Test_TC_DGGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsActiveNetworkFaultsAttributeValueFromDut_16() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -22768,6 +25155,7 @@ class Test_TC_DGGEN_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTestEventTriggersEnabledAttributeValue_17() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -22900,6 +25288,7 @@ class Test_TC_I_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -22907,10 +25296,9 @@ class Test_TC_I_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionAttributeFromTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -22932,10 +25320,9 @@ class Test_TC_I_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapAttributeFromTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -22957,10 +25344,9 @@ class Test_TC_I_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -22985,10 +25371,9 @@ class Test_TC_I_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -23007,10 +25392,9 @@ class Test_TC_I_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandTriggerEffectInAcceptedCommandList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -23029,10 +25413,9 @@ class Test_TC_I_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -23145,6 +25528,7 @@ class Test_TC_I_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -23152,10 +25536,9 @@ class Test_TC_I_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheIdentifyTimeAttributeFromTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeIdentifyTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -23175,10 +25558,9 @@ class Test_TC_I_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheIdentifyTypeAttributeFromTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeIdentifyTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -23382,6 +25764,7 @@ class Test_TC_I_2_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -23389,10 +25772,9 @@ class Test_TC_I_2_2 : public TestCommandBridge { CHIP_ERROR TestThSendsIdentifyCommandToDutWithTheIdentifyTimeFieldSetTo0x003c60s_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRIdentifyClusterIdentifyParams alloc] init]; @@ -23412,10 +25794,9 @@ class Test_TC_I_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsImmediatelyIdentifyTimeAttributeFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeIdentifyTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -23434,6 +25815,7 @@ class Test_TC_I_2_2 : public TestCommandBridge { CHIP_ERROR TestWait10000ms_3() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -23441,10 +25823,9 @@ class Test_TC_I_2_2 : public TestCommandBridge { CHIP_ERROR TestAfter10SecondsTheThReadsIdentifyTimeAttributeFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeIdentifyTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -23464,6 +25845,7 @@ class Test_TC_I_2_2 : public TestCommandBridge { CHIP_ERROR TestThSendsIdentifyQueryCommandToDutAndVerifyIdentifyQueryResponseCommandToTHwithTheTimeoutFieldSetToAValueInTheRange0x0000To0x0032_5() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -23473,10 +25855,9 @@ class Test_TC_I_2_2 : public TestCommandBridge { CHIP_ERROR TestThSendsIdentifyCommandToDutWithTheIdentifyTimeFieldSetTo0x0000StopIdentifying_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRIdentifyClusterIdentifyParams alloc] init]; @@ -23497,10 +25878,9 @@ class Test_TC_I_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsImmediatelyIdentifyTimeAttributeFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeIdentifyTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -23521,10 +25901,9 @@ class Test_TC_I_2_2 : public TestCommandBridge { CHIP_ERROR TestThWritesAValueOf0x000f15sToIdentifyTimeAttributeOfDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id identifyTimeArgument; @@ -23544,6 +25923,7 @@ class Test_TC_I_2_2 : public TestCommandBridge { CHIP_ERROR TestWait5000ms_9() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -23551,10 +25931,9 @@ class Test_TC_I_2_2 : public TestCommandBridge { CHIP_ERROR TestAfter5SecondsTheThReadsIdentifyTimeAttributeFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeIdentifyTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -23890,6 +26269,7 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR Test1WaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -23898,10 +26278,9 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTriggerEffectCommandToDutWithTheEffectIdentifierFieldSetTo0x00BlinkAndTheEffectVariantFieldSetTo0x00Default_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRIdentifyClusterTriggerEffectParams alloc] init]; @@ -23923,6 +26302,7 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestDutExecutesABlinkEffect_2() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -23933,10 +26313,9 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTriggerEffectCommandToDutWithTheEffectIdentifierFieldSetTo0x01BreatheAndTheEffectVariantFieldSetTo0x00Default_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRIdentifyClusterTriggerEffectParams alloc] init]; @@ -23958,6 +26337,7 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestDutExecutesABreatheEffect_4() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -23968,10 +26348,9 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTriggerEffectCommandToDutWithTheEffectIdentifierFieldSetTo0x02OkayAndTheEffectVariantFieldSetTo0x00Default_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRIdentifyClusterTriggerEffectParams alloc] init]; @@ -23993,6 +26372,7 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestDutExecutesAnOkayEffect_6() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -24003,10 +26383,9 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTriggerEffectCommandToDutWithTheEffectIdentifierFieldSetTo0x0bChannelChangeAndTheEffectVariantFieldSetTo0x00Default_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRIdentifyClusterTriggerEffectParams alloc] init]; @@ -24028,6 +26407,7 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestDutExecutesAChannelChangeEffect_8() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -24038,10 +26418,9 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTriggerEffectCommandToDutWithTheEffectIdentifierFieldSetTo0x01BreatheAndTheEffectVariantFieldSetTo0x00Default_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRIdentifyClusterTriggerEffectParams alloc] init]; @@ -24063,6 +26442,7 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestDutExecutesABreatheEffect_10() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -24073,10 +26453,9 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTriggerEffectCommandToDutWithTheEffectIdentifierFieldSetTo0xfeFinishEffectAndTheEffectVariantFieldSetTo0x00Default_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRIdentifyClusterTriggerEffectParams alloc] init]; @@ -24098,6 +26477,7 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestDutStopsTheBreatheEffectAfterTheCurrentEffectSequence_12() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -24108,10 +26488,9 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTriggerEffectCommandToDutWithTheEffectIdentifierFieldSetTo0x01BreatheAndTheEffectVariantFieldSetTo0x00Default_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRIdentifyClusterTriggerEffectParams alloc] init]; @@ -24133,6 +26512,7 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestDutExecutesABreatheEffect_14() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -24143,10 +26523,9 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTriggerEffectCommandToDutWithTheEffectIdentifierFieldSetTo0xffStopEffectAndTheEffectVariantFieldSetTo0x00Default_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRIdentifyClusterTriggerEffectParams alloc] init]; @@ -24168,6 +26547,7 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestDutStopsTheBreatheEffectAsSoonAsPossible_16() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -24178,10 +26558,9 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTriggerEffectCommandToDutWithTheEffectIdentifierFieldSetTo0x00BlinkAndTheEffectVariantFieldSetTo0x42Unknown_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRIdentifyClusterTriggerEffectParams alloc] init]; @@ -24203,6 +26582,7 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestCheckDutExecutesABlinkEffect_18() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -24213,10 +26593,9 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTriggerEffectCommandToDutWithTheEffectIdentifierFieldSetTo0xffStopEffectAndTheEffectVariantFieldSetTo0x00Default_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRIdentifyClusterTriggerEffectParams alloc] init]; @@ -24238,6 +26617,7 @@ class Test_TC_I_2_3 : public TestCommandBridge { CHIP_ERROR TestDutStopsAnyEffectThatMayBeStillRunningAsSoonAsPossible_20() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -24381,6 +26761,7 @@ class Test_TC_ILL_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -24388,9 +26769,11 @@ class Test_TC_ILL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -24412,9 +26795,11 @@ class Test_TC_ILL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -24436,9 +26821,11 @@ class Test_TC_ILL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -24464,9 +26851,11 @@ class Test_TC_ILL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeToleranceInAttributeList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -24485,9 +26874,11 @@ class Test_TC_ILL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeLightSensorTypeInAttributeList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -24506,9 +26897,11 @@ class Test_TC_ILL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -24530,9 +26923,11 @@ class Test_TC_ILL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -24686,6 +27081,7 @@ class Test_TC_ILL_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -24693,9 +27089,11 @@ class Test_TC_ILL_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsMinMeasuredValueAttributeFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -24718,9 +27116,11 @@ class Test_TC_ILL_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsMaxMeasuredValueAttributeFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -24743,9 +27143,11 @@ class Test_TC_ILL_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsMeasuredValueAttributeFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -24768,9 +27170,11 @@ class Test_TC_ILL_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsToleranceAttributeFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeToleranceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -24790,9 +27194,11 @@ class Test_TC_ILL_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsLightSensorTypeAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLightSensorTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -24972,6 +27378,7 @@ class Test_TC_ILL_2_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -24980,9 +27387,11 @@ class Test_TC_ILL_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsMinMeasuredValueAttributeFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -25007,9 +27416,11 @@ class Test_TC_ILL_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsMaxMeasuredValueAttributeFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -25033,6 +27444,7 @@ class Test_TC_ILL_2_2 : public TestCommandBridge { CHIP_ERROR TestCoverTheSensorOrDarkenTheRoom_3() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for Successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -25042,6 +27454,7 @@ class Test_TC_ILL_2_2 : public TestCommandBridge { CHIP_ERROR TestWait1s_4() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 1000UL; return WaitForMs("alpha", value); @@ -25049,9 +27462,11 @@ class Test_TC_ILL_2_2 : public TestCommandBridge { CHIP_ERROR TestAfterAFewSecondsThReadsMeasuredValueAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -25073,6 +27488,7 @@ class Test_TC_ILL_2_2 : public TestCommandBridge { CHIP_ERROR TestExposeTheSensorAgainToLight_6() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for Successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -25082,6 +27498,7 @@ class Test_TC_ILL_2_2 : public TestCommandBridge { CHIP_ERROR TestWait1s_7() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 1000UL; return WaitForMs("alpha", value); @@ -25089,9 +27506,11 @@ class Test_TC_ILL_2_2 : public TestCommandBridge { CHIP_ERROR TestAfterAFewSecondsThReadsMeasuredValueAttributeFromDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIlluminanceMeasurement * cluster = - [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIlluminanceMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -25365,6 +27784,7 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -25372,10 +27792,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -25397,10 +27816,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -25422,10 +27840,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenLvlsf00ooEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -25442,10 +27859,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenLvlsf01ltEnsureFeaturemapHasTheCorrectBitSet_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -25462,10 +27878,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenLvlsf02fqEnsureFeaturemapHasTheCorrectBitSet_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -25482,10 +27897,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -25511,10 +27925,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeStartUpCurrentLevelAndRemainingTimeInAttributeList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -25534,10 +27947,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeCurrentFrequencyMinFrequencyAndMinFrequencyInAttributeList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -25558,10 +27970,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMinLevelInAttributeList_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -25580,10 +27991,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMaxLevelInAttributeList_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -25602,10 +28012,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeOnOffTransitionTimeInAttributeList_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -25624,10 +28033,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeOnTransitionTimeInAttributeList_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -25646,10 +28054,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeOffTransitionTimeInAttributeList_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -25668,10 +28075,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeDefaultMoveRateInAttributeList_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -25690,10 +28096,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -25719,10 +28124,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentLVLSF02CommandInAcceptedCommandList_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -25741,10 +28145,9 @@ class Test_TC_LVL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -26063,6 +28466,7 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -26071,10 +28475,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentLevelAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26100,10 +28503,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheRemainingTimeAttribute_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRemainingTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26124,10 +28526,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheMinLevelAttribute_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26154,10 +28555,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheMinLevelAttribute_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26181,10 +28581,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheMaxLevelAttribute_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26212,10 +28611,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheMaxLevelAttribute_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26239,10 +28637,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestStep4b4cReadsTheCurrentLevelAttribute_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26265,10 +28662,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestStep4b4cReadsTheCurrentLevelAttribute_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26293,10 +28689,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentFrequencyAttribute_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentFrequencyWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26317,10 +28712,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheMinFrequencyAttribute_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinFrequencyWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26344,10 +28738,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheMaxFrequencyAttribute_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxFrequencyWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26370,10 +28763,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestStep7b7cReadsTheCurrentFrequencyAttribute_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentFrequencyWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26393,10 +28785,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheOnOffTransitionTimeAttribute_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffTransitionTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26416,10 +28807,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheOnLevelAttribute_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26442,10 +28832,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheOnLevelAttribute_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26470,10 +28859,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheOnTransitionTimeAttribute_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnTransitionTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26496,10 +28884,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheOffTransitionTimeAttribute_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOffTransitionTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26522,10 +28909,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheDefaultMoveRateAttribute_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeDefaultMoveRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26548,10 +28934,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheOptionsAttribute_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOptionsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26568,10 +28953,9 @@ class Test_TC_LVL_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheStartUpCurrentLevelAttribute_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeStartUpCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26892,6 +29276,7 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -26900,10 +29285,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheOnOffTransitionTimeAttributeFromTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffTransitionTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26926,10 +29310,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesTheOnOffTransitionTimeAttributeOnTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id onOffTransitionTimeArgument; @@ -26950,10 +29333,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheOnOffTransitionTimeAttributeFromTheDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffTransitionTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -26979,10 +29361,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheOnLevelAttributeFromTheDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -27008,10 +29389,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesTheOnLevelAttributeOnTheDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id onLevelArgument; @@ -27031,10 +29411,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheOnLevelAttributeFromTheDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -27063,10 +29442,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheOnTransitionTimeAttributeFromTheDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnTransitionTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -27092,10 +29470,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesTheOnTransitionTimeAttributeOnTheDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id onTransitionTimeArgument; @@ -27116,10 +29493,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheOnTransitionTimeAttributeFromTheDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnTransitionTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -27148,10 +29524,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheOffTransitionTimeAttributeFromTheDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOffTransitionTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -27177,10 +29552,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesTheOffTransitionTimeAttributeOnTheDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id offTransitionTimeArgument; @@ -27201,10 +29575,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheOffTransitionTimeAttributeFromTheDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOffTransitionTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -27233,10 +29606,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheDefaultMoveRateAttributeFromTheDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeDefaultMoveRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -27262,10 +29634,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesTheDefaultMoveRateAttributeOnTheDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id defaultMoveRateArgument; @@ -27286,10 +29657,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheDefaultMoveRateAttributeFromTheDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeDefaultMoveRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -27318,10 +29688,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheStartUpCurrentLevelAttributeFromTheDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeStartUpCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -27347,10 +29716,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesTheStartUpCurrentLevelAttributeOnTheDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id startUpCurrentLevelArgument; @@ -27371,10 +29739,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheStartUpCurrentLevelAttributeFromTheDut_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeStartUpCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -27402,10 +29769,9 @@ class Test_TC_LVL_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesBackDefaultValueOfOnOffTransitionTimeAttribute_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id onOffTransitionTimeArgument; @@ -27986,6 +30352,7 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -27993,8 +30360,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestPreconditionSendOnCommand_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -28010,8 +30378,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsTrueAfterOnCommand_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28032,10 +30401,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestPreconditionWriteDefaultValueOfOnOffTransitionTimeAttribute_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id onOffTransitionTimeArgument; @@ -28057,10 +30425,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -28079,8 +30446,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOffCommandToDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -28096,10 +30464,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveToLevelWithOnOffCommandToDutWithLevel50AndTransitionTime0Immediate_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelWithOnOffParams alloc] init]; @@ -28123,8 +30490,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOnOffAttributeOnOffClusterFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28145,10 +30513,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28170,8 +30537,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -28187,10 +30555,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveToLevelCommandToDutWithLevel50AndTransitionTime0Immediate_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; @@ -28215,10 +30582,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28241,10 +30607,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveToLevelCommandToTheDutWithLevel200AndTransitionTime30030SThisMeansTheLevelShouldIncreaseBy150UnitsIn30sSo5UnitsS_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; @@ -28268,6 +30633,7 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestWait10000ms_13() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -28275,10 +30641,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28300,6 +30665,7 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestWait10000ms_15() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -28307,10 +30673,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28332,6 +30697,7 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestWait10000ms_17() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -28339,10 +30705,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28364,6 +30729,7 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestWait5000ms_19() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -28371,10 +30737,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28396,10 +30761,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28421,10 +30785,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -28443,10 +30806,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionsAttribute_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOptionsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28467,8 +30829,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -28484,10 +30847,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveToLevelCommandToTheDutWith_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; @@ -28509,10 +30871,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28534,8 +30895,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOffCommandToDut_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -28551,10 +30913,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveToLevelCommandToTheDutWith_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; @@ -28576,10 +30937,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28601,10 +30961,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveToLevelCommandToTheDutWith_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; @@ -28626,10 +30985,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28651,10 +31009,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveToLevelCommandToTheDutWith_32() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; @@ -28676,10 +31033,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_33() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28701,10 +31057,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThWrites1ToTheOptionsAttribute_34() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -28723,10 +31078,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionsAttribute_35() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOptionsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28747,8 +31101,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_36() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -28764,10 +31119,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveToLevelCommandToTheDutWith_37() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; @@ -28789,10 +31143,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_38() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28814,8 +31167,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOffCommandToDut_39() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -28831,10 +31185,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveToLevelCommandToTheDutWith_40() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; @@ -28856,10 +31209,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_41() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28881,10 +31233,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveToLevelCommandToTheDutWith_42() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; @@ -28906,10 +31257,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_43() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -28931,10 +31281,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveToLevelCommandToTheDutWith_44() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; @@ -28956,10 +31305,9 @@ class Test_TC_LVL_3_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_45() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -29316,6 +31664,7 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -29323,8 +31672,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestPreconditionSendOnCommand_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -29340,8 +31690,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsTrueAfterOnCommand_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -29362,10 +31713,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestPreconditionWriteDefaultValueOfOnOffTransitionTimeAttribute_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id onOffTransitionTimeArgument; @@ -29387,10 +31737,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -29409,10 +31758,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheMaxLevelAttributeFromTheDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -29432,8 +31780,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOffCommandToDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -29449,10 +31798,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveWithOnOffCommandToDutWithMoveMode0x00UpAndRate10UnitsS_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveWithOnOffParams alloc] init]; @@ -29476,8 +31824,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOnOffAttributeOnOffClusterFromDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -29499,10 +31848,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -29526,6 +31874,7 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestWait5000ms_10() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -29533,10 +31882,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -29558,8 +31906,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -29575,10 +31924,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveToLevelCommandToDutWithLevel50AndTransitionTime0Immediate_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; @@ -29603,10 +31951,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -29628,10 +31975,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveCommandToTheDutWithMoveMode0x00UpAndRate5UnitsS_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveParams alloc] init]; @@ -29653,6 +31999,7 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestWait10s_16() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -29660,10 +32007,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -29685,6 +32031,7 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestWait10s_18() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -29692,10 +32039,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -29717,6 +32063,7 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestWait10s_20() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -29724,10 +32071,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -29749,6 +32095,7 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestWait19s_22() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 19000UL; return WaitForMs("alpha", value); @@ -29756,10 +32103,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -29781,8 +32127,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestPreconditionSendOffCommand_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -29798,8 +32145,9 @@ class Test_TC_LVL_4_1 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -30129,6 +32477,7 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -30136,8 +32485,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestPreconditionSendOnCommand_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -30153,8 +32503,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsTrueAfterOnCommand_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -30175,10 +32526,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestPreconditionWriteDefaultValueOfOnOffTransitionTimeAttribute_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id onOffTransitionTimeArgument; @@ -30200,10 +32550,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -30222,8 +32571,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOffCommandToDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -30239,10 +32589,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAStepWithOnOffCommandToDutWithStepMode0x00UpStepSize50AndTransitionTime0Immediate_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterStepWithOnOffParams alloc] init]; @@ -30267,8 +32616,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOnOffAttributeOnOffClusterFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -30289,8 +32639,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -30306,10 +32657,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveToLevelCommandToDutWithLevel50AndTransitionTime0Immediate_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; @@ -30334,10 +32684,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestReadsCurrentLevelAttributeFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -30359,10 +32708,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAStepCommandToTheDutWithStepMode0x00UpStepSize150AndTransitionTime300_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterStepParams alloc] init]; @@ -30387,6 +32735,7 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestWait10s_12() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -30394,10 +32743,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -30419,6 +32767,7 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestWait10s_14() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -30426,10 +32775,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -30451,6 +32799,7 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestWait10s_16() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -30458,10 +32807,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -30483,6 +32831,7 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestWait5000ms_18() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -30490,10 +32839,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -30515,10 +32863,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDutAfterDutHasFinishedTheTransition_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -30540,8 +32887,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestPreconditionSendOffCommand_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -30557,8 +32905,9 @@ class Test_TC_LVL_5_1 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -30840,6 +33189,7 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -30847,10 +33197,9 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestPreconditionWriteDefaultValueOfOnOffTransitionTimeAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id onOffTransitionTimeArgument; @@ -30872,10 +33221,9 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestThWrites0ToTheOptionsAttribute_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id optionsArgument; @@ -30894,8 +33242,9 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -30911,10 +33260,9 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveToLevelCommandToDutWithLevel50AndTransitionTime0Immediate_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; @@ -30939,10 +33287,9 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -30964,10 +33311,9 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveCommandToTheDutWithTheMoveModeFieldSetTo0x00MoveUpAndTheRateFieldSetTo0x055UnitsS_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveParams alloc] init]; @@ -30991,6 +33337,7 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestWait5000ms_7() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -30998,10 +33345,9 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestSendsStopCommandToDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterStopParams alloc] init]; @@ -31021,6 +33367,7 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestPhysicallyVerifyThatTheDeviceHasStoppedTransitioning_9() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -31030,10 +33377,9 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentLevelAttributeFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -31055,10 +33401,9 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAMoveCommandToTheDutWithTheMoveModeFieldSetTo0x00MoveUpAndTheRateFieldSetTo0x055UnitsS_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveParams alloc] init]; @@ -31082,6 +33427,7 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestWait5000ms_12() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -31089,10 +33435,9 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestThSendsAStopWithOnOffCommandToTheDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterStopWithOnOffParams alloc] init]; @@ -31112,6 +33457,7 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestPhysicallyVerifyThatTheDeviceHasStoppedTransitioning_14() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -31121,10 +33467,9 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestReadsCurrentLevelAttributeFromDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -31146,8 +33491,9 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestPreconditionSendOffCommand_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -31163,8 +33509,9 @@ class Test_TC_LVL_6_1 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -31297,6 +33644,7 @@ class Test_TC_LCFG_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -31304,9 +33652,11 @@ class Test_TC_LCFG_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -31328,9 +33678,11 @@ class Test_TC_LCFG_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -31352,9 +33704,11 @@ class Test_TC_LCFG_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAttributeListFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -31379,9 +33733,11 @@ class Test_TC_LCFG_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAcceptedCommandListFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -31403,9 +33759,11 @@ class Test_TC_LCFG_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsGeneratedCommandListFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLocalizationConfiguration * cluster = - [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLocalizationConfiguration alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -31581,6 +33939,7 @@ class Test_TC_LUNIT_1_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -31588,10 +33947,9 @@ class Test_TC_LUNIT_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -31613,10 +33971,9 @@ class Test_TC_LUNIT_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -31638,10 +33995,9 @@ class Test_TC_LUNIT_1_2 : public TestCommandBridge { CHIP_ERROR TestGivenLunitsf00tempEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -31658,10 +34014,9 @@ class Test_TC_LUNIT_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsAttributeListFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -31684,10 +34039,9 @@ class Test_TC_LUNIT_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentLUNITSF00AttributeInAttributeList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -31706,10 +34060,9 @@ class Test_TC_LUNIT_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsAcceptedCommandListFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -31731,10 +34084,9 @@ class Test_TC_LUNIT_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsGeneratedCommandListFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitLocalization * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitLocalization alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -31912,6 +34264,7 @@ class Test_TC_LTIME_1_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -31919,9 +34272,11 @@ class Test_TC_LTIME_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -31943,9 +34298,11 @@ class Test_TC_LTIME_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -31965,9 +34322,11 @@ class Test_TC_LTIME_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsAttributeListFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -31991,9 +34350,11 @@ class Test_TC_LTIME_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeActiveCalendarTypeInAttributeListFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -32012,9 +34373,11 @@ class Test_TC_LTIME_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeSupportedCalendarTypesInAttributeListFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -32033,9 +34396,11 @@ class Test_TC_LTIME_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsAcceptedCommandListFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -32057,9 +34422,11 @@ class Test_TC_LTIME_1_2 : public TestCommandBridge { CHIP_ERROR TestThReadsGeneratedCommandListFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTimeFormatLocalization * cluster = - [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTimeFormatLocalization alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -32193,6 +34560,7 @@ class Test_TC_LOWPOWER_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -32200,10 +34568,9 @@ class Test_TC_LOWPOWER_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -32225,10 +34592,9 @@ class Test_TC_LOWPOWER_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -32250,10 +34616,9 @@ class Test_TC_LOWPOWER_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -32280,10 +34645,9 @@ class Test_TC_LOWPOWER_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -32306,10 +34670,9 @@ class Test_TC_LOWPOWER_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -32480,6 +34843,7 @@ class Test_TC_KEYPADINPUT_1_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -32487,10 +34851,9 @@ class Test_TC_KEYPADINPUT_1_2 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -32512,10 +34875,9 @@ class Test_TC_KEYPADINPUT_1_2 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -32537,10 +34899,9 @@ class Test_TC_KEYPADINPUT_1_2 : public TestCommandBridge { CHIP_ERROR TestGivenKeypadinputsnvFeatureMapBitMaskIsSetOrNot_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -32557,10 +34918,9 @@ class Test_TC_KEYPADINPUT_1_2 : public TestCommandBridge { CHIP_ERROR TestGivenKeypadinputslkFeatureMapBitMaskIsSetOrNot_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -32577,10 +34937,9 @@ class Test_TC_KEYPADINPUT_1_2 : public TestCommandBridge { CHIP_ERROR TestGivenKeypadinputsnkFeatureMapBitMaskIsSetOrNot_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -32597,10 +34956,9 @@ class Test_TC_KEYPADINPUT_1_2 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -32623,10 +34981,9 @@ class Test_TC_KEYPADINPUT_1_2 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -32645,10 +35002,9 @@ class Test_TC_KEYPADINPUT_1_2 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -32816,6 +35172,7 @@ class Test_TC_APPLAUNCHER_1_3 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -32823,10 +35180,11 @@ class Test_TC_APPLAUNCHER_1_3 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -32848,10 +35206,11 @@ class Test_TC_APPLAUNCHER_1_3 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -32873,10 +35232,11 @@ class Test_TC_APPLAUNCHER_1_3 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -32898,10 +35258,11 @@ class Test_TC_APPLAUNCHER_1_3 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -32924,10 +35285,11 @@ class Test_TC_APPLAUNCHER_1_3 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeCatalogListInAttributeList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -32946,10 +35308,11 @@ class Test_TC_APPLAUNCHER_1_3 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeCurrentAppInAttributeList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -32968,10 +35331,11 @@ class Test_TC_APPLAUNCHER_1_3 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -32992,10 +35356,11 @@ class Test_TC_APPLAUNCHER_1_3 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -33163,6 +35528,7 @@ class Test_TC_MEDIAINPUT_1_4 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -33170,10 +35536,9 @@ class Test_TC_MEDIAINPUT_1_4 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -33195,10 +35560,9 @@ class Test_TC_MEDIAINPUT_1_4 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -33220,10 +35584,9 @@ class Test_TC_MEDIAINPUT_1_4 : public TestCommandBridge { CHIP_ERROR TestGivenMediainputsnuEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -33240,10 +35603,9 @@ class Test_TC_MEDIAINPUT_1_4 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -33266,10 +35628,9 @@ class Test_TC_MEDIAINPUT_1_4 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeInputListInAttributeList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -33288,10 +35649,9 @@ class Test_TC_MEDIAINPUT_1_4 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeCurrentInputInAttributeList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -33310,10 +35670,9 @@ class Test_TC_MEDIAINPUT_1_4 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -33335,10 +35694,9 @@ class Test_TC_MEDIAINPUT_1_4 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -33483,6 +35841,7 @@ class Test_TC_WAKEONLAN_1_5 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -33490,10 +35849,9 @@ class Test_TC_WAKEONLAN_1_5 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -33515,10 +35873,9 @@ class Test_TC_WAKEONLAN_1_5 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -33540,10 +35897,9 @@ class Test_TC_WAKEONLAN_1_5 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -33566,10 +35922,9 @@ class Test_TC_WAKEONLAN_1_5 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMACAddressInAttributeList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -33588,10 +35943,9 @@ class Test_TC_WAKEONLAN_1_5 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -33613,10 +35967,9 @@ class Test_TC_WAKEONLAN_1_5 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -33851,6 +36204,7 @@ class Test_TC_CHANNEL_1_6 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -33858,10 +36212,9 @@ class Test_TC_CHANNEL_1_6 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -33883,10 +36236,9 @@ class Test_TC_CHANNEL_1_6 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -33908,10 +36260,9 @@ class Test_TC_CHANNEL_1_6 : public TestCommandBridge { CHIP_ERROR TestGivenChannelsclEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -33928,10 +36279,9 @@ class Test_TC_CHANNEL_1_6 : public TestCommandBridge { CHIP_ERROR TestGivenChannelsliEnsureFeaturemapHasTheCorrectBitSet_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -33948,10 +36298,9 @@ class Test_TC_CHANNEL_1_6 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -33974,10 +36323,9 @@ class Test_TC_CHANNEL_1_6 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeChannelListAttributeList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -33996,10 +36344,9 @@ class Test_TC_CHANNEL_1_6 : public TestCommandBridge { CHIP_ERROR TestReadingOptionalAttributeLineupInAttributeList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34018,10 +36365,9 @@ class Test_TC_CHANNEL_1_6 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeCurrentChannelAttributeList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34040,10 +36386,9 @@ class Test_TC_CHANNEL_1_6 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandChangeChannelInAcceptedCommandList_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34062,10 +36407,9 @@ class Test_TC_CHANNEL_1_6 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandChangeChannelByNumberInAcceptedCommandList_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34084,10 +36428,9 @@ class Test_TC_CHANNEL_1_6 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandSkipChannelInAcceptedCommandList_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34106,10 +36449,9 @@ class Test_TC_CHANNEL_1_6 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34131,10 +36473,9 @@ class Test_TC_CHANNEL_1_6 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34445,6 +36786,7 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -34452,10 +36794,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -34477,10 +36818,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -34502,10 +36842,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestGivenMediaplaybacksasEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -34522,10 +36861,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestGivenMediaplaybacksvsEnsureFeaturemapHasTheCorrectBitSet_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -34542,10 +36880,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34569,10 +36906,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeStartTimeInAttributeList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34591,10 +36927,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeDurationInAttributeList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34613,10 +36948,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeSampledPositionInAttributeList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34635,10 +36969,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributePlaybackSpeedInAttributeList_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34657,10 +36990,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeSeekRangeEndInAttributeList_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34679,10 +37011,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeSeekRangeStartInAttributeList_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34701,10 +37032,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34725,10 +37055,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandStartOverInAcceptedCommandList_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34747,10 +37076,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandPreviousInAcceptedCommandList_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34769,10 +37097,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandNextInAcceptedCommandList_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34791,10 +37118,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandRewindInAcceptedCommandList_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34813,10 +37139,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandFastForwardInAcceptedCommandList_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34835,10 +37160,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandSkipForwardInAcceptedCommandList_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34857,10 +37181,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandSkipBackwardInAcceptedCommandList_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34879,10 +37202,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandSeekInAcceptedCommandList_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -34901,10 +37223,9 @@ class Test_TC_MEDIAPLAYBACK_1_7 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -35035,6 +37356,7 @@ class Test_TC_AUDIOOUTPUT_1_8 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -35042,10 +37364,9 @@ class Test_TC_AUDIOOUTPUT_1_8 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -35067,10 +37388,9 @@ class Test_TC_AUDIOOUTPUT_1_8 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -35090,10 +37410,9 @@ class Test_TC_AUDIOOUTPUT_1_8 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -35118,10 +37437,9 @@ class Test_TC_AUDIOOUTPUT_1_8 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -35140,10 +37458,9 @@ class Test_TC_AUDIOOUTPUT_1_8 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -35288,6 +37605,7 @@ class Test_TC_TGTNAV_1_9 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -35295,10 +37613,9 @@ class Test_TC_TGTNAV_1_9 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -35320,10 +37637,9 @@ class Test_TC_TGTNAV_1_9 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -35345,10 +37661,9 @@ class Test_TC_TGTNAV_1_9 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -35372,10 +37687,9 @@ class Test_TC_TGTNAV_1_9 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeCurrentTargetInAttributeList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -35394,10 +37708,9 @@ class Test_TC_TGTNAV_1_9 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -35416,10 +37729,9 @@ class Test_TC_TGTNAV_1_9 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -35653,6 +37965,7 @@ class Test_TC_APBSC_1_10 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -35660,10 +37973,9 @@ class Test_TC_APBSC_1_10 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -35685,10 +37997,9 @@ class Test_TC_APBSC_1_10 : public TestCommandBridge { CHIP_ERROR TestReadFeatureMapAttributeFromTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -35710,10 +38021,9 @@ class Test_TC_APBSC_1_10 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -35741,10 +38051,9 @@ class Test_TC_APBSC_1_10 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeVendorNameInAttributeList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -35763,10 +38072,9 @@ class Test_TC_APBSC_1_10 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeVendorIDInAttributeList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -35785,10 +38093,9 @@ class Test_TC_APBSC_1_10 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeProductIDInAttributeList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -35807,10 +38114,9 @@ class Test_TC_APBSC_1_10 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -35832,10 +38138,9 @@ class Test_TC_APBSC_1_10 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -36037,6 +38342,7 @@ class Test_TC_CONTENTLAUNCHER_1_11 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -36044,10 +38350,9 @@ class Test_TC_CONTENTLAUNCHER_1_11 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -36069,10 +38374,9 @@ class Test_TC_CONTENTLAUNCHER_1_11 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -36094,10 +38398,9 @@ class Test_TC_CONTENTLAUNCHER_1_11 : public TestCommandBridge { CHIP_ERROR TestGivenContentlauncherscsEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -36114,10 +38417,9 @@ class Test_TC_CONTENTLAUNCHER_1_11 : public TestCommandBridge { CHIP_ERROR TestGivenContentlaunchersupEnsureFeaturemapHasTheCorrectBitSet_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -36134,10 +38436,9 @@ class Test_TC_CONTENTLAUNCHER_1_11 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -36160,10 +38461,9 @@ class Test_TC_CONTENTLAUNCHER_1_11 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeAcceptHeaderAttributeList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -36182,10 +38482,9 @@ class Test_TC_CONTENTLAUNCHER_1_11 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeSupportedStreamingProtocolsAttributeList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -36204,10 +38503,9 @@ class Test_TC_CONTENTLAUNCHER_1_11 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandLaunchContentInAcceptedCommandListAttribute_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -36226,10 +38524,9 @@ class Test_TC_CONTENTLAUNCHER_1_11 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalCommandLaunchURLInAcceptedCommandListAttribute_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -36248,10 +38545,9 @@ class Test_TC_CONTENTLAUNCHER_1_11 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -36382,6 +38678,7 @@ class Test_TC_ALOGIN_1_12 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -36389,10 +38686,9 @@ class Test_TC_ALOGIN_1_12 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -36414,10 +38710,9 @@ class Test_TC_ALOGIN_1_12 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -36439,10 +38734,9 @@ class Test_TC_ALOGIN_1_12 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -36465,10 +38759,9 @@ class Test_TC_ALOGIN_1_12 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -36489,10 +38782,9 @@ class Test_TC_ALOGIN_1_12 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -36510,6 +38802,261 @@ class Test_TC_ALOGIN_1_12 : public TestCommandBridge { } }; +class Test_TC_ALOGIN_12_1 : public TestCommandBridge { +public: + // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced + Test_TC_ALOGIN_12_1() + : TestCommandBridge("Test_TC_ALOGIN_12_1") + , mTestIndex(0) + { + AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); + AddArgument("cluster", &mCluster); + AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("TempAccountIdentifier", &mTempAccountIdentifier); + AddArgument("catalogVendorId", 0, UINT16_MAX, &mCatalogVendorId); + AddArgument("applicationId", &mApplicationId); + AddArgument("timeout", 0, UINT16_MAX, &mTimeout); + } + // NOLINTEND(clang-analyzer-nullability.NullPassedToNonnull) + + ~Test_TC_ALOGIN_12_1() {} + + /////////// TestCommand Interface ///////// + void NextTest() override + { + CHIP_ERROR err = CHIP_NO_ERROR; + + if (0 == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Start: Test_TC_ALOGIN_12_1\n"); + } + + if (mTestCount == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Complete: Test_TC_ALOGIN_12_1\n"); + SetCommandExitStatus(CHIP_NO_ERROR); + return; + } + + Wait(); + + // Ensure we increment mTestIndex before we start running the relevant + // command. That way if we lose the timeslice after we send the message + // but before our function call returns, we won't end up with an + // incorrect mTestIndex value observed when we get the response. + switch (mTestIndex++) { + case 0: + ChipLogProgress(chipTool, " ***** Test Step 0 : Wait for the commissioned device to be retrieved\n"); + err = TestWaitForTheCommissionedDeviceToBeRetrieved_0(); + break; + case 1: + ChipLogProgress(chipTool, " ***** Test Step 1 : Launch an app with the provided a application ID\n"); + if (ShouldSkip("APPLAUNCHER.S.C00.Rsp")) { + NextTest(); + return; + } + err = TestLaunchAnAppWithTheProvidedAApplicationId_1(); + break; + case 2: + ChipLogProgress(chipTool, + " ***** Test Step 2 : TH sends a GetSetupPIN command to the DUT with test values provided by the product maker.\n"); + if (ShouldSkip("ALOGIN.S.C00.Rsp")) { + NextTest(); + return; + } + err = TestThSendsAGetSetupPINCommandToTheDutWithTestValuesProvidedByTheProductMaker_2(); + break; + case 3: + ChipLogProgress(chipTool, + " ***** Test Step 3 : TH sends a Login command to the DUT with test values provided by the product maker.\n"); + if (ShouldSkip("ALOGIN.S.C02.Rsp")) { + NextTest(); + return; + } + err = TestThSendsALoginCommandToTheDutWithTestValuesProvidedByTheProductMaker_3(); + break; + case 4: + ChipLogProgress(chipTool, + " ***** Test Step 4 : TH sends a Logout command to the DUT with test values provided by the product maker.\n"); + if (ShouldSkip("ALOGIN.S.C03.Rsp")) { + NextTest(); + return; + } + err = TestThSendsALogoutCommandToTheDutWithTestValuesProvidedByTheProductMaker_4(); + break; + } + + if (CHIP_NO_ERROR != err) { + ChipLogError(chipTool, " ***** Test Failure: %s\n", chip::ErrorStr(err)); + SetCommandExitStatus(err); + } + } + + void OnStatusUpdate(const chip::app::StatusIB & status) override + { + switch (mTestIndex - 1) { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 4: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + } + + // Go on to the next test. + ContinueOnChipMainThread(CHIP_NO_ERROR); + } + + chip::System::Clock::Timeout GetWaitDuration() const override + { + return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); + } + +private: + std::atomic_uint16_t mTestIndex; + const uint16_t mTestCount = 5; + + chip::Optional mNodeId; + chip::Optional mCluster; + chip::Optional mEndpoint; + chip::Optional mTempAccountIdentifier; + chip::Optional mCatalogVendorId; + chip::Optional mApplicationId; + chip::Optional mTimeout; + + CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() + { + + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee("alpha", value); + } + + CHIP_ERROR TestLaunchAnAppWithTheProvidedAApplicationId_1() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(3) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRApplicationLauncherClusterLaunchAppParams alloc] init]; + params.application = [[MTRApplicationLauncherClusterApplication alloc] init]; + ((MTRApplicationLauncherClusterApplication *) params.application).catalogVendorId = mCatalogVendorId.HasValue() + ? [NSNumber numberWithUnsignedShort:mCatalogVendorId.Value()] + : [NSNumber numberWithUnsignedShort:123U]; + ((MTRApplicationLauncherClusterApplication *) params.application).applicationId = mApplicationId.HasValue() + ? [[NSString alloc] initWithBytes:mApplicationId.Value().data() + length:mApplicationId.Value().size() + encoding:NSUTF8StringEncoding] + : @"exampleid"; + + params.data = [[NSData alloc] initWithBytes:"Hello World" length:11]; + [cluster + launchAppWithParams:params + completion:^(MTRApplicationLauncherClusterLauncherResponseParams * _Nullable values, NSError * _Nullable err) { + NSLog(@"Launch an app with the provided a application ID Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = values.status; + VerifyOrReturn(CheckValue("status", actualValue, 0U)); + } + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + NSString * _Nonnull setupPIN; + + CHIP_ERROR TestThSendsAGetSetupPINCommandToTheDutWithTestValuesProvidedByTheProductMaker_2() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRAccountLoginClusterGetSetupPINParams alloc] init]; + params.tempAccountIdentifier = mTempAccountIdentifier.HasValue() + ? [[NSString alloc] initWithBytes:mTempAccountIdentifier.Value().data() + length:mTempAccountIdentifier.Value().size() + encoding:NSUTF8StringEncoding] + : @"1111"; + [cluster + getSetupPINWithParams:params + completion:^(MTRAccountLoginClusterGetSetupPINResponseParams * _Nullable values, NSError * _Nullable err) { + NSLog(@"TH sends a GetSetupPIN command to the DUT with test values provided by the product maker. " + @"Error: %@", + err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + setupPIN = values.setupPIN; + } + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThSendsALoginCommandToTheDutWithTestValuesProvidedByTheProductMaker_3() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRAccountLoginClusterLoginParams alloc] init]; + params.tempAccountIdentifier = mTempAccountIdentifier.HasValue() + ? [[NSString alloc] initWithBytes:mTempAccountIdentifier.Value().data() + length:mTempAccountIdentifier.Value().size() + encoding:NSUTF8StringEncoding] + : @"1111"; + params.setupPIN = [setupPIN copy]; + [cluster + loginWithParams:params + completion:^(NSError * _Nullable err) { + NSLog(@"TH sends a Login command to the DUT with test values provided by the product maker. Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThSendsALogoutCommandToTheDutWithTestValuesProvidedByTheProductMaker_4() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster logoutWithCompletion:^(NSError * _Nullable err) { + NSLog(@"TH sends a Logout command to the DUT with test values provided by the product maker. Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } +}; + class Test_TC_LOWPOWER_2_1 : public TestCommandBridge { public: // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced @@ -36599,6 +39146,7 @@ class Test_TC_LOWPOWER_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -36606,10 +39154,9 @@ class Test_TC_LOWPOWER_2_1 : public TestCommandBridge { CHIP_ERROR TestThSendsSleepCommandToDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster sleepWithCompletion:^(NSError * _Nullable err) { @@ -36724,6 +39271,7 @@ class Test_TC_KEYPADINPUT_3_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -36731,10 +39279,9 @@ class Test_TC_KEYPADINPUT_3_2 : public TestCommandBridge { CHIP_ERROR TestThSendsCecSettingsKeys0x0AToDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRKeypadInputClusterSendKeyParams alloc] init]; @@ -36758,10 +39305,9 @@ class Test_TC_KEYPADINPUT_3_2 : public TestCommandBridge { CHIP_ERROR TestThSendsCecHomeKeys0x09ToDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRKeypadInputClusterSendKeyParams alloc] init]; @@ -36961,6 +39507,7 @@ class Test_TC_KEYPADINPUT_3_3 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -36968,10 +39515,9 @@ class Test_TC_KEYPADINPUT_3_3 : public TestCommandBridge { CHIP_ERROR TestSendNumbers1_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRKeypadInputClusterSendKeyParams alloc] init]; @@ -36995,10 +39541,9 @@ class Test_TC_KEYPADINPUT_3_3 : public TestCommandBridge { CHIP_ERROR TestSendNumbers2_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRKeypadInputClusterSendKeyParams alloc] init]; @@ -37022,10 +39567,9 @@ class Test_TC_KEYPADINPUT_3_3 : public TestCommandBridge { CHIP_ERROR TestSendNumbers3_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRKeypadInputClusterSendKeyParams alloc] init]; @@ -37049,10 +39593,9 @@ class Test_TC_KEYPADINPUT_3_3 : public TestCommandBridge { CHIP_ERROR TestSendNumbers4_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRKeypadInputClusterSendKeyParams alloc] init]; @@ -37076,10 +39619,9 @@ class Test_TC_KEYPADINPUT_3_3 : public TestCommandBridge { CHIP_ERROR TestSendNumbers5_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRKeypadInputClusterSendKeyParams alloc] init]; @@ -37103,10 +39645,9 @@ class Test_TC_KEYPADINPUT_3_3 : public TestCommandBridge { CHIP_ERROR TestSendNumbers6_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRKeypadInputClusterSendKeyParams alloc] init]; @@ -37130,10 +39671,9 @@ class Test_TC_KEYPADINPUT_3_3 : public TestCommandBridge { CHIP_ERROR TestSendNumbers7_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRKeypadInputClusterSendKeyParams alloc] init]; @@ -37157,10 +39697,9 @@ class Test_TC_KEYPADINPUT_3_3 : public TestCommandBridge { CHIP_ERROR TestSendNumbers8_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRKeypadInputClusterSendKeyParams alloc] init]; @@ -37184,10 +39723,9 @@ class Test_TC_KEYPADINPUT_3_3 : public TestCommandBridge { CHIP_ERROR TestSendNumbers9_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRKeypadInputClusterSendKeyParams alloc] init]; @@ -37301,6 +39839,7 @@ class Test_TC_APPLAUNCHER_3_5 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -37309,10 +39848,11 @@ class Test_TC_APPLAUNCHER_3_5 : public TestCommandBridge { CHIP_ERROR TestThReadsCatalogListAttributeFromTheDutAndWhereEachEntryInTheListIsACsaIssuedVendorIdOfTypeUnsigned16BitIntegerRangingBetween065536ForTheCatalog_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCatalogListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -37421,6 +39961,7 @@ class Test_TC_APPLAUNCHER_3_6 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -37429,10 +39970,11 @@ class Test_TC_APPLAUNCHER_3_6 : public TestCommandBridge { CHIP_ERROR TestThReadsCurrentAppAttributeFromTheDutAndVerifyTheInFocusApplicationAttributesWhichShouldIncludeTheDisplayApplicationIDtypeuint16CatalogVendorIDtypestringOrNullIfThereIsNoCurrentInFocusApplication_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentAppWithCompletion:^( @@ -37543,6 +40085,7 @@ class Test_TC_MEDIAINPUT_3_10 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -37551,10 +40094,9 @@ class Test_TC_MEDIAINPUT_3_10 : public TestCommandBridge { CHIP_ERROR TestThReadsTheInputListAttributeFromTheDutToShowListOfInputsAvailableAndVerifyListOfAvailableInputsSupportedByTheDeviceIsProvidedWhereEachEntryInTheListContainsAnIndextypeuint8InputTypeInputTypeEnumsNameTypeStringsAndDescriptionTypeString_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInputListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -37686,6 +40228,7 @@ class Test_TC_MEDIAINPUT_3_11 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -37694,10 +40237,9 @@ class Test_TC_MEDIAINPUT_3_11 : public TestCommandBridge { CHIP_ERROR TestThReadsTheInputListAttributeFromTheDutToShowListOfInputsAvailableAndVerifyListOfAvailableInputsSupportedByTheDeviceIsProvidedWhereEachEntryInTheListContainsAnIndextypeuint8InputTypeInputTypeEnumsNameTypeStringsAndDescriptionTypeString_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInputListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -37716,10 +40258,9 @@ class Test_TC_MEDIAINPUT_3_11 : public TestCommandBridge { CHIP_ERROR TestSelectInputCommand_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRMediaInputClusterSelectInputParams alloc] init]; @@ -37738,10 +40279,9 @@ class Test_TC_MEDIAINPUT_3_11 : public TestCommandBridge { CHIP_ERROR TestReadCurrentInputList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentInputWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -37875,6 +40415,7 @@ class Test_TC_MEDIAINPUT_3_12 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -37883,10 +40424,9 @@ class Test_TC_MEDIAINPUT_3_12 : public TestCommandBridge { CHIP_ERROR TestThReadsTheInputListAttributeFromTheDutToShowListOfInputsAvailableAndVerifyListOfAvailableInputsSupportedByTheDeviceIsProvidedWhereEachEntryInTheListContainsAnIndextypeuint8InputTypeInputTypeEnumsNameTypeStringsAndDescriptionTypeString_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInputListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -37905,10 +40445,9 @@ class Test_TC_MEDIAINPUT_3_12 : public TestCommandBridge { CHIP_ERROR TestShowInputStatusCommand_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster showInputStatusWithCompletion:^(NSError * _Nullable err) { @@ -37924,10 +40463,9 @@ class Test_TC_MEDIAINPUT_3_12 : public TestCommandBridge { CHIP_ERROR TestHideInputStatusCommand_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster hideInputStatusWithCompletion:^(NSError * _Nullable err) { @@ -38055,6 +40593,7 @@ class Test_TC_MEDIAINPUT_3_13 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -38062,10 +40601,9 @@ class Test_TC_MEDIAINPUT_3_13 : public TestCommandBridge { CHIP_ERROR TestThReadsTheInputListAttributeFromTheDutToShowListOfInputsAvailable_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInputListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -38081,10 +40619,9 @@ class Test_TC_MEDIAINPUT_3_13 : public TestCommandBridge { CHIP_ERROR TestRenameInputCommand_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRMediaInputClusterRenameInputParams alloc] init]; @@ -38104,6 +40641,7 @@ class Test_TC_MEDIAINPUT_3_13 : public TestCommandBridge { CHIP_ERROR TestThReadsTheInputListAttributeFromTheDutToShowListOfInputsAvailable_3() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -38112,6 +40650,172 @@ class Test_TC_MEDIAINPUT_3_13 : public TestCommandBridge { } }; +class Test_TC_WAKEONLAN_4_1 : public TestCommandBridge { +public: + // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced + Test_TC_WAKEONLAN_4_1() + : TestCommandBridge("Test_TC_WAKEONLAN_4_1") + , mTestIndex(0) + { + AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); + AddArgument("cluster", &mCluster); + AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("timeout", 0, UINT16_MAX, &mTimeout); + } + // NOLINTEND(clang-analyzer-nullability.NullPassedToNonnull) + + ~Test_TC_WAKEONLAN_4_1() {} + + /////////// TestCommand Interface ///////// + void NextTest() override + { + CHIP_ERROR err = CHIP_NO_ERROR; + + if (0 == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Start: Test_TC_WAKEONLAN_4_1\n"); + } + + if (mTestCount == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Complete: Test_TC_WAKEONLAN_4_1\n"); + SetCommandExitStatus(CHIP_NO_ERROR); + return; + } + + Wait(); + + // Ensure we increment mTestIndex before we start running the relevant + // command. That way if we lose the timeslice after we send the message + // but before our function call returns, we won't end up with an + // incorrect mTestIndex value observed when we get the response. + switch (mTestIndex++) { + case 0: + ChipLogProgress(chipTool, " ***** Test Step 0 : Wait for the commissioned device to be retrieved\n"); + err = TestWaitForTheCommissionedDeviceToBeRetrieved_0(); + break; + case 1: + ChipLogProgress(chipTool, " ***** Test Step 1 : TH reads the MACAddress attribute from the DUT\n"); + if (ShouldSkip("WAKEONLAN.S.A0000")) { + NextTest(); + return; + } + err = TestThReadsTheMACAddressAttributeFromTheDut_1(); + break; + case 2: + ChipLogProgress(chipTool, " ***** Test Step 2 : TH sends a Sleep command to DUT\n"); + if (ShouldSkip("LOWPOWER.S.C00.Rsp")) { + NextTest(); + return; + } + err = TestThSendsASleepCommandToDut_2(); + break; + case 3: + ChipLogProgress( + chipTool, " ***** Test Step 3 : TH sends a Wake-On LAN magic packet containing the MAC address from step 1\n"); + if (ShouldSkip("PICS_USER_PROMPT")) { + NextTest(); + return; + } + err = TestThSendsAWakeOnLanMagicPacketContainingTheMacAddressFromStep1_3(); + break; + } + + if (CHIP_NO_ERROR != err) { + ChipLogError(chipTool, " ***** Test Failure: %s\n", chip::ErrorStr(err)); + SetCommandExitStatus(err); + } + } + + void OnStatusUpdate(const chip::app::StatusIB & status) override + { + switch (mTestIndex - 1) { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + } + + // Go on to the next test. + ContinueOnChipMainThread(CHIP_NO_ERROR); + } + + chip::System::Clock::Timeout GetWaitDuration() const override + { + return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); + } + +private: + std::atomic_uint16_t mTestIndex; + const uint16_t mTestCount = 4; + + chip::Optional mNodeId; + chip::Optional mCluster; + chip::Optional mEndpoint; + chip::Optional mTimeout; + + CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() + { + + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee("alpha", value); + } + + CHIP_ERROR TestThReadsTheMACAddressAttributeFromTheDut_1() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeMACAddressWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads the MACAddress attribute from the DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintMinLength("MACAddress", value, 12)); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThSendsASleepCommandToDut_2() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster sleepWithCompletion:^(NSError * _Nullable err) { + NSLog(@"TH sends a Sleep command to DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThSendsAWakeOnLanMagicPacketContainingTheMacAddressFromStep1_3() + { + + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; + value.message = chip::Span("Please enter 'y' after successgarbage: not in length on purpose", 30); + value.expectedValue.Emplace(); + value.expectedValue.Value() = chip::Span("ygarbage: not in length on purpose", 1); + return UserPrompt("alpha", value); + } +}; + class Test_TC_CHANNEL_5_1 : public TestCommandBridge { public: // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced @@ -38205,6 +40909,7 @@ class Test_TC_CHANNEL_5_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -38213,10 +40918,9 @@ class Test_TC_CHANNEL_5_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheChannelListAttributeFromTheDutToShowListOfInputsAvailableAndVerifyThatTheResponseContainsAListOfTheKnownTvChannelsEachListElementShouldConsistOfTheFollowingMajorNumberUnsigned16BitIntegerMandatoryMinorNumberUnsigned16BitIntegerMandatoryNameStringOptionalCallSignStringOptionalAffiliateCallSignStringOptional_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeChannelListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -38361,6 +41065,7 @@ class Test_TC_CHANNEL_5_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -38368,10 +41073,9 @@ class Test_TC_CHANNEL_5_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheChannelListAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeChannelListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -38388,10 +41092,9 @@ class Test_TC_CHANNEL_5_2 : public TestCommandBridge { CHIP_ERROR TestThSendsAChangeChannelByNumberCommand_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRChannelClusterChangeChannelByNumberParams alloc] init]; @@ -38413,6 +41116,7 @@ class Test_TC_CHANNEL_5_2 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheChannelHasChangedOnTheDevice_3() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' if channel has changed on the devicegarbage: not in length on purpose", 53); @@ -38423,10 +41127,9 @@ class Test_TC_CHANNEL_5_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentChannelAttribute_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -38597,6 +41300,7 @@ class Test_TC_CHANNEL_5_3 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -38605,10 +41309,9 @@ class Test_TC_CHANNEL_5_3 : public TestCommandBridge { CHIP_ERROR TestThReadsTheLineupAttributeFromTheDutToShowListOfInputsAvailableAndVerifyThatTheResponseContainsALineupInfoObject_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLineupWithCompletion:^(MTRChannelClusterLineupInfo * _Nullable value, NSError * _Nullable err) { @@ -38626,10 +41329,9 @@ class Test_TC_CHANNEL_5_3 : public TestCommandBridge { CHIP_ERROR TestReadsTheChannelListAttributeFromTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeChannelListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -38646,10 +41348,9 @@ class Test_TC_CHANNEL_5_3 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentChannelAttributeFromTheDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -38671,10 +41372,9 @@ class Test_TC_CHANNEL_5_3 : public TestCommandBridge { CHIP_ERROR TestSendsASkipChannelCommandToTheDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRChannelClusterSkipChannelParams alloc] init]; @@ -38693,6 +41393,7 @@ class Test_TC_CHANNEL_5_3 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheChannelHasChangedOnTheDevice_5() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' if channel has changed on the devicegarbage: not in length on purpose", 53); @@ -38703,10 +41404,9 @@ class Test_TC_CHANNEL_5_3 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentChannelAttributeFromTheDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -38931,6 +41631,7 @@ class Test_TC_MEDIAPLAYBACK_6_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -38938,10 +41639,9 @@ class Test_TC_MEDIAPLAYBACK_6_1 : public TestCommandBridge { CHIP_ERROR TestPreconditionMediaContentInAPausedStateAtTheBeginningOfTheContent_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster pauseWithCompletion:^(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable values, NSError * _Nullable err) { @@ -38962,10 +41662,9 @@ class Test_TC_MEDIAPLAYBACK_6_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentStateAttribute_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -38986,10 +41685,9 @@ class Test_TC_MEDIAPLAYBACK_6_1 : public TestCommandBridge { CHIP_ERROR TestSendsAPlayCommand_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster playWithCompletion:^(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable values, NSError * _Nullable err) { @@ -39010,6 +41708,7 @@ class Test_TC_MEDIAPLAYBACK_6_1 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheMediaStateIsPlaying_4() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' if media state is playinggarbage: not in length on purpose", 42); value.expectedValue.Emplace(); @@ -39019,10 +41718,9 @@ class Test_TC_MEDIAPLAYBACK_6_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentStateAttribute_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -39043,10 +41741,9 @@ class Test_TC_MEDIAPLAYBACK_6_1 : public TestCommandBridge { CHIP_ERROR TestSendsAPauseCommand_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster pauseWithCompletion:^(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable values, NSError * _Nullable err) { @@ -39067,6 +41764,7 @@ class Test_TC_MEDIAPLAYBACK_6_1 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheMediaIsPaused_7() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' if media state is pausedgarbage: not in length on purpose", 41); value.expectedValue.Emplace(); @@ -39076,10 +41774,9 @@ class Test_TC_MEDIAPLAYBACK_6_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentStateAttribute_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -39100,10 +41797,9 @@ class Test_TC_MEDIAPLAYBACK_6_1 : public TestCommandBridge { CHIP_ERROR TestSendsAStopCommand_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster stopPlaybackWithCompletion:^( @@ -39125,6 +41821,7 @@ class Test_TC_MEDIAPLAYBACK_6_1 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheMediaIsStoped_10() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' if media state is stopedgarbage: not in length on purpose", 41); value.expectedValue.Emplace(); @@ -39134,10 +41831,9 @@ class Test_TC_MEDIAPLAYBACK_6_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentStateAttribute_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -39423,6 +42119,7 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -39430,10 +42127,9 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestPreconditionMediaContentInAPausedStateAtTheBeginningOfTheContent_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster pauseWithCompletion:^(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable values, NSError * _Nullable err) { @@ -39454,10 +42150,9 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentStateAttributeFromTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -39478,10 +42173,9 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestSendsAPlayCommandToTheDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster playWithCompletion:^(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable values, NSError * _Nullable err) { @@ -39502,6 +42196,7 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheMediaStateIsPlaying_4() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' if media state is playinggarbage: not in length on purpose", 42); value.expectedValue.Emplace(); @@ -39511,10 +42206,9 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentStateAttribute_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -39535,10 +42229,9 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestSendsAStartOverCommandToTheDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -39560,6 +42253,7 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheMediaIsStartedOver_7() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' if media is started overgarbage: not in length on purpose", 41); value.expectedValue.Emplace(); @@ -39569,10 +42263,9 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestSendsANextCommandToTheDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster nextWithCompletion:^(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable values, NSError * _Nullable err) { @@ -39593,6 +42286,7 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheNextMediaItemInTheQueueHasBeenLoaded_9() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span( "Please enter 'y' if media item in the queue has been loadedgarbage: not in length on purpose", 59); @@ -39603,10 +42297,9 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestSendsAPreviousCommandToTheDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -39628,6 +42321,7 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestVerifyThatThePreviousMediaItemInTheQueueHasBeenLoaded_11() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span( "Please enter 'y' if previous media item in the queue has been loadedgarbage: not in length on purpose", 68); @@ -39638,10 +42332,9 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestSendsASkipForwardCommandToTheDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRMediaPlaybackClusterSkipForwardParams alloc] init]; @@ -39666,6 +42359,7 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheMediaHasSkippedForward10Seconds_13() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span( "Please enter 'y' if media has skipped forward 10 secondsgarbage: not in length on purpose", 56); @@ -39676,10 +42370,9 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheSampledPositionAttributeFromTheDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSampledPositionWithCompletion:^( @@ -39701,10 +42394,9 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestSendsASkipBackwardCommandToTheDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRMediaPlaybackClusterSkipBackwardParams alloc] init]; @@ -39729,6 +42421,7 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheMediaHasSkippedBackward10Seconds_16() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span( "Please enter 'y' if media has skipped backward 10 secondsgarbage: not in length on purpose", 57); @@ -39739,10 +42432,9 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheSampledPositionAttributeFromTheDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSampledPositionWithCompletion:^( @@ -39956,6 +42648,7 @@ class Test_TC_MEDIAPLAYBACK_6_3 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -39963,10 +42656,9 @@ class Test_TC_MEDIAPLAYBACK_6_3 : public TestCommandBridge { CHIP_ERROR TestPreconditionMediaContentInAPausedStateAtTheBeginningOfTheContent_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster pauseWithCompletion:^(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable values, NSError * _Nullable err) { @@ -39987,10 +42679,9 @@ class Test_TC_MEDIAPLAYBACK_6_3 : public TestCommandBridge { CHIP_ERROR TestSendsASeekCommand_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRMediaPlaybackClusterSeekParams alloc] init]; @@ -40014,6 +42705,7 @@ class Test_TC_MEDIAPLAYBACK_6_3 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheMediaHasMovedTo10SecondsFromTheStartingPoint_3() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span( "Please enter 'y' if media has moved to 10 seconds from the starting pointgarbage: not in length on purpose", 73); @@ -40024,10 +42716,9 @@ class Test_TC_MEDIAPLAYBACK_6_3 : public TestCommandBridge { CHIP_ERROR TestReadsTheSampledPositionAttribute_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSampledPositionWithCompletion:^( @@ -40049,6 +42740,7 @@ class Test_TC_MEDIAPLAYBACK_6_3 : public TestCommandBridge { CHIP_ERROR TestThReadsTheStartTimeAttributeFromTheDut_5() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -40058,6 +42750,7 @@ class Test_TC_MEDIAPLAYBACK_6_3 : public TestCommandBridge { CHIP_ERROR TestThReadsTheSeekRangeEndAttributeFromTheDut_6() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -40067,6 +42760,7 @@ class Test_TC_MEDIAPLAYBACK_6_3 : public TestCommandBridge { CHIP_ERROR TestThReadsTheSeekRangeStartAttributeFromTheDut_7() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -40076,6 +42770,7 @@ class Test_TC_MEDIAPLAYBACK_6_3 : public TestCommandBridge { CHIP_ERROR TestThReadsTheDurationAttributeFromTheDut_8() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -40085,10 +42780,9 @@ class Test_TC_MEDIAPLAYBACK_6_3 : public TestCommandBridge { CHIP_ERROR TestSendsASeekCommandPositionValueBeyondTheFurthestValidPosition_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRMediaPlaybackClusterSeekParams alloc] init]; @@ -40113,6 +42807,7 @@ class Test_TC_MEDIAPLAYBACK_6_3 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheMediaHasNotMoved_10() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' if media has not movedgarbage: not in length on purpose", 39); value.expectedValue.Emplace(); @@ -40444,6 +43139,7 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -40451,10 +43147,9 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestPreconditionMediaContentInAPausedStateAtTheBeginningOfTheContent_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster pauseWithCompletion:^(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable values, NSError * _Nullable err) { @@ -40475,10 +43170,9 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentStateAttributeFromTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -40499,10 +43193,9 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestReadsThePlaybackSpeedAttributeFromTheDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePlaybackSpeedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -40523,10 +43216,9 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestSendsAFastForwardCommand_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -40548,6 +43240,7 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheMediaStateIsPlaying_5() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' if media state is playinggarbage: not in length on purpose", 42); value.expectedValue.Emplace(); @@ -40557,10 +43250,9 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentStateAttribute_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -40581,10 +43273,9 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestReadsThePlaybackSpeedAttributeFromTheDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePlaybackSpeedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -40605,10 +43296,9 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestSendsAFastForwardCommand_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -40630,6 +43320,7 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheMediaPlaySpeedHasIncreased_9() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' if media play speed has increased.garbage: not in length on purpose", 51); @@ -40640,10 +43331,9 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestReadsThePlaybackSpeedAttributeFromTheDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePlaybackSpeedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -40664,10 +43354,9 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestSendsARewindCommandToTheDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster rewindWithCompletion:^(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable values, NSError * _Nullable err) { @@ -40688,6 +43377,7 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheMediaPlayHasReversedDirection_12() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' if media play has reversed directiongarbage: not in length on purpose", 53); @@ -40698,10 +43388,9 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentStateAttribute_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -40722,6 +43411,7 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestReadsThePlaybackSpeedAttributeFromTheDut_14() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' if PlaybackSpeed value is -1garbage: not in length on purpose", 45); @@ -40732,10 +43422,9 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestSendsARewindCommandToTheDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster rewindWithCompletion:^(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable values, NSError * _Nullable err) { @@ -40756,6 +43445,7 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheMediaPlaySpeedHasIncreasedInTheReverseDirection_16() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span( "Please enter 'y' if media play speed has increased in the reverse directiongarbage: not in length on purpose", 75); @@ -40766,6 +43456,7 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestReadsThePlaybackSpeedAttributeFromTheDut_17() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' if PlaybackSpeed value is -2garbage: not in length on purpose", 45); @@ -40776,10 +43467,9 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestSendsAPlayCommand_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster playWithCompletion:^(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable values, NSError * _Nullable err) { @@ -40800,6 +43490,7 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestVerifyThatTheMediaIsHasResumedPlayingForwardAtTheDefaultSpeed_19() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span( "Please enter 'y' if media is has resumed playing forward at the default speedgarbage: not in length on purpose", 77); @@ -40810,10 +43501,9 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestReadsThePlaybackSpeedAttributeFromTheDut_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePlaybackSpeedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -40834,6 +43524,7 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestSendsConsecutiveFastForwardCommands_21() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -40843,6 +43534,7 @@ class Test_TC_MEDIAPLAYBACK_6_4 : public TestCommandBridge { CHIP_ERROR TestSendsConsecutiveRewindCommands_22() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -40964,6 +43656,7 @@ class Test_TC_AUDIOOUTPUT_7_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -40971,10 +43664,9 @@ class Test_TC_AUDIOOUTPUT_7_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheOutputListAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOutputListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -40991,10 +43683,9 @@ class Test_TC_AUDIOOUTPUT_7_1 : public TestCommandBridge { CHIP_ERROR TestSendsASelectAudioOutputCommand_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAudioOutputClusterSelectOutputParams alloc] init]; @@ -41013,10 +43704,9 @@ class Test_TC_AUDIOOUTPUT_7_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentOutputAttribute_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentOutputWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -41151,6 +43841,7 @@ class Test_TC_AUDIOOUTPUT_7_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -41159,10 +43850,9 @@ class Test_TC_AUDIOOUTPUT_7_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheOutputListAttributeFromTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOutputListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -41183,10 +43873,9 @@ class Test_TC_AUDIOOUTPUT_7_2 : public TestCommandBridge { CHIP_ERROR TestSendsARenameOutputCommand_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAudioOutputClusterRenameOutputParams alloc] init]; @@ -41206,6 +43895,7 @@ class Test_TC_AUDIOOUTPUT_7_2 : public TestCommandBridge { CHIP_ERROR TestReadsTheOutputListAttributeFromTheDutVerifyThatTheOutputAtTheIndexProvidedInStep2HasTheNameCertTest_3() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -41338,6 +44028,7 @@ class Test_TC_TGTNAV_8_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -41345,10 +44036,9 @@ class Test_TC_TGTNAV_8_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentTargetAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentTargetWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -41369,10 +44059,9 @@ class Test_TC_TGTNAV_8_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheTargetListAttribute_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -41393,10 +44082,9 @@ class Test_TC_TGTNAV_8_1 : public TestCommandBridge { CHIP_ERROR TestSendsANavigateTargetCommand_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRTargetNavigatorClusterNavigateTargetParams alloc] init]; @@ -41417,10 +44105,9 @@ class Test_TC_TGTNAV_8_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheCurrentTargetAttribute_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentTargetWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -41606,6 +44293,7 @@ class Test_TC_APBSC_9_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -41613,10 +44301,9 @@ class Test_TC_APBSC_9_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheVendorNameAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeVendorNameWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -41634,10 +44321,9 @@ class Test_TC_APBSC_9_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheVendorIDAttribute_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeVendorIDWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -41654,10 +44340,9 @@ class Test_TC_APBSC_9_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheApplicationNameAttribute_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeApplicationNameWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -41675,10 +44360,9 @@ class Test_TC_APBSC_9_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheProductIDAttribute_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeProductIDWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -41698,10 +44382,9 @@ class Test_TC_APBSC_9_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheApplicationAttribute_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeApplicationWithCompletion:^( @@ -41719,10 +44402,9 @@ class Test_TC_APBSC_9_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheStatusAttribute_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -41741,10 +44423,9 @@ class Test_TC_APBSC_9_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheApplicationVersionAttribute_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeApplicationVersionWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -41762,10 +44443,9 @@ class Test_TC_APBSC_9_1 : public TestCommandBridge { CHIP_ERROR TestReadsTheAllowedVendorListAttribute_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAllowedVendorListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -41881,6 +44561,7 @@ class Test_TC_CONTENTLAUNCHER_10_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -41888,10 +44569,9 @@ class Test_TC_CONTENTLAUNCHER_10_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheAcceptHeaderAttributeFromTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptHeaderWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -41908,10 +44588,9 @@ class Test_TC_CONTENTLAUNCHER_10_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheSupportedStreamingProtocolsAttributeFromTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSupportedStreamingProtocolsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -42079,6 +44758,7 @@ class Test_TC_MOD_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -42086,10 +44766,9 @@ class Test_TC_MOD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionAttributeFromTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -42111,10 +44790,9 @@ class Test_TC_MOD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapAttributeFromTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -42136,10 +44814,9 @@ class Test_TC_MOD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapAttributeFromTheDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -42161,10 +44838,9 @@ class Test_TC_MOD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheAttributeListAttributeFromTheDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -42191,10 +44867,9 @@ class Test_TC_MOD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheOptionalAttributeStartUpModeInAttributeListFromTheDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -42213,10 +44888,9 @@ class Test_TC_MOD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheOptionalAttributeOnModeInAttributeListFromTheDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -42235,10 +44909,9 @@ class Test_TC_MOD_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -42257,10 +44930,9 @@ class Test_TC_MOD_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -42445,6 +45117,7 @@ class OTA_SuccessfulTransfer : public TestCommandBridge { CHIP_ERROR TestCreateOtaImage_0() { + chip::app::Clusters::SystemCommands::Commands::CreateOtaImage::Type value; value.otaImageFilePath = mOtaImageFilePath.HasValue() ? mOtaImageFilePath.Value() : chip::Span("/tmp/otaImage", 13); @@ -42457,6 +45130,7 @@ class OTA_SuccessfulTransfer : public TestCommandBridge { CHIP_ERROR TestStartTheProviderWithAnImage_1() { + chip::app::Clusters::SystemCommands::Commands::Start::Type value; value.registerKey.Emplace(); value.registerKey.Value() = chip::Span("chip-ota-provider-appgarbage: not in length on purpose", 21); @@ -42474,6 +45148,7 @@ class OTA_SuccessfulTransfer : public TestCommandBridge { CHIP_ERROR TestCommissionTheProviderFromAlpha_2() { + chip::app::Clusters::CommissionerCommands::Commands::PairWithCode::Type value; value.nodeId = mProviderNodeId.HasValue() ? mProviderNodeId.Value() : 12648430ULL; value.payload @@ -42483,6 +45158,7 @@ class OTA_SuccessfulTransfer : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedProviderToBeRetrievedForAlpha_3() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mProviderNodeId.HasValue() ? mProviderNodeId.Value() : 12648430ULL; return WaitForCommissionee("alpha", value); @@ -42490,10 +45166,9 @@ class OTA_SuccessfulTransfer : public TestCommandBridge { CHIP_ERROR TestInstallAclForQueryImage_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -42527,7 +45202,7 @@ class OTA_SuccessfulTransfer : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Install ACL for QueryImage Error: %@", err); @@ -42541,12 +45216,14 @@ class OTA_SuccessfulTransfer : public TestCommandBridge { CHIP_ERROR TestStopTheRequestor_5() { + chip::app::Clusters::SystemCommands::Commands::Stop::Type value; return Stop("alpha", value); } CHIP_ERROR TestStartTheRequestorWithAnOtaDownloadPath_6() { + chip::app::Clusters::SystemCommands::Commands::Start::Type value; value.otaDownloadPath.Emplace(); value.otaDownloadPath.Value() = mDownloadImageFilePath.HasValue() ? mDownloadImageFilePath.Value() @@ -42556,6 +45233,7 @@ class OTA_SuccessfulTransfer : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedRequestorToBeRetrievedForAlpha_7() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mRequestorNodeId.HasValue() ? mRequestorNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -42563,12 +45241,14 @@ class OTA_SuccessfulTransfer : public TestCommandBridge { CHIP_ERROR TestSendAnAnnounceOtaProviderCommandToTheRequestor_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOtaSoftwareUpdateRequestor * cluster = - [[MTRBaseClusterOtaSoftwareUpdateRequestor alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOTASoftwareUpdateRequestor alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - __auto_type * params = [[MTROtaSoftwareUpdateRequestorClusterAnnounceOtaProviderParams alloc] init]; + __auto_type * params = [[MTROTASoftwareUpdateRequestorClusterAnnounceOtaProviderParams alloc] init]; params.providerNodeId = mProviderNodeId.HasValue() ? [NSNumber numberWithUnsignedLongLong:mProviderNodeId.Value()] : [NSNumber numberWithUnsignedLongLong:12648430ULL]; params.vendorId = [NSNumber numberWithUnsignedShort:0U]; @@ -42589,6 +45269,7 @@ class OTA_SuccessfulTransfer : public TestCommandBridge { CHIP_ERROR TestWaitForTransferCompleteMessage_9() { + chip::app::Clusters::DelayCommands::Commands::WaitForMessage::Type value; value.registerKey.Emplace(); value.registerKey.Value() = chip::Span("defaultgarbage: not in length on purpose", 7); @@ -42598,6 +45279,7 @@ class OTA_SuccessfulTransfer : public TestCommandBridge { CHIP_ERROR TestCompareOriginalFileToDownloadedFile_10() { + chip::app::Clusters::SystemCommands::Commands::CompareFiles::Type value; value.file1 = mRawImageFilePath.HasValue() ? mRawImageFilePath.Value() : chip::Span("/tmp/rawImage", 13); value.file2 = mDownloadImageFilePath.HasValue() ? mDownloadImageFilePath.Value() @@ -42719,6 +45401,7 @@ class Test_TC_OCC_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -42726,10 +45409,9 @@ class Test_TC_OCC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -42751,10 +45433,9 @@ class Test_TC_OCC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -42776,10 +45457,9 @@ class Test_TC_OCC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -42805,10 +45485,9 @@ class Test_TC_OCC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -42830,10 +45509,9 @@ class Test_TC_OCC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -43068,6 +45746,7 @@ class Test_TC_OCC_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -43075,10 +45754,9 @@ class Test_TC_OCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsMandatoryAttributeConstrainsOccupancy_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOccupancyWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -43098,10 +45776,9 @@ class Test_TC_OCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsMandatoryAttributeConstrainsOccupancySensorType_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOccupancySensorTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -43121,10 +45798,9 @@ class Test_TC_OCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsMandatoryAttributeConstrainsOccupancySensorTypeBitmap_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOccupancySensorTypeBitmapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -43144,13 +45820,12 @@ class Test_TC_OCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsOptionalAttributePIROccupiedToUnoccupiedDelay_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - [cluster readAttributePirOccupiedToUnoccupiedDelayWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + [cluster readAttributePIROccupiedToUnoccupiedDelayWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { NSLog(@"Reads optional attribute: PIROccupiedToUnoccupiedDelay Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); @@ -43167,13 +45842,12 @@ class Test_TC_OCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsOptionalAttributeConstrainsPIRUnoccupiedToOccupiedDelay_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - [cluster readAttributePirUnoccupiedToOccupiedDelayWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + [cluster readAttributePIRUnoccupiedToOccupiedDelayWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { NSLog(@"Reads optional attribute constrains: PIRUnoccupiedToOccupiedDelay Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); @@ -43190,13 +45864,12 @@ class Test_TC_OCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsOptionalAttributeConstrainsPIRUnoccupiedToOccupiedThreshold_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - [cluster readAttributePirUnoccupiedToOccupiedThresholdWithCompletion:^( + [cluster readAttributePIRUnoccupiedToOccupiedThresholdWithCompletion:^( NSNumber * _Nullable value, NSError * _Nullable err) { NSLog(@"Reads optional attribute constrains: PIRUnoccupiedToOccupiedThreshold Error: %@", err); @@ -43214,10 +45887,9 @@ class Test_TC_OCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadOptionalAttributeUltrasonicOccupiedToUnoccupiedDelay_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -43240,10 +45912,9 @@ class Test_TC_OCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadAttributeUltrasonicUnoccupiedToOccupiedDelay_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -43266,10 +45937,9 @@ class Test_TC_OCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadAttributeUltrasonicUnoccupiedToOccupiedThreshold_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeUltrasonicUnoccupiedToOccupiedThresholdWithCompletion:^( @@ -43292,10 +45962,9 @@ class Test_TC_OCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsOptionalAttributeConstrainsPhysicalContactOccupiedToUnoccupiedDelay_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePhysicalContactOccupiedToUnoccupiedDelayWithCompletion:^( @@ -43318,10 +45987,9 @@ class Test_TC_OCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsOptionalAttributeConstrainsPhysicalContactUnoccupiedToOccupiedDelay_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePhysicalContactUnoccupiedToOccupiedDelayWithCompletion:^( @@ -43344,10 +46012,9 @@ class Test_TC_OCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsOptionalAttributeConstrainsPhysicalContactUnoccupiedToOccupiedThreshold_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOccupancySensing * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOccupancySensing alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePhysicalContactUnoccupiedToOccupiedThresholdWithCompletion:^( @@ -43520,6 +46187,7 @@ class Test_TC_OO_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -43527,8 +46195,9 @@ class Test_TC_OO_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -43550,8 +46219,9 @@ class Test_TC_OO_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -43573,8 +46243,9 @@ class Test_TC_OO_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenOosf00ltEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -43591,8 +46262,9 @@ class Test_TC_OO_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -43616,8 +46288,9 @@ class Test_TC_OO_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentOOSF00AttributeInAttributeList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -43639,8 +46312,9 @@ class Test_TC_OO_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -43661,8 +46335,9 @@ class Test_TC_OO_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentOOSF00CommandsInAcceptedCommandList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -43683,8 +46358,9 @@ class Test_TC_OO_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -43838,6 +46514,7 @@ class Test_TC_OO_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -43845,8 +46522,9 @@ class Test_TC_OO_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeOnOff_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -43863,8 +46541,9 @@ class Test_TC_OO_2_1 : public TestCommandBridge { CHIP_ERROR TestReadLtAttributeGlobalSceneControl_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGlobalSceneControlWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -43881,8 +46560,9 @@ class Test_TC_OO_2_1 : public TestCommandBridge { CHIP_ERROR TestReadLtAttributeOnTime_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -43902,8 +46582,9 @@ class Test_TC_OO_2_1 : public TestCommandBridge { CHIP_ERROR TestReadLtAttributeOffWaitTime_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOffWaitTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -43923,8 +46604,9 @@ class Test_TC_OO_2_1 : public TestCommandBridge { CHIP_ERROR TestReadLtAttributeStartUpOnOff_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeStartUpOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -44256,6 +46938,7 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -44263,8 +46946,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestSendOffCommand_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -44280,8 +46964,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -44302,8 +46987,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestSendOnCommand_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -44319,8 +47005,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsTrueAfterOnCommand_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -44341,8 +47028,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestSendOnCommand_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -44358,8 +47046,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsTrueAfterOnCommand_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -44380,8 +47069,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestSendOffCommand_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -44397,8 +47087,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -44419,8 +47110,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestSendOffCommand_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -44436,8 +47128,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -44458,8 +47151,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestSendToggleCommand_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster toggleWithCompletion:^(NSError * _Nullable err) { @@ -44475,6 +47169,7 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestWait1000ms_12() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 1000UL; return WaitForMs("alpha", value); @@ -44482,8 +47177,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsTrueAfterToggleCommand_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -44504,8 +47200,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestSendToggleCommand_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster toggleWithCompletion:^(NSError * _Nullable err) { @@ -44521,6 +47218,7 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestWait1000ms_15() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 1000UL; return WaitForMs("alpha", value); @@ -44528,8 +47226,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterToggleCommand_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -44550,6 +47249,7 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestOperateOnDeviceToSetOnOffAttributeManuallyToOn_17() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -44559,8 +47259,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsTrueAfterOnCommand_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -44581,6 +47282,7 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestOperateOnDeviceToSetOnOffAttributeManuallyToOff_19() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -44590,8 +47292,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -44612,8 +47315,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestResetOffCommand_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -44629,8 +47333,9 @@ class Test_TC_OO_2_2 : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -45034,6 +47739,7 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -45041,8 +47747,9 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestThSendsOnCommandToDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -45058,8 +47765,9 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestThWritesAValueOf0ToStartUpOnOffAttributeOfDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id startUpOnOffArgument; @@ -45078,12 +47786,14 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestRebootTargetDevice_3() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestRebootTargetDeviceDUT_4() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please reboot the DUT and enter 'y' after DUT startsgarbage: not in length on purpose", 52); @@ -45094,6 +47804,7 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_5() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -45101,8 +47812,9 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestThReadsTheOnOffAttributeFromTheDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -45123,8 +47835,9 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestThWritesAValueOf1ToStartUpOnOffAttributeOfDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id startUpOnOffArgument; @@ -45143,12 +47856,14 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestRebootTargetDevice_8() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestRebootTargetDeviceDUT_9() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please reboot the DUT and enter 'y' after DUT startsgarbage: not in length on purpose", 52); @@ -45159,6 +47874,7 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_10() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -45166,8 +47882,9 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestThReadsTheOnOffAttributeFromTheDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -45188,8 +47905,9 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestThWritesAValueOf2ToStartUpOnOffAttributeOfDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id startUpOnOffArgument; @@ -45208,12 +47926,14 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestRebootTargetDevice_13() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestRebootTargetDeviceDUT_14() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please reboot the DUT and enter 'y' after DUT startsgarbage: not in length on purpose", 52); @@ -45224,6 +47944,7 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_15() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -45231,8 +47952,9 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestThReadsTheOnOffAttributeFromTheDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -45253,12 +47975,14 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestRebootTargetDevice_17() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestRebootTargetDeviceDUT_18() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please reboot the DUT and enter 'y' after DUT startsgarbage: not in length on purpose", 52); @@ -45269,6 +47993,7 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_19() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -45276,8 +48001,9 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestThReadsTheOnOffAttributeFromTheDut_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -45298,8 +48024,9 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestThWritesNullToStartUpOnOffAttributeOfDut_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id startUpOnOffArgument; @@ -45318,12 +48045,14 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestRebootTargetDevice_22() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestRebootTargetDeviceDUT_23() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please reboot the DUT and enter 'y' after DUT startsgarbage: not in length on purpose", 52); @@ -45334,6 +48063,7 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_24() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -45341,8 +48071,9 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestThReadsTheOnOffAttributeFromTheDut_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -45363,8 +48094,9 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestThSendsOffCommandToDut_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -45380,12 +48112,14 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestRebootTargetDevice_27() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestRebootTargetDeviceDUT_28() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please reboot the DUT and enter 'y' after DUT startsgarbage: not in length on purpose", 52); @@ -45396,6 +48130,7 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_29() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -45403,8 +48138,9 @@ class Test_TC_OO_2_4 : public TestCommandBridge { CHIP_ERROR TestThReadsTheOnOffAttributeFromTheDut_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -45632,6 +48368,7 @@ class Test_TC_PS_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -45639,10 +48376,9 @@ class Test_TC_PS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -45664,10 +48400,9 @@ class Test_TC_PS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -45689,10 +48424,9 @@ class Test_TC_PS_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenPssf00wiredEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -45709,10 +48443,9 @@ class Test_TC_PS_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenPssf01batEnsureFeaturemapHasTheCorrectBitSet_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -45729,10 +48462,9 @@ class Test_TC_PS_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenPssf02rechgEnsureFeaturemapHasTheCorrectBitSet_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -45749,10 +48481,9 @@ class Test_TC_PS_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenPssf03replcEnsureFeaturemapHasTheCorrectBitSet_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -45769,10 +48500,9 @@ class Test_TC_PS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -45798,10 +48528,9 @@ class Test_TC_PS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentPSSF00WiredAttributeInAttributeList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -45820,10 +48549,9 @@ class Test_TC_PS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentPSSF01BatAttributeInAttributeList_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -45844,10 +48572,9 @@ class Test_TC_PS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentPSSF02RechgAttributeInAttributeList_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -45867,10 +48594,9 @@ class Test_TC_PS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentPSSF03ReplcAttributeInAttributeList_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -45890,10 +48616,9 @@ class Test_TC_PS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -45915,10 +48640,9 @@ class Test_TC_PS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -46364,6 +49088,7 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -46371,10 +49096,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsStatusAttributeFromServerDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46394,10 +49118,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsOrderAttributeFromServerDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOrderWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46417,10 +49140,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsDescriptionAttributeFromServerDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeDescriptionWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -46437,10 +49159,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsWiredAssessedInputVoltageAttribueFromServerDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWiredAssessedInputVoltageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46464,10 +49185,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsWiredAssessedInputFrequencyAttributeFromServerDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWiredAssessedInputFrequencyWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46491,10 +49211,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsWiredCurrentTypeAttributeFromServerDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWiredCurrentTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46514,10 +49233,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsWiredAssessedCurrentAttributeFromServerDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWiredAssessedCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46540,10 +49258,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsWiredNominalVoltageFromServerDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWiredNominalVoltageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46563,10 +49280,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsWiredMaximumCurrentFromServerDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWiredMaximumCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46586,10 +49302,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsWiredPresentFromServerDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWiredPresentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46606,10 +49321,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsActiveWiredFaultsFromServerDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeActiveWiredFaultsWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -46627,10 +49341,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatVoltageFromServerDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatVoltageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46653,10 +49366,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatPercentRemainingFromServerDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatPercentRemainingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46679,10 +49391,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatTimeRemainingFromServerDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatTimeRemainingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46705,10 +49416,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatChargeLevelFromServerDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatChargeLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46728,10 +49438,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatReplacementNeededFromServerDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatReplacementNeededWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46748,10 +49457,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatReplaceabilityFromServerDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatReplaceabilityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46771,10 +49479,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatPresentFromServerDut_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatPresentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46791,10 +49498,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsActiveBatFaultsFromServerDut_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeActiveBatFaultsWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -46812,10 +49518,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatReplacementDescriptionFromServerDut_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatReplacementDescriptionWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -46833,10 +49538,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatCommonDesignationFromServerDut_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatCommonDesignationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46856,10 +49560,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatANSIDesignationFromServerDut_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatANSIDesignationWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -46877,10 +49580,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatIECDesignationFromServerDut_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatIECDesignationWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -46898,10 +49600,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatApprovedChemistryFromServerDut_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatApprovedChemistryWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46921,10 +49622,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatCapacityFromServerDut_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatCapacityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46944,10 +49644,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatQuantityFromServerDut_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatQuantityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46967,10 +49666,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatChargeStateFromServerDut_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatChargeStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -46990,10 +49688,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatTimeToFullChargeFromServerDut_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatTimeToFullChargeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -47016,10 +49713,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatFunctionalWhileChargingFromServerDut_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatFunctionalWhileChargingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -47036,10 +49732,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsBatChargingCurrentFromServerDut_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBatChargingCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -47062,10 +49757,9 @@ class Test_TC_PS_2_1 : public TestCommandBridge { CHIP_ERROR TestTestHarnessClientReadsActiveBatChargeFaultsFromServerDut_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSource * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSource alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeActiveBatChargeFaultsWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -47275,6 +49969,7 @@ class Test_TC_PRS_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -47282,10 +49977,11 @@ class Test_TC_PRS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -47307,10 +50003,11 @@ class Test_TC_PRS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -47332,10 +50029,11 @@ class Test_TC_PRS_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenPrssf00extEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -47352,10 +50050,11 @@ class Test_TC_PRS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalMandatoryAttributeAttributeList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -47381,10 +50080,11 @@ class Test_TC_PRS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeScaledValueInAttributeList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -47403,10 +50103,11 @@ class Test_TC_PRS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMinScaledValueInAttributeList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -47425,10 +50126,11 @@ class Test_TC_PRS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMaxScaledValueInAttributeList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -47447,10 +50149,11 @@ class Test_TC_PRS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeScaleInAttributeList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -47469,10 +50172,11 @@ class Test_TC_PRS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeToleranceInAttributeList_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -47491,10 +50195,11 @@ class Test_TC_PRS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeScaledToleranceInAttributeList_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -47513,10 +50218,11 @@ class Test_TC_PRS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -47538,10 +50244,11 @@ class Test_TC_PRS_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -47739,6 +50446,7 @@ class Test_TC_PRS_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -47746,10 +50454,11 @@ class Test_TC_PRS_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeConstraintsMeasuredValue_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -47772,10 +50481,11 @@ class Test_TC_PRS_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeConstraintsMinMeasuredValue_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -47798,10 +50508,11 @@ class Test_TC_PRS_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeConstraintsMaxMeasuredValue_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -47824,10 +50535,11 @@ class Test_TC_PRS_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeTolerance_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeToleranceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -47847,10 +50559,11 @@ class Test_TC_PRS_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeScaledValue_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeScaledValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -47873,10 +50586,11 @@ class Test_TC_PRS_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMinScaledValue_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinScaledValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -47899,10 +50613,11 @@ class Test_TC_PRS_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMaxScaledValue_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxScaledValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -47925,10 +50640,11 @@ class Test_TC_PRS_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeScaledTolerance_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeScaledToleranceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -47948,10 +50664,11 @@ class Test_TC_PRS_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeScale_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeScaleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -48089,6 +50806,7 @@ class Test_TC_PRS_2_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -48097,10 +50815,11 @@ class Test_TC_PRS_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsFromTheDutTheMeasuredValueAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -48120,6 +50839,7 @@ class Test_TC_PRS_2_2 : public TestCommandBridge { CHIP_ERROR TestOperateOnDeviceToChangeThePressureSignificantly_2() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -48129,6 +50849,7 @@ class Test_TC_PRS_2_2 : public TestCommandBridge { CHIP_ERROR TestWait2s_3() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 2000UL; return WaitForMs("alpha", value); @@ -48136,10 +50857,11 @@ class Test_TC_PRS_2_2 : public TestCommandBridge { CHIP_ERROR TestAfterAFewSecondsThReadsFromTheDutTheMeasuredValueAttribute_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPressureMeasurement * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPressureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -48465,6 +51187,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -48472,9 +51195,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionAttributeFromTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -48496,9 +51221,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapAttributeFromTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -48520,9 +51247,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheAttributeListAttributeFromTheDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48552,9 +51281,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeMinConstPressureAttributeInAttributeListFromTheDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48573,9 +51304,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeMaxConstPressureAttributeInAttributeListFromTheDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48594,9 +51327,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeMinCompPressureAttributeInAttributeListFromTheDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48615,9 +51350,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeMaxCompPressureAttributeInAttributeListFromTheDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48636,9 +51373,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeMinConstSpeedAttributeInAttributeListFromTheDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48657,9 +51396,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeMaxConstSpeedAttributeInAttributeListFromTheDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48678,9 +51419,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeMinConstFlowAttributeInAttributeListFromTheDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48699,9 +51442,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeMaxConstFlowAttributeInAttributeListFromTheDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48720,9 +51465,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeMinConstTempAttributeInAttributeListFromTheDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48741,9 +51488,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeMaxConstTempAttributeInAttributeListFromTheDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48762,9 +51511,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributePumpStatusAttributeInAttributeListFromTheDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48783,9 +51534,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeSpeedAttributeInAttributeListFromTheDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48804,9 +51557,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeLifetimeRunningHoursAttributeInAttributeListFromTheDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48825,9 +51580,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributePowerAttributeInAttributeListFromTheDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48846,9 +51603,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeLifetimeEnergyConsumedAttributeInAttributeListFromTheDut_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48867,9 +51626,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeControlModeAttributeInAttributeListFromTheDut_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48888,9 +51649,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheAcceptedCommandListAttributeFromTheDut_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -48912,9 +51675,11 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheGeneratedCommandListAttributeFromTheDut_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -49266,6 +52031,7 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -49273,9 +52039,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeMaxPressure_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxPressureWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49298,9 +52066,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeMaxSpeed_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxSpeedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49323,9 +52093,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeMaxFlow_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxFlowWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49348,9 +52120,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMinConstPressure_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinConstPressureWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49373,9 +52147,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMaxConstPressure_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxConstPressureWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49398,9 +52174,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMinCompPressure_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinCompPressureWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49423,9 +52201,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMaxCompPressure_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxCompPressureWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49448,9 +52228,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMinConstSpeed_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinConstSpeedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49473,9 +52255,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMaxConstSpeed_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxConstSpeedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49498,9 +52282,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMinConstFlow_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinConstFlowWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49523,9 +52309,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMaxConstFlow_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxConstFlowWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49548,9 +52336,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMinConstTemp_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinConstTempWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49573,9 +52363,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeMaxConstTemp_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxConstTempWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49598,9 +52390,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributePumpStatus_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePumpStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49620,9 +52414,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadAttributeEffectiveOperationMode_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEffectiveOperationModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49642,9 +52438,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadAttributeEffectiveControlMode_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEffectiveControlModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49664,9 +52462,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadAttributeCapacity_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCapacityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49689,9 +52489,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeSpeed_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSpeedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49714,9 +52516,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeLifetimeRunningHours_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLifetimeRunningHoursWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49739,9 +52543,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributePower_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePowerWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49764,9 +52570,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeLifetimeEnergyConsumed_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLifetimeEnergyConsumedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49789,9 +52597,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadOptionalAttributeOperationMode_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49811,9 +52621,11 @@ class Test_TC_PCC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadOptionalAttributeControlMode_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeControlModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -49999,6 +52811,7 @@ class Test_TC_PCC_2_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -50006,9 +52819,11 @@ class Test_TC_PCC_2_2 : public TestCommandBridge { CHIP_ERROR TestThWrite0NormalToTheOperationModeAttributeToDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id operationModeArgument; @@ -50027,9 +52842,11 @@ class Test_TC_PCC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsFromTheDutTheEffectiveOperationModeAttribute_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEffectiveOperationModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -50050,9 +52867,11 @@ class Test_TC_PCC_2_2 : public TestCommandBridge { CHIP_ERROR TestThWrite1MinimumToTheOperationModeAttributeToDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id operationModeArgument; @@ -50071,9 +52890,11 @@ class Test_TC_PCC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsFromTheDutTheEffectiveOperationModeAttribute_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEffectiveOperationModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -50094,9 +52915,11 @@ class Test_TC_PCC_2_2 : public TestCommandBridge { CHIP_ERROR TestThWrite2MaximumToTheOperationModeAttributeToDutOneAtATime_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id operationModeArgument; @@ -50117,9 +52940,11 @@ class Test_TC_PCC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsFromTheDutTheEffectiveOperationModeAttribute_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEffectiveOperationModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -50140,9 +52965,11 @@ class Test_TC_PCC_2_2 : public TestCommandBridge { CHIP_ERROR TestThWrite3LocalToTheOperationModeAttributeToDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id operationModeArgument; @@ -50161,9 +52988,11 @@ class Test_TC_PCC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsFromTheDutTheEffectiveOperationModeAttribute_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEffectiveOperationModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -50415,6 +53244,7 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -50422,9 +53252,11 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { CHIP_ERROR TestWrite0ToTheOperationModeAttributeToDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id operationModeArgument; @@ -50443,9 +53275,11 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { CHIP_ERROR TestReadsTheAttributeEffectiveOperationMode_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEffectiveOperationModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -50466,9 +53300,11 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { CHIP_ERROR TestWrite0ToTheControlModeAttributeToDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id controlModeArgument; @@ -50487,9 +53323,11 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { CHIP_ERROR TestReadsTheAttributeEffectiveControlMode_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEffectiveControlModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -50510,9 +53348,11 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { CHIP_ERROR TestWrite1ToTheControlModeAttributeToDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id controlModeArgument; @@ -50531,9 +53371,11 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { CHIP_ERROR TestReadsTheAttributeEffectiveControlMode_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEffectiveControlModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -50554,9 +53396,11 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { CHIP_ERROR TestWrite2ToTheControlModeAttributeToDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id controlModeArgument; @@ -50575,9 +53419,11 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { CHIP_ERROR TestReadsTheAttributeEffectiveControlMode_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEffectiveControlModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -50598,9 +53444,11 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { CHIP_ERROR TestWrite3ToTheControlModeAttributeToDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id controlModeArgument; @@ -50619,9 +53467,11 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { CHIP_ERROR TestReadsTheAttributeEffectiveControlMode_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEffectiveControlModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -50642,9 +53492,11 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { CHIP_ERROR TestWrite5ToTheControlModeAttributeToDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id controlModeArgument; @@ -50663,9 +53515,11 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { CHIP_ERROR TestReadsTheAttributeEffectiveControlMode_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEffectiveControlModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -50686,9 +53540,11 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { CHIP_ERROR TestWrite7ToTheControlModeAttributeToDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id controlModeArgument; @@ -50707,9 +53563,11 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { CHIP_ERROR TestReadsTheAttributeEffectiveControlMode_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEffectiveControlModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -50939,6 +53797,7 @@ class Test_TC_PCC_2_4 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -50946,9 +53805,11 @@ class Test_TC_PCC_2_4 : public TestCommandBridge { CHIP_ERROR TestWrite1ToTheLifetimeRunningHoursAttributeToDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id lifetimeRunningHoursArgument; @@ -50967,9 +53828,11 @@ class Test_TC_PCC_2_4 : public TestCommandBridge { CHIP_ERROR TestReadsTheAttributeLifetimeRunningHours_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLifetimeRunningHoursWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -50991,9 +53854,11 @@ class Test_TC_PCC_2_4 : public TestCommandBridge { CHIP_ERROR TestWrite2ToTheLifetimeRunningHoursAttributeToDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id lifetimeRunningHoursArgument; @@ -51012,9 +53877,11 @@ class Test_TC_PCC_2_4 : public TestCommandBridge { CHIP_ERROR TestReadsTheAttributeLifetimeRunningHours_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLifetimeRunningHoursWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -51036,9 +53903,11 @@ class Test_TC_PCC_2_4 : public TestCommandBridge { CHIP_ERROR TestWrite3ToTheLifetimeRunningHoursAttributeToDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id lifetimeRunningHoursArgument; @@ -51057,9 +53926,11 @@ class Test_TC_PCC_2_4 : public TestCommandBridge { CHIP_ERROR TestReadsTheAttributeLifetimeRunningHours_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLifetimeRunningHoursWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -51081,9 +53952,11 @@ class Test_TC_PCC_2_4 : public TestCommandBridge { CHIP_ERROR TestWrite1ToTheLifetimeEnergyConsumedAttributeToDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id lifetimeEnergyConsumedArgument; @@ -51103,9 +53976,11 @@ class Test_TC_PCC_2_4 : public TestCommandBridge { CHIP_ERROR TestReadsTheAttributeLifetimeEnergyConsumed_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLifetimeEnergyConsumedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -51127,9 +54002,11 @@ class Test_TC_PCC_2_4 : public TestCommandBridge { CHIP_ERROR TestWrite2ToTheLifetimeEnergyConsumedAttributeToDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id lifetimeEnergyConsumedArgument; @@ -51149,9 +54026,11 @@ class Test_TC_PCC_2_4 : public TestCommandBridge { CHIP_ERROR TestReadsTheAttributeLifetimeEnergyConsumed_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLifetimeEnergyConsumedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -51173,9 +54052,11 @@ class Test_TC_PCC_2_4 : public TestCommandBridge { CHIP_ERROR TestWrite3ToTheLifetimeEnergyConsumedAttributeToDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id lifetimeEnergyConsumedArgument; @@ -51195,9 +54076,11 @@ class Test_TC_PCC_2_4 : public TestCommandBridge { CHIP_ERROR TestReadsTheAttributeLifetimeEnergyConsumed_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPumpConfigurationAndControl * cluster = - [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLifetimeEnergyConsumedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -51331,6 +54214,7 @@ class Test_TC_PSCFG_1_1 : public TestCommandBridge { CHIP_ERROR TestCommissionDutToTh_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -51338,9 +54222,11 @@ class Test_TC_PSCFG_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionAttributeFromTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -51362,9 +54248,11 @@ class Test_TC_PSCFG_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapAttributeFromTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -51386,9 +54274,11 @@ class Test_TC_PSCFG_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheAttributeListAttributeFromTheDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -51412,9 +54302,11 @@ class Test_TC_PSCFG_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheAcceptedCommandListAttributeFromTheDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -51436,9 +54328,11 @@ class Test_TC_PSCFG_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheGeneratedCommandListAttributeFromTheDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -51548,6 +54442,7 @@ class Test_TC_PSCFG_2_1 : public TestCommandBridge { CHIP_ERROR TestCommissionDutToTh_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -51555,9 +54450,11 @@ class Test_TC_PSCFG_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheSourcesAttributeFromTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterPowerSourceConfiguration * cluster = - [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterPowerSourceConfiguration alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSourcesWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -51697,6 +54594,7 @@ class Test_TC_RH_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -51704,9 +54602,11 @@ class Test_TC_RH_1_1 : public TestCommandBridge { CHIP_ERROR TestReadClusterRevisionAttributeFromTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -51728,9 +54628,11 @@ class Test_TC_RH_1_1 : public TestCommandBridge { CHIP_ERROR TestReadFeatureMapAttributeFromTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -51752,9 +54654,11 @@ class Test_TC_RH_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -51780,9 +54684,11 @@ class Test_TC_RH_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeToleranceInAttributeList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -51801,9 +54707,11 @@ class Test_TC_RH_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -51825,9 +54733,11 @@ class Test_TC_RH_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -51970,6 +54880,7 @@ class Test_TC_RH_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -51977,9 +54888,11 @@ class Test_TC_RH_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheMinMeasuredValueAttributeFromTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52002,9 +54915,11 @@ class Test_TC_RH_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheMaxMeasuredValueAttributeFromTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52027,9 +54942,11 @@ class Test_TC_RH_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheMeasuredValueAttributeFromTheDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52052,9 +54969,11 @@ class Test_TC_RH_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheToleranceAttributeFromTheDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterRelativeHumidityMeasurement * cluster = - [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterRelativeHumidityMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeToleranceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52261,6 +55180,7 @@ class Test_TC_SWTCH_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -52268,8 +55188,9 @@ class Test_TC_SWTCH_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52291,8 +55212,9 @@ class Test_TC_SWTCH_1_1 : public TestCommandBridge { CHIP_ERROR TestReadFeatureMapAttributeAndCheckValuesOfFlagsInThisFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52314,8 +55236,9 @@ class Test_TC_SWTCH_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenSwtchsf00lsEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52332,8 +55255,9 @@ class Test_TC_SWTCH_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenSwtchsf01msEnsureFeaturemapHasTheCorrectBitSet_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52350,8 +55274,9 @@ class Test_TC_SWTCH_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenSwtchsf02msrEnsureFeaturemapHasTheCorrectBitSet_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52368,8 +55293,9 @@ class Test_TC_SWTCH_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenSwtchsf03mslEnsureFeaturemapHasTheCorrectBitSet_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52386,8 +55312,9 @@ class Test_TC_SWTCH_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenSwtchsf04msmEnsureFeaturemapHasTheCorrectBitSet_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52404,8 +55331,9 @@ class Test_TC_SWTCH_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -52431,8 +55359,9 @@ class Test_TC_SWTCH_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -52457,8 +55386,9 @@ class Test_TC_SWTCH_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -52475,8 +55405,9 @@ class Test_TC_SWTCH_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSwitch * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSwitch alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -52621,6 +55552,7 @@ class Test_TC_TMP_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -52628,9 +55560,11 @@ class Test_TC_TMP_1_1 : public TestCommandBridge { CHIP_ERROR TestReadClusterRevisionAttributeFromTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52652,9 +55586,11 @@ class Test_TC_TMP_1_1 : public TestCommandBridge { CHIP_ERROR TestReadFeatureMapAttributeFromTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52676,9 +55612,11 @@ class Test_TC_TMP_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -52704,9 +55642,11 @@ class Test_TC_TMP_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeToleranceInAttributeList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -52725,9 +55665,11 @@ class Test_TC_TMP_1_1 : public TestCommandBridge { CHIP_ERROR TestReadAcceptedCommandListAttributeFromTheDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -52749,9 +55691,11 @@ class Test_TC_TMP_1_1 : public TestCommandBridge { CHIP_ERROR TestReadGeneratedCommandListAttributeFromTheDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -52894,6 +55838,7 @@ class Test_TC_TMP_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -52901,9 +55846,11 @@ class Test_TC_TMP_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeMinMeasuredValue_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52926,9 +55873,11 @@ class Test_TC_TMP_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeMaxMeasuredValue_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52951,9 +55900,11 @@ class Test_TC_TMP_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeMeasuredValue_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMeasuredValueWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -52976,9 +55927,11 @@ class Test_TC_TMP_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeTolerance_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTemperatureMeasurement * cluster = - [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTemperatureMeasurement alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeToleranceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -53303,6 +56256,7 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -53310,10 +56264,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -53335,10 +56288,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -53360,10 +56312,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenTstatsf00heatEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -53380,10 +56331,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenTstatsf01coolEnsureFeaturemapHasTheCorrectBitSet_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -53400,10 +56350,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenTstatsf02occEnsureFeaturemapHasTheCorrectBitSet_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -53420,10 +56369,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenTstatsf03schEnsureFeaturemapHasTheCorrectBitSet_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -53440,10 +56388,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenTstatsf04sbEnsureFeaturemapHasTheCorrectBitSet_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -53460,10 +56407,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenTstatsf05autoEnsureFeaturemapHasTheCorrectBitSet_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -53480,10 +56426,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -53509,10 +56454,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentTSTATSF00HEATAttributeInAttributeList_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -53531,10 +56475,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentTSTATSF01COOLAttributeInAttributeList_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -53553,10 +56496,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentTSTATSF02OCCAttributeInAttributeList_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -53575,10 +56517,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentTSTATSF00HEATTstatsf02occAttributeInAttributeList_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -53597,10 +56538,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentTSTATSF01COOLTstatsf02occAttributeInAttributeList_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -53619,10 +56559,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentTSTATSF05AUTOAttributeInAttributeList_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -53643,10 +56582,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentTSTATSF03SCHAttributeInAttributeList_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -53667,10 +56605,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentTSTATSF04SBAttributeInAttributeList_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -53691,10 +56628,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentTSTATSF04SBTstatsf02occAttributeInAttributeList_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -53715,10 +56651,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -53737,10 +56672,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadFeatureDependentTSTATSF03SCHCommandsInAcceptedCommandList_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -53762,10 +56696,9 @@ class Test_TC_TSTAT_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostat * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostat alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -53894,6 +56827,7 @@ class Test_TC_TSUIC_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -53901,9 +56835,11 @@ class Test_TC_TSUIC_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadClusterRevisionAttributeFromTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -53925,9 +56861,11 @@ class Test_TC_TSUIC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadFeatureMapAttributeFromTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -53949,9 +56887,11 @@ class Test_TC_TSUIC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -53977,9 +56917,11 @@ class Test_TC_TSUIC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -54001,9 +56943,11 @@ class Test_TC_TSUIC_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -54135,6 +57079,7 @@ class Test_TC_TSUIC_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -54142,9 +57087,11 @@ class Test_TC_TSUIC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeTemperatureDisplayMode_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTemperatureDisplayModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -54164,9 +57111,11 @@ class Test_TC_TSUIC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeKeypadLockout_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeKeypadLockoutWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -54186,9 +57135,11 @@ class Test_TC_TSUIC_2_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeScheduleProgrammingVisibility_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeScheduleProgrammingVisibilityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -54687,6 +57638,7 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -54694,9 +57646,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesAValueOf0ToTemperatureDisplayModeAttributeOfDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id temperatureDisplayModeArgument; @@ -54718,6 +57672,7 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestVerifyDeviceTemperatureDisplayedInc_2() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -54727,9 +57682,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheTemperatureDisplayModeAttributeOfDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTemperatureDisplayModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -54745,9 +57702,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesAValueOf1ToTemperatureDisplayModeAttributeOfDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id temperatureDisplayModeArgument; @@ -54769,6 +57728,7 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestVerifyDeviceTemperatureDisplayedInf_5() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -54778,9 +57738,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheTemperatureDisplayModeAttributeOfDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTemperatureDisplayModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -54801,9 +57763,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesAValueOfGreaterThan1ToTemperatureDisplayModeAttributeOfDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id temperatureDisplayModeArgument; @@ -54828,9 +57792,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheTemperatureDisplayModeAttributeOfDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTemperatureDisplayModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -54851,9 +57817,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesAValueOf0ToKeypadLockoutAttributeOfDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id keypadLockoutArgument; @@ -54872,6 +57840,7 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestVerifyAllDeviceFunctionalityAvailableToTheUser_10() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -54881,9 +57850,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheKeypadLockoutAttributeOfDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeKeypadLockoutWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -54904,9 +57875,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesAValueOf1ToKeypadLockoutAttributeOfDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id keypadLockoutArgument; @@ -54925,6 +57898,7 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestVerifyDeviceOperatesAtLevel1ReducedFunctionality_13() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -54934,9 +57908,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheKeypadLockoutAttributeOfDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeKeypadLockoutWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -54957,9 +57933,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesAValueOf2ToKeypadLockoutAttributeOfDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id keypadLockoutArgument; @@ -54978,6 +57956,7 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestVerifyDeviceOperatesAtLevel2ReducedFunctionality_16() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -54987,9 +57966,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheKeypadLockoutAttributeOfDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeKeypadLockoutWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -55010,9 +57991,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesAValueOf3ToKeypadLockoutAttributeOfDut_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id keypadLockoutArgument; @@ -55031,6 +58014,7 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestVerifyDeviceOperatesAtLevel3ReducedFunctionality_19() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -55040,9 +58024,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheKeypadLockoutAttributeOfDut_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeKeypadLockoutWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -55063,9 +58049,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesAValueOf4ToKeypadLockoutAttributeOfDut_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id keypadLockoutArgument; @@ -55084,6 +58072,7 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestVerifyDeviceOperatesAtLevel4ReducedFunctionality_22() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -55093,9 +58082,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheKeypadLockoutAttributeOfDut_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeKeypadLockoutWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -55116,9 +58107,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesAValueOf5ToKeypadLockoutAttributeOfDut_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id keypadLockoutArgument; @@ -55137,6 +58130,7 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestVerifyDeviceOperatesAtLeastFunctionalityLevel_25() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -55146,9 +58140,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheKeypadLockoutAttributeOfDut_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeKeypadLockoutWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -55169,9 +58165,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesAValueOfGreaterThan5ToKeypadLockoutAttributeOfDut_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id keypadLockoutArgument; @@ -55196,9 +58194,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheKeypadLockoutAttributeOfDut_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeKeypadLockoutWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -55219,9 +58219,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesAValueOf0ToScheduleProgrammingVisibilityAttributeOfDut_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id scheduleProgrammingVisibilityArgument; @@ -55242,6 +58244,7 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestVerifyLocalScheduleProgrammingFunctionalityIsEnabledAtTheThermostat_30() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -55251,9 +58254,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheScheduleProgrammingVisibilityAttributeOfDut_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeScheduleProgrammingVisibilityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -55274,9 +58279,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesAValueOf1ToScheduleProgrammingVisibilityAttributeOfDut_32() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id scheduleProgrammingVisibilityArgument; @@ -55297,6 +58304,7 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestVerifyLocalScheduleProgrammingFunctionalityIsDisabledAtTheThermostat_33() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -55306,9 +58314,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheScheduleProgrammingVisibilityAttributeOfDut_34() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeScheduleProgrammingVisibilityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -55329,9 +58339,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestWritesAValueOfGreaterThan1ToScheduleProgrammingVisibilityAttributeOfDut_35() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id scheduleProgrammingVisibilityArgument; @@ -55356,9 +58368,11 @@ class Test_TC_TSUIC_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheScheduleProgrammingVisibilityAttributeOfDut_36() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThermostatUserInterfaceConfiguration * cluster = - [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThermostatUserInterfaceConfiguration alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeScheduleProgrammingVisibilityWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -55831,7 +58845,7 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { break; case 51: ChipLogProgress(chipTool, " ***** Test Step 51 : Read the optional attribute (ActiveTimestamp) in AttributeList\n"); - if (ShouldSkip("DGTHREAD.S.A0039")) { + if (ShouldSkip("DGTHREAD.S.A0038")) { NextTest(); return; } @@ -55839,7 +58853,7 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { break; case 52: ChipLogProgress(chipTool, " ***** Test Step 52 : Read the optional attribute (PendingTimestamp) in AttributeList\n"); - if (ShouldSkip("DGTHREAD.S.A003A")) { + if (ShouldSkip("DGTHREAD.S.A0039")) { NextTest(); return; } @@ -55847,7 +58861,7 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { break; case 53: ChipLogProgress(chipTool, " ***** Test Step 53 : Read the optional attribute (Delay) in AttributeList\n"); - if (ShouldSkip("DGTHREAD.S.A003B")) { + if (ShouldSkip("DGTHREAD.S.A003a")) { NextTest(); return; } @@ -56062,6 +59076,7 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -56069,9 +59084,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -56093,9 +59110,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -56117,9 +59136,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDgthreadsf00pktcntEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -56136,9 +59157,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDgthreadsf01errcntEnsureFeaturemapHasTheCorrectBitSet_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -56155,9 +59178,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDgthreadsf02mlecntEnsureFeaturemapHasTheCorrectBitSet_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -56174,9 +59199,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDgthreadsf03maccntEnsureFeaturemapHasTheCorrectBitSet_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -56193,9 +59220,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsMandatoryAttributesInAttributeListFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56235,9 +59264,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentAttributeDGTHREADSF01ERRCNTInAttributeList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56256,9 +59287,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeDetachedRoleCountInAttributeList_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56277,9 +59310,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeChildRoleCountAttributeList_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56298,9 +59333,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRouterRoleCountInAttributeList_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56319,9 +59356,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeLeaderRoleCountInAttributeList_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56340,9 +59379,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeAttachAttemptCountInAttributeList_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56361,9 +59402,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributePartitionIdChangeCountInAttributeList_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56382,9 +59425,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeBetterPartitionAttachAttemptCountInAttributeList_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56403,9 +59448,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeParentChangeCountInAttributeList_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56424,9 +59471,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxTotalCountInAttributeList_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56445,9 +59494,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxUnicastCountInAttributeList_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56466,9 +59517,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxBroadcastCountInAttributeList_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56487,9 +59540,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxAckRequestedCountInAttributeList_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56508,9 +59563,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxAckedCountInAttributeList_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56529,9 +59586,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxNoAckRequestedCountInAttributeList_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56550,9 +59609,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributesTxDataCountInAttributeList_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56571,9 +59632,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxDataPollCountInAttributeList_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56592,9 +59655,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxBeaconCountInAttributeList_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56613,9 +59678,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxBeaconRequestCountInAttributeList_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56634,9 +59701,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxOtherCountInAttributeList_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56655,9 +59724,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxRetryCountInAttributeList_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56676,9 +59747,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxDirectMaxRetryExpiryCountInAttributeList_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56697,9 +59770,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxIndirectMaxRetryExpiryCountInAttributeList_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56718,9 +59793,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxErrCcaCountInAttributeList_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56739,9 +59816,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxErrAbortCountInAttributeList_32() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56760,9 +59839,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeTxErrBusyChannelCountInAttributeList_33() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56781,9 +59862,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxTotalCountInAttributeList_34() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56802,9 +59885,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxUnicastCountInAttributeList_35() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56823,9 +59908,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxBroadcastCountInAttributeList_36() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56844,9 +59931,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxDataCountInAttributeList_37() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56865,9 +59954,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxDataPollCountInAttributeList_38() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56886,9 +59977,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxBeaconCountInAttributeList_39() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56907,9 +60000,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxBeaconRequestCountInAttributeList_40() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56928,9 +60023,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxOtherCountInAttributeList_41() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56949,9 +60046,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxAddressFilteredCountInAttributeList_42() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56970,9 +60069,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxDestAddrFilteredCountInAttributeList_43() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -56991,9 +60092,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxDuplicatedCountInAttributeList_44() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57012,9 +60115,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxErrNoFrameCountInAttributeList_45() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57033,9 +60138,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxErrUnknownNeighborCountInAttributeList_46() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57054,9 +60161,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxErrInvalidScrAddrCountInAttributeList_47() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57075,9 +60184,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxErrSecCountInAttributeList_48() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57096,9 +60207,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxErrFcsCountInAttributeList_49() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57117,9 +60230,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeRxErrOtherCountInAttributeList_50() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57138,9 +60253,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeActiveTimestampInAttributeList_51() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57159,9 +60276,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributePendingTimestampInAttributeList_52() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57180,9 +60299,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheOptionalAttributeDelayInAttributeList_53() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57201,9 +60322,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAcceptedCommandListFromDut_54() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57222,9 +60345,11 @@ class Test_TC_DGTHREAD_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsGeneratedCommandListFromDut_55() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterThreadNetworkDiagnostics * cluster = - [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterThreadNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57358,6 +60483,7 @@ class Test_TC_ULABEL_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -57365,10 +60491,9 @@ class Test_TC_ULABEL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeClusterRevision_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -57390,10 +60515,9 @@ class Test_TC_ULABEL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeFeatureMap_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -57415,10 +60539,9 @@ class Test_TC_ULABEL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAttributeList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57442,10 +60565,9 @@ class Test_TC_ULABEL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeAcceptedCommandList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57467,10 +60589,9 @@ class Test_TC_ULABEL_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheGlobalAttributeGeneratedCommandList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57580,6 +60701,7 @@ class Test_TC_ULABEL_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -57587,10 +60709,9 @@ class Test_TC_ULABEL_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsLabelListAttributeOfTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLabelListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57706,6 +60827,7 @@ class Test_TC_ULABEL_2_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -57713,10 +60835,9 @@ class Test_TC_ULABEL_2_2 : public TestCommandBridge { CHIP_ERROR TestThWritesLabelListAttributeFromTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id labelListArgument; @@ -57754,10 +60875,9 @@ class Test_TC_ULABEL_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsLabelListAttributeFromTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLabelListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -57889,6 +61009,7 @@ class Test_TC_ULABEL_2_3 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -57896,10 +61017,9 @@ class Test_TC_ULABEL_2_3 : public TestCommandBridge { CHIP_ERROR TestThWritesLabelListAttributeOfTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id labelListArgument; @@ -57929,10 +61049,9 @@ class Test_TC_ULABEL_2_3 : public TestCommandBridge { CHIP_ERROR TestThWritesLabelListAttributeOfTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id labelListArgument; @@ -58083,6 +61202,7 @@ class Test_TC_ULABEL_2_4 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -58090,10 +61210,9 @@ class Test_TC_ULABEL_2_4 : public TestCommandBridge { CHIP_ERROR TestThWritesLabelListAttributeOfTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id labelListArgument; @@ -58123,10 +61242,9 @@ class Test_TC_ULABEL_2_4 : public TestCommandBridge { CHIP_ERROR TestThReadsLabelListAttributeOfTheDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLabelListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -58153,10 +61271,9 @@ class Test_TC_ULABEL_2_4 : public TestCommandBridge { CHIP_ERROR TestThWritesLabelListAttributeOfTheDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id labelListArgument; @@ -58182,10 +61299,9 @@ class Test_TC_ULABEL_2_4 : public TestCommandBridge { CHIP_ERROR TestThReadsLabelListAttributeOfTheDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLabelListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -58400,6 +61516,7 @@ class Test_TC_DGWIFI_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -58407,9 +61524,11 @@ class Test_TC_DGWIFI_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -58431,9 +61550,11 @@ class Test_TC_DGWIFI_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -58455,9 +61576,11 @@ class Test_TC_DGWIFI_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDGWIFISF00PacketCountsEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -58474,9 +61597,11 @@ class Test_TC_DGWIFI_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDGWIFISF01ErrorCountsEnsureFeaturemapHasTheCorrectBitSet_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -58493,9 +61618,11 @@ class Test_TC_DGWIFI_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAttributeListFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -58523,9 +61650,11 @@ class Test_TC_DGWIFI_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentDGWIFISF00AttributesInAttributeListFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -58548,9 +61677,11 @@ class Test_TC_DGWIFI_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentDGWIFISF01AttributesInAttributeListFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -58570,9 +61701,11 @@ class Test_TC_DGWIFI_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeCurrentMaxRateInAttributeListFromDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -58591,9 +61724,11 @@ class Test_TC_DGWIFI_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAcceptedCommandListFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -58615,9 +61750,11 @@ class Test_TC_DGWIFI_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentDGWIFISF01CommandInAcceptedCommandListFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -58636,9 +61773,11 @@ class Test_TC_DGWIFI_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsGeneratedCommandListFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -58880,6 +62019,7 @@ class Test_TC_DGWIFI_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -58887,9 +62027,11 @@ class Test_TC_DGWIFI_2_1 : public TestCommandBridge { CHIP_ERROR TestThReadsBssidAttributeFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBssidWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -58910,9 +62052,11 @@ class Test_TC_DGWIFI_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsSecurityTypeAttributeConstraints_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSecurityTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -58933,9 +62077,11 @@ class Test_TC_DGWIFI_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsWiFiVersionAttributeConstraints_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWiFiVersionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -58958,9 +62104,11 @@ class Test_TC_DGWIFI_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsChannelNumberAttributeConstraints_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeChannelNumberWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -58983,9 +62131,11 @@ class Test_TC_DGWIFI_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsRssiAttributeConstraints_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRssiWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59008,9 +62158,11 @@ class Test_TC_DGWIFI_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsBeaconLostCountAttributeConstraints_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBeaconLostCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59033,9 +62185,11 @@ class Test_TC_DGWIFI_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsBeaconRxCountAttributeConstraints_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBeaconRxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59058,9 +62212,11 @@ class Test_TC_DGWIFI_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsPacketMulticastRxCountAttributeConstraints_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePacketMulticastRxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59083,9 +62239,11 @@ class Test_TC_DGWIFI_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsPacketMulticastTxCountAttributeConstraints_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePacketMulticastTxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59108,9 +62266,11 @@ class Test_TC_DGWIFI_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsPacketUnicastRxCountAttributeConstraints_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePacketUnicastRxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59133,9 +62293,11 @@ class Test_TC_DGWIFI_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsPacketUnicastTxCountAttributeConstraints_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePacketUnicastTxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59158,9 +62320,11 @@ class Test_TC_DGWIFI_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsCurrentMaxRateAttributeConstraints_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentMaxRateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59181,9 +62345,11 @@ class Test_TC_DGWIFI_2_1 : public TestCommandBridge { CHIP_ERROR TestReadsOverrunCountAttributeConstraints_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOverrunCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59358,6 +62524,7 @@ class Test_TC_DGWIFI_2_3 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -59365,9 +62532,11 @@ class Test_TC_DGWIFI_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsResetCountsCommandToDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster resetCountsWithCompletion:^(NSError * _Nullable err) { @@ -59383,9 +62552,11 @@ class Test_TC_DGWIFI_2_3 : public TestCommandBridge { CHIP_ERROR TestReadsBeaconLostCountAttributeFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBeaconLostCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59408,9 +62579,11 @@ class Test_TC_DGWIFI_2_3 : public TestCommandBridge { CHIP_ERROR TestReadsBeaconRxCountAttributeFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBeaconRxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59433,9 +62606,11 @@ class Test_TC_DGWIFI_2_3 : public TestCommandBridge { CHIP_ERROR TestReadsPacketMulticastRxCountAttributeFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePacketMulticastRxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59458,9 +62633,11 @@ class Test_TC_DGWIFI_2_3 : public TestCommandBridge { CHIP_ERROR TestReadsPacketMulticastTxCountAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePacketMulticastTxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59483,9 +62660,11 @@ class Test_TC_DGWIFI_2_3 : public TestCommandBridge { CHIP_ERROR TestReadsPacketUnicastRxCountAttributeFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePacketUnicastRxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59508,9 +62687,11 @@ class Test_TC_DGWIFI_2_3 : public TestCommandBridge { CHIP_ERROR TestReadsPacketUnicastTxCountAttributeFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWiFiNetworkDiagnostics * cluster = - [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWiFiNetworkDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePacketUnicastTxCountWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59817,6 +62998,7 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -59824,10 +63006,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFromTheDutThe0xFFFDClusterRevisionAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59852,10 +63033,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFromTheDutThe0xFFFCFeatureMapAttribute_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59877,10 +63057,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenWncvsf00lfEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59897,10 +63076,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenWncvsf01tlEnsureFeaturemapHasTheCorrectBitSet_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59917,10 +63095,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenWncvsf02paLfEnsureFeaturemapHasTheCorrectBitSet_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59937,10 +63114,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenWncvsf03absEnsureFeaturemapHasTheCorrectBitSet_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59957,10 +63133,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenWncvsf04paTlEnsureFeaturemapHasTheCorrectBitSet_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -59977,10 +63152,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFromTheDutThe0xFFFBAttributeListAttribute_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -60008,10 +63182,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeSafetyStatusInAttributeList_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -60030,10 +63203,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentWNCVSF00Wncvsf02Wncvsf03AttributeInAttributeList_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -60053,10 +63225,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentWNCVSF00Wncvsf02AttributeInAttributeList_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -60076,10 +63247,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentWNCVSF01Wncvsf04Wncvsf03AttributeInAttributeList_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -60099,10 +63269,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestReadTheFeatureDependentWNCVSF01Wncvsf04AttributeInAttributeList_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -60122,10 +63291,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFromTheDutThe0xFFF9AcceptedCommandListAttribute_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -60146,10 +63314,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentWNCVSF00Wncvsf02CommandInAcceptedCommandList_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -60168,10 +63335,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentWNCVSF01Wncvsf03CommandInAcceptedCommandList_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -60190,10 +63356,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentWNCVSF01Wncvsf04CommandInAcceptedCommandList_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -60212,10 +63377,9 @@ class Test_TC_WNCV_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFromTheDutThe0xFFF8GeneratedCommandListAttribute_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -60577,6 +63741,7 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -60584,10 +63749,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test1aReadTheRoMandatoryAttributeDefaultType_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -60607,10 +63771,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test1bReadTheRoMandatoryAttributeDefaultConfigStatus_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeConfigStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -60630,10 +63793,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test1cReadTheRoMandatoryAttributeDefaultOperationalStatus_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -60653,10 +63815,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test1dReadTheRoMandatoryAttributeDefaultEndProductType_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEndProductTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -60676,10 +63837,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test1eReadTheRwMandatoryAttributeDefaultMode_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -60699,10 +63859,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test1fWriteAValueIntoTheRwMandatoryAttributeMode_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id modeArgument; @@ -60721,10 +63880,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test2aReadTheRoOptionalAttributeDefaultTargetPositionLiftPercent100ths_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionLiftPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -60749,10 +63907,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test2bReadTheRoOptionalAttributeDefaultTargetPositionTiltPercent100ths_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionTiltPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -60777,10 +63934,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test2cReadTheRoOptionalAttributeDefaultCurrentPositionLiftPercent100ths_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -60806,10 +63962,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test2dReadTheRoOptionalAttributeDefaultCurrentPositionTiltPercent100ths_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -60835,10 +63990,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test2eReadTheRoOptionalAttributeDefaultInstalledOpenLimitLift_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInstalledOpenLimitLiftWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -60858,10 +64012,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test2fReadTheRoOptionalAttributeDefaultInstalledClosedLimitLift_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInstalledClosedLimitLiftWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -60881,10 +64034,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test2gReadTheRoOptionalAttributeDefaultInstalledOpenLimitTilt_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInstalledOpenLimitTiltWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -60904,10 +64056,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test2hReadTheRoOptionalAttributeDefaultInstalledClosedLimitTilt_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInstalledClosedLimitTiltWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -60927,10 +64078,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test3aReadTheRoMandatoryAttributeDefaultSafetyStatus_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSafetyStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -60950,10 +64100,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test3bReadTheRoOptionalAttributeDefaultPhysicalClosedLimitLift_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePhysicalClosedLimitLiftWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -60973,10 +64122,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test3cReadTheRoOptionalAttributeDefaultPhysicalClosedLimitTilt_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePhysicalClosedLimitTiltWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -60996,10 +64144,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test3dReadTheRoOptionalAttributeDefaultCurrentPositionLift_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionLiftWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -61022,10 +64169,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test3eReadTheRoOptionalAttributeDefaultCurrentPositionTilt_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionTiltWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -61048,10 +64194,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test3fReadTheRoOptionalAttributeDefaultNumberOfActuationsLift_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNumberOfActuationsLiftWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -61071,10 +64216,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test3gReadTheRoOptionalAttributeDefaultNumberOfActuationsTilt_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNumberOfActuationsTiltWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -61094,10 +64238,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test3hReadTheRoOptionalAttributeDefaultCurrentPositionLiftPercentage_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionLiftPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -61122,10 +64265,9 @@ class Test_TC_WNCV_2_1 : public TestCommandBridge { CHIP_ERROR Test3ireadTheRoOptionalAttributeDefaultCurrentPositionTiltPercentage_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionTiltPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -61240,6 +64382,7 @@ class Test_TC_WNCV_2_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -61247,6 +64390,7 @@ class Test_TC_WNCV_2_2 : public TestCommandBridge { CHIP_ERROR TestReadsConfigStatusAttributeFromDutIfPaLfValueOfBit3MustBe1bElse0bIfPaTlValueOfBit4MustBe1bElse0b_1() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -61521,6 +64665,7 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -61528,10 +64673,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test1aThSetTheModeAttributeBit0OfTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id modeArgument; @@ -61550,10 +64694,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test1bThReadsConfigStatusAttributeFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeConfigStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -61572,10 +64715,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test1cThClearTheModeAttributeBit0OfTheDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id modeArgument; @@ -61594,10 +64736,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test1dThReadsConfigStatusAttributeFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeConfigStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -61616,10 +64757,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test2aThSetTheModeAttributeBit1OfTheDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id modeArgument; @@ -61639,10 +64779,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test2bThReadsConfigStatusAttributeFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeConfigStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -61664,10 +64803,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test2cIfConfigStatusBit00ThSendDownOrCloseCommandToTheDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster downOrCloseWithCompletion:^(NSError * _Nullable err) { @@ -61684,10 +64822,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test2dThClearTheModeAttributeBit1OfTheDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id modeArgument; @@ -61706,10 +64843,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test2eThReadsConfigStatusAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeConfigStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -61728,10 +64864,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test2fThReadsTheModeAttributeFromTheDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -61750,10 +64885,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test2gThSendDownOrCloseCommandToTheDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster downOrCloseWithCompletion:^(NSError * _Nullable err) { @@ -61769,10 +64903,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test3aThSetTheModeAttributeBit2OfTheDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id modeArgument; @@ -61791,10 +64924,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test3bThSendDownOrCloseCommandToTheDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster downOrCloseWithCompletion:^(NSError * _Nullable err) { @@ -61812,10 +64944,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test3cThReadsConfigStatusAttributeFromDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeConfigStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -61837,10 +64968,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test3dThClearTheModeAttributeBit2OfTheDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id modeArgument; @@ -61859,10 +64989,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test3eThSendDownOrCloseCommandToTheDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster downOrCloseWithCompletion:^(NSError * _Nullable err) { @@ -61878,10 +65007,9 @@ class Test_TC_WNCV_2_3 : public TestCommandBridge { CHIP_ERROR Test3fThReadsConfigStatusAttributeFromDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeConfigStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -61988,6 +65116,7 @@ class Test_TC_WNCV_2_4 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -61995,6 +65124,7 @@ class Test_TC_WNCV_2_4 : public TestCommandBridge { CHIP_ERROR TestReadsTypeAttributeFromDut_1() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -62092,6 +65222,7 @@ class Test_TC_WNCV_2_5 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -62099,10 +65230,9 @@ class Test_TC_WNCV_2_5 : public TestCommandBridge { CHIP_ERROR TestThReadsEndProductTypeAttributeFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEndProductTypeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -62505,6 +65635,7 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test0WaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -62512,10 +65643,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test1aThSendsDownOrCloseCommandToPrepositionTheDutInTheOppositeDirection_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster downOrCloseWithCompletion:^(NSError * _Nullable err) { @@ -62531,6 +65661,7 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test1bThWaitsFor10SecondsMovementsOnTheDevice_2() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -62538,10 +65669,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test1cIfPaLfThReadsCurrentPositionLiftPercent100thsAttributeFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -62567,10 +65697,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test1dIfPaLfThReadsCurrentPositionLiftPercentageOptionalAttributeFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionLiftPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -62595,10 +65724,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test1eIfPaTlThReadsCurrentPositionTiltPercent100thsAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -62624,10 +65752,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test1fIfPaTlThReadsCurrentPositionTiltPercentageOptionalAttributeFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionTiltPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -62654,10 +65781,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR TestReport2SubscribeToDutReportsOnOperationalStatusAttribute_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_Test_TC_WNCV_3_1_OperationalStatus_Reported = ^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -62675,16 +65801,15 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test2SubscribeToDutReportsOnOperationalStatusAttribute_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); uint16_t minIntervalArgument = 4U; uint16_t maxIntervalArgument = 5U; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) - maxInterval:@(maxIntervalArgument)]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) + maxInterval:@(maxIntervalArgument)]; params.filterByFabric = true; params.replaceExistingSubscriptions = true; [cluster subscribeAttributeOperationalStatusWithParams:params @@ -62709,10 +65834,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test2aThSendsUpOrOpenCommandToDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster upOrOpenWithCompletion:^(NSError * _Nullable err) { @@ -62728,6 +65852,7 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test2bDutUpdatesItsAttributes_10() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -62735,10 +65860,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test2cIfPaLfThReadsTargetPositionLiftPercent100thsAttributeFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionLiftPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -62760,10 +65884,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test2dIfPaTlThReadsTargetPositionTiltPercent100thsAttributeFromDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionTiltPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -62785,6 +65908,7 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test2eThLeaveTheDeviceMovingFor2Seconds_13() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 2000UL; return WaitForMs("alpha", value); @@ -62792,10 +65916,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test3aThReadsOperationalStatusAttributesBit01_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -62812,10 +65935,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test3aThReadsOperationalStatusAttributesBit23Wncvsf00lf_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -62832,10 +65954,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test3aThReadsOperationalStatusAttributesBit23Wncvsf00lf_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -62852,10 +65973,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test3aThReadsOperationalStatusAttributesBit45Wncvsf01tl_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -62872,10 +65992,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test3aThReadsOperationalStatusAttributesBit45Wncvsf01tl_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -62892,6 +66011,7 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test3a2DutUpdatesItsAttributes_19() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 3000UL; return WaitForMs("alpha", value); @@ -62899,10 +66019,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test3bIfPaLfThReadsCurrentPositionLiftPercent100thsAttributeFromDut_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -62928,10 +66047,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test3cIfPaLfThReadsCurrentPositionLiftPercentageOptionalAttributeFromDut_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionLiftPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -62956,10 +66074,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test3dIfPaTlThReadsCurrentPositionTiltPercent100thsAttributeFromDut_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -62985,10 +66102,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test3eIfPaLfThReadsCurrentPositionTiltPercentageOptionalAttributeFromDut_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionTiltPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -63013,10 +66129,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test4aThSendsAStopMotionCommandToDut_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster stopMotionWithCompletion:^(NSError * _Nullable err) { @@ -63032,6 +66147,7 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test4bThWaitsFor3SecondsTheEndOfInertialMovementsOnTheDevice_25() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 3000UL; return WaitForMs("alpha", value); @@ -63039,10 +66155,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test4cVerifyDutUpdateOperationalStatusAttributeToThAfterAStopMotion_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -63063,6 +66178,7 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test5aThWaitsForXSecondsAttributesUpdateOnTheDevice_27() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 1000UL; return WaitForMs("alpha", value); @@ -63070,10 +66186,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test5bIfPaLfThReadsTargetPositionLiftPercent100thsAttributeFromDut_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionLiftPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -63098,10 +66213,9 @@ class Test_TC_WNCV_3_1 : public TestCommandBridge { CHIP_ERROR Test5cIfPaTlThReadsTargetPositionTiltPercent100thsAttributeFromDut_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionTiltPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -63509,6 +66623,7 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test0WaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -63516,10 +66631,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test1aThSendsUpOrOpenCommandToPrepositionTheDutInTheOppositeDirection_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster upOrOpenWithCompletion:^(NSError * _Nullable err) { @@ -63535,6 +66649,7 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test1bThWaitsFor10SecondsMovementsOnTheDevice_2() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -63542,10 +66657,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test1cIfPaLfThReadsCurrentPositionLiftPercent100thsAttributeFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -63571,10 +66685,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test1dIfPaLfThReadsCurrentPositionLiftPercentageOptionalAttributeFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionLiftPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -63599,10 +66712,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test1eIfPaTlThReadsCurrentPositionTiltPercent100thsAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -63628,10 +66740,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test1fIfPaTlThReadsCurrentPositionTiltPercentageOptionalAttributeFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionTiltPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -63658,10 +66769,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR TestReport2SubscribeToDutReportsOnOperationalStatusAttribute_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_Test_TC_WNCV_3_2_OperationalStatus_Reported = ^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -63679,16 +66789,15 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test2SubscribeToDutReportsOnOperationalStatusAttribute_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); uint16_t minIntervalArgument = 4U; uint16_t maxIntervalArgument = 5U; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) - maxInterval:@(maxIntervalArgument)]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) + maxInterval:@(maxIntervalArgument)]; params.filterByFabric = true; params.replaceExistingSubscriptions = true; [cluster subscribeAttributeOperationalStatusWithParams:params @@ -63713,10 +66822,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test2aThSendsDownOrCloseCommandToDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster downOrCloseWithCompletion:^(NSError * _Nullable err) { @@ -63732,6 +66840,7 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test2bDutUpdatesItsAttributes_10() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -63739,10 +66848,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test2cIfPaLfThReadsTargetPositionLiftPercent100thsAttributeFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionLiftPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -63764,10 +66872,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test2dIfPaTlThReadsTargetPositionTiltPercent100thsAttributeFromDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionTiltPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -63789,6 +66896,7 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test2eThLeaveTheDeviceMovingFor2Seconds_13() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 2000UL; return WaitForMs("alpha", value); @@ -63796,10 +66904,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test3aThReadsOperationalStatusAttributesBit01_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -63816,10 +66923,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test3aThReadsOperationalStatusAttributesBit23Wncvsf00lf_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -63836,10 +66942,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test3aThReadsOperationalStatusAttributesBit23Wncvsf00lf_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -63856,10 +66961,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test3aThReadsOperationalStatusAttributesBit45Wncvsf01tl_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -63876,10 +66980,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test3aThReadsOperationalStatusAttributesBit45Wncvsf01tl_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -63896,6 +66999,7 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test3a2DutUpdatesItsAttributes_19() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 3000UL; return WaitForMs("alpha", value); @@ -63903,10 +67007,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test3bIfPaLfThReadsCurrentPositionLiftPercent100thsAttributeFromDut_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -63932,10 +67035,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test3cIfPaLfThReadsCurrentPositionLiftPercentageOptionalAttributeFromDut_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionLiftPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -63960,10 +67062,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test3dIfPaTlThReadsCurrentPositionTiltPercent100thsAttributeFromDut_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -63989,10 +67090,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test3eIfPaLfThReadsCurrentPositionTiltPercentageOptionalAttributeFromDut_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionTiltPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -64017,10 +67117,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test4aThSendsAStopMotionCommandToDut_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster stopMotionWithCompletion:^(NSError * _Nullable err) { @@ -64036,6 +67135,7 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test4bThWaitsFor3SecondsTheEndOfInertialMovementsOnTheDevice_25() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 3000UL; return WaitForMs("alpha", value); @@ -64043,10 +67143,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test4cVerifyDutUpdateOperationalStatusAttributeToThAfterAStopMotion_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -64067,6 +67166,7 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test5aThWaitsForXSecondsAttributesUpdateOnTheDevice_27() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 1000UL; return WaitForMs("alpha", value); @@ -64074,10 +67174,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test5bIfPaLfThReadsTargetPositionLiftPercent100thsAttributeFromDut_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionLiftPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -64102,10 +67201,9 @@ class Test_TC_WNCV_3_2 : public TestCommandBridge { CHIP_ERROR Test5cIfPaTlThReadsTargetPositionTiltPercent100thsAttributeFromDut_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionTiltPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -64376,6 +67474,7 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test0WaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -64383,10 +67482,9 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test1aThSendsDownOrCloseCommandToPrepositionTheDutInTheOppositeDirection_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster downOrCloseWithCompletion:^(NSError * _Nullable err) { @@ -64402,6 +67500,7 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test1bThWaitsFor68SecondsMovementsOnTheDevice_2() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 6000UL; return WaitForMs("alpha", value); @@ -64409,10 +67508,9 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test1cThSendsUpOrOpenCommandToPrepositionTheDutInTheOppositeDirection_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster upOrOpenWithCompletion:^(NSError * _Nullable err) { @@ -64428,6 +67526,7 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test1dThWaitsFor2SecondsMovementsOnTheDevice_4() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 2000UL; return WaitForMs("alpha", value); @@ -64435,10 +67534,9 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test1eThReadsOperationalStatusAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -64456,6 +67554,7 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test1dThWaitsFor2SecondsMovementsOnTheDevice_6() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 2000UL; return WaitForMs("alpha", value); @@ -64465,10 +67564,9 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR TestReport2SubscribeToDutReportsOnOperationalStatusAttribute_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_Test_TC_WNCV_3_3_OperationalStatus_Reported = ^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -64486,16 +67584,15 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test2SubscribeToDutReportsOnOperationalStatusAttribute_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); uint16_t minIntervalArgument = 4U; uint16_t maxIntervalArgument = 5U; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) - maxInterval:@(maxIntervalArgument)]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) + maxInterval:@(maxIntervalArgument)]; params.filterByFabric = true; params.replaceExistingSubscriptions = true; [cluster subscribeAttributeOperationalStatusWithParams:params @@ -64520,10 +67617,9 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test2aThSendsAStopMotionCommandToDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster stopMotionWithCompletion:^(NSError * _Nullable err) { @@ -64539,6 +67635,7 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test2bThWaitsFor3SecondsTheEndOfInertialMovementsOnTheDevice_10() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 3000UL; return WaitForMs("alpha", value); @@ -64546,10 +67643,9 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test2cThReadsOperationalStatusAttributeFromDutAfterAStopMotion_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -64570,6 +67666,7 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test2dThWaitsFor100ms3sAttributesUpdateOnTheDevice_12() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 2000UL; return WaitForMs("alpha", value); @@ -64577,10 +67674,9 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test2eThReadsOperationalStatusAttributeFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -64602,10 +67698,9 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test3aIfPaLfThReadsCurrentPositionLiftPercent100thsAttributeFromDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -64634,10 +67729,9 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test3bIfPaLfThReadsTargetPositionLiftPercent100thsAttribute3cItMustBeEqualWithCurrentPositionLiftPercent100thsFromDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionLiftPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -64666,10 +67760,9 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test4aIfPaTlThReadsCurrentPositionTiltPercent100thsAttributeFromDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -64698,10 +67791,9 @@ class Test_TC_WNCV_3_3 : public TestCommandBridge { CHIP_ERROR Test4bIfPaTlThReadsTargetPositionTiltPercent100thsAttribute4cItMustBeEqualWithCurrentPositionTiltPercent100thsFromDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionTiltPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -64908,6 +68000,7 @@ class Test_TC_WNCV_3_4 : public TestCommandBridge { CHIP_ERROR Test0WaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -64915,10 +68008,9 @@ class Test_TC_WNCV_3_4 : public TestCommandBridge { CHIP_ERROR Test1aThSendsDownOrCloseCommandToPrepositionTheDutInTheOppositeDirection_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster downOrCloseWithCompletion:^(NSError * _Nullable err) { @@ -64934,6 +68026,7 @@ class Test_TC_WNCV_3_4 : public TestCommandBridge { CHIP_ERROR Test1bThWaitsForFastMotionDurationSecondsMovementsOnTheDevice_2() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = mFastMotionDuration.HasValue() ? mFastMotionDuration.Value() : 3000UL; return WaitForMs("alpha", value); @@ -64941,10 +68034,9 @@ class Test_TC_WNCV_3_4 : public TestCommandBridge { CHIP_ERROR Test2aThSendsUpOrOpenCommandToDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster upOrOpenWithCompletion:^(NSError * _Nullable err) { @@ -64960,6 +68052,7 @@ class Test_TC_WNCV_3_4 : public TestCommandBridge { CHIP_ERROR Test2bThWaitsForFullMotionDurationSecondsMovementsOnTheDevice_4() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = mFullMotionDuration.HasValue() ? mFullMotionDuration.Value() : 6000UL; return WaitForMs("alpha", value); @@ -64967,10 +68060,9 @@ class Test_TC_WNCV_3_4 : public TestCommandBridge { CHIP_ERROR Test2cThReadsOperationalStatusAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -64991,10 +68083,9 @@ class Test_TC_WNCV_3_4 : public TestCommandBridge { CHIP_ERROR Test3aIfPaLfThReadsCurrentPositionLiftPercent100thsAttributeFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -65017,10 +68108,9 @@ class Test_TC_WNCV_3_4 : public TestCommandBridge { CHIP_ERROR Test3bIfPaLfThReadsCurrentPositionLiftPercentageOptionalAttributeFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionLiftPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -65042,10 +68132,9 @@ class Test_TC_WNCV_3_4 : public TestCommandBridge { CHIP_ERROR Test3cIfPaTlThReadsCurrentPositionTiltPercent100thsAttributeFromDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -65068,10 +68157,9 @@ class Test_TC_WNCV_3_4 : public TestCommandBridge { CHIP_ERROR Test3dIfPaTlThReadsCurrentPositionTiltPercentageOptionalAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionTiltPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -65272,6 +68360,7 @@ class Test_TC_WNCV_3_5 : public TestCommandBridge { CHIP_ERROR Test0WaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -65279,10 +68368,9 @@ class Test_TC_WNCV_3_5 : public TestCommandBridge { CHIP_ERROR Test1aThSendsUpOrOpenCommandToPrepositionTheDutInTheOppositeDirection_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster upOrOpenWithCompletion:^(NSError * _Nullable err) { @@ -65298,6 +68386,7 @@ class Test_TC_WNCV_3_5 : public TestCommandBridge { CHIP_ERROR Test1bThWaitsForFastMotionDurationSecondsMovementsOnTheDevice_2() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = mFastMotionDuration.HasValue() ? mFastMotionDuration.Value() : 3000UL; return WaitForMs("alpha", value); @@ -65305,10 +68394,9 @@ class Test_TC_WNCV_3_5 : public TestCommandBridge { CHIP_ERROR Test2aThSendsDownOrCloseCommandToDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster downOrCloseWithCompletion:^(NSError * _Nullable err) { @@ -65324,6 +68412,7 @@ class Test_TC_WNCV_3_5 : public TestCommandBridge { CHIP_ERROR Test2bThWaitsForFullMotionDurationSecondsMovementsOnTheDevice_4() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = mFullMotionDuration.HasValue() ? mFullMotionDuration.Value() : 6000UL; return WaitForMs("alpha", value); @@ -65331,10 +68420,9 @@ class Test_TC_WNCV_3_5 : public TestCommandBridge { CHIP_ERROR Test2cThReadsOperationalStatusAttributeFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -65355,10 +68443,9 @@ class Test_TC_WNCV_3_5 : public TestCommandBridge { CHIP_ERROR Test3aIfPaLfThReadsCurrentPositionLiftPercent100thsAttributeFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -65381,10 +68468,9 @@ class Test_TC_WNCV_3_5 : public TestCommandBridge { CHIP_ERROR Test3bIfPaLfThReadsCurrentPositionLiftPercentageOptionalAttributeFromDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionLiftPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -65406,10 +68492,9 @@ class Test_TC_WNCV_3_5 : public TestCommandBridge { CHIP_ERROR Test3cIfPaTlThReadsCurrentPositionTiltPercent100thsAttributeFromDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -65432,10 +68517,9 @@ class Test_TC_WNCV_3_5 : public TestCommandBridge { CHIP_ERROR Test3dIfPaTlThReadsCurrentPositionTiltPercentageOptionalAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionTiltPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -65711,6 +68795,7 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test0WaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -65718,10 +68803,9 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test1aThSendsDownOrCloseCommandToPrepositionTheDutInTheOppositeDirection_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster downOrCloseWithCompletion:^(NSError * _Nullable err) { @@ -65737,6 +68821,7 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test1bThWaitsForXSecondsMovementsOnTheDut_2() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = mFullMotionDuration.HasValue() ? mFullMotionDuration.Value() : 6000UL; return WaitForMs("alpha", value); @@ -65744,10 +68829,9 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test1cIfPaLfThReadsCurrentPositionLiftPercent100thsAttributeFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -65768,10 +68852,9 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test2aThSendsGoToLiftPercentageCommandWith25PercentToDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRWindowCoveringClusterGoToLiftPercentageParams alloc] init]; @@ -65790,6 +68873,7 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test2bDutUpdatesItsAttributes_5() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -65797,10 +68881,9 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test2cIfPaLfThReadsTargetPositionLiftPercent100thsAttributeFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionLiftPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -65822,6 +68905,7 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test3aThSetATimeoutOfXMinutesForFailure_7() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = mFullMotionDuration.HasValue() ? mFullMotionDuration.Value() : 6000UL; return WaitForMs("alpha", value); @@ -65829,10 +68913,9 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test3bThReadsOperationalStatusAttributeFromDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -65853,10 +68936,9 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test3cIfPaLfThReadsCurrentPositionLiftPercent100thsAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -65879,10 +68961,9 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test3dIfPaLfThReadsCurrentPositionLiftPercentageOptionalAttributeFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionLiftPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -65904,10 +68985,9 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test4aThSendsGoToLiftPercentageCommandWith7520PercentToDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRWindowCoveringClusterGoToLiftPercentageParams alloc] init]; @@ -65926,6 +69006,7 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test4bDutUpdatesItsAttributes_12() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -65933,10 +69014,9 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test4cIfPaLfThReadsTargetPositionLiftPercent100thsAttributeFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionLiftPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -65958,6 +69038,7 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test5aThWaitsForXSecondsMovementsOnTheDut_14() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = mFullMotionDuration.HasValue() ? mFullMotionDuration.Value() : 6000UL; return WaitForMs("alpha", value); @@ -65965,10 +69046,9 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test5bThReadsOperationalStatusAttributeFromDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -65989,10 +69069,9 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test5cIfPaLfThReadsCurrentPositionLiftPercent100thsAttributeFromDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -66015,10 +69094,9 @@ class Test_TC_WNCV_4_1 : public TestCommandBridge { CHIP_ERROR Test5dIfPaLfThReadsCurrentPositionLiftPercentageOptionalAttributeFromDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionLiftPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -66294,6 +69372,7 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test0WaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -66301,10 +69380,9 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test1aThSendsDownOrCloseCommandToPrepositionTheDutInTheOppositeDirection_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster downOrCloseWithCompletion:^(NSError * _Nullable err) { @@ -66320,6 +69398,7 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test1bThWaitsForXSecondsMovementsOnTheDut_2() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = mFullMotionDuration.HasValue() ? mFullMotionDuration.Value() : 6000UL; return WaitForMs("alpha", value); @@ -66327,10 +69406,9 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test1cIfPaTlThReadsCurrentPositionTiltPercent100thsAttributeFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -66351,10 +69429,9 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test2aThSendsGoToTiltPercentageCommandWith30PercentToDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRWindowCoveringClusterGoToTiltPercentageParams alloc] init]; @@ -66373,6 +69450,7 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test2bDutUpdatesItsAttributes_5() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -66380,10 +69458,9 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test2cIfPaTlThReadsTargetPositionTiltPercent100thsAttributeFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionTiltPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -66405,6 +69482,7 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test3aThSetATimeoutOfXMinutesForFailure_7() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = mFullMotionDuration.HasValue() ? mFullMotionDuration.Value() : 6000UL; return WaitForMs("alpha", value); @@ -66412,10 +69490,9 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test3bThReadsOperationalStatusAttributeFromDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -66436,10 +69513,9 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test3cIfPaTlThReadsCurrentPositionTiltPercent100thsAttributeFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -66462,10 +69538,9 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test3dIfPaTlThReadsCurrentPositionTiltPercentageOptionalAttributeFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionTiltPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -66487,10 +69562,9 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test4aThSendsGoToTiltPercentageCommandWith6005PercentToDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRWindowCoveringClusterGoToTiltPercentageParams alloc] init]; @@ -66509,6 +69583,7 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test4bDutUpdatesItsAttributes_12() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -66516,10 +69591,9 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test4cIfPaTlThReadsTargetPositionTiltPercent100thsAttributeFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetPositionTiltPercent100thsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -66541,6 +69615,7 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test5aThWaitsForXSecondsMovementsOnTheDut_14() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = mFullMotionDuration.HasValue() ? mFullMotionDuration.Value() : 6000UL; return WaitForMs("alpha", value); @@ -66548,10 +69623,9 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test5bThReadsOperationalStatusAttributeFromDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOperationalStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -66572,10 +69646,9 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test5cIfPaTlThReadsCurrentPositionTiltPercent100thsAttributeFromDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -66598,10 +69671,9 @@ class Test_TC_WNCV_4_2 : public TestCommandBridge { CHIP_ERROR Test5dIfPaTlThReadsCurrentPositionTiltPercentageOptionalAttributeFromDut_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionTiltPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -66758,6 +69830,7 @@ class Test_TC_WNCV_4_3 : public TestCommandBridge { CHIP_ERROR Test0WaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -66766,10 +69839,9 @@ class Test_TC_WNCV_4_3 : public TestCommandBridge { CHIP_ERROR Test1aIfPaLfLfThReadsCurrentPositionLiftPercent100thsFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -66798,10 +69870,9 @@ class Test_TC_WNCV_4_3 : public TestCommandBridge { CHIP_ERROR Test1b1cIfPaLfLfThReadsCurrentPositionLiftPercentageFromDutAssertCurrentPositionLiftPercent100ths100EqualsCurrentPositionLiftPercentage_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionLiftPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -66833,10 +69904,9 @@ class Test_TC_WNCV_4_3 : public TestCommandBridge { CHIP_ERROR Test2bThSendsGoToLiftPercentageCommandWithBadParamToDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRWindowCoveringClusterGoToLiftPercentageParams alloc] init]; @@ -66858,10 +69928,9 @@ class Test_TC_WNCV_4_3 : public TestCommandBridge { CHIP_ERROR Test3aThSendsGoToLiftPercentageCommandWith10001ToDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRWindowCoveringClusterGoToLiftPercentageParams alloc] init]; @@ -66883,10 +69952,9 @@ class Test_TC_WNCV_4_3 : public TestCommandBridge { CHIP_ERROR Test4aThSendsGoToLiftPercentageCommandWith0xFFFFToDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRWindowCoveringClusterGoToLiftPercentageParams alloc] init]; @@ -67043,6 +70111,7 @@ class Test_TC_WNCV_4_4 : public TestCommandBridge { CHIP_ERROR Test0WaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -67051,10 +70120,9 @@ class Test_TC_WNCV_4_4 : public TestCommandBridge { CHIP_ERROR Test1aIfPaTlTlThReadsCurrentPositionTiltPercent100thsFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -67083,10 +70151,9 @@ class Test_TC_WNCV_4_4 : public TestCommandBridge { CHIP_ERROR Test1b1cIfPaLfLfThReadsCurrentPositionTiltPercentageFromDutAssertCurrentPositionTiltPercent100ths100EqualsCurrentPositionTiltPercentage_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentPositionTiltPercentageWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -67118,10 +70185,9 @@ class Test_TC_WNCV_4_4 : public TestCommandBridge { CHIP_ERROR Test2bThSendsGoToTiltPercentageCommandWithBadParamToDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRWindowCoveringClusterGoToTiltPercentageParams alloc] init]; @@ -67143,10 +70209,9 @@ class Test_TC_WNCV_4_4 : public TestCommandBridge { CHIP_ERROR Test3aThSendsGoToTiltPercentageCommandWith10001ToDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRWindowCoveringClusterGoToTiltPercentageParams alloc] init]; @@ -67168,10 +70233,9 @@ class Test_TC_WNCV_4_4 : public TestCommandBridge { CHIP_ERROR Test4aThSendsGoToTiltPercentageCommandWith0xFFFFToDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRWindowCoveringClusterGoToTiltPercentageParams alloc] init]; @@ -67424,6 +70488,7 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test0aWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -67431,10 +70496,9 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test0bThSendsUpOrOpenCommandToPrepositionTheDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster upOrOpenWithCompletion:^(NSError * _Nullable err) { @@ -67450,10 +70514,9 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test1aIfPaLfLfThSendsGoToLiftPercentageCommandWith90ToDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRWindowCoveringClusterGoToLiftPercentageParams alloc] init]; @@ -67473,6 +70536,7 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test1bThWaitsFor100ms1s_3() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -67480,10 +70544,9 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test1cThSendsStopMotionCommandToDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster stopMotionWithCompletion:^(NSError * _Nullable err) { @@ -67499,6 +70562,7 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test1dThWaitsFor100ms1s_5() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 500UL; return WaitForMs("alpha", value); @@ -67506,10 +70570,9 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test2aIfPaTlTlThSendsGoToTiltPercentageCommandWith90ToDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRWindowCoveringClusterGoToTiltPercentageParams alloc] init]; @@ -67529,6 +70592,7 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test2bThWaitsFor100ms1s_7() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 5000UL; return WaitForMs("alpha", value); @@ -67536,10 +70600,9 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test2cThSendsStopMotionCommandToDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster stopMotionWithCompletion:^(NSError * _Nullable err) { @@ -67555,6 +70618,7 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test2dThWaitsFor100ms1s_9() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 500UL; return WaitForMs("alpha", value); @@ -67563,10 +70627,9 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test3aThReadsCurrentPositionLiftPercent100thsFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -67591,10 +70654,9 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test3bThReadsCurrentPositionTiltPercent100thsFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -67618,12 +70680,14 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test3cRebootRestartTheDut_12() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestRebootTargetDeviceDUT_13() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please reboot the DUT and enter 'y' after DUT startsgarbage: not in length on purpose", 52); @@ -67634,6 +70698,7 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test3dWaitForTheCommissionedDeviceToBeRetrieved_14() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -67641,10 +70706,9 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test3eThReadsCurrentPositionLiftPercent100thsFromDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -67672,10 +70736,9 @@ class Test_TC_WNCV_4_5 : public TestCommandBridge { CHIP_ERROR Test3fThReadsCurrentPositionTiltPercent100thsFromDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWindowCovering * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWindowCovering alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -67801,6 +70864,7 @@ class TV_TargetNavigatorCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -67808,10 +70872,9 @@ class TV_TargetNavigatorCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeTargetNavigatorList_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeTargetListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -67838,10 +70901,9 @@ class TV_TargetNavigatorCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeCurrentNavigatorTarget_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentTargetWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -67862,10 +70924,9 @@ class TV_TargetNavigatorCluster : public TestCommandBridge { CHIP_ERROR TestNavigateTargetRequestCommand_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterTargetNavigator * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterTargetNavigator alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRTargetNavigatorClusterNavigateTargetParams alloc] init]; @@ -68008,6 +71069,7 @@ class TV_AudioOutputCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -68015,10 +71077,9 @@ class TV_AudioOutputCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeAudioOutputList_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOutputListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -68048,10 +71109,9 @@ class TV_AudioOutputCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeCurrentAudioOutput_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentOutputWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -68072,10 +71132,9 @@ class TV_AudioOutputCluster : public TestCommandBridge { CHIP_ERROR TestSelectOutputCommand_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAudioOutputClusterSelectOutputParams alloc] init]; @@ -68094,10 +71153,9 @@ class TV_AudioOutputCluster : public TestCommandBridge { CHIP_ERROR TestRenameOutputCommand_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAudioOutputClusterRenameOutputParams alloc] init]; @@ -68117,10 +71175,9 @@ class TV_AudioOutputCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeAudioOutputList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAudioOutput * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAudioOutput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOutputListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -68262,6 +71319,7 @@ class TV_ApplicationLauncherCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -68269,10 +71327,11 @@ class TV_ApplicationLauncherCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeApplicationLauncherList_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCatalogListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -68295,10 +71354,11 @@ class TV_ApplicationLauncherCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeApplicationLauncherApp_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentAppWithCompletion:^( @@ -68320,10 +71380,11 @@ class TV_ApplicationLauncherCluster : public TestCommandBridge { CHIP_ERROR TestLaunchAppCommand_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRApplicationLauncherClusterLaunchAppParams alloc] init]; @@ -68358,10 +71419,11 @@ class TV_ApplicationLauncherCluster : public TestCommandBridge { CHIP_ERROR TestStopAppCommand_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRApplicationLauncherClusterStopAppParams alloc] init]; @@ -68394,10 +71456,11 @@ class TV_ApplicationLauncherCluster : public TestCommandBridge { CHIP_ERROR TestHideAppCommand_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationLauncher * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationLauncher alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRApplicationLauncherClusterHideAppParams alloc] init]; @@ -68514,6 +71577,7 @@ class TV_KeypadInputCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -68521,10 +71585,9 @@ class TV_KeypadInputCluster : public TestCommandBridge { CHIP_ERROR TestSendKeyCommand_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterKeypadInput * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterKeypadInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRKeypadInputClusterSendKeyParams alloc] init]; @@ -68646,6 +71709,7 @@ class TV_AccountLoginCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -68653,10 +71717,9 @@ class TV_AccountLoginCluster : public TestCommandBridge { CHIP_ERROR TestGetSetupPinCommand_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAccountLoginClusterGetSetupPINParams alloc] init]; @@ -68681,10 +71744,9 @@ class TV_AccountLoginCluster : public TestCommandBridge { CHIP_ERROR TestLoginCommand_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAccountLoginClusterLoginParams alloc] init]; @@ -68704,10 +71766,9 @@ class TV_AccountLoginCluster : public TestCommandBridge { CHIP_ERROR TestLogoutCommand_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccountLogin * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccountLogin alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster logoutWithCompletion:^(NSError * _Nullable err) { @@ -68807,6 +71868,7 @@ class TV_WakeOnLanCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -68814,10 +71876,9 @@ class TV_WakeOnLanCluster : public TestCommandBridge { CHIP_ERROR TestReadMacAddress_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterWakeOnLan * cluster = [[MTRBaseClusterWakeOnLan alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterWakeOnLAN alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMACAddressWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -68971,6 +72032,7 @@ class TV_ApplicationBasicCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -68978,10 +72040,9 @@ class TV_ApplicationBasicCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeVendorName_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeVendorNameWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -69002,10 +72063,9 @@ class TV_ApplicationBasicCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeVendorId_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeVendorIDWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -69026,10 +72086,9 @@ class TV_ApplicationBasicCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeApplicationName_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeApplicationNameWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -69050,10 +72109,9 @@ class TV_ApplicationBasicCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeProductId_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeProductIDWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -69074,10 +72132,9 @@ class TV_ApplicationBasicCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeApplicationStatus_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -69098,10 +72155,9 @@ class TV_ApplicationBasicCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeApplicationStatus_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeApplicationWithCompletion:^( @@ -69126,10 +72182,9 @@ class TV_ApplicationBasicCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeApplicationVersion_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeApplicationVersionWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -69150,10 +72205,9 @@ class TV_ApplicationBasicCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeApplicationAllowedVendorList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterApplicationBasic * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterApplicationBasic alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAllowedVendorListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -69400,6 +72454,7 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -69407,10 +72462,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributePlaybackState_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -69431,10 +72485,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeStartTime_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeStartTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -69456,10 +72509,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeDuration_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeDurationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -69481,10 +72533,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributePosition_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSampledPositionWithCompletion:^( @@ -69509,10 +72560,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributePlaybackSpeed_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePlaybackSpeedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -69533,10 +72583,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeSeekRangeEnd_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSeekRangeEndWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -69558,10 +72607,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeSeekRangeStart_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSeekRangeStartWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -69583,10 +72631,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestMediaPlaybackPlayCommand_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster playWithCompletion:^(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable values, NSError * _Nullable err) { @@ -69612,10 +72659,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestMediaPlaybackPauseCommand_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster pauseWithCompletion:^(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable values, NSError * _Nullable err) { @@ -69641,10 +72687,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestMediaPlaybackStopCommand_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster stopPlaybackWithCompletion:^( @@ -69671,10 +72716,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestMediaPlaybackStartOverCommand_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -69701,10 +72745,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestMediaPlaybackPreviousCommand_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -69731,10 +72774,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestMediaPlaybackNextCommand_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster nextWithCompletion:^(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable values, NSError * _Nullable err) { @@ -69760,10 +72802,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestMediaPlaybackRewindCommand_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster rewindWithCompletion:^(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable values, NSError * _Nullable err) { @@ -69789,10 +72830,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestMediaPlaybackFastForwardCommand_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -69819,10 +72859,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestMediaPlaybackSkipForwardCommand_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRMediaPlaybackClusterSkipForwardParams alloc] init]; @@ -69852,10 +72891,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributePositionAfterSkipForward_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSampledPositionWithCompletion:^( @@ -69880,10 +72918,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestMediaPlaybackSkipBackwardCommand_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRMediaPlaybackClusterSkipBackwardParams alloc] init]; @@ -69913,10 +72950,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributePositionAfterSkipBackward_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSampledPositionWithCompletion:^( @@ -69941,10 +72977,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestMediaPlaybackSeekCommand_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRMediaPlaybackClusterSeekParams alloc] init]; @@ -69973,10 +73008,9 @@ class TV_MediaPlaybackCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributePositionAfterSeek_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaPlayback * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device - endpointID:@(3) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaPlayback alloc] initWithDevice:device endpointID:@(3) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSampledPositionWithCompletion:^( @@ -70120,6 +73154,7 @@ class TV_ChannelCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -70127,10 +73162,9 @@ class TV_ChannelCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeChannelList_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeChannelListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -70180,10 +73214,9 @@ class TV_ChannelCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeChannelLineup_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLineupWithCompletion:^(MTRChannelClusterLineupInfo * _Nullable value, NSError * _Nullable err) { @@ -70211,10 +73244,9 @@ class TV_ChannelCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeCurrentChannel_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentChannelWithCompletion:^( @@ -70242,10 +73274,9 @@ class TV_ChannelCluster : public TestCommandBridge { CHIP_ERROR TestChangeChannelCommand_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRChannelClusterChangeChannelParams alloc] init]; @@ -70275,10 +73306,9 @@ class TV_ChannelCluster : public TestCommandBridge { CHIP_ERROR TestChangeChannelByNumberCommand_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRChannelClusterChangeChannelByNumberParams alloc] init]; @@ -70298,10 +73328,9 @@ class TV_ChannelCluster : public TestCommandBridge { CHIP_ERROR TestSkipChannelCommand_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterChannel * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterChannel alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRChannelClusterSkipChannelParams alloc] init]; @@ -70404,6 +73433,7 @@ class TV_LowPowerCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -70411,10 +73441,9 @@ class TV_LowPowerCluster : public TestCommandBridge { CHIP_ERROR TestSleepInputStatusCommand_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLowPower * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLowPower alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster sleepWithCompletion:^(NSError * _Nullable err) { @@ -70535,6 +73564,7 @@ class TV_ContentLauncherCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -70542,10 +73572,9 @@ class TV_ContentLauncherCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeAcceptHeaderList_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptHeaderWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -70568,10 +73597,9 @@ class TV_ContentLauncherCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeSupportedStreamingProtocols_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSupportedStreamingProtocolsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -70592,10 +73620,9 @@ class TV_ContentLauncherCluster : public TestCommandBridge { CHIP_ERROR TestLaunchContentCommand_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRContentLauncherClusterLaunchContentParams alloc] init]; @@ -70644,10 +73671,9 @@ class TV_ContentLauncherCluster : public TestCommandBridge { CHIP_ERROR TestLaunchUrlCommand_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterContentLauncher * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterContentLauncher alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRContentLauncherClusterLaunchURLParams alloc] init]; @@ -70970,6 +73996,7 @@ class TV_MediaInputCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -70977,10 +74004,9 @@ class TV_MediaInputCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeMediaInputList_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInputListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -71011,10 +74037,9 @@ class TV_MediaInputCluster : public TestCommandBridge { CHIP_ERROR TestReadCurrentMediaInput_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentInputWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -71035,10 +74060,9 @@ class TV_MediaInputCluster : public TestCommandBridge { CHIP_ERROR TestSelectInputCommand_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRMediaInputClusterSelectInputParams alloc] init]; @@ -71057,10 +74081,9 @@ class TV_MediaInputCluster : public TestCommandBridge { CHIP_ERROR TestHideInputStatusCommand_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster hideInputStatusWithCompletion:^(NSError * _Nullable err) { @@ -71076,10 +74099,9 @@ class TV_MediaInputCluster : public TestCommandBridge { CHIP_ERROR TestShowInputStatusCommand_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster showInputStatusWithCompletion:^(NSError * _Nullable err) { @@ -71095,10 +74117,9 @@ class TV_MediaInputCluster : public TestCommandBridge { CHIP_ERROR TestRenameInputCommand_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRMediaInputClusterRenameInputParams alloc] init]; @@ -71118,10 +74139,9 @@ class TV_MediaInputCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeMediaInputList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterMediaInput * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterMediaInput alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInputListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -71271,6 +74291,7 @@ class TestCASERecovery : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -71278,8 +74299,9 @@ class TestCASERecovery : public TestCommandBridge { CHIP_ERROR TestReadAnAttribute_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeDataModelRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -71300,12 +74322,14 @@ class TestCASERecovery : public TestCommandBridge { CHIP_ERROR TestRebootTheServer_2() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestReGetOurSessionButWithoutExpiringSesssions_3() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; value.expireExistingSession.Emplace(); @@ -71315,8 +74339,9 @@ class TestCASERecovery : public TestCommandBridge { CHIP_ERROR TestReadAnAttributeAgain_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeDataModelRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -71333,6 +74358,7 @@ class TestCASERecovery : public TestCommandBridge { CHIP_ERROR TestReGetOurSessionButWithoutExpiringSesssions_5() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; value.expireExistingSession.Emplace(); @@ -71342,8 +74368,9 @@ class TestCASERecovery : public TestCommandBridge { CHIP_ERROR TestReadAnAttributeAThirdTime_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeDataModelRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -71946,970 +74973,969 @@ class TestCluster : public TestCommandBridge { err = TestReadAttributeListLongOctetStringForChunkedRead_135(); break; case 136: - ChipLogProgress(chipTool, " ***** Test Step 136 : Read attribute EPOCH_US Default Value\n"); - err = TestReadAttributeEpochUsDefaultValue_136(); + ChipLogProgress(chipTool, " ***** Test Step 136 : Write attribute LIST_LONG_OCTET_STRING (for chunked write)\n"); + err = TestWriteAttributeListLongOctetStringForChunkedWrite_136(); break; case 137: - ChipLogProgress(chipTool, " ***** Test Step 137 : Write attribute EPOCH_US Max Value\n"); - err = TestWriteAttributeEpochUsMaxValue_137(); + ChipLogProgress(chipTool, " ***** Test Step 137 : Read attribute EPOCH_US Default Value\n"); + err = TestReadAttributeEpochUsDefaultValue_137(); break; case 138: - ChipLogProgress(chipTool, " ***** Test Step 138 : Read attribute EPOCH_US Max Value\n"); - err = TestReadAttributeEpochUsMaxValue_138(); + ChipLogProgress(chipTool, " ***** Test Step 138 : Write attribute EPOCH_US Max Value\n"); + err = TestWriteAttributeEpochUsMaxValue_138(); break; case 139: - ChipLogProgress(chipTool, " ***** Test Step 139 : Write attribute EPOCH_US Min Value\n"); - err = TestWriteAttributeEpochUsMinValue_139(); + ChipLogProgress(chipTool, " ***** Test Step 139 : Read attribute EPOCH_US Max Value\n"); + err = TestReadAttributeEpochUsMaxValue_139(); break; case 140: - ChipLogProgress(chipTool, " ***** Test Step 140 : Read attribute EPOCH_US Min Value\n"); - err = TestReadAttributeEpochUsMinValue_140(); + ChipLogProgress(chipTool, " ***** Test Step 140 : Write attribute EPOCH_US Min Value\n"); + err = TestWriteAttributeEpochUsMinValue_140(); break; case 141: - ChipLogProgress(chipTool, " ***** Test Step 141 : Read attribute EPOCH_S Default Value\n"); - err = TestReadAttributeEpochSDefaultValue_141(); + ChipLogProgress(chipTool, " ***** Test Step 141 : Read attribute EPOCH_US Min Value\n"); + err = TestReadAttributeEpochUsMinValue_141(); break; case 142: - ChipLogProgress(chipTool, " ***** Test Step 142 : Write attribute EPOCH_S Max Value\n"); - err = TestWriteAttributeEpochSMaxValue_142(); + ChipLogProgress(chipTool, " ***** Test Step 142 : Read attribute EPOCH_S Default Value\n"); + err = TestReadAttributeEpochSDefaultValue_142(); break; case 143: - ChipLogProgress(chipTool, " ***** Test Step 143 : Read attribute EPOCH_S Max Value\n"); - err = TestReadAttributeEpochSMaxValue_143(); + ChipLogProgress(chipTool, " ***** Test Step 143 : Write attribute EPOCH_S Max Value\n"); + err = TestWriteAttributeEpochSMaxValue_143(); break; case 144: - ChipLogProgress(chipTool, " ***** Test Step 144 : Write attribute EPOCH_S Min Value\n"); - err = TestWriteAttributeEpochSMinValue_144(); + ChipLogProgress(chipTool, " ***** Test Step 144 : Read attribute EPOCH_S Max Value\n"); + err = TestReadAttributeEpochSMaxValue_144(); break; case 145: - ChipLogProgress(chipTool, " ***** Test Step 145 : Read attribute EPOCH_S Min Value\n"); - err = TestReadAttributeEpochSMinValue_145(); + ChipLogProgress(chipTool, " ***** Test Step 145 : Write attribute EPOCH_S Min Value\n"); + err = TestWriteAttributeEpochSMinValue_145(); break; case 146: - ChipLogProgress(chipTool, " ***** Test Step 146 : Read attribute UNSUPPORTED\n"); - err = TestReadAttributeUnsupported_146(); + ChipLogProgress(chipTool, " ***** Test Step 146 : Read attribute EPOCH_S Min Value\n"); + err = TestReadAttributeEpochSMinValue_146(); break; case 147: - ChipLogProgress(chipTool, " ***** Test Step 147 : Writeattribute UNSUPPORTED\n"); - err = TestWriteattributeUnsupported_147(); + ChipLogProgress(chipTool, " ***** Test Step 147 : Read attribute UNSUPPORTED\n"); + err = TestReadAttributeUnsupported_147(); break; case 148: - ChipLogProgress(chipTool, " ***** Test Step 148 : Send Test Command to unsupported endpoint\n"); - err = TestSendTestCommandToUnsupportedEndpoint_148(); + ChipLogProgress(chipTool, " ***** Test Step 148 : Writeattribute UNSUPPORTED\n"); + err = TestWriteattributeUnsupported_148(); break; case 149: - ChipLogProgress(chipTool, " ***** Test Step 149 : Send Test Command to unsupported cluster\n"); - err = TestSendTestCommandToUnsupportedCluster_149(); + ChipLogProgress(chipTool, " ***** Test Step 149 : Send Test Command to unsupported endpoint\n"); + err = TestSendTestCommandToUnsupportedEndpoint_149(); break; case 150: - ChipLogProgress(chipTool, " ***** Test Step 150 : Read attribute vendor_id Default Value\n"); - err = TestReadAttributeVendorIdDefaultValue_150(); + ChipLogProgress(chipTool, " ***** Test Step 150 : Send Test Command to unsupported cluster\n"); + err = TestSendTestCommandToUnsupportedCluster_150(); break; case 151: - ChipLogProgress(chipTool, " ***** Test Step 151 : Write attribute vendor_id\n"); - err = TestWriteAttributeVendorId_151(); + ChipLogProgress(chipTool, " ***** Test Step 151 : Read attribute vendor_id Default Value\n"); + err = TestReadAttributeVendorIdDefaultValue_151(); break; case 152: - ChipLogProgress(chipTool, " ***** Test Step 152 : Read attribute vendor_id\n"); - err = TestReadAttributeVendorId_152(); + ChipLogProgress(chipTool, " ***** Test Step 152 : Write attribute vendor_id\n"); + err = TestWriteAttributeVendorId_152(); break; case 153: - ChipLogProgress(chipTool, " ***** Test Step 153 : Restore attribute vendor_id\n"); - err = TestRestoreAttributeVendorId_153(); + ChipLogProgress(chipTool, " ***** Test Step 153 : Read attribute vendor_id\n"); + err = TestReadAttributeVendorId_153(); break; case 154: - ChipLogProgress(chipTool, " ***** Test Step 154 : Send a command with a vendor_id and enum\n"); - err = TestSendACommandWithAVendorIdAndEnum_154(); + ChipLogProgress(chipTool, " ***** Test Step 154 : Restore attribute vendor_id\n"); + err = TestRestoreAttributeVendorId_154(); break; case 155: - ChipLogProgress(chipTool, " ***** Test Step 155 : Send a command with a vendor_id and invalid enum\n"); - err = TestSendACommandWithAVendorIdAndInvalidEnum_155(); + ChipLogProgress(chipTool, " ***** Test Step 155 : Send a command with a vendor_id and enum\n"); + err = TestSendACommandWithAVendorIdAndEnum_155(); break; case 156: - ChipLogProgress(chipTool, " ***** Test Step 156 : Send Test Command With Struct Argument and arg1.b is true\n"); - err = TestSendTestCommandWithStructArgumentAndArg1bIsTrue_156(); + ChipLogProgress(chipTool, " ***** Test Step 156 : Send a command with a vendor_id and invalid enum\n"); + err = TestSendACommandWithAVendorIdAndInvalidEnum_156(); break; case 157: - ChipLogProgress(chipTool, " ***** Test Step 157 : Send Test Command With Struct Argument and arg1.b is false\n"); - err = TestSendTestCommandWithStructArgumentAndArg1bIsFalse_157(); + ChipLogProgress(chipTool, " ***** Test Step 157 : Send Test Command With Struct Argument and arg1.b is true\n"); + err = TestSendTestCommandWithStructArgumentAndArg1bIsTrue_157(); break; case 158: - ChipLogProgress( - chipTool, " ***** Test Step 158 : Send Test Command With Nested Struct Argument and arg1.c.b is true\n"); - err = TestSendTestCommandWithNestedStructArgumentAndArg1cbIsTrue_158(); + ChipLogProgress(chipTool, " ***** Test Step 158 : Send Test Command With Struct Argument and arg1.b is false\n"); + err = TestSendTestCommandWithStructArgumentAndArg1bIsFalse_158(); break; case 159: - ChipLogProgress(chipTool, " ***** Test Step 159 : Send Test Command With Nested Struct Argument arg1.c.b is false\n"); - err = TestSendTestCommandWithNestedStructArgumentArg1cbIsFalse_159(); + ChipLogProgress( + chipTool, " ***** Test Step 159 : Send Test Command With Nested Struct Argument and arg1.c.b is true\n"); + err = TestSendTestCommandWithNestedStructArgumentAndArg1cbIsTrue_159(); break; case 160: - ChipLogProgress(chipTool, - " ***** Test Step 160 : Send Test Command With Nested Struct List Argument and all fields b of arg1.d are true\n"); - err = TestSendTestCommandWithNestedStructListArgumentAndAllFieldsBOfArg1dAreTrue_160(); + ChipLogProgress(chipTool, " ***** Test Step 160 : Send Test Command With Nested Struct Argument arg1.c.b is false\n"); + err = TestSendTestCommandWithNestedStructArgumentArg1cbIsFalse_160(); break; case 161: ChipLogProgress(chipTool, - " ***** Test Step 161 : Send Test Command With Nested Struct List Argument and some fields b of arg1.d are " - "false\n"); - err = TestSendTestCommandWithNestedStructListArgumentAndSomeFieldsBOfArg1dAreFalse_161(); + " ***** Test Step 161 : Send Test Command With Nested Struct List Argument and all fields b of arg1.d are true\n"); + err = TestSendTestCommandWithNestedStructListArgumentAndAllFieldsBOfArg1dAreTrue_161(); break; case 162: - ChipLogProgress(chipTool, " ***** Test Step 162 : Send Test Command With Struct Argument and see what we get back\n"); - err = TestSendTestCommandWithStructArgumentAndSeeWhatWeGetBack_162(); + ChipLogProgress(chipTool, + " ***** Test Step 162 : Send Test Command With Nested Struct List Argument and some fields b of arg1.d are " + "false\n"); + err = TestSendTestCommandWithNestedStructListArgumentAndSomeFieldsBOfArg1dAreFalse_162(); break; case 163: - ChipLogProgress(chipTool, " ***** Test Step 163 : Send Test Command With List of INT8U and none of them is set to 0\n"); - err = TestSendTestCommandWithListOfInt8uAndNoneOfThemIsSetTo0_163(); + ChipLogProgress(chipTool, " ***** Test Step 163 : Send Test Command With Struct Argument and see what we get back\n"); + err = TestSendTestCommandWithStructArgumentAndSeeWhatWeGetBack_163(); break; case 164: - ChipLogProgress(chipTool, " ***** Test Step 164 : Send Test Command With List of INT8U and one of them is set to 0\n"); - err = TestSendTestCommandWithListOfInt8uAndOneOfThemIsSetTo0_164(); + ChipLogProgress(chipTool, " ***** Test Step 164 : Send Test Command With List of INT8U and none of them is set to 0\n"); + err = TestSendTestCommandWithListOfInt8uAndNoneOfThemIsSetTo0_164(); break; case 165: - ChipLogProgress(chipTool, " ***** Test Step 165 : Send Test Command With List of INT8U and get it reversed\n"); - err = TestSendTestCommandWithListOfInt8uAndGetItReversed_165(); + ChipLogProgress(chipTool, " ***** Test Step 165 : Send Test Command With List of INT8U and one of them is set to 0\n"); + err = TestSendTestCommandWithListOfInt8uAndOneOfThemIsSetTo0_165(); break; case 166: - ChipLogProgress( - chipTool, " ***** Test Step 166 : Send Test Command With empty List of INT8U and get an empty list back\n"); - err = TestSendTestCommandWithEmptyListOfInt8uAndGetAnEmptyListBack_166(); + ChipLogProgress(chipTool, " ***** Test Step 166 : Send Test Command With List of INT8U and get it reversed\n"); + err = TestSendTestCommandWithListOfInt8uAndGetItReversed_166(); break; case 167: - ChipLogProgress(chipTool, - " ***** Test Step 167 : Send Test Command With List of Struct Argument and arg1.b of first item is true\n"); - err = TestSendTestCommandWithListOfStructArgumentAndArg1bOfFirstItemIsTrue_167(); + ChipLogProgress( + chipTool, " ***** Test Step 167 : Send Test Command With empty List of INT8U and get an empty list back\n"); + err = TestSendTestCommandWithEmptyListOfInt8uAndGetAnEmptyListBack_167(); break; case 168: ChipLogProgress(chipTool, - " ***** Test Step 168 : Send Test Command With List of Struct Argument and arg1.b of first item is false\n"); - err = TestSendTestCommandWithListOfStructArgumentAndArg1bOfFirstItemIsFalse_168(); + " ***** Test Step 168 : Send Test Command With List of Struct Argument and arg1.b of first item is true\n"); + err = TestSendTestCommandWithListOfStructArgumentAndArg1bOfFirstItemIsTrue_168(); break; case 169: ChipLogProgress(chipTool, - " ***** Test Step 169 : Send Test Command With List of Nested Struct List Argument and all fields b of elements of " - "arg1.d are true\n"); - err = TestSendTestCommandWithListOfNestedStructListArgumentAndAllFieldsBOfElementsOfArg1dAreTrue_169(); + " ***** Test Step 169 : Send Test Command With List of Struct Argument and arg1.b of first item is false\n"); + err = TestSendTestCommandWithListOfStructArgumentAndArg1bOfFirstItemIsFalse_169(); break; case 170: ChipLogProgress(chipTool, - " ***** Test Step 170 : Send Test Command With Nested Struct List Argument and some fields b of elements of arg1.d " - "are false\n"); - err = TestSendTestCommandWithNestedStructListArgumentAndSomeFieldsBOfElementsOfArg1dAreFalse_170(); + " ***** Test Step 170 : Send Test Command With List of Nested Struct List Argument and all fields b of elements of " + "arg1.d are true\n"); + err = TestSendTestCommandWithListOfNestedStructListArgumentAndAllFieldsBOfElementsOfArg1dAreTrue_170(); break; case 171: - ChipLogProgress( - chipTool, " ***** Test Step 171 : Write attribute LIST With List of INT8U and none of them is set to 0\n"); - err = TestWriteAttributeListWithListOfInt8uAndNoneOfThemIsSetTo0_171(); + ChipLogProgress(chipTool, + " ***** Test Step 171 : Send Test Command With Nested Struct List Argument and some fields b of elements of arg1.d " + "are false\n"); + err = TestSendTestCommandWithNestedStructListArgumentAndSomeFieldsBOfElementsOfArg1dAreFalse_171(); break; case 172: - ChipLogProgress(chipTool, " ***** Test Step 172 : Read attribute LIST With List of INT8U\n"); - err = TestReadAttributeListWithListOfInt8u_172(); + ChipLogProgress( + chipTool, " ***** Test Step 172 : Write attribute LIST With List of INT8U and none of them is set to 0\n"); + err = TestWriteAttributeListWithListOfInt8uAndNoneOfThemIsSetTo0_172(); break; case 173: - ChipLogProgress(chipTool, " ***** Test Step 173 : Write attribute LIST With List of OCTET_STRING\n"); - err = TestWriteAttributeListWithListOfOctetString_173(); + ChipLogProgress(chipTool, " ***** Test Step 173 : Read attribute LIST With List of INT8U\n"); + err = TestReadAttributeListWithListOfInt8u_173(); break; case 174: - ChipLogProgress(chipTool, " ***** Test Step 174 : Read attribute LIST With List of OCTET_STRING\n"); - err = TestReadAttributeListWithListOfOctetString_174(); + ChipLogProgress(chipTool, " ***** Test Step 174 : Write attribute LIST With List of OCTET_STRING\n"); + err = TestWriteAttributeListWithListOfOctetString_174(); break; case 175: - ChipLogProgress(chipTool, " ***** Test Step 175 : Write attribute LIST With List of LIST_STRUCT_OCTET_STRING\n"); - err = TestWriteAttributeListWithListOfListStructOctetString_175(); + ChipLogProgress(chipTool, " ***** Test Step 175 : Read attribute LIST With List of OCTET_STRING\n"); + err = TestReadAttributeListWithListOfOctetString_175(); break; case 176: - ChipLogProgress(chipTool, " ***** Test Step 176 : Read attribute LIST With List of LIST_STRUCT_OCTET_STRING\n"); - err = TestReadAttributeListWithListOfListStructOctetString_176(); + ChipLogProgress(chipTool, " ***** Test Step 176 : Write attribute LIST With List of LIST_STRUCT_OCTET_STRING\n"); + err = TestWriteAttributeListWithListOfListStructOctetString_176(); break; case 177: - ChipLogProgress(chipTool, " ***** Test Step 177 : Send Test Command with optional arg set.\n"); - err = TestSendTestCommandWithOptionalArgSet_177(); + ChipLogProgress(chipTool, " ***** Test Step 177 : Read attribute LIST With List of LIST_STRUCT_OCTET_STRING\n"); + err = TestReadAttributeListWithListOfListStructOctetString_177(); break; case 178: - ChipLogProgress(chipTool, " ***** Test Step 178 : Send Test Command without its optional arg.\n"); - err = TestSendTestCommandWithoutItsOptionalArg_178(); + ChipLogProgress(chipTool, " ***** Test Step 178 : Send Test Command with optional arg set.\n"); + err = TestSendTestCommandWithOptionalArgSet_178(); break; case 179: - ChipLogProgress(chipTool, " ***** Test Step 179 : Read list of structs containing nullables and optionals\n"); - err = TestReadListOfStructsContainingNullablesAndOptionals_179(); + ChipLogProgress(chipTool, " ***** Test Step 179 : Send Test Command without its optional arg.\n"); + err = TestSendTestCommandWithoutItsOptionalArg_179(); break; case 180: - ChipLogProgress(chipTool, " ***** Test Step 180 : Write list of structs containing nullables and optionals\n"); - err = TestWriteListOfStructsContainingNullablesAndOptionals_180(); + ChipLogProgress(chipTool, " ***** Test Step 180 : Read list of structs containing nullables and optionals\n"); + err = TestReadListOfStructsContainingNullablesAndOptionals_180(); break; case 181: - ChipLogProgress( - chipTool, " ***** Test Step 181 : Read list of structs containing nullables and optionals after writing\n"); - err = TestReadListOfStructsContainingNullablesAndOptionalsAfterWriting_181(); + ChipLogProgress(chipTool, " ***** Test Step 181 : Write list of structs containing nullables and optionals\n"); + err = TestWriteListOfStructsContainingNullablesAndOptionals_181(); break; case 182: - ChipLogProgress(chipTool, " ***** Test Step 182 : Write attribute NULLABLE_BOOLEAN null\n"); - err = TestWriteAttributeNullableBooleanNull_182(); + ChipLogProgress( + chipTool, " ***** Test Step 182 : Read list of structs containing nullables and optionals after writing\n"); + err = TestReadListOfStructsContainingNullablesAndOptionalsAfterWriting_182(); break; case 183: - ChipLogProgress(chipTool, " ***** Test Step 183 : Read attribute NULLABLE_BOOLEAN null\n"); - err = TestReadAttributeNullableBooleanNull_183(); + ChipLogProgress(chipTool, " ***** Test Step 183 : Write attribute NULLABLE_BOOLEAN null\n"); + err = TestWriteAttributeNullableBooleanNull_183(); break; case 184: - ChipLogProgress(chipTool, " ***** Test Step 184 : Write attribute NULLABLE_BOOLEAN True\n"); - err = TestWriteAttributeNullableBooleanTrue_184(); + ChipLogProgress(chipTool, " ***** Test Step 184 : Read attribute NULLABLE_BOOLEAN null\n"); + err = TestReadAttributeNullableBooleanNull_184(); break; case 185: - ChipLogProgress(chipTool, " ***** Test Step 185 : Read attribute NULLABLE_BOOLEAN True\n"); - err = TestReadAttributeNullableBooleanTrue_185(); + ChipLogProgress(chipTool, " ***** Test Step 185 : Write attribute NULLABLE_BOOLEAN True\n"); + err = TestWriteAttributeNullableBooleanTrue_185(); break; case 186: - ChipLogProgress(chipTool, " ***** Test Step 186 : Read attribute NULLABLE_BOOLEAN not null\n"); - err = TestReadAttributeNullableBooleanNotNull_186(); + ChipLogProgress(chipTool, " ***** Test Step 186 : Read attribute NULLABLE_BOOLEAN True\n"); + err = TestReadAttributeNullableBooleanTrue_186(); break; case 187: - ChipLogProgress(chipTool, " ***** Test Step 187 : Write attribute NULLABLE_BITMAP8 Max Value\n"); - err = TestWriteAttributeNullableBitmap8MaxValue_187(); + ChipLogProgress(chipTool, " ***** Test Step 187 : Read attribute NULLABLE_BOOLEAN not null\n"); + err = TestReadAttributeNullableBooleanNotNull_187(); break; case 188: - ChipLogProgress(chipTool, " ***** Test Step 188 : Read attribute NULLABLE_BITMAP8 Max Value\n"); - err = TestReadAttributeNullableBitmap8MaxValue_188(); + ChipLogProgress(chipTool, " ***** Test Step 188 : Write attribute NULLABLE_BITMAP8 Max Value\n"); + err = TestWriteAttributeNullableBitmap8MaxValue_188(); break; case 189: - ChipLogProgress(chipTool, " ***** Test Step 189 : Write attribute NULLABLE_BITMAP8 Invalid Value\n"); - err = TestWriteAttributeNullableBitmap8InvalidValue_189(); + ChipLogProgress(chipTool, " ***** Test Step 189 : Read attribute NULLABLE_BITMAP8 Max Value\n"); + err = TestReadAttributeNullableBitmap8MaxValue_189(); break; case 190: - ChipLogProgress(chipTool, " ***** Test Step 190 : Read attribute NULLABLE_BITMAP8 unchanged Value\n"); - err = TestReadAttributeNullableBitmap8UnchangedValue_190(); + ChipLogProgress(chipTool, " ***** Test Step 190 : Write attribute NULLABLE_BITMAP8 Invalid Value\n"); + err = TestWriteAttributeNullableBitmap8InvalidValue_190(); break; case 191: - ChipLogProgress(chipTool, " ***** Test Step 191 : Write attribute NULLABLE_BITMAP8 null Value\n"); - err = TestWriteAttributeNullableBitmap8NullValue_191(); + ChipLogProgress(chipTool, " ***** Test Step 191 : Read attribute NULLABLE_BITMAP8 unchanged Value\n"); + err = TestReadAttributeNullableBitmap8UnchangedValue_191(); break; case 192: - ChipLogProgress(chipTool, " ***** Test Step 192 : Read attribute NULLABLE_BITMAP8 null Value\n"); - err = TestReadAttributeNullableBitmap8NullValue_192(); + ChipLogProgress(chipTool, " ***** Test Step 192 : Write attribute NULLABLE_BITMAP8 null Value\n"); + err = TestWriteAttributeNullableBitmap8NullValue_192(); break; case 193: - ChipLogProgress(chipTool, " ***** Test Step 193 : Read attribute NULLABLE_BITMAP8 not 254 Value\n"); - err = TestReadAttributeNullableBitmap8Not254Value_193(); + ChipLogProgress(chipTool, " ***** Test Step 193 : Read attribute NULLABLE_BITMAP8 null Value\n"); + err = TestReadAttributeNullableBitmap8NullValue_193(); break; case 194: - ChipLogProgress(chipTool, " ***** Test Step 194 : Write attribute NULLABLE_BITMAP16 Max Value\n"); - err = TestWriteAttributeNullableBitmap16MaxValue_194(); + ChipLogProgress(chipTool, " ***** Test Step 194 : Read attribute NULLABLE_BITMAP8 not 254 Value\n"); + err = TestReadAttributeNullableBitmap8Not254Value_194(); break; case 195: - ChipLogProgress(chipTool, " ***** Test Step 195 : Read attribute NULLABLE_BITMAP16 Max Value\n"); - err = TestReadAttributeNullableBitmap16MaxValue_195(); + ChipLogProgress(chipTool, " ***** Test Step 195 : Write attribute NULLABLE_BITMAP16 Max Value\n"); + err = TestWriteAttributeNullableBitmap16MaxValue_195(); break; case 196: - ChipLogProgress(chipTool, " ***** Test Step 196 : Write attribute NULLABLE_BITMAP16 Invalid Value\n"); - err = TestWriteAttributeNullableBitmap16InvalidValue_196(); + ChipLogProgress(chipTool, " ***** Test Step 196 : Read attribute NULLABLE_BITMAP16 Max Value\n"); + err = TestReadAttributeNullableBitmap16MaxValue_196(); break; case 197: - ChipLogProgress(chipTool, " ***** Test Step 197 : Read attribute NULLABLE_BITMAP16 unchanged Value\n"); - err = TestReadAttributeNullableBitmap16UnchangedValue_197(); + ChipLogProgress(chipTool, " ***** Test Step 197 : Write attribute NULLABLE_BITMAP16 Invalid Value\n"); + err = TestWriteAttributeNullableBitmap16InvalidValue_197(); break; case 198: - ChipLogProgress(chipTool, " ***** Test Step 198 : Write attribute NULLABLE_BITMAP16 null Value\n"); - err = TestWriteAttributeNullableBitmap16NullValue_198(); + ChipLogProgress(chipTool, " ***** Test Step 198 : Read attribute NULLABLE_BITMAP16 unchanged Value\n"); + err = TestReadAttributeNullableBitmap16UnchangedValue_198(); break; case 199: - ChipLogProgress(chipTool, " ***** Test Step 199 : Read attribute NULLABLE_BITMAP16 null Value\n"); - err = TestReadAttributeNullableBitmap16NullValue_199(); + ChipLogProgress(chipTool, " ***** Test Step 199 : Write attribute NULLABLE_BITMAP16 null Value\n"); + err = TestWriteAttributeNullableBitmap16NullValue_199(); break; case 200: - ChipLogProgress(chipTool, " ***** Test Step 200 : Write attribute NULLABLE_BITMAP32 Max Value\n"); - err = TestWriteAttributeNullableBitmap32MaxValue_200(); + ChipLogProgress(chipTool, " ***** Test Step 200 : Read attribute NULLABLE_BITMAP16 null Value\n"); + err = TestReadAttributeNullableBitmap16NullValue_200(); break; case 201: - ChipLogProgress(chipTool, " ***** Test Step 201 : Read attribute NULLABLE_BITMAP32 Max Value\n"); - err = TestReadAttributeNullableBitmap32MaxValue_201(); + ChipLogProgress(chipTool, " ***** Test Step 201 : Write attribute NULLABLE_BITMAP32 Max Value\n"); + err = TestWriteAttributeNullableBitmap32MaxValue_201(); break; case 202: - ChipLogProgress(chipTool, " ***** Test Step 202 : Write attribute NULLABLE_BITMAP32 Invalid Value\n"); - err = TestWriteAttributeNullableBitmap32InvalidValue_202(); + ChipLogProgress(chipTool, " ***** Test Step 202 : Read attribute NULLABLE_BITMAP32 Max Value\n"); + err = TestReadAttributeNullableBitmap32MaxValue_202(); break; case 203: - ChipLogProgress(chipTool, " ***** Test Step 203 : Read attribute NULLABLE_BITMAP32 unchanged Value\n"); - err = TestReadAttributeNullableBitmap32UnchangedValue_203(); + ChipLogProgress(chipTool, " ***** Test Step 203 : Write attribute NULLABLE_BITMAP32 Invalid Value\n"); + err = TestWriteAttributeNullableBitmap32InvalidValue_203(); break; case 204: - ChipLogProgress(chipTool, " ***** Test Step 204 : Write attribute NULLABLE_BITMAP32 null Value\n"); - err = TestWriteAttributeNullableBitmap32NullValue_204(); + ChipLogProgress(chipTool, " ***** Test Step 204 : Read attribute NULLABLE_BITMAP32 unchanged Value\n"); + err = TestReadAttributeNullableBitmap32UnchangedValue_204(); break; case 205: - ChipLogProgress(chipTool, " ***** Test Step 205 : Read attribute NULLABLE_BITMAP32 null Value\n"); - err = TestReadAttributeNullableBitmap32NullValue_205(); + ChipLogProgress(chipTool, " ***** Test Step 205 : Write attribute NULLABLE_BITMAP32 null Value\n"); + err = TestWriteAttributeNullableBitmap32NullValue_205(); break; case 206: - ChipLogProgress(chipTool, " ***** Test Step 206 : Write attribute NULLABLE_BITMAP64 Max Value\n"); - err = TestWriteAttributeNullableBitmap64MaxValue_206(); + ChipLogProgress(chipTool, " ***** Test Step 206 : Read attribute NULLABLE_BITMAP32 null Value\n"); + err = TestReadAttributeNullableBitmap32NullValue_206(); break; case 207: - ChipLogProgress(chipTool, " ***** Test Step 207 : Read attribute NULLABLE_BITMAP64 Max Value\n"); - err = TestReadAttributeNullableBitmap64MaxValue_207(); + ChipLogProgress(chipTool, " ***** Test Step 207 : Write attribute NULLABLE_BITMAP64 Max Value\n"); + err = TestWriteAttributeNullableBitmap64MaxValue_207(); break; case 208: - ChipLogProgress(chipTool, " ***** Test Step 208 : Write attribute NULLABLE_BITMAP64 Invalid Value\n"); - err = TestWriteAttributeNullableBitmap64InvalidValue_208(); + ChipLogProgress(chipTool, " ***** Test Step 208 : Read attribute NULLABLE_BITMAP64 Max Value\n"); + err = TestReadAttributeNullableBitmap64MaxValue_208(); break; case 209: - ChipLogProgress(chipTool, " ***** Test Step 209 : Read attribute NULLABLE_BITMAP64 unchanged Value\n"); - err = TestReadAttributeNullableBitmap64UnchangedValue_209(); + ChipLogProgress(chipTool, " ***** Test Step 209 : Write attribute NULLABLE_BITMAP64 Invalid Value\n"); + err = TestWriteAttributeNullableBitmap64InvalidValue_209(); break; case 210: - ChipLogProgress(chipTool, " ***** Test Step 210 : Write attribute NULLABLE_BITMAP64 null Value\n"); - err = TestWriteAttributeNullableBitmap64NullValue_210(); + ChipLogProgress(chipTool, " ***** Test Step 210 : Read attribute NULLABLE_BITMAP64 unchanged Value\n"); + err = TestReadAttributeNullableBitmap64UnchangedValue_210(); break; case 211: - ChipLogProgress(chipTool, " ***** Test Step 211 : Read attribute NULLABLE_BITMAP64 null Value\n"); - err = TestReadAttributeNullableBitmap64NullValue_211(); + ChipLogProgress(chipTool, " ***** Test Step 211 : Write attribute NULLABLE_BITMAP64 null Value\n"); + err = TestWriteAttributeNullableBitmap64NullValue_211(); break; case 212: - ChipLogProgress(chipTool, " ***** Test Step 212 : Write attribute NULLABLE_INT8U Min Value\n"); - err = TestWriteAttributeNullableInt8uMinValue_212(); + ChipLogProgress(chipTool, " ***** Test Step 212 : Read attribute NULLABLE_BITMAP64 null Value\n"); + err = TestReadAttributeNullableBitmap64NullValue_212(); break; case 213: - ChipLogProgress(chipTool, " ***** Test Step 213 : Read attribute NULLABLE_INT8U Min Value\n"); - err = TestReadAttributeNullableInt8uMinValue_213(); + ChipLogProgress(chipTool, " ***** Test Step 213 : Write attribute NULLABLE_INT8U Min Value\n"); + err = TestWriteAttributeNullableInt8uMinValue_213(); break; case 214: - ChipLogProgress(chipTool, " ***** Test Step 214 : Write attribute NULLABLE_INT8U Max Value\n"); - err = TestWriteAttributeNullableInt8uMaxValue_214(); + ChipLogProgress(chipTool, " ***** Test Step 214 : Read attribute NULLABLE_INT8U Min Value\n"); + err = TestReadAttributeNullableInt8uMinValue_214(); break; case 215: - ChipLogProgress(chipTool, " ***** Test Step 215 : Read attribute NULLABLE_INT8U Max Value\n"); - err = TestReadAttributeNullableInt8uMaxValue_215(); + ChipLogProgress(chipTool, " ***** Test Step 215 : Write attribute NULLABLE_INT8U Max Value\n"); + err = TestWriteAttributeNullableInt8uMaxValue_215(); break; case 216: - ChipLogProgress(chipTool, " ***** Test Step 216 : Write attribute NULLABLE_INT8U Invalid Value\n"); - err = TestWriteAttributeNullableInt8uInvalidValue_216(); + ChipLogProgress(chipTool, " ***** Test Step 216 : Read attribute NULLABLE_INT8U Max Value\n"); + err = TestReadAttributeNullableInt8uMaxValue_216(); break; case 217: - ChipLogProgress(chipTool, " ***** Test Step 217 : Read attribute NULLABLE_INT8U unchanged Value\n"); - err = TestReadAttributeNullableInt8uUnchangedValue_217(); + ChipLogProgress(chipTool, " ***** Test Step 217 : Write attribute NULLABLE_INT8U Invalid Value\n"); + err = TestWriteAttributeNullableInt8uInvalidValue_217(); break; case 218: - ChipLogProgress(chipTool, " ***** Test Step 218 : Read attribute NULLABLE_INT8U unchanged Value with constraint\n"); - err = TestReadAttributeNullableInt8uUnchangedValueWithConstraint_218(); + ChipLogProgress(chipTool, " ***** Test Step 218 : Read attribute NULLABLE_INT8U unchanged Value\n"); + err = TestReadAttributeNullableInt8uUnchangedValue_218(); break; case 219: - ChipLogProgress(chipTool, " ***** Test Step 219 : Write attribute NULLABLE_INT8U null Value\n"); - err = TestWriteAttributeNullableInt8uNullValue_219(); + ChipLogProgress(chipTool, " ***** Test Step 219 : Read attribute NULLABLE_INT8U unchanged Value with constraint\n"); + err = TestReadAttributeNullableInt8uUnchangedValueWithConstraint_219(); break; case 220: - ChipLogProgress(chipTool, " ***** Test Step 220 : Read attribute NULLABLE_INT8U null Value\n"); - err = TestReadAttributeNullableInt8uNullValue_220(); + ChipLogProgress(chipTool, " ***** Test Step 220 : Write attribute NULLABLE_INT8U null Value\n"); + err = TestWriteAttributeNullableInt8uNullValue_220(); break; case 221: - ChipLogProgress(chipTool, " ***** Test Step 221 : Read attribute NULLABLE_INT8U null Value & range\n"); - err = TestReadAttributeNullableInt8uNullValueRange_221(); + ChipLogProgress(chipTool, " ***** Test Step 221 : Read attribute NULLABLE_INT8U null Value\n"); + err = TestReadAttributeNullableInt8uNullValue_221(); break; case 222: - ChipLogProgress(chipTool, " ***** Test Step 222 : Read attribute NULLABLE_INT8U null Value & not\n"); - err = TestReadAttributeNullableInt8uNullValueNot_222(); + ChipLogProgress(chipTool, " ***** Test Step 222 : Read attribute NULLABLE_INT8U null Value & range\n"); + err = TestReadAttributeNullableInt8uNullValueRange_222(); break; case 223: - ChipLogProgress(chipTool, " ***** Test Step 223 : Write attribute NULLABLE_INT8U Value\n"); - err = TestWriteAttributeNullableInt8uValue_223(); + ChipLogProgress(chipTool, " ***** Test Step 223 : Read attribute NULLABLE_INT8U null Value & not\n"); + err = TestReadAttributeNullableInt8uNullValueNot_223(); break; case 224: - ChipLogProgress(chipTool, " ***** Test Step 224 : Read attribute NULLABLE_INT8U Value in range\n"); - err = TestReadAttributeNullableInt8uValueInRange_224(); + ChipLogProgress(chipTool, " ***** Test Step 224 : Write attribute NULLABLE_INT8U Value\n"); + err = TestWriteAttributeNullableInt8uValue_224(); break; case 225: - ChipLogProgress(chipTool, " ***** Test Step 225 : Read attribute NULLABLE_INT8U notValue OK\n"); - err = TestReadAttributeNullableInt8uNotValueOk_225(); + ChipLogProgress(chipTool, " ***** Test Step 225 : Read attribute NULLABLE_INT8U Value in range\n"); + err = TestReadAttributeNullableInt8uValueInRange_225(); break; case 226: - ChipLogProgress(chipTool, " ***** Test Step 226 : Write attribute NULLABLE_INT16U Min Value\n"); - err = TestWriteAttributeNullableInt16uMinValue_226(); + ChipLogProgress(chipTool, " ***** Test Step 226 : Read attribute NULLABLE_INT8U notValue OK\n"); + err = TestReadAttributeNullableInt8uNotValueOk_226(); break; case 227: - ChipLogProgress(chipTool, " ***** Test Step 227 : Read attribute NULLABLE_INT16U Min Value\n"); - err = TestReadAttributeNullableInt16uMinValue_227(); + ChipLogProgress(chipTool, " ***** Test Step 227 : Write attribute NULLABLE_INT16U Min Value\n"); + err = TestWriteAttributeNullableInt16uMinValue_227(); break; case 228: - ChipLogProgress(chipTool, " ***** Test Step 228 : Write attribute NULLABLE_INT16U Max Value\n"); - err = TestWriteAttributeNullableInt16uMaxValue_228(); + ChipLogProgress(chipTool, " ***** Test Step 228 : Read attribute NULLABLE_INT16U Min Value\n"); + err = TestReadAttributeNullableInt16uMinValue_228(); break; case 229: - ChipLogProgress(chipTool, " ***** Test Step 229 : Read attribute NULLABLE_INT16U Max Value\n"); - err = TestReadAttributeNullableInt16uMaxValue_229(); + ChipLogProgress(chipTool, " ***** Test Step 229 : Write attribute NULLABLE_INT16U Max Value\n"); + err = TestWriteAttributeNullableInt16uMaxValue_229(); break; case 230: - ChipLogProgress(chipTool, " ***** Test Step 230 : Write attribute NULLABLE_INT16U Invalid Value\n"); - err = TestWriteAttributeNullableInt16uInvalidValue_230(); + ChipLogProgress(chipTool, " ***** Test Step 230 : Read attribute NULLABLE_INT16U Max Value\n"); + err = TestReadAttributeNullableInt16uMaxValue_230(); break; case 231: - ChipLogProgress(chipTool, " ***** Test Step 231 : Read attribute NULLABLE_INT16U unchanged Value\n"); - err = TestReadAttributeNullableInt16uUnchangedValue_231(); + ChipLogProgress(chipTool, " ***** Test Step 231 : Write attribute NULLABLE_INT16U Invalid Value\n"); + err = TestWriteAttributeNullableInt16uInvalidValue_231(); break; case 232: - ChipLogProgress(chipTool, " ***** Test Step 232 : Write attribute NULLABLE_INT16U null Value\n"); - err = TestWriteAttributeNullableInt16uNullValue_232(); + ChipLogProgress(chipTool, " ***** Test Step 232 : Read attribute NULLABLE_INT16U unchanged Value\n"); + err = TestReadAttributeNullableInt16uUnchangedValue_232(); break; case 233: - ChipLogProgress(chipTool, " ***** Test Step 233 : Read attribute NULLABLE_INT16U null Value\n"); - err = TestReadAttributeNullableInt16uNullValue_233(); + ChipLogProgress(chipTool, " ***** Test Step 233 : Write attribute NULLABLE_INT16U null Value\n"); + err = TestWriteAttributeNullableInt16uNullValue_233(); break; case 234: - ChipLogProgress(chipTool, " ***** Test Step 234 : Read attribute NULLABLE_INT16U null Value & range\n"); - err = TestReadAttributeNullableInt16uNullValueRange_234(); + ChipLogProgress(chipTool, " ***** Test Step 234 : Read attribute NULLABLE_INT16U null Value\n"); + err = TestReadAttributeNullableInt16uNullValue_234(); break; case 235: - ChipLogProgress(chipTool, " ***** Test Step 235 : Read attribute NULLABLE_INT16U null Value & not\n"); - err = TestReadAttributeNullableInt16uNullValueNot_235(); + ChipLogProgress(chipTool, " ***** Test Step 235 : Read attribute NULLABLE_INT16U null Value & range\n"); + err = TestReadAttributeNullableInt16uNullValueRange_235(); break; case 236: - ChipLogProgress(chipTool, " ***** Test Step 236 : Write attribute NULLABLE_INT16U Value\n"); - err = TestWriteAttributeNullableInt16uValue_236(); + ChipLogProgress(chipTool, " ***** Test Step 236 : Read attribute NULLABLE_INT16U null Value & not\n"); + err = TestReadAttributeNullableInt16uNullValueNot_236(); break; case 237: - ChipLogProgress(chipTool, " ***** Test Step 237 : Read attribute NULLABLE_INT16U Value in range\n"); - err = TestReadAttributeNullableInt16uValueInRange_237(); + ChipLogProgress(chipTool, " ***** Test Step 237 : Write attribute NULLABLE_INT16U Value\n"); + err = TestWriteAttributeNullableInt16uValue_237(); break; case 238: - ChipLogProgress(chipTool, " ***** Test Step 238 : Read attribute NULLABLE_INT16U notValue OK\n"); - err = TestReadAttributeNullableInt16uNotValueOk_238(); + ChipLogProgress(chipTool, " ***** Test Step 238 : Read attribute NULLABLE_INT16U Value in range\n"); + err = TestReadAttributeNullableInt16uValueInRange_238(); break; case 239: - ChipLogProgress(chipTool, " ***** Test Step 239 : Write attribute NULLABLE_INT32U Min Value\n"); - err = TestWriteAttributeNullableInt32uMinValue_239(); + ChipLogProgress(chipTool, " ***** Test Step 239 : Read attribute NULLABLE_INT16U notValue OK\n"); + err = TestReadAttributeNullableInt16uNotValueOk_239(); break; case 240: - ChipLogProgress(chipTool, " ***** Test Step 240 : Read attribute NULLABLE_INT32U Min Value\n"); - err = TestReadAttributeNullableInt32uMinValue_240(); + ChipLogProgress(chipTool, " ***** Test Step 240 : Write attribute NULLABLE_INT32U Min Value\n"); + err = TestWriteAttributeNullableInt32uMinValue_240(); break; case 241: - ChipLogProgress(chipTool, " ***** Test Step 241 : Write attribute NULLABLE_INT32U Max Value\n"); - err = TestWriteAttributeNullableInt32uMaxValue_241(); + ChipLogProgress(chipTool, " ***** Test Step 241 : Read attribute NULLABLE_INT32U Min Value\n"); + err = TestReadAttributeNullableInt32uMinValue_241(); break; case 242: - ChipLogProgress(chipTool, " ***** Test Step 242 : Read attribute NULLABLE_INT32U Max Value\n"); - err = TestReadAttributeNullableInt32uMaxValue_242(); + ChipLogProgress(chipTool, " ***** Test Step 242 : Write attribute NULLABLE_INT32U Max Value\n"); + err = TestWriteAttributeNullableInt32uMaxValue_242(); break; case 243: - ChipLogProgress(chipTool, " ***** Test Step 243 : Write attribute NULLABLE_INT32U Invalid Value\n"); - err = TestWriteAttributeNullableInt32uInvalidValue_243(); + ChipLogProgress(chipTool, " ***** Test Step 243 : Read attribute NULLABLE_INT32U Max Value\n"); + err = TestReadAttributeNullableInt32uMaxValue_243(); break; case 244: - ChipLogProgress(chipTool, " ***** Test Step 244 : Read attribute NULLABLE_INT32U unchanged Value\n"); - err = TestReadAttributeNullableInt32uUnchangedValue_244(); + ChipLogProgress(chipTool, " ***** Test Step 244 : Write attribute NULLABLE_INT32U Invalid Value\n"); + err = TestWriteAttributeNullableInt32uInvalidValue_244(); break; case 245: - ChipLogProgress(chipTool, " ***** Test Step 245 : Write attribute NULLABLE_INT32U null Value\n"); - err = TestWriteAttributeNullableInt32uNullValue_245(); + ChipLogProgress(chipTool, " ***** Test Step 245 : Read attribute NULLABLE_INT32U unchanged Value\n"); + err = TestReadAttributeNullableInt32uUnchangedValue_245(); break; case 246: - ChipLogProgress(chipTool, " ***** Test Step 246 : Read attribute NULLABLE_INT32U null Value\n"); - err = TestReadAttributeNullableInt32uNullValue_246(); + ChipLogProgress(chipTool, " ***** Test Step 246 : Write attribute NULLABLE_INT32U null Value\n"); + err = TestWriteAttributeNullableInt32uNullValue_246(); break; case 247: - ChipLogProgress(chipTool, " ***** Test Step 247 : Read attribute NULLABLE_INT32U null Value & range\n"); - err = TestReadAttributeNullableInt32uNullValueRange_247(); + ChipLogProgress(chipTool, " ***** Test Step 247 : Read attribute NULLABLE_INT32U null Value\n"); + err = TestReadAttributeNullableInt32uNullValue_247(); break; case 248: - ChipLogProgress(chipTool, " ***** Test Step 248 : Read attribute NULLABLE_INT32U null Value & not\n"); - err = TestReadAttributeNullableInt32uNullValueNot_248(); + ChipLogProgress(chipTool, " ***** Test Step 248 : Read attribute NULLABLE_INT32U null Value & range\n"); + err = TestReadAttributeNullableInt32uNullValueRange_248(); break; case 249: - ChipLogProgress(chipTool, " ***** Test Step 249 : Write attribute NULLABLE_INT32U Value\n"); - err = TestWriteAttributeNullableInt32uValue_249(); + ChipLogProgress(chipTool, " ***** Test Step 249 : Read attribute NULLABLE_INT32U null Value & not\n"); + err = TestReadAttributeNullableInt32uNullValueNot_249(); break; case 250: - ChipLogProgress(chipTool, " ***** Test Step 250 : Read attribute NULLABLE_INT32U Value in range\n"); - err = TestReadAttributeNullableInt32uValueInRange_250(); + ChipLogProgress(chipTool, " ***** Test Step 250 : Write attribute NULLABLE_INT32U Value\n"); + err = TestWriteAttributeNullableInt32uValue_250(); break; case 251: - ChipLogProgress(chipTool, " ***** Test Step 251 : Read attribute NULLABLE_INT32U notValue OK\n"); - err = TestReadAttributeNullableInt32uNotValueOk_251(); + ChipLogProgress(chipTool, " ***** Test Step 251 : Read attribute NULLABLE_INT32U Value in range\n"); + err = TestReadAttributeNullableInt32uValueInRange_251(); break; case 252: - ChipLogProgress(chipTool, " ***** Test Step 252 : Write attribute NULLABLE_INT64U Min Value\n"); - err = TestWriteAttributeNullableInt64uMinValue_252(); + ChipLogProgress(chipTool, " ***** Test Step 252 : Read attribute NULLABLE_INT32U notValue OK\n"); + err = TestReadAttributeNullableInt32uNotValueOk_252(); break; case 253: - ChipLogProgress(chipTool, " ***** Test Step 253 : Read attribute NULLABLE_INT64U Min Value\n"); - err = TestReadAttributeNullableInt64uMinValue_253(); + ChipLogProgress(chipTool, " ***** Test Step 253 : Write attribute NULLABLE_INT64U Min Value\n"); + err = TestWriteAttributeNullableInt64uMinValue_253(); break; case 254: - ChipLogProgress(chipTool, " ***** Test Step 254 : Write attribute NULLABLE_INT64U Max Value\n"); - err = TestWriteAttributeNullableInt64uMaxValue_254(); + ChipLogProgress(chipTool, " ***** Test Step 254 : Read attribute NULLABLE_INT64U Min Value\n"); + err = TestReadAttributeNullableInt64uMinValue_254(); break; case 255: - ChipLogProgress(chipTool, " ***** Test Step 255 : Read attribute NULLABLE_INT64U Max Value\n"); - err = TestReadAttributeNullableInt64uMaxValue_255(); + ChipLogProgress(chipTool, " ***** Test Step 255 : Write attribute NULLABLE_INT64U Max Value\n"); + err = TestWriteAttributeNullableInt64uMaxValue_255(); break; case 256: - ChipLogProgress(chipTool, " ***** Test Step 256 : Write attribute NULLABLE_INT64U Invalid Value\n"); - err = TestWriteAttributeNullableInt64uInvalidValue_256(); + ChipLogProgress(chipTool, " ***** Test Step 256 : Read attribute NULLABLE_INT64U Max Value\n"); + err = TestReadAttributeNullableInt64uMaxValue_256(); break; case 257: - ChipLogProgress(chipTool, " ***** Test Step 257 : Read attribute NULLABLE_INT64U unchanged Value\n"); - err = TestReadAttributeNullableInt64uUnchangedValue_257(); + ChipLogProgress(chipTool, " ***** Test Step 257 : Write attribute NULLABLE_INT64U Invalid Value\n"); + err = TestWriteAttributeNullableInt64uInvalidValue_257(); break; case 258: - ChipLogProgress(chipTool, " ***** Test Step 258 : Write attribute NULLABLE_INT64U null Value\n"); - err = TestWriteAttributeNullableInt64uNullValue_258(); + ChipLogProgress(chipTool, " ***** Test Step 258 : Read attribute NULLABLE_INT64U unchanged Value\n"); + err = TestReadAttributeNullableInt64uUnchangedValue_258(); break; case 259: - ChipLogProgress(chipTool, " ***** Test Step 259 : Read attribute NULLABLE_INT64U null Value\n"); - err = TestReadAttributeNullableInt64uNullValue_259(); + ChipLogProgress(chipTool, " ***** Test Step 259 : Write attribute NULLABLE_INT64U null Value\n"); + err = TestWriteAttributeNullableInt64uNullValue_259(); break; case 260: - ChipLogProgress(chipTool, " ***** Test Step 260 : Read attribute NULLABLE_INT64U null Value & range\n"); - err = TestReadAttributeNullableInt64uNullValueRange_260(); + ChipLogProgress(chipTool, " ***** Test Step 260 : Read attribute NULLABLE_INT64U null Value\n"); + err = TestReadAttributeNullableInt64uNullValue_260(); break; case 261: - ChipLogProgress(chipTool, " ***** Test Step 261 : Read attribute NULLABLE_INT64U null Value & not\n"); - err = TestReadAttributeNullableInt64uNullValueNot_261(); + ChipLogProgress(chipTool, " ***** Test Step 261 : Read attribute NULLABLE_INT64U null Value & range\n"); + err = TestReadAttributeNullableInt64uNullValueRange_261(); break; case 262: - ChipLogProgress(chipTool, " ***** Test Step 262 : Write attribute NULLABLE_INT64U Value\n"); - err = TestWriteAttributeNullableInt64uValue_262(); + ChipLogProgress(chipTool, " ***** Test Step 262 : Read attribute NULLABLE_INT64U null Value & not\n"); + err = TestReadAttributeNullableInt64uNullValueNot_262(); break; case 263: - ChipLogProgress(chipTool, " ***** Test Step 263 : Read attribute NULLABLE_INT64U Value in range\n"); - err = TestReadAttributeNullableInt64uValueInRange_263(); + ChipLogProgress(chipTool, " ***** Test Step 263 : Write attribute NULLABLE_INT64U Value\n"); + err = TestWriteAttributeNullableInt64uValue_263(); break; case 264: - ChipLogProgress(chipTool, " ***** Test Step 264 : Read attribute NULLABLE_INT64U notValue OK\n"); - err = TestReadAttributeNullableInt64uNotValueOk_264(); + ChipLogProgress(chipTool, " ***** Test Step 264 : Read attribute NULLABLE_INT64U Value in range\n"); + err = TestReadAttributeNullableInt64uValueInRange_264(); break; case 265: - ChipLogProgress(chipTool, " ***** Test Step 265 : Write attribute NULLABLE_INT8S Min Value\n"); - err = TestWriteAttributeNullableInt8sMinValue_265(); + ChipLogProgress(chipTool, " ***** Test Step 265 : Read attribute NULLABLE_INT64U notValue OK\n"); + err = TestReadAttributeNullableInt64uNotValueOk_265(); break; case 266: - ChipLogProgress(chipTool, " ***** Test Step 266 : Read attribute NULLABLE_INT8S Min Value\n"); - err = TestReadAttributeNullableInt8sMinValue_266(); + ChipLogProgress(chipTool, " ***** Test Step 266 : Write attribute NULLABLE_INT8S Min Value\n"); + err = TestWriteAttributeNullableInt8sMinValue_266(); break; case 267: - ChipLogProgress(chipTool, " ***** Test Step 267 : Write attribute NULLABLE_INT8S Invalid Value\n"); - err = TestWriteAttributeNullableInt8sInvalidValue_267(); + ChipLogProgress(chipTool, " ***** Test Step 267 : Read attribute NULLABLE_INT8S Min Value\n"); + err = TestReadAttributeNullableInt8sMinValue_267(); break; case 268: - ChipLogProgress(chipTool, " ***** Test Step 268 : Read attribute NULLABLE_INT8S unchanged Value\n"); - err = TestReadAttributeNullableInt8sUnchangedValue_268(); + ChipLogProgress(chipTool, " ***** Test Step 268 : Write attribute NULLABLE_INT8S Invalid Value\n"); + err = TestWriteAttributeNullableInt8sInvalidValue_268(); break; case 269: - ChipLogProgress(chipTool, " ***** Test Step 269 : Write attribute NULLABLE_INT8S null Value\n"); - err = TestWriteAttributeNullableInt8sNullValue_269(); + ChipLogProgress(chipTool, " ***** Test Step 269 : Read attribute NULLABLE_INT8S unchanged Value\n"); + err = TestReadAttributeNullableInt8sUnchangedValue_269(); break; case 270: - ChipLogProgress(chipTool, " ***** Test Step 270 : Read attribute NULLABLE_INT8S null Value\n"); - err = TestReadAttributeNullableInt8sNullValue_270(); + ChipLogProgress(chipTool, " ***** Test Step 270 : Write attribute NULLABLE_INT8S null Value\n"); + err = TestWriteAttributeNullableInt8sNullValue_270(); break; case 271: - ChipLogProgress(chipTool, " ***** Test Step 271 : Read attribute NULLABLE_INT8S null Value & range\n"); - err = TestReadAttributeNullableInt8sNullValueRange_271(); + ChipLogProgress(chipTool, " ***** Test Step 271 : Read attribute NULLABLE_INT8S null Value\n"); + err = TestReadAttributeNullableInt8sNullValue_271(); break; case 272: - ChipLogProgress(chipTool, " ***** Test Step 272 : Read attribute NULLABLE_INT8S null Value & not\n"); - err = TestReadAttributeNullableInt8sNullValueNot_272(); + ChipLogProgress(chipTool, " ***** Test Step 272 : Read attribute NULLABLE_INT8S null Value & range\n"); + err = TestReadAttributeNullableInt8sNullValueRange_272(); break; case 273: - ChipLogProgress(chipTool, " ***** Test Step 273 : Write attribute NULLABLE_INT8S Value\n"); - err = TestWriteAttributeNullableInt8sValue_273(); + ChipLogProgress(chipTool, " ***** Test Step 273 : Read attribute NULLABLE_INT8S null Value & not\n"); + err = TestReadAttributeNullableInt8sNullValueNot_273(); break; case 274: - ChipLogProgress(chipTool, " ***** Test Step 274 : Read attribute NULLABLE_INT8S Value in range\n"); - err = TestReadAttributeNullableInt8sValueInRange_274(); + ChipLogProgress(chipTool, " ***** Test Step 274 : Write attribute NULLABLE_INT8S Value\n"); + err = TestWriteAttributeNullableInt8sValue_274(); break; case 275: - ChipLogProgress(chipTool, " ***** Test Step 275 : Read attribute NULLABLE_INT8S notValue OK\n"); - err = TestReadAttributeNullableInt8sNotValueOk_275(); + ChipLogProgress(chipTool, " ***** Test Step 275 : Read attribute NULLABLE_INT8S Value in range\n"); + err = TestReadAttributeNullableInt8sValueInRange_275(); break; case 276: - ChipLogProgress(chipTool, " ***** Test Step 276 : Write attribute NULLABLE_INT16S Min Value\n"); - err = TestWriteAttributeNullableInt16sMinValue_276(); + ChipLogProgress(chipTool, " ***** Test Step 276 : Read attribute NULLABLE_INT8S notValue OK\n"); + err = TestReadAttributeNullableInt8sNotValueOk_276(); break; case 277: - ChipLogProgress(chipTool, " ***** Test Step 277 : Read attribute NULLABLE_INT16S Min Value\n"); - err = TestReadAttributeNullableInt16sMinValue_277(); + ChipLogProgress(chipTool, " ***** Test Step 277 : Write attribute NULLABLE_INT16S Min Value\n"); + err = TestWriteAttributeNullableInt16sMinValue_277(); break; case 278: - ChipLogProgress(chipTool, " ***** Test Step 278 : Write attribute NULLABLE_INT16S Invalid Value\n"); - err = TestWriteAttributeNullableInt16sInvalidValue_278(); + ChipLogProgress(chipTool, " ***** Test Step 278 : Read attribute NULLABLE_INT16S Min Value\n"); + err = TestReadAttributeNullableInt16sMinValue_278(); break; case 279: - ChipLogProgress(chipTool, " ***** Test Step 279 : Read attribute NULLABLE_INT16S unchanged Value\n"); - err = TestReadAttributeNullableInt16sUnchangedValue_279(); + ChipLogProgress(chipTool, " ***** Test Step 279 : Write attribute NULLABLE_INT16S Invalid Value\n"); + err = TestWriteAttributeNullableInt16sInvalidValue_279(); break; case 280: - ChipLogProgress(chipTool, " ***** Test Step 280 : Write attribute NULLABLE_INT16S null Value\n"); - err = TestWriteAttributeNullableInt16sNullValue_280(); + ChipLogProgress(chipTool, " ***** Test Step 280 : Read attribute NULLABLE_INT16S unchanged Value\n"); + err = TestReadAttributeNullableInt16sUnchangedValue_280(); break; case 281: - ChipLogProgress(chipTool, " ***** Test Step 281 : Read attribute NULLABLE_INT16S null Value\n"); - err = TestReadAttributeNullableInt16sNullValue_281(); + ChipLogProgress(chipTool, " ***** Test Step 281 : Write attribute NULLABLE_INT16S null Value\n"); + err = TestWriteAttributeNullableInt16sNullValue_281(); break; case 282: - ChipLogProgress(chipTool, " ***** Test Step 282 : Read attribute NULLABLE_INT16S null Value & range\n"); - err = TestReadAttributeNullableInt16sNullValueRange_282(); + ChipLogProgress(chipTool, " ***** Test Step 282 : Read attribute NULLABLE_INT16S null Value\n"); + err = TestReadAttributeNullableInt16sNullValue_282(); break; case 283: - ChipLogProgress(chipTool, " ***** Test Step 283 : Read attribute NULLABLE_INT16S null Value & not\n"); - err = TestReadAttributeNullableInt16sNullValueNot_283(); + ChipLogProgress(chipTool, " ***** Test Step 283 : Read attribute NULLABLE_INT16S null Value & range\n"); + err = TestReadAttributeNullableInt16sNullValueRange_283(); break; case 284: - ChipLogProgress(chipTool, " ***** Test Step 284 : Write attribute NULLABLE_INT16S Value\n"); - err = TestWriteAttributeNullableInt16sValue_284(); + ChipLogProgress(chipTool, " ***** Test Step 284 : Read attribute NULLABLE_INT16S null Value & not\n"); + err = TestReadAttributeNullableInt16sNullValueNot_284(); break; case 285: - ChipLogProgress(chipTool, " ***** Test Step 285 : Read attribute NULLABLE_INT16S Value in range\n"); - err = TestReadAttributeNullableInt16sValueInRange_285(); + ChipLogProgress(chipTool, " ***** Test Step 285 : Write attribute NULLABLE_INT16S Value\n"); + err = TestWriteAttributeNullableInt16sValue_285(); break; case 286: - ChipLogProgress(chipTool, " ***** Test Step 286 : Read attribute NULLABLE_INT16S notValue OK\n"); - err = TestReadAttributeNullableInt16sNotValueOk_286(); + ChipLogProgress(chipTool, " ***** Test Step 286 : Read attribute NULLABLE_INT16S Value in range\n"); + err = TestReadAttributeNullableInt16sValueInRange_286(); break; case 287: - ChipLogProgress(chipTool, " ***** Test Step 287 : Write attribute NULLABLE_INT32S Min Value\n"); - err = TestWriteAttributeNullableInt32sMinValue_287(); + ChipLogProgress(chipTool, " ***** Test Step 287 : Read attribute NULLABLE_INT16S notValue OK\n"); + err = TestReadAttributeNullableInt16sNotValueOk_287(); break; case 288: - ChipLogProgress(chipTool, " ***** Test Step 288 : Read attribute NULLABLE_INT32S Min Value\n"); - err = TestReadAttributeNullableInt32sMinValue_288(); + ChipLogProgress(chipTool, " ***** Test Step 288 : Write attribute NULLABLE_INT32S Min Value\n"); + err = TestWriteAttributeNullableInt32sMinValue_288(); break; case 289: - ChipLogProgress(chipTool, " ***** Test Step 289 : Write attribute NULLABLE_INT32S Invalid Value\n"); - err = TestWriteAttributeNullableInt32sInvalidValue_289(); + ChipLogProgress(chipTool, " ***** Test Step 289 : Read attribute NULLABLE_INT32S Min Value\n"); + err = TestReadAttributeNullableInt32sMinValue_289(); break; case 290: - ChipLogProgress(chipTool, " ***** Test Step 290 : Read attribute NULLABLE_INT32S unchanged Value\n"); - err = TestReadAttributeNullableInt32sUnchangedValue_290(); + ChipLogProgress(chipTool, " ***** Test Step 290 : Write attribute NULLABLE_INT32S Invalid Value\n"); + err = TestWriteAttributeNullableInt32sInvalidValue_290(); break; case 291: - ChipLogProgress(chipTool, " ***** Test Step 291 : Write attribute NULLABLE_INT32S null Value\n"); - err = TestWriteAttributeNullableInt32sNullValue_291(); + ChipLogProgress(chipTool, " ***** Test Step 291 : Read attribute NULLABLE_INT32S unchanged Value\n"); + err = TestReadAttributeNullableInt32sUnchangedValue_291(); break; case 292: - ChipLogProgress(chipTool, " ***** Test Step 292 : Read attribute NULLABLE_INT32S null Value\n"); - err = TestReadAttributeNullableInt32sNullValue_292(); + ChipLogProgress(chipTool, " ***** Test Step 292 : Write attribute NULLABLE_INT32S null Value\n"); + err = TestWriteAttributeNullableInt32sNullValue_292(); break; case 293: - ChipLogProgress(chipTool, " ***** Test Step 293 : Read attribute NULLABLE_INT32S null Value & range\n"); - err = TestReadAttributeNullableInt32sNullValueRange_293(); + ChipLogProgress(chipTool, " ***** Test Step 293 : Read attribute NULLABLE_INT32S null Value\n"); + err = TestReadAttributeNullableInt32sNullValue_293(); break; case 294: - ChipLogProgress(chipTool, " ***** Test Step 294 : Read attribute NULLABLE_INT32S null Value & not\n"); - err = TestReadAttributeNullableInt32sNullValueNot_294(); + ChipLogProgress(chipTool, " ***** Test Step 294 : Read attribute NULLABLE_INT32S null Value & range\n"); + err = TestReadAttributeNullableInt32sNullValueRange_294(); break; case 295: - ChipLogProgress(chipTool, " ***** Test Step 295 : Write attribute NULLABLE_INT32S Value\n"); - err = TestWriteAttributeNullableInt32sValue_295(); + ChipLogProgress(chipTool, " ***** Test Step 295 : Read attribute NULLABLE_INT32S null Value & not\n"); + err = TestReadAttributeNullableInt32sNullValueNot_295(); break; case 296: - ChipLogProgress(chipTool, " ***** Test Step 296 : Read attribute NULLABLE_INT32S Value in range\n"); - err = TestReadAttributeNullableInt32sValueInRange_296(); + ChipLogProgress(chipTool, " ***** Test Step 296 : Write attribute NULLABLE_INT32S Value\n"); + err = TestWriteAttributeNullableInt32sValue_296(); break; case 297: - ChipLogProgress(chipTool, " ***** Test Step 297 : Read attribute NULLABLE_INT32S notValue OK\n"); - err = TestReadAttributeNullableInt32sNotValueOk_297(); + ChipLogProgress(chipTool, " ***** Test Step 297 : Read attribute NULLABLE_INT32S Value in range\n"); + err = TestReadAttributeNullableInt32sValueInRange_297(); break; case 298: - ChipLogProgress(chipTool, " ***** Test Step 298 : Write attribute NULLABLE_INT64S Min Value\n"); - err = TestWriteAttributeNullableInt64sMinValue_298(); + ChipLogProgress(chipTool, " ***** Test Step 298 : Read attribute NULLABLE_INT32S notValue OK\n"); + err = TestReadAttributeNullableInt32sNotValueOk_298(); break; case 299: - ChipLogProgress(chipTool, " ***** Test Step 299 : Read attribute NULLABLE_INT64S Min Value\n"); - err = TestReadAttributeNullableInt64sMinValue_299(); + ChipLogProgress(chipTool, " ***** Test Step 299 : Write attribute NULLABLE_INT64S Min Value\n"); + err = TestWriteAttributeNullableInt64sMinValue_299(); break; case 300: - ChipLogProgress(chipTool, " ***** Test Step 300 : Write attribute NULLABLE_INT64S Invalid Value\n"); - err = TestWriteAttributeNullableInt64sInvalidValue_300(); + ChipLogProgress(chipTool, " ***** Test Step 300 : Read attribute NULLABLE_INT64S Min Value\n"); + err = TestReadAttributeNullableInt64sMinValue_300(); break; case 301: - ChipLogProgress(chipTool, " ***** Test Step 301 : Read attribute NULLABLE_INT64S unchanged Value\n"); - err = TestReadAttributeNullableInt64sUnchangedValue_301(); + ChipLogProgress(chipTool, " ***** Test Step 301 : Write attribute NULLABLE_INT64S Invalid Value\n"); + err = TestWriteAttributeNullableInt64sInvalidValue_301(); break; case 302: - ChipLogProgress(chipTool, " ***** Test Step 302 : Write attribute NULLABLE_INT64S null Value\n"); - err = TestWriteAttributeNullableInt64sNullValue_302(); + ChipLogProgress(chipTool, " ***** Test Step 302 : Read attribute NULLABLE_INT64S unchanged Value\n"); + err = TestReadAttributeNullableInt64sUnchangedValue_302(); break; case 303: - ChipLogProgress(chipTool, " ***** Test Step 303 : Read attribute NULLABLE_INT64S null Value\n"); - err = TestReadAttributeNullableInt64sNullValue_303(); + ChipLogProgress(chipTool, " ***** Test Step 303 : Write attribute NULLABLE_INT64S null Value\n"); + err = TestWriteAttributeNullableInt64sNullValue_303(); break; case 304: - ChipLogProgress(chipTool, " ***** Test Step 304 : Read attribute NULLABLE_INT64S null Value & range\n"); - err = TestReadAttributeNullableInt64sNullValueRange_304(); + ChipLogProgress(chipTool, " ***** Test Step 304 : Read attribute NULLABLE_INT64S null Value\n"); + err = TestReadAttributeNullableInt64sNullValue_304(); break; case 305: - ChipLogProgress(chipTool, " ***** Test Step 305 : Read attribute NULLABLE_INT64S null Value & not\n"); - err = TestReadAttributeNullableInt64sNullValueNot_305(); + ChipLogProgress(chipTool, " ***** Test Step 305 : Read attribute NULLABLE_INT64S null Value & range\n"); + err = TestReadAttributeNullableInt64sNullValueRange_305(); break; case 306: - ChipLogProgress(chipTool, " ***** Test Step 306 : Write attribute NULLABLE_INT64S Value\n"); - err = TestWriteAttributeNullableInt64sValue_306(); + ChipLogProgress(chipTool, " ***** Test Step 306 : Read attribute NULLABLE_INT64S null Value & not\n"); + err = TestReadAttributeNullableInt64sNullValueNot_306(); break; case 307: - ChipLogProgress(chipTool, " ***** Test Step 307 : Read attribute NULLABLE_INT64S Value in range\n"); - err = TestReadAttributeNullableInt64sValueInRange_307(); + ChipLogProgress(chipTool, " ***** Test Step 307 : Write attribute NULLABLE_INT64S Value\n"); + err = TestWriteAttributeNullableInt64sValue_307(); break; case 308: - ChipLogProgress(chipTool, " ***** Test Step 308 : Read attribute NULLABLE_INT64S notValue OK\n"); - err = TestReadAttributeNullableInt64sNotValueOk_308(); + ChipLogProgress(chipTool, " ***** Test Step 308 : Read attribute NULLABLE_INT64S Value in range\n"); + err = TestReadAttributeNullableInt64sValueInRange_308(); break; case 309: - ChipLogProgress(chipTool, " ***** Test Step 309 : Write attribute NULLABLE_SINGLE medium Value\n"); - err = TestWriteAttributeNullableSingleMediumValue_309(); + ChipLogProgress(chipTool, " ***** Test Step 309 : Read attribute NULLABLE_INT64S notValue OK\n"); + err = TestReadAttributeNullableInt64sNotValueOk_309(); break; case 310: - ChipLogProgress(chipTool, " ***** Test Step 310 : Read attribute NULLABLE_SINGLE medium Value\n"); - err = TestReadAttributeNullableSingleMediumValue_310(); + ChipLogProgress(chipTool, " ***** Test Step 310 : Write attribute NULLABLE_SINGLE medium Value\n"); + err = TestWriteAttributeNullableSingleMediumValue_310(); break; case 311: - ChipLogProgress(chipTool, " ***** Test Step 311 : Write attribute NULLABLE_SINGLE largest Value\n"); - err = TestWriteAttributeNullableSingleLargestValue_311(); + ChipLogProgress(chipTool, " ***** Test Step 311 : Read attribute NULLABLE_SINGLE medium Value\n"); + err = TestReadAttributeNullableSingleMediumValue_311(); break; case 312: - ChipLogProgress(chipTool, " ***** Test Step 312 : Read attribute NULLABLE_SINGLE largest Value\n"); - err = TestReadAttributeNullableSingleLargestValue_312(); + ChipLogProgress(chipTool, " ***** Test Step 312 : Write attribute NULLABLE_SINGLE largest Value\n"); + err = TestWriteAttributeNullableSingleLargestValue_312(); break; case 313: - ChipLogProgress(chipTool, " ***** Test Step 313 : Write attribute NULLABLE_SINGLE smallest Value\n"); - err = TestWriteAttributeNullableSingleSmallestValue_313(); + ChipLogProgress(chipTool, " ***** Test Step 313 : Read attribute NULLABLE_SINGLE largest Value\n"); + err = TestReadAttributeNullableSingleLargestValue_313(); break; case 314: - ChipLogProgress(chipTool, " ***** Test Step 314 : Read attribute NULLABLE_SINGLE smallest Value\n"); - err = TestReadAttributeNullableSingleSmallestValue_314(); + ChipLogProgress(chipTool, " ***** Test Step 314 : Write attribute NULLABLE_SINGLE smallest Value\n"); + err = TestWriteAttributeNullableSingleSmallestValue_314(); break; case 315: - ChipLogProgress(chipTool, " ***** Test Step 315 : Write attribute NULLABLE_SINGLE null Value\n"); - err = TestWriteAttributeNullableSingleNullValue_315(); + ChipLogProgress(chipTool, " ***** Test Step 315 : Read attribute NULLABLE_SINGLE smallest Value\n"); + err = TestReadAttributeNullableSingleSmallestValue_315(); break; case 316: - ChipLogProgress(chipTool, " ***** Test Step 316 : Read attribute NULLABLE_SINGLE null Value\n"); - err = TestReadAttributeNullableSingleNullValue_316(); + ChipLogProgress(chipTool, " ***** Test Step 316 : Write attribute NULLABLE_SINGLE null Value\n"); + err = TestWriteAttributeNullableSingleNullValue_316(); break; case 317: - ChipLogProgress(chipTool, " ***** Test Step 317 : Write attribute NULLABLE_SINGLE 0 Value\n"); - err = TestWriteAttributeNullableSingle0Value_317(); + ChipLogProgress(chipTool, " ***** Test Step 317 : Read attribute NULLABLE_SINGLE null Value\n"); + err = TestReadAttributeNullableSingleNullValue_317(); break; case 318: - ChipLogProgress(chipTool, " ***** Test Step 318 : Read attribute NULLABLE_SINGLE 0 Value\n"); - err = TestReadAttributeNullableSingle0Value_318(); + ChipLogProgress(chipTool, " ***** Test Step 318 : Write attribute NULLABLE_SINGLE 0 Value\n"); + err = TestWriteAttributeNullableSingle0Value_318(); break; case 319: - ChipLogProgress(chipTool, " ***** Test Step 319 : Write attribute NULLABLE_DOUBLE medium Value\n"); - err = TestWriteAttributeNullableDoubleMediumValue_319(); + ChipLogProgress(chipTool, " ***** Test Step 319 : Read attribute NULLABLE_SINGLE 0 Value\n"); + err = TestReadAttributeNullableSingle0Value_319(); break; case 320: - ChipLogProgress(chipTool, " ***** Test Step 320 : Read attribute NULLABLE_DOUBLE medium Value\n"); - err = TestReadAttributeNullableDoubleMediumValue_320(); + ChipLogProgress(chipTool, " ***** Test Step 320 : Write attribute NULLABLE_DOUBLE medium Value\n"); + err = TestWriteAttributeNullableDoubleMediumValue_320(); break; case 321: - ChipLogProgress(chipTool, " ***** Test Step 321 : Write attribute NULLABLE_DOUBLE largest Value\n"); - err = TestWriteAttributeNullableDoubleLargestValue_321(); + ChipLogProgress(chipTool, " ***** Test Step 321 : Read attribute NULLABLE_DOUBLE medium Value\n"); + err = TestReadAttributeNullableDoubleMediumValue_321(); break; case 322: - ChipLogProgress(chipTool, " ***** Test Step 322 : Read attribute NULLABLE_DOUBLE largest Value\n"); - err = TestReadAttributeNullableDoubleLargestValue_322(); + ChipLogProgress(chipTool, " ***** Test Step 322 : Write attribute NULLABLE_DOUBLE largest Value\n"); + err = TestWriteAttributeNullableDoubleLargestValue_322(); break; case 323: - ChipLogProgress(chipTool, " ***** Test Step 323 : Write attribute NULLABLE_DOUBLE smallest Value\n"); - err = TestWriteAttributeNullableDoubleSmallestValue_323(); + ChipLogProgress(chipTool, " ***** Test Step 323 : Read attribute NULLABLE_DOUBLE largest Value\n"); + err = TestReadAttributeNullableDoubleLargestValue_323(); break; case 324: - ChipLogProgress(chipTool, " ***** Test Step 324 : Read attribute NULLABLE_DOUBLE smallest Value\n"); - err = TestReadAttributeNullableDoubleSmallestValue_324(); + ChipLogProgress(chipTool, " ***** Test Step 324 : Write attribute NULLABLE_DOUBLE smallest Value\n"); + err = TestWriteAttributeNullableDoubleSmallestValue_324(); break; case 325: - ChipLogProgress(chipTool, " ***** Test Step 325 : Write attribute NULLABLE_DOUBLE null Value\n"); - err = TestWriteAttributeNullableDoubleNullValue_325(); + ChipLogProgress(chipTool, " ***** Test Step 325 : Read attribute NULLABLE_DOUBLE smallest Value\n"); + err = TestReadAttributeNullableDoubleSmallestValue_325(); break; case 326: - ChipLogProgress(chipTool, " ***** Test Step 326 : Read attribute NULLABLE_DOUBLE null Value\n"); - err = TestReadAttributeNullableDoubleNullValue_326(); + ChipLogProgress(chipTool, " ***** Test Step 326 : Write attribute NULLABLE_DOUBLE null Value\n"); + err = TestWriteAttributeNullableDoubleNullValue_326(); break; case 327: - ChipLogProgress(chipTool, " ***** Test Step 327 : Write attribute NULLABLE_DOUBLE 0 Value\n"); - err = TestWriteAttributeNullableDouble0Value_327(); + ChipLogProgress(chipTool, " ***** Test Step 327 : Read attribute NULLABLE_DOUBLE null Value\n"); + err = TestReadAttributeNullableDoubleNullValue_327(); break; case 328: - ChipLogProgress(chipTool, " ***** Test Step 328 : Read attribute NULLABLE_DOUBLE 0 Value\n"); - err = TestReadAttributeNullableDouble0Value_328(); + ChipLogProgress(chipTool, " ***** Test Step 328 : Write attribute NULLABLE_DOUBLE 0 Value\n"); + err = TestWriteAttributeNullableDouble0Value_328(); break; case 329: - ChipLogProgress(chipTool, " ***** Test Step 329 : Write attribute NULLABLE_ENUM8 Min Value\n"); - err = TestWriteAttributeNullableEnum8MinValue_329(); + ChipLogProgress(chipTool, " ***** Test Step 329 : Read attribute NULLABLE_DOUBLE 0 Value\n"); + err = TestReadAttributeNullableDouble0Value_329(); break; case 330: - ChipLogProgress(chipTool, " ***** Test Step 330 : Read attribute NULLABLE_ENUM8 Min Value\n"); - err = TestReadAttributeNullableEnum8MinValue_330(); + ChipLogProgress(chipTool, " ***** Test Step 330 : Write attribute NULLABLE_ENUM8 Min Value\n"); + err = TestWriteAttributeNullableEnum8MinValue_330(); break; case 331: - ChipLogProgress(chipTool, " ***** Test Step 331 : Write attribute NULLABLE_ENUM8 Max Value\n"); - err = TestWriteAttributeNullableEnum8MaxValue_331(); + ChipLogProgress(chipTool, " ***** Test Step 331 : Read attribute NULLABLE_ENUM8 Min Value\n"); + err = TestReadAttributeNullableEnum8MinValue_331(); break; case 332: - ChipLogProgress(chipTool, " ***** Test Step 332 : Read attribute NULLABLE_ENUM8 Max Value\n"); - err = TestReadAttributeNullableEnum8MaxValue_332(); + ChipLogProgress(chipTool, " ***** Test Step 332 : Write attribute NULLABLE_ENUM8 Max Value\n"); + err = TestWriteAttributeNullableEnum8MaxValue_332(); break; case 333: - ChipLogProgress(chipTool, " ***** Test Step 333 : Write attribute NULLABLE_ENUM8 Invalid Value\n"); - err = TestWriteAttributeNullableEnum8InvalidValue_333(); + ChipLogProgress(chipTool, " ***** Test Step 333 : Read attribute NULLABLE_ENUM8 Max Value\n"); + err = TestReadAttributeNullableEnum8MaxValue_333(); break; case 334: - ChipLogProgress(chipTool, " ***** Test Step 334 : Read attribute NULLABLE_ENUM8 unchanged Value\n"); - err = TestReadAttributeNullableEnum8UnchangedValue_334(); + ChipLogProgress(chipTool, " ***** Test Step 334 : Write attribute NULLABLE_ENUM8 Invalid Value\n"); + err = TestWriteAttributeNullableEnum8InvalidValue_334(); break; case 335: - ChipLogProgress(chipTool, " ***** Test Step 335 : Write attribute NULLABLE_ENUM8 null Value\n"); - err = TestWriteAttributeNullableEnum8NullValue_335(); + ChipLogProgress(chipTool, " ***** Test Step 335 : Read attribute NULLABLE_ENUM8 unchanged Value\n"); + err = TestReadAttributeNullableEnum8UnchangedValue_335(); break; case 336: - ChipLogProgress(chipTool, " ***** Test Step 336 : Read attribute NULLABLE_ENUM8 null Value\n"); - err = TestReadAttributeNullableEnum8NullValue_336(); + ChipLogProgress(chipTool, " ***** Test Step 336 : Write attribute NULLABLE_ENUM8 null Value\n"); + err = TestWriteAttributeNullableEnum8NullValue_336(); break; case 337: - ChipLogProgress(chipTool, " ***** Test Step 337 : Write attribute NULLABLE_ENUM16 Min Value\n"); - err = TestWriteAttributeNullableEnum16MinValue_337(); + ChipLogProgress(chipTool, " ***** Test Step 337 : Read attribute NULLABLE_ENUM8 null Value\n"); + err = TestReadAttributeNullableEnum8NullValue_337(); break; case 338: - ChipLogProgress(chipTool, " ***** Test Step 338 : Read attribute NULLABLE_ENUM16 Min Value\n"); - err = TestReadAttributeNullableEnum16MinValue_338(); + ChipLogProgress(chipTool, " ***** Test Step 338 : Write attribute NULLABLE_ENUM16 Min Value\n"); + err = TestWriteAttributeNullableEnum16MinValue_338(); break; case 339: - ChipLogProgress(chipTool, " ***** Test Step 339 : Write attribute NULLABLE_ENUM16 Max Value\n"); - err = TestWriteAttributeNullableEnum16MaxValue_339(); + ChipLogProgress(chipTool, " ***** Test Step 339 : Read attribute NULLABLE_ENUM16 Min Value\n"); + err = TestReadAttributeNullableEnum16MinValue_339(); break; case 340: - ChipLogProgress(chipTool, " ***** Test Step 340 : Read attribute NULLABLE_ENUM16 Max Value\n"); - err = TestReadAttributeNullableEnum16MaxValue_340(); + ChipLogProgress(chipTool, " ***** Test Step 340 : Write attribute NULLABLE_ENUM16 Max Value\n"); + err = TestWriteAttributeNullableEnum16MaxValue_340(); break; case 341: - ChipLogProgress(chipTool, " ***** Test Step 341 : Write attribute NULLABLE_ENUM16 Invalid Value\n"); - err = TestWriteAttributeNullableEnum16InvalidValue_341(); + ChipLogProgress(chipTool, " ***** Test Step 341 : Read attribute NULLABLE_ENUM16 Max Value\n"); + err = TestReadAttributeNullableEnum16MaxValue_341(); break; case 342: - ChipLogProgress(chipTool, " ***** Test Step 342 : Read attribute NULLABLE_ENUM16 unchanged Value\n"); - err = TestReadAttributeNullableEnum16UnchangedValue_342(); + ChipLogProgress(chipTool, " ***** Test Step 342 : Write attribute NULLABLE_ENUM16 Invalid Value\n"); + err = TestWriteAttributeNullableEnum16InvalidValue_342(); break; case 343: - ChipLogProgress(chipTool, " ***** Test Step 343 : Write attribute NULLABLE_ENUM16 null Value\n"); - err = TestWriteAttributeNullableEnum16NullValue_343(); + ChipLogProgress(chipTool, " ***** Test Step 343 : Read attribute NULLABLE_ENUM16 unchanged Value\n"); + err = TestReadAttributeNullableEnum16UnchangedValue_343(); break; case 344: - ChipLogProgress(chipTool, " ***** Test Step 344 : Read attribute NULLABLE_ENUM16 null Value\n"); - err = TestReadAttributeNullableEnum16NullValue_344(); + ChipLogProgress(chipTool, " ***** Test Step 344 : Write attribute NULLABLE_ENUM16 null Value\n"); + err = TestWriteAttributeNullableEnum16NullValue_344(); break; case 345: - ChipLogProgress(chipTool, " ***** Test Step 345 : Write attribute NULLABLE_SIMPLE_ENUM Min Value\n"); - err = TestWriteAttributeNullableSimpleEnumMinValue_345(); + ChipLogProgress(chipTool, " ***** Test Step 345 : Read attribute NULLABLE_ENUM16 null Value\n"); + err = TestReadAttributeNullableEnum16NullValue_345(); break; case 346: - ChipLogProgress(chipTool, " ***** Test Step 346 : Read attribute NULLABLE_SIMPLE_ENUM Min Value\n"); - err = TestReadAttributeNullableSimpleEnumMinValue_346(); + ChipLogProgress(chipTool, " ***** Test Step 346 : Write attribute NULLABLE_SIMPLE_ENUM Min Value\n"); + err = TestWriteAttributeNullableSimpleEnumMinValue_346(); break; case 347: - ChipLogProgress(chipTool, " ***** Test Step 347 : Write attribute NULLABLE_SIMPLE_ENUM Max Value\n"); - err = TestWriteAttributeNullableSimpleEnumMaxValue_347(); + ChipLogProgress(chipTool, " ***** Test Step 347 : Read attribute NULLABLE_SIMPLE_ENUM Min Value\n"); + err = TestReadAttributeNullableSimpleEnumMinValue_347(); break; case 348: - ChipLogProgress(chipTool, " ***** Test Step 348 : Read attribute NULLABLE_SIMPLE_ENUM Max Value\n"); - err = TestReadAttributeNullableSimpleEnumMaxValue_348(); + ChipLogProgress(chipTool, " ***** Test Step 348 : Write attribute NULLABLE_SIMPLE_ENUM Max Value\n"); + err = TestWriteAttributeNullableSimpleEnumMaxValue_348(); break; case 349: - ChipLogProgress(chipTool, " ***** Test Step 349 : Write attribute NULLABLE_SIMPLE_ENUM Invalid Value\n"); - err = TestWriteAttributeNullableSimpleEnumInvalidValue_349(); + ChipLogProgress(chipTool, " ***** Test Step 349 : Read attribute NULLABLE_SIMPLE_ENUM Max Value\n"); + err = TestReadAttributeNullableSimpleEnumMaxValue_349(); break; case 350: - ChipLogProgress(chipTool, " ***** Test Step 350 : Read attribute NULLABLE_SIMPLE_ENUM unchanged Value\n"); - err = TestReadAttributeNullableSimpleEnumUnchangedValue_350(); + ChipLogProgress(chipTool, " ***** Test Step 350 : Write attribute NULLABLE_SIMPLE_ENUM Invalid Value\n"); + err = TestWriteAttributeNullableSimpleEnumInvalidValue_350(); break; case 351: - ChipLogProgress(chipTool, " ***** Test Step 351 : Write attribute NULLABLE_SIMPLE_ENUM null Value\n"); - err = TestWriteAttributeNullableSimpleEnumNullValue_351(); + ChipLogProgress(chipTool, " ***** Test Step 351 : Read attribute NULLABLE_SIMPLE_ENUM unchanged Value\n"); + err = TestReadAttributeNullableSimpleEnumUnchangedValue_351(); break; case 352: - ChipLogProgress(chipTool, " ***** Test Step 352 : Read attribute NULLABLE_SIMPLE_ENUM null Value\n"); - err = TestReadAttributeNullableSimpleEnumNullValue_352(); + ChipLogProgress(chipTool, " ***** Test Step 352 : Write attribute NULLABLE_SIMPLE_ENUM null Value\n"); + err = TestWriteAttributeNullableSimpleEnumNullValue_352(); break; case 353: - ChipLogProgress(chipTool, " ***** Test Step 353 : Read attribute NULLABLE_SIMPLE_ENUM not 3 Value\n"); - err = TestReadAttributeNullableSimpleEnumNot3Value_353(); + ChipLogProgress(chipTool, " ***** Test Step 353 : Read attribute NULLABLE_SIMPLE_ENUM null Value\n"); + err = TestReadAttributeNullableSimpleEnumNullValue_353(); break; case 354: - ChipLogProgress(chipTool, " ***** Test Step 354 : Read attribute NULLABLE_OCTET_STRING Default Value\n"); - err = TestReadAttributeNullableOctetStringDefaultValue_354(); + ChipLogProgress(chipTool, " ***** Test Step 354 : Read attribute NULLABLE_SIMPLE_ENUM not 3 Value\n"); + err = TestReadAttributeNullableSimpleEnumNot3Value_354(); break; case 355: - ChipLogProgress(chipTool, " ***** Test Step 355 : Write attribute NULLABLE_OCTET_STRING\n"); - err = TestWriteAttributeNullableOctetString_355(); + ChipLogProgress(chipTool, " ***** Test Step 355 : Read attribute NULLABLE_OCTET_STRING Default Value\n"); + err = TestReadAttributeNullableOctetStringDefaultValue_355(); break; case 356: - ChipLogProgress(chipTool, " ***** Test Step 356 : Read attribute NULLABLE_OCTET_STRING\n"); - err = TestReadAttributeNullableOctetString_356(); + ChipLogProgress(chipTool, " ***** Test Step 356 : Write attribute NULLABLE_OCTET_STRING\n"); + err = TestWriteAttributeNullableOctetString_356(); break; case 357: - ChipLogProgress(chipTool, " ***** Test Step 357 : Write attribute NULLABLE_OCTET_STRING\n"); - err = TestWriteAttributeNullableOctetString_357(); + ChipLogProgress(chipTool, " ***** Test Step 357 : Read attribute NULLABLE_OCTET_STRING\n"); + err = TestReadAttributeNullableOctetString_357(); break; case 358: - ChipLogProgress(chipTool, " ***** Test Step 358 : Read attribute NULLABLE_OCTET_STRING\n"); - err = TestReadAttributeNullableOctetString_358(); + ChipLogProgress(chipTool, " ***** Test Step 358 : Write attribute NULLABLE_OCTET_STRING\n"); + err = TestWriteAttributeNullableOctetString_358(); break; case 359: - ChipLogProgress(chipTool, " ***** Test Step 359 : Write attribute NULLABLE_OCTET_STRING\n"); - err = TestWriteAttributeNullableOctetString_359(); + ChipLogProgress(chipTool, " ***** Test Step 359 : Read attribute NULLABLE_OCTET_STRING\n"); + err = TestReadAttributeNullableOctetString_359(); break; case 360: - ChipLogProgress(chipTool, " ***** Test Step 360 : Read attribute NULLABLE_OCTET_STRING\n"); - err = TestReadAttributeNullableOctetString_360(); + ChipLogProgress(chipTool, " ***** Test Step 360 : Write attribute NULLABLE_OCTET_STRING\n"); + err = TestWriteAttributeNullableOctetString_360(); break; case 361: - ChipLogProgress(chipTool, " ***** Test Step 361 : Read attribute NULLABLE_OCTET_STRING not TestValue\n"); - err = TestReadAttributeNullableOctetStringNotTestValue_361(); + ChipLogProgress(chipTool, " ***** Test Step 361 : Read attribute NULLABLE_OCTET_STRING\n"); + err = TestReadAttributeNullableOctetString_361(); break; case 362: - ChipLogProgress(chipTool, " ***** Test Step 362 : Read attribute NULLABLE_CHAR_STRING Default Value\n"); - err = TestReadAttributeNullableCharStringDefaultValue_362(); + ChipLogProgress(chipTool, " ***** Test Step 362 : Read attribute NULLABLE_OCTET_STRING not TestValue\n"); + err = TestReadAttributeNullableOctetStringNotTestValue_362(); break; case 363: - ChipLogProgress(chipTool, " ***** Test Step 363 : Write attribute NULLABLE_CHAR_STRING\n"); - err = TestWriteAttributeNullableCharString_363(); + ChipLogProgress(chipTool, " ***** Test Step 363 : Read attribute NULLABLE_CHAR_STRING Default Value\n"); + err = TestReadAttributeNullableCharStringDefaultValue_363(); break; case 364: - ChipLogProgress(chipTool, " ***** Test Step 364 : Read attribute NULLABLE_CHAR_STRING\n"); - err = TestReadAttributeNullableCharString_364(); + ChipLogProgress(chipTool, " ***** Test Step 364 : Write attribute NULLABLE_CHAR_STRING\n"); + err = TestWriteAttributeNullableCharString_364(); break; case 365: ChipLogProgress(chipTool, " ***** Test Step 365 : Read attribute NULLABLE_CHAR_STRING\n"); err = TestReadAttributeNullableCharString_365(); break; case 366: - ChipLogProgress(chipTool, " ***** Test Step 366 : Write attribute NULLABLE_CHAR_STRING - Value too long\n"); - err = TestWriteAttributeNullableCharStringValueTooLong_366(); + ChipLogProgress(chipTool, " ***** Test Step 366 : Read attribute NULLABLE_CHAR_STRING\n"); + err = TestReadAttributeNullableCharString_366(); break; case 367: - ChipLogProgress(chipTool, " ***** Test Step 367 : Read attribute NULLABLE_CHAR_STRING\n"); - err = TestReadAttributeNullableCharString_367(); + ChipLogProgress(chipTool, " ***** Test Step 367 : Write attribute NULLABLE_CHAR_STRING - Value too long\n"); + err = TestWriteAttributeNullableCharStringValueTooLong_367(); break; case 368: - ChipLogProgress(chipTool, " ***** Test Step 368 : Write attribute NULLABLE_CHAR_STRING - Empty\n"); - err = TestWriteAttributeNullableCharStringEmpty_368(); + ChipLogProgress(chipTool, " ***** Test Step 368 : Read attribute NULLABLE_CHAR_STRING\n"); + err = TestReadAttributeNullableCharString_368(); break; case 369: - ChipLogProgress(chipTool, " ***** Test Step 369 : Read attribute NULLABLE_CHAR_STRING\n"); - err = TestReadAttributeNullableCharString_369(); + ChipLogProgress(chipTool, " ***** Test Step 369 : Write attribute NULLABLE_CHAR_STRING - Empty\n"); + err = TestWriteAttributeNullableCharStringEmpty_369(); break; case 370: - ChipLogProgress(chipTool, " ***** Test Step 370 : Read attribute NULLABLE_CHAR_STRING not ☉T☉\n"); - err = TestReadAttributeNullableCharStringNott_370(); + ChipLogProgress(chipTool, " ***** Test Step 370 : Read attribute NULLABLE_CHAR_STRING\n"); + err = TestReadAttributeNullableCharString_370(); break; case 371: - ChipLogProgress(chipTool, " ***** Test Step 371 : Read attribute from nonexistent endpoint.\n"); - err = TestReadAttributeFromNonexistentEndpoint_371(); + ChipLogProgress(chipTool, " ***** Test Step 371 : Read attribute NULLABLE_CHAR_STRING not ☉T☉\n"); + err = TestReadAttributeNullableCharStringNott_371(); break; case 372: - ChipLogProgress(chipTool, " ***** Test Step 372 : Read attribute from nonexistent cluster.\n"); - err = TestReadAttributeFromNonexistentCluster_372(); + ChipLogProgress(chipTool, " ***** Test Step 372 : Read attribute from nonexistent endpoint.\n"); + err = TestReadAttributeFromNonexistentEndpoint_372(); break; case 373: - ChipLogProgress( - chipTool, " ***** Test Step 373 : Send a command that takes an optional parameter but do not set it.\n"); - err = TestSendACommandThatTakesAnOptionalParameterButDoNotSetIt_373(); + ChipLogProgress(chipTool, " ***** Test Step 373 : Read attribute from nonexistent cluster.\n"); + err = TestReadAttributeFromNonexistentCluster_373(); break; case 374: ChipLogProgress( @@ -72917,552 +75943,557 @@ class TestCluster : public TestCommandBridge { err = TestSendACommandThatTakesAnOptionalParameterButDoNotSetIt_374(); break; case 375: - ChipLogProgress(chipTool, " ***** Test Step 375 : Report: Subscribe to list attribute\n"); - err = TestReportSubscribeToListAttribute_375(); + ChipLogProgress( + chipTool, " ***** Test Step 375 : Send a command that takes an optional parameter but do not set it.\n"); + err = TestSendACommandThatTakesAnOptionalParameterButDoNotSetIt_375(); break; case 376: - ChipLogProgress(chipTool, " ***** Test Step 376 : Subscribe to list attribute\n"); - err = TestSubscribeToListAttribute_376(); + ChipLogProgress(chipTool, " ***** Test Step 376 : Report: Subscribe to list attribute\n"); + err = TestReportSubscribeToListAttribute_376(); break; case 377: - ChipLogProgress(chipTool, " ***** Test Step 377 : Write subscribed-to list attribute\n"); - err = TestWriteSubscribedToListAttribute_377(); + ChipLogProgress(chipTool, " ***** Test Step 377 : Subscribe to list attribute\n"); + err = TestSubscribeToListAttribute_377(); break; case 378: - ChipLogProgress(chipTool, " ***** Test Step 378 : Check for list attribute report\n"); - err = TestCheckForListAttributeReport_378(); + ChipLogProgress(chipTool, " ***** Test Step 378 : Write subscribed-to list attribute\n"); + err = TestWriteSubscribedToListAttribute_378(); break; case 379: - ChipLogProgress(chipTool, " ***** Test Step 379 : Read range-restricted unsigned 8-bit integer\n"); - err = TestReadRangeRestrictedUnsigned8BitInteger_379(); + ChipLogProgress(chipTool, " ***** Test Step 379 : Check for list attribute report\n"); + err = TestCheckForListAttributeReport_379(); break; case 380: - ChipLogProgress(chipTool, " ***** Test Step 380 : Write min value to a range-restricted unsigned 8-bit integer\n"); - err = TestWriteMinValueToARangeRestrictedUnsigned8BitInteger_380(); + ChipLogProgress(chipTool, " ***** Test Step 380 : Read range-restricted unsigned 8-bit integer\n"); + err = TestReadRangeRestrictedUnsigned8BitInteger_380(); break; case 381: - ChipLogProgress( - chipTool, " ***** Test Step 381 : Write just-below-range value to a range-restricted unsigned 8-bit integer\n"); - err = TestWriteJustBelowRangeValueToARangeRestrictedUnsigned8BitInteger_381(); + ChipLogProgress(chipTool, " ***** Test Step 381 : Write min value to a range-restricted unsigned 8-bit integer\n"); + err = TestWriteMinValueToARangeRestrictedUnsigned8BitInteger_381(); break; case 382: ChipLogProgress( - chipTool, " ***** Test Step 382 : Write just-above-range value to a range-restricted unsigned 8-bit integer\n"); - err = TestWriteJustAboveRangeValueToARangeRestrictedUnsigned8BitInteger_382(); + chipTool, " ***** Test Step 382 : Write just-below-range value to a range-restricted unsigned 8-bit integer\n"); + err = TestWriteJustBelowRangeValueToARangeRestrictedUnsigned8BitInteger_382(); break; case 383: - ChipLogProgress(chipTool, " ***** Test Step 383 : Write max value to a range-restricted unsigned 8-bit integer\n"); - err = TestWriteMaxValueToARangeRestrictedUnsigned8BitInteger_383(); + ChipLogProgress( + chipTool, " ***** Test Step 383 : Write just-above-range value to a range-restricted unsigned 8-bit integer\n"); + err = TestWriteJustAboveRangeValueToARangeRestrictedUnsigned8BitInteger_383(); break; case 384: - ChipLogProgress( - chipTool, " ***** Test Step 384 : Verify range-restricted unsigned 8-bit integer value has not changed\n"); - err = TestVerifyRangeRestrictedUnsigned8BitIntegerValueHasNotChanged_384(); + ChipLogProgress(chipTool, " ***** Test Step 384 : Write max value to a range-restricted unsigned 8-bit integer\n"); + err = TestWriteMaxValueToARangeRestrictedUnsigned8BitInteger_384(); break; case 385: ChipLogProgress( - chipTool, " ***** Test Step 385 : Write min valid value to a range-restricted unsigned 8-bit integer\n"); - err = TestWriteMinValidValueToARangeRestrictedUnsigned8BitInteger_385(); + chipTool, " ***** Test Step 385 : Verify range-restricted unsigned 8-bit integer value has not changed\n"); + err = TestVerifyRangeRestrictedUnsigned8BitIntegerValueHasNotChanged_385(); break; case 386: ChipLogProgress( - chipTool, " ***** Test Step 386 : Verify range-restricted unsigned 8-bit integer value is at min valid\n"); - err = TestVerifyRangeRestrictedUnsigned8BitIntegerValueIsAtMinValid_386(); + chipTool, " ***** Test Step 386 : Write min valid value to a range-restricted unsigned 8-bit integer\n"); + err = TestWriteMinValidValueToARangeRestrictedUnsigned8BitInteger_386(); break; case 387: ChipLogProgress( - chipTool, " ***** Test Step 387 : Write max valid value to a range-restricted unsigned 8-bit integer\n"); - err = TestWriteMaxValidValueToARangeRestrictedUnsigned8BitInteger_387(); + chipTool, " ***** Test Step 387 : Verify range-restricted unsigned 8-bit integer value is at min valid\n"); + err = TestVerifyRangeRestrictedUnsigned8BitIntegerValueIsAtMinValid_387(); break; case 388: ChipLogProgress( - chipTool, " ***** Test Step 388 : Verify range-restricted unsigned 8-bit integer value is at max valid\n"); - err = TestVerifyRangeRestrictedUnsigned8BitIntegerValueIsAtMaxValid_388(); + chipTool, " ***** Test Step 388 : Write max valid value to a range-restricted unsigned 8-bit integer\n"); + err = TestWriteMaxValidValueToARangeRestrictedUnsigned8BitInteger_388(); break; case 389: ChipLogProgress( - chipTool, " ***** Test Step 389 : Write middle valid value to a range-restricted unsigned 8-bit integer\n"); - err = TestWriteMiddleValidValueToARangeRestrictedUnsigned8BitInteger_389(); + chipTool, " ***** Test Step 389 : Verify range-restricted unsigned 8-bit integer value is at max valid\n"); + err = TestVerifyRangeRestrictedUnsigned8BitIntegerValueIsAtMaxValid_389(); break; case 390: ChipLogProgress( - chipTool, " ***** Test Step 390 : Verify range-restricted unsigned 8-bit integer value is at mid valid\n"); - err = TestVerifyRangeRestrictedUnsigned8BitIntegerValueIsAtMidValid_390(); + chipTool, " ***** Test Step 390 : Write middle valid value to a range-restricted unsigned 8-bit integer\n"); + err = TestWriteMiddleValidValueToARangeRestrictedUnsigned8BitInteger_390(); break; case 391: - ChipLogProgress(chipTool, " ***** Test Step 391 : Read range-restricted unsigned 16-bit integer\n"); - err = TestReadRangeRestrictedUnsigned16BitInteger_391(); + ChipLogProgress( + chipTool, " ***** Test Step 391 : Verify range-restricted unsigned 8-bit integer value is at mid valid\n"); + err = TestVerifyRangeRestrictedUnsigned8BitIntegerValueIsAtMidValid_391(); break; case 392: - ChipLogProgress(chipTool, " ***** Test Step 392 : Write min value to a range-restricted unsigned 16-bit integer\n"); - err = TestWriteMinValueToARangeRestrictedUnsigned16BitInteger_392(); + ChipLogProgress(chipTool, " ***** Test Step 392 : Read range-restricted unsigned 16-bit integer\n"); + err = TestReadRangeRestrictedUnsigned16BitInteger_392(); break; case 393: - ChipLogProgress( - chipTool, " ***** Test Step 393 : Write just-below-range value to a range-restricted unsigned 16-bit integer\n"); - err = TestWriteJustBelowRangeValueToARangeRestrictedUnsigned16BitInteger_393(); + ChipLogProgress(chipTool, " ***** Test Step 393 : Write min value to a range-restricted unsigned 16-bit integer\n"); + err = TestWriteMinValueToARangeRestrictedUnsigned16BitInteger_393(); break; case 394: ChipLogProgress( - chipTool, " ***** Test Step 394 : Write just-above-range value to a range-restricted unsigned 16-bit integer\n"); - err = TestWriteJustAboveRangeValueToARangeRestrictedUnsigned16BitInteger_394(); + chipTool, " ***** Test Step 394 : Write just-below-range value to a range-restricted unsigned 16-bit integer\n"); + err = TestWriteJustBelowRangeValueToARangeRestrictedUnsigned16BitInteger_394(); break; case 395: - ChipLogProgress(chipTool, " ***** Test Step 395 : Write max value to a range-restricted unsigned 16-bit integer\n"); - err = TestWriteMaxValueToARangeRestrictedUnsigned16BitInteger_395(); + ChipLogProgress( + chipTool, " ***** Test Step 395 : Write just-above-range value to a range-restricted unsigned 16-bit integer\n"); + err = TestWriteJustAboveRangeValueToARangeRestrictedUnsigned16BitInteger_395(); break; case 396: - ChipLogProgress( - chipTool, " ***** Test Step 396 : Verify range-restricted unsigned 16-bit integer value has not changed\n"); - err = TestVerifyRangeRestrictedUnsigned16BitIntegerValueHasNotChanged_396(); + ChipLogProgress(chipTool, " ***** Test Step 396 : Write max value to a range-restricted unsigned 16-bit integer\n"); + err = TestWriteMaxValueToARangeRestrictedUnsigned16BitInteger_396(); break; case 397: ChipLogProgress( - chipTool, " ***** Test Step 397 : Write min valid value to a range-restricted unsigned 16-bit integer\n"); - err = TestWriteMinValidValueToARangeRestrictedUnsigned16BitInteger_397(); + chipTool, " ***** Test Step 397 : Verify range-restricted unsigned 16-bit integer value has not changed\n"); + err = TestVerifyRangeRestrictedUnsigned16BitIntegerValueHasNotChanged_397(); break; case 398: ChipLogProgress( - chipTool, " ***** Test Step 398 : Verify range-restricted unsigned 16-bit integer value is at min valid\n"); - err = TestVerifyRangeRestrictedUnsigned16BitIntegerValueIsAtMinValid_398(); + chipTool, " ***** Test Step 398 : Write min valid value to a range-restricted unsigned 16-bit integer\n"); + err = TestWriteMinValidValueToARangeRestrictedUnsigned16BitInteger_398(); break; case 399: ChipLogProgress( - chipTool, " ***** Test Step 399 : Write max valid value to a range-restricted unsigned 16-bit integer\n"); - err = TestWriteMaxValidValueToARangeRestrictedUnsigned16BitInteger_399(); + chipTool, " ***** Test Step 399 : Verify range-restricted unsigned 16-bit integer value is at min valid\n"); + err = TestVerifyRangeRestrictedUnsigned16BitIntegerValueIsAtMinValid_399(); break; case 400: ChipLogProgress( - chipTool, " ***** Test Step 400 : Verify range-restricted unsigned 16-bit integer value is at max valid\n"); - err = TestVerifyRangeRestrictedUnsigned16BitIntegerValueIsAtMaxValid_400(); + chipTool, " ***** Test Step 400 : Write max valid value to a range-restricted unsigned 16-bit integer\n"); + err = TestWriteMaxValidValueToARangeRestrictedUnsigned16BitInteger_400(); break; case 401: ChipLogProgress( - chipTool, " ***** Test Step 401 : Write middle valid value to a range-restricted unsigned 16-bit integer\n"); - err = TestWriteMiddleValidValueToARangeRestrictedUnsigned16BitInteger_401(); + chipTool, " ***** Test Step 401 : Verify range-restricted unsigned 16-bit integer value is at max valid\n"); + err = TestVerifyRangeRestrictedUnsigned16BitIntegerValueIsAtMaxValid_401(); break; case 402: ChipLogProgress( - chipTool, " ***** Test Step 402 : Verify range-restricted unsigned 16-bit integer value is at mid valid\n"); - err = TestVerifyRangeRestrictedUnsigned16BitIntegerValueIsAtMidValid_402(); + chipTool, " ***** Test Step 402 : Write middle valid value to a range-restricted unsigned 16-bit integer\n"); + err = TestWriteMiddleValidValueToARangeRestrictedUnsigned16BitInteger_402(); break; case 403: - ChipLogProgress(chipTool, " ***** Test Step 403 : Read range-restricted signed 8-bit integer\n"); - err = TestReadRangeRestrictedSigned8BitInteger_403(); + ChipLogProgress( + chipTool, " ***** Test Step 403 : Verify range-restricted unsigned 16-bit integer value is at mid valid\n"); + err = TestVerifyRangeRestrictedUnsigned16BitIntegerValueIsAtMidValid_403(); break; case 404: - ChipLogProgress(chipTool, " ***** Test Step 404 : Write min value to a range-restricted signed 8-bit integer\n"); - err = TestWriteMinValueToARangeRestrictedSigned8BitInteger_404(); + ChipLogProgress(chipTool, " ***** Test Step 404 : Read range-restricted signed 8-bit integer\n"); + err = TestReadRangeRestrictedSigned8BitInteger_404(); break; case 405: - ChipLogProgress( - chipTool, " ***** Test Step 405 : Write just-below-range value to a range-restricted signed 8-bit integer\n"); - err = TestWriteJustBelowRangeValueToARangeRestrictedSigned8BitInteger_405(); + ChipLogProgress(chipTool, " ***** Test Step 405 : Write min value to a range-restricted signed 8-bit integer\n"); + err = TestWriteMinValueToARangeRestrictedSigned8BitInteger_405(); break; case 406: ChipLogProgress( - chipTool, " ***** Test Step 406 : Write just-above-range value to a range-restricted signed 8-bit integer\n"); - err = TestWriteJustAboveRangeValueToARangeRestrictedSigned8BitInteger_406(); + chipTool, " ***** Test Step 406 : Write just-below-range value to a range-restricted signed 8-bit integer\n"); + err = TestWriteJustBelowRangeValueToARangeRestrictedSigned8BitInteger_406(); break; case 407: - ChipLogProgress(chipTool, " ***** Test Step 407 : Write max value to a range-restricted signed 8-bit integer\n"); - err = TestWriteMaxValueToARangeRestrictedSigned8BitInteger_407(); + ChipLogProgress( + chipTool, " ***** Test Step 407 : Write just-above-range value to a range-restricted signed 8-bit integer\n"); + err = TestWriteJustAboveRangeValueToARangeRestrictedSigned8BitInteger_407(); break; case 408: - ChipLogProgress( - chipTool, " ***** Test Step 408 : Verify range-restricted signed 8-bit integer value has not changed\n"); - err = TestVerifyRangeRestrictedSigned8BitIntegerValueHasNotChanged_408(); + ChipLogProgress(chipTool, " ***** Test Step 408 : Write max value to a range-restricted signed 8-bit integer\n"); + err = TestWriteMaxValueToARangeRestrictedSigned8BitInteger_408(); break; case 409: - ChipLogProgress(chipTool, " ***** Test Step 409 : Write min valid value to a range-restricted signed 8-bit integer\n"); - err = TestWriteMinValidValueToARangeRestrictedSigned8BitInteger_409(); + ChipLogProgress( + chipTool, " ***** Test Step 409 : Verify range-restricted signed 8-bit integer value has not changed\n"); + err = TestVerifyRangeRestrictedSigned8BitIntegerValueHasNotChanged_409(); break; case 410: - ChipLogProgress( - chipTool, " ***** Test Step 410 : Verify range-restricted signed 8-bit integer value is at min valid\n"); - err = TestVerifyRangeRestrictedSigned8BitIntegerValueIsAtMinValid_410(); + ChipLogProgress(chipTool, " ***** Test Step 410 : Write min valid value to a range-restricted signed 8-bit integer\n"); + err = TestWriteMinValidValueToARangeRestrictedSigned8BitInteger_410(); break; case 411: - ChipLogProgress(chipTool, " ***** Test Step 411 : Write max valid value to a range-restricted signed 8-bit integer\n"); - err = TestWriteMaxValidValueToARangeRestrictedSigned8BitInteger_411(); + ChipLogProgress( + chipTool, " ***** Test Step 411 : Verify range-restricted signed 8-bit integer value is at min valid\n"); + err = TestVerifyRangeRestrictedSigned8BitIntegerValueIsAtMinValid_411(); break; case 412: - ChipLogProgress( - chipTool, " ***** Test Step 412 : Verify range-restricted signed 8-bit integer value is at max valid\n"); - err = TestVerifyRangeRestrictedSigned8BitIntegerValueIsAtMaxValid_412(); + ChipLogProgress(chipTool, " ***** Test Step 412 : Write max valid value to a range-restricted signed 8-bit integer\n"); + err = TestWriteMaxValidValueToARangeRestrictedSigned8BitInteger_412(); break; case 413: ChipLogProgress( - chipTool, " ***** Test Step 413 : Write middle valid value to a range-restricted signed 8-bit integer\n"); - err = TestWriteMiddleValidValueToARangeRestrictedSigned8BitInteger_413(); + chipTool, " ***** Test Step 413 : Verify range-restricted signed 8-bit integer value is at max valid\n"); + err = TestVerifyRangeRestrictedSigned8BitIntegerValueIsAtMaxValid_413(); break; case 414: ChipLogProgress( - chipTool, " ***** Test Step 414 : Verify range-restricted signed 8-bit integer value is at mid valid\n"); - err = TestVerifyRangeRestrictedSigned8BitIntegerValueIsAtMidValid_414(); + chipTool, " ***** Test Step 414 : Write middle valid value to a range-restricted signed 8-bit integer\n"); + err = TestWriteMiddleValidValueToARangeRestrictedSigned8BitInteger_414(); break; case 415: - ChipLogProgress(chipTool, " ***** Test Step 415 : Read range-restricted signed 16-bit integer\n"); - err = TestReadRangeRestrictedSigned16BitInteger_415(); + ChipLogProgress( + chipTool, " ***** Test Step 415 : Verify range-restricted signed 8-bit integer value is at mid valid\n"); + err = TestVerifyRangeRestrictedSigned8BitIntegerValueIsAtMidValid_415(); break; case 416: - ChipLogProgress(chipTool, " ***** Test Step 416 : Write min value to a range-restricted signed 16-bit integer\n"); - err = TestWriteMinValueToARangeRestrictedSigned16BitInteger_416(); + ChipLogProgress(chipTool, " ***** Test Step 416 : Read range-restricted signed 16-bit integer\n"); + err = TestReadRangeRestrictedSigned16BitInteger_416(); break; case 417: - ChipLogProgress( - chipTool, " ***** Test Step 417 : Write just-below-range value to a range-restricted signed 16-bit integer\n"); - err = TestWriteJustBelowRangeValueToARangeRestrictedSigned16BitInteger_417(); + ChipLogProgress(chipTool, " ***** Test Step 417 : Write min value to a range-restricted signed 16-bit integer\n"); + err = TestWriteMinValueToARangeRestrictedSigned16BitInteger_417(); break; case 418: ChipLogProgress( - chipTool, " ***** Test Step 418 : Write just-above-range value to a range-restricted signed 16-bit integer\n"); - err = TestWriteJustAboveRangeValueToARangeRestrictedSigned16BitInteger_418(); + chipTool, " ***** Test Step 418 : Write just-below-range value to a range-restricted signed 16-bit integer\n"); + err = TestWriteJustBelowRangeValueToARangeRestrictedSigned16BitInteger_418(); break; case 419: - ChipLogProgress(chipTool, " ***** Test Step 419 : Write max value to a range-restricted signed 16-bit integer\n"); - err = TestWriteMaxValueToARangeRestrictedSigned16BitInteger_419(); + ChipLogProgress( + chipTool, " ***** Test Step 419 : Write just-above-range value to a range-restricted signed 16-bit integer\n"); + err = TestWriteJustAboveRangeValueToARangeRestrictedSigned16BitInteger_419(); break; case 420: - ChipLogProgress( - chipTool, " ***** Test Step 420 : Verify range-restricted signed 16-bit integer value has not changed\n"); - err = TestVerifyRangeRestrictedSigned16BitIntegerValueHasNotChanged_420(); + ChipLogProgress(chipTool, " ***** Test Step 420 : Write max value to a range-restricted signed 16-bit integer\n"); + err = TestWriteMaxValueToARangeRestrictedSigned16BitInteger_420(); break; case 421: - ChipLogProgress(chipTool, " ***** Test Step 421 : Write min valid value to a range-restricted signed 16-bit integer\n"); - err = TestWriteMinValidValueToARangeRestrictedSigned16BitInteger_421(); + ChipLogProgress( + chipTool, " ***** Test Step 421 : Verify range-restricted signed 16-bit integer value has not changed\n"); + err = TestVerifyRangeRestrictedSigned16BitIntegerValueHasNotChanged_421(); break; case 422: - ChipLogProgress( - chipTool, " ***** Test Step 422 : Verify range-restricted signed 16-bit integer value is at min valid\n"); - err = TestVerifyRangeRestrictedSigned16BitIntegerValueIsAtMinValid_422(); + ChipLogProgress(chipTool, " ***** Test Step 422 : Write min valid value to a range-restricted signed 16-bit integer\n"); + err = TestWriteMinValidValueToARangeRestrictedSigned16BitInteger_422(); break; case 423: - ChipLogProgress(chipTool, " ***** Test Step 423 : Write max valid value to a range-restricted signed 16-bit integer\n"); - err = TestWriteMaxValidValueToARangeRestrictedSigned16BitInteger_423(); + ChipLogProgress( + chipTool, " ***** Test Step 423 : Verify range-restricted signed 16-bit integer value is at min valid\n"); + err = TestVerifyRangeRestrictedSigned16BitIntegerValueIsAtMinValid_423(); break; case 424: - ChipLogProgress( - chipTool, " ***** Test Step 424 : Verify range-restricted signed 16-bit integer value is at max valid\n"); - err = TestVerifyRangeRestrictedSigned16BitIntegerValueIsAtMaxValid_424(); + ChipLogProgress(chipTool, " ***** Test Step 424 : Write max valid value to a range-restricted signed 16-bit integer\n"); + err = TestWriteMaxValidValueToARangeRestrictedSigned16BitInteger_424(); break; case 425: ChipLogProgress( - chipTool, " ***** Test Step 425 : Write middle valid value to a range-restricted signed 16-bit integer\n"); - err = TestWriteMiddleValidValueToARangeRestrictedSigned16BitInteger_425(); + chipTool, " ***** Test Step 425 : Verify range-restricted signed 16-bit integer value is at max valid\n"); + err = TestVerifyRangeRestrictedSigned16BitIntegerValueIsAtMaxValid_425(); break; case 426: ChipLogProgress( - chipTool, " ***** Test Step 426 : Verify range-restricted signed 16-bit integer value is at mid valid\n"); - err = TestVerifyRangeRestrictedSigned16BitIntegerValueIsAtMidValid_426(); + chipTool, " ***** Test Step 426 : Write middle valid value to a range-restricted signed 16-bit integer\n"); + err = TestWriteMiddleValidValueToARangeRestrictedSigned16BitInteger_426(); break; case 427: - ChipLogProgress(chipTool, " ***** Test Step 427 : Read nullable range-restricted unsigned 8-bit integer\n"); - err = TestReadNullableRangeRestrictedUnsigned8BitInteger_427(); + ChipLogProgress( + chipTool, " ***** Test Step 427 : Verify range-restricted signed 16-bit integer value is at mid valid\n"); + err = TestVerifyRangeRestrictedSigned16BitIntegerValueIsAtMidValid_427(); break; case 428: - ChipLogProgress( - chipTool, " ***** Test Step 428 : Write min value to a nullable range-restricted unsigned 8-bit integer\n"); - err = TestWriteMinValueToANullableRangeRestrictedUnsigned8BitInteger_428(); + ChipLogProgress(chipTool, " ***** Test Step 428 : Read nullable range-restricted unsigned 8-bit integer\n"); + err = TestReadNullableRangeRestrictedUnsigned8BitInteger_428(); break; case 429: - ChipLogProgress(chipTool, - " ***** Test Step 429 : Write just-below-range value to a nullable range-restricted unsigned 8-bit integer\n"); - err = TestWriteJustBelowRangeValueToANullableRangeRestrictedUnsigned8BitInteger_429(); + ChipLogProgress( + chipTool, " ***** Test Step 429 : Write min value to a nullable range-restricted unsigned 8-bit integer\n"); + err = TestWriteMinValueToANullableRangeRestrictedUnsigned8BitInteger_429(); break; case 430: ChipLogProgress(chipTool, - " ***** Test Step 430 : Write just-above-range value to a nullable range-restricted unsigned 8-bit integer\n"); - err = TestWriteJustAboveRangeValueToANullableRangeRestrictedUnsigned8BitInteger_430(); + " ***** Test Step 430 : Write just-below-range value to a nullable range-restricted unsigned 8-bit integer\n"); + err = TestWriteJustBelowRangeValueToANullableRangeRestrictedUnsigned8BitInteger_430(); break; case 431: - ChipLogProgress( - chipTool, " ***** Test Step 431 : Write max value to a nullable range-restricted unsigned 8-bit integer\n"); - err = TestWriteMaxValueToANullableRangeRestrictedUnsigned8BitInteger_431(); + ChipLogProgress(chipTool, + " ***** Test Step 431 : Write just-above-range value to a nullable range-restricted unsigned 8-bit integer\n"); + err = TestWriteJustAboveRangeValueToANullableRangeRestrictedUnsigned8BitInteger_431(); break; case 432: ChipLogProgress( - chipTool, " ***** Test Step 432 : Verify nullable range-restricted unsigned 8-bit integer value has not changed\n"); - err = TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueHasNotChanged_432(); + chipTool, " ***** Test Step 432 : Write max value to a nullable range-restricted unsigned 8-bit integer\n"); + err = TestWriteMaxValueToANullableRangeRestrictedUnsigned8BitInteger_432(); break; case 433: ChipLogProgress( - chipTool, " ***** Test Step 433 : Write min valid value to a nullable range-restricted unsigned 8-bit integer\n"); - err = TestWriteMinValidValueToANullableRangeRestrictedUnsigned8BitInteger_433(); + chipTool, " ***** Test Step 433 : Verify nullable range-restricted unsigned 8-bit integer value has not changed\n"); + err = TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueHasNotChanged_433(); break; case 434: ChipLogProgress( - chipTool, " ***** Test Step 434 : Verify nullable range-restricted unsigned 8-bit integer value is at min valid\n"); - err = TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsAtMinValid_434(); + chipTool, " ***** Test Step 434 : Write min valid value to a nullable range-restricted unsigned 8-bit integer\n"); + err = TestWriteMinValidValueToANullableRangeRestrictedUnsigned8BitInteger_434(); break; case 435: ChipLogProgress( - chipTool, " ***** Test Step 435 : Write max valid value to a nullable range-restricted unsigned 8-bit integer\n"); - err = TestWriteMaxValidValueToANullableRangeRestrictedUnsigned8BitInteger_435(); + chipTool, " ***** Test Step 435 : Verify nullable range-restricted unsigned 8-bit integer value is at min valid\n"); + err = TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsAtMinValid_435(); break; case 436: ChipLogProgress( - chipTool, " ***** Test Step 436 : Verify nullable range-restricted unsigned 8-bit integer value is at max valid\n"); - err = TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsAtMaxValid_436(); + chipTool, " ***** Test Step 436 : Write max valid value to a nullable range-restricted unsigned 8-bit integer\n"); + err = TestWriteMaxValidValueToANullableRangeRestrictedUnsigned8BitInteger_436(); break; case 437: - ChipLogProgress(chipTool, - " ***** Test Step 437 : Write middle valid value to a nullable range-restricted unsigned 8-bit integer\n"); - err = TestWriteMiddleValidValueToANullableRangeRestrictedUnsigned8BitInteger_437(); + ChipLogProgress( + chipTool, " ***** Test Step 437 : Verify nullable range-restricted unsigned 8-bit integer value is at max valid\n"); + err = TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsAtMaxValid_437(); break; case 438: - ChipLogProgress( - chipTool, " ***** Test Step 438 : Verify nullable range-restricted unsigned 8-bit integer value is at mid valid\n"); - err = TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsAtMidValid_438(); + ChipLogProgress(chipTool, + " ***** Test Step 438 : Write middle valid value to a nullable range-restricted unsigned 8-bit integer\n"); + err = TestWriteMiddleValidValueToANullableRangeRestrictedUnsigned8BitInteger_438(); break; case 439: ChipLogProgress( - chipTool, " ***** Test Step 439 : Write null value to a nullable range-restricted unsigned 8-bit integer\n"); - err = TestWriteNullValueToANullableRangeRestrictedUnsigned8BitInteger_439(); + chipTool, " ***** Test Step 439 : Verify nullable range-restricted unsigned 8-bit integer value is at mid valid\n"); + err = TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsAtMidValid_439(); break; case 440: ChipLogProgress( - chipTool, " ***** Test Step 440 : Verify nullable range-restricted unsigned 8-bit integer value is null\n"); - err = TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsNull_440(); + chipTool, " ***** Test Step 440 : Write null value to a nullable range-restricted unsigned 8-bit integer\n"); + err = TestWriteNullValueToANullableRangeRestrictedUnsigned8BitInteger_440(); break; case 441: - ChipLogProgress(chipTool, " ***** Test Step 441 : Read nullable range-restricted unsigned 16-bit integer\n"); - err = TestReadNullableRangeRestrictedUnsigned16BitInteger_441(); + ChipLogProgress( + chipTool, " ***** Test Step 441 : Verify nullable range-restricted unsigned 8-bit integer value is null\n"); + err = TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsNull_441(); break; case 442: - ChipLogProgress( - chipTool, " ***** Test Step 442 : Write min value to a nullable range-restricted unsigned 16-bit integer\n"); - err = TestWriteMinValueToANullableRangeRestrictedUnsigned16BitInteger_442(); + ChipLogProgress(chipTool, " ***** Test Step 442 : Read nullable range-restricted unsigned 16-bit integer\n"); + err = TestReadNullableRangeRestrictedUnsigned16BitInteger_442(); break; case 443: - ChipLogProgress(chipTool, - " ***** Test Step 443 : Write just-below-range value to a nullable range-restricted unsigned 16-bit integer\n"); - err = TestWriteJustBelowRangeValueToANullableRangeRestrictedUnsigned16BitInteger_443(); + ChipLogProgress( + chipTool, " ***** Test Step 443 : Write min value to a nullable range-restricted unsigned 16-bit integer\n"); + err = TestWriteMinValueToANullableRangeRestrictedUnsigned16BitInteger_443(); break; case 444: ChipLogProgress(chipTool, - " ***** Test Step 444 : Write just-above-range value to a nullable range-restricted unsigned 16-bit integer\n"); - err = TestWriteJustAboveRangeValueToANullableRangeRestrictedUnsigned16BitInteger_444(); + " ***** Test Step 444 : Write just-below-range value to a nullable range-restricted unsigned 16-bit integer\n"); + err = TestWriteJustBelowRangeValueToANullableRangeRestrictedUnsigned16BitInteger_444(); break; case 445: - ChipLogProgress( - chipTool, " ***** Test Step 445 : Write max value to a nullable range-restricted unsigned 16-bit integer\n"); - err = TestWriteMaxValueToANullableRangeRestrictedUnsigned16BitInteger_445(); + ChipLogProgress(chipTool, + " ***** Test Step 445 : Write just-above-range value to a nullable range-restricted unsigned 16-bit integer\n"); + err = TestWriteJustAboveRangeValueToANullableRangeRestrictedUnsigned16BitInteger_445(); break; case 446: - ChipLogProgress(chipTool, - " ***** Test Step 446 : Verify nullable range-restricted unsigned 16-bit integer value has not changed\n"); - err = TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueHasNotChanged_446(); + ChipLogProgress( + chipTool, " ***** Test Step 446 : Write max value to a nullable range-restricted unsigned 16-bit integer\n"); + err = TestWriteMaxValueToANullableRangeRestrictedUnsigned16BitInteger_446(); break; case 447: - ChipLogProgress( - chipTool, " ***** Test Step 447 : Write min valid value to a nullable range-restricted unsigned 16-bit integer\n"); - err = TestWriteMinValidValueToANullableRangeRestrictedUnsigned16BitInteger_447(); + ChipLogProgress(chipTool, + " ***** Test Step 447 : Verify nullable range-restricted unsigned 16-bit integer value has not changed\n"); + err = TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueHasNotChanged_447(); break; case 448: - ChipLogProgress(chipTool, - " ***** Test Step 448 : Verify nullable range-restricted unsigned 16-bit integer value is at min valid\n"); - err = TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsAtMinValid_448(); + ChipLogProgress( + chipTool, " ***** Test Step 448 : Write min valid value to a nullable range-restricted unsigned 16-bit integer\n"); + err = TestWriteMinValidValueToANullableRangeRestrictedUnsigned16BitInteger_448(); break; case 449: - ChipLogProgress( - chipTool, " ***** Test Step 449 : Write max valid value to a nullable range-restricted unsigned 16-bit integer\n"); - err = TestWriteMaxValidValueToANullableRangeRestrictedUnsigned16BitInteger_449(); + ChipLogProgress(chipTool, + " ***** Test Step 449 : Verify nullable range-restricted unsigned 16-bit integer value is at min valid\n"); + err = TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsAtMinValid_449(); break; case 450: - ChipLogProgress(chipTool, - " ***** Test Step 450 : Verify nullable range-restricted unsigned 16-bit integer value is at max valid\n"); - err = TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsAtMaxValid_450(); + ChipLogProgress( + chipTool, " ***** Test Step 450 : Write max valid value to a nullable range-restricted unsigned 16-bit integer\n"); + err = TestWriteMaxValidValueToANullableRangeRestrictedUnsigned16BitInteger_450(); break; case 451: ChipLogProgress(chipTool, - " ***** Test Step 451 : Write middle valid value to a nullable range-restricted unsigned 16-bit integer\n"); - err = TestWriteMiddleValidValueToANullableRangeRestrictedUnsigned16BitInteger_451(); + " ***** Test Step 451 : Verify nullable range-restricted unsigned 16-bit integer value is at max valid\n"); + err = TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsAtMaxValid_451(); break; case 452: ChipLogProgress(chipTool, - " ***** Test Step 452 : Verify nullable range-restricted unsigned 16-bit integer value is at mid valid\n"); - err = TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsAtMidValid_452(); + " ***** Test Step 452 : Write middle valid value to a nullable range-restricted unsigned 16-bit integer\n"); + err = TestWriteMiddleValidValueToANullableRangeRestrictedUnsigned16BitInteger_452(); break; case 453: - ChipLogProgress( - chipTool, " ***** Test Step 453 : Write null value to a nullable range-restricted unsigned 16-bit integer\n"); - err = TestWriteNullValueToANullableRangeRestrictedUnsigned16BitInteger_453(); + ChipLogProgress(chipTool, + " ***** Test Step 453 : Verify nullable range-restricted unsigned 16-bit integer value is at mid valid\n"); + err = TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsAtMidValid_453(); break; case 454: ChipLogProgress( - chipTool, " ***** Test Step 454 : Verify nullable range-restricted unsigned 16-bit integer value is null\n"); - err = TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsNull_454(); + chipTool, " ***** Test Step 454 : Write null value to a nullable range-restricted unsigned 16-bit integer\n"); + err = TestWriteNullValueToANullableRangeRestrictedUnsigned16BitInteger_454(); break; case 455: - ChipLogProgress(chipTool, " ***** Test Step 455 : Read nullable range-restricted signed 8-bit integer\n"); - err = TestReadNullableRangeRestrictedSigned8BitInteger_455(); + ChipLogProgress( + chipTool, " ***** Test Step 455 : Verify nullable range-restricted unsigned 16-bit integer value is null\n"); + err = TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsNull_455(); break; case 456: - ChipLogProgress( - chipTool, " ***** Test Step 456 : Write min value to a nullable range-restricted signed 8-bit integer\n"); - err = TestWriteMinValueToANullableRangeRestrictedSigned8BitInteger_456(); + ChipLogProgress(chipTool, " ***** Test Step 456 : Read nullable range-restricted signed 8-bit integer\n"); + err = TestReadNullableRangeRestrictedSigned8BitInteger_456(); break; case 457: - ChipLogProgress(chipTool, - " ***** Test Step 457 : Write just-below-range value to a nullable range-restricted signed 8-bit integer\n"); - err = TestWriteJustBelowRangeValueToANullableRangeRestrictedSigned8BitInteger_457(); + ChipLogProgress( + chipTool, " ***** Test Step 457 : Write min value to a nullable range-restricted signed 8-bit integer\n"); + err = TestWriteMinValueToANullableRangeRestrictedSigned8BitInteger_457(); break; case 458: ChipLogProgress(chipTool, - " ***** Test Step 458 : Write just-above-range value to a nullable range-restricted signed 8-bit integer\n"); - err = TestWriteJustAboveRangeValueToANullableRangeRestrictedSigned8BitInteger_458(); + " ***** Test Step 458 : Write just-below-range value to a nullable range-restricted signed 8-bit integer\n"); + err = TestWriteJustBelowRangeValueToANullableRangeRestrictedSigned8BitInteger_458(); break; case 459: - ChipLogProgress( - chipTool, " ***** Test Step 459 : Write max value to a nullable range-restricted signed 8-bit integer\n"); - err = TestWriteMaxValueToANullableRangeRestrictedSigned8BitInteger_459(); + ChipLogProgress(chipTool, + " ***** Test Step 459 : Write just-above-range value to a nullable range-restricted signed 8-bit integer\n"); + err = TestWriteJustAboveRangeValueToANullableRangeRestrictedSigned8BitInteger_459(); break; case 460: ChipLogProgress( - chipTool, " ***** Test Step 460 : Verify nullable range-restricted signed 8-bit integer value has not changed\n"); - err = TestVerifyNullableRangeRestrictedSigned8BitIntegerValueHasNotChanged_460(); + chipTool, " ***** Test Step 460 : Write max value to a nullable range-restricted signed 8-bit integer\n"); + err = TestWriteMaxValueToANullableRangeRestrictedSigned8BitInteger_460(); break; case 461: ChipLogProgress( - chipTool, " ***** Test Step 461 : Write min valid value to a nullable range-restricted signed 8-bit integer\n"); - err = TestWriteMinValidValueToANullableRangeRestrictedSigned8BitInteger_461(); + chipTool, " ***** Test Step 461 : Verify nullable range-restricted signed 8-bit integer value has not changed\n"); + err = TestVerifyNullableRangeRestrictedSigned8BitIntegerValueHasNotChanged_461(); break; case 462: ChipLogProgress( - chipTool, " ***** Test Step 462 : Verify nullable range-restricted signed 8-bit integer value is at min valid\n"); - err = TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtMinValid_462(); + chipTool, " ***** Test Step 462 : Write min valid value to a nullable range-restricted signed 8-bit integer\n"); + err = TestWriteMinValidValueToANullableRangeRestrictedSigned8BitInteger_462(); break; case 463: ChipLogProgress( - chipTool, " ***** Test Step 463 : Write max valid value to a nullable range-restricted signed 8-bit integer\n"); - err = TestWriteMaxValidValueToANullableRangeRestrictedSigned8BitInteger_463(); + chipTool, " ***** Test Step 463 : Verify nullable range-restricted signed 8-bit integer value is at min valid\n"); + err = TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtMinValid_463(); break; case 464: ChipLogProgress( - chipTool, " ***** Test Step 464 : Verify nullable range-restricted signed 8-bit integer value is at max valid\n"); - err = TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtMaxValid_464(); + chipTool, " ***** Test Step 464 : Write max valid value to a nullable range-restricted signed 8-bit integer\n"); + err = TestWriteMaxValidValueToANullableRangeRestrictedSigned8BitInteger_464(); break; case 465: ChipLogProgress( - chipTool, " ***** Test Step 465 : Write middle valid value to a nullable range-restricted signed 8-bit integer\n"); - err = TestWriteMiddleValidValueToANullableRangeRestrictedSigned8BitInteger_465(); + chipTool, " ***** Test Step 465 : Verify nullable range-restricted signed 8-bit integer value is at max valid\n"); + err = TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtMaxValid_465(); break; case 466: ChipLogProgress( - chipTool, " ***** Test Step 466 : Verify nullable range-restricted signed 8-bit integer value is at mid valid\n"); - err = TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtMidValid_466(); + chipTool, " ***** Test Step 466 : Write middle valid value to a nullable range-restricted signed 8-bit integer\n"); + err = TestWriteMiddleValidValueToANullableRangeRestrictedSigned8BitInteger_466(); break; case 467: ChipLogProgress( - chipTool, " ***** Test Step 467 : Write null value to a nullable range-restricted signed 8-bit integer\n"); - err = TestWriteNullValueToANullableRangeRestrictedSigned8BitInteger_467(); + chipTool, " ***** Test Step 467 : Verify nullable range-restricted signed 8-bit integer value is at mid valid\n"); + err = TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtMidValid_467(); break; case 468: ChipLogProgress( - chipTool, " ***** Test Step 468 : Verify nullable range-restricted signed 8-bit integer value is at null\n"); - err = TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtNull_468(); + chipTool, " ***** Test Step 468 : Write null value to a nullable range-restricted signed 8-bit integer\n"); + err = TestWriteNullValueToANullableRangeRestrictedSigned8BitInteger_468(); break; case 469: - ChipLogProgress(chipTool, " ***** Test Step 469 : Read nullable range-restricted signed 16-bit integer\n"); - err = TestReadNullableRangeRestrictedSigned16BitInteger_469(); + ChipLogProgress( + chipTool, " ***** Test Step 469 : Verify nullable range-restricted signed 8-bit integer value is at null\n"); + err = TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtNull_469(); break; case 470: - ChipLogProgress( - chipTool, " ***** Test Step 470 : Write min value to a nullable range-restricted signed 16-bit integer\n"); - err = TestWriteMinValueToANullableRangeRestrictedSigned16BitInteger_470(); + ChipLogProgress(chipTool, " ***** Test Step 470 : Read nullable range-restricted signed 16-bit integer\n"); + err = TestReadNullableRangeRestrictedSigned16BitInteger_470(); break; case 471: - ChipLogProgress(chipTool, - " ***** Test Step 471 : Write just-below-range value to a nullable range-restricted signed 16-bit integer\n"); - err = TestWriteJustBelowRangeValueToANullableRangeRestrictedSigned16BitInteger_471(); + ChipLogProgress( + chipTool, " ***** Test Step 471 : Write min value to a nullable range-restricted signed 16-bit integer\n"); + err = TestWriteMinValueToANullableRangeRestrictedSigned16BitInteger_471(); break; case 472: ChipLogProgress(chipTool, - " ***** Test Step 472 : Write just-above-range value to a nullable range-restricted signed 16-bit integer\n"); - err = TestWriteJustAboveRangeValueToANullableRangeRestrictedSigned16BitInteger_472(); + " ***** Test Step 472 : Write just-below-range value to a nullable range-restricted signed 16-bit integer\n"); + err = TestWriteJustBelowRangeValueToANullableRangeRestrictedSigned16BitInteger_472(); break; case 473: - ChipLogProgress( - chipTool, " ***** Test Step 473 : Write max value to a nullable range-restricted signed 16-bit integer\n"); - err = TestWriteMaxValueToANullableRangeRestrictedSigned16BitInteger_473(); + ChipLogProgress(chipTool, + " ***** Test Step 473 : Write just-above-range value to a nullable range-restricted signed 16-bit integer\n"); + err = TestWriteJustAboveRangeValueToANullableRangeRestrictedSigned16BitInteger_473(); break; case 474: ChipLogProgress( - chipTool, " ***** Test Step 474 : Verify nullable range-restricted signed 16-bit integer value has not changed\n"); - err = TestVerifyNullableRangeRestrictedSigned16BitIntegerValueHasNotChanged_474(); + chipTool, " ***** Test Step 474 : Write max value to a nullable range-restricted signed 16-bit integer\n"); + err = TestWriteMaxValueToANullableRangeRestrictedSigned16BitInteger_474(); break; case 475: ChipLogProgress( - chipTool, " ***** Test Step 475 : Write min valid value to a nullable range-restricted signed 16-bit integer\n"); - err = TestWriteMinValidValueToANullableRangeRestrictedSigned16BitInteger_475(); + chipTool, " ***** Test Step 475 : Verify nullable range-restricted signed 16-bit integer value has not changed\n"); + err = TestVerifyNullableRangeRestrictedSigned16BitIntegerValueHasNotChanged_475(); break; case 476: ChipLogProgress( - chipTool, " ***** Test Step 476 : Verify nullable range-restricted signed 16-bit integer value is at min valid\n"); - err = TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsAtMinValid_476(); + chipTool, " ***** Test Step 476 : Write min valid value to a nullable range-restricted signed 16-bit integer\n"); + err = TestWriteMinValidValueToANullableRangeRestrictedSigned16BitInteger_476(); break; case 477: ChipLogProgress( - chipTool, " ***** Test Step 477 : Write max valid value to a nullable range-restricted signed 16-bit integer\n"); - err = TestWriteMaxValidValueToANullableRangeRestrictedSigned16BitInteger_477(); + chipTool, " ***** Test Step 477 : Verify nullable range-restricted signed 16-bit integer value is at min valid\n"); + err = TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsAtMinValid_477(); break; case 478: ChipLogProgress( - chipTool, " ***** Test Step 478 : Verify nullable range-restricted signed 16-bit integer value is at max valid\n"); - err = TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsAtMaxValid_478(); + chipTool, " ***** Test Step 478 : Write max valid value to a nullable range-restricted signed 16-bit integer\n"); + err = TestWriteMaxValidValueToANullableRangeRestrictedSigned16BitInteger_478(); break; case 479: ChipLogProgress( - chipTool, " ***** Test Step 479 : Write middle valid value to a nullable range-restricted signed 16-bit integer\n"); - err = TestWriteMiddleValidValueToANullableRangeRestrictedSigned16BitInteger_479(); + chipTool, " ***** Test Step 479 : Verify nullable range-restricted signed 16-bit integer value is at max valid\n"); + err = TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsAtMaxValid_479(); break; case 480: ChipLogProgress( - chipTool, " ***** Test Step 480 : Verify nullable range-restricted signed 16-bit integer value is at mid valid\n"); - err = TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsAtMidValid_480(); + chipTool, " ***** Test Step 480 : Write middle valid value to a nullable range-restricted signed 16-bit integer\n"); + err = TestWriteMiddleValidValueToANullableRangeRestrictedSigned16BitInteger_480(); break; case 481: ChipLogProgress( - chipTool, " ***** Test Step 481 : Write null value to a nullable range-restricted signed 16-bit integer\n"); - err = TestWriteNullValueToANullableRangeRestrictedSigned16BitInteger_481(); + chipTool, " ***** Test Step 481 : Verify nullable range-restricted signed 16-bit integer value is at mid valid\n"); + err = TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsAtMidValid_481(); break; case 482: ChipLogProgress( - chipTool, " ***** Test Step 482 : Verify nullable range-restricted signed 16-bit integer value is null\n"); - err = TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsNull_482(); + chipTool, " ***** Test Step 482 : Write null value to a nullable range-restricted signed 16-bit integer\n"); + err = TestWriteNullValueToANullableRangeRestrictedSigned16BitInteger_482(); break; case 483: - ChipLogProgress(chipTool, " ***** Test Step 483 : Write attribute that returns general status on write\n"); - err = TestWriteAttributeThatReturnsGeneralStatusOnWrite_483(); + ChipLogProgress( + chipTool, " ***** Test Step 483 : Verify nullable range-restricted signed 16-bit integer value is null\n"); + err = TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsNull_483(); break; case 484: - ChipLogProgress(chipTool, " ***** Test Step 484 : Write attribute that returns cluster-specific status on write\n"); - err = TestWriteAttributeThatReturnsClusterSpecificStatusOnWrite_484(); + ChipLogProgress(chipTool, " ***** Test Step 484 : Write attribute that returns general status on write\n"); + err = TestWriteAttributeThatReturnsGeneralStatusOnWrite_484(); break; case 485: - ChipLogProgress(chipTool, " ***** Test Step 485 : Read attribute that returns general status on read\n"); - err = TestReadAttributeThatReturnsGeneralStatusOnRead_485(); + ChipLogProgress(chipTool, " ***** Test Step 485 : Write attribute that returns cluster-specific status on write\n"); + err = TestWriteAttributeThatReturnsClusterSpecificStatusOnWrite_485(); break; case 486: - ChipLogProgress(chipTool, " ***** Test Step 486 : read attribute that returns cluster-specific status on read\n"); - err = TestReadAttributeThatReturnsClusterSpecificStatusOnRead_486(); + ChipLogProgress(chipTool, " ***** Test Step 486 : Read attribute that returns general status on read\n"); + err = TestReadAttributeThatReturnsGeneralStatusOnRead_486(); break; case 487: - ChipLogProgress(chipTool, " ***** Test Step 487 : read AcceptedCommandList attribute\n"); - err = TestReadAcceptedCommandListAttribute_487(); + ChipLogProgress(chipTool, " ***** Test Step 487 : read attribute that returns cluster-specific status on read\n"); + err = TestReadAttributeThatReturnsClusterSpecificStatusOnRead_487(); break; case 488: - ChipLogProgress(chipTool, " ***** Test Step 488 : read GeneratedCommandList attribute\n"); - err = TestReadGeneratedCommandListAttribute_488(); + ChipLogProgress(chipTool, " ***** Test Step 488 : read AcceptedCommandList attribute\n"); + err = TestReadAcceptedCommandListAttribute_488(); break; case 489: - ChipLogProgress(chipTool, " ***** Test Step 489 : Write struct-typed attribute\n"); - err = TestWriteStructTypedAttribute_489(); + ChipLogProgress(chipTool, " ***** Test Step 489 : read GeneratedCommandList attribute\n"); + err = TestReadGeneratedCommandListAttribute_489(); break; case 490: - ChipLogProgress(chipTool, " ***** Test Step 490 : Read struct-typed attribute\n"); - err = TestReadStructTypedAttribute_490(); + ChipLogProgress(chipTool, " ***** Test Step 490 : Write struct-typed attribute\n"); + err = TestWriteStructTypedAttribute_490(); + break; + case 491: + ChipLogProgress(chipTool, " ***** Test Step 491 : Read struct-typed attribute\n"); + err = TestReadStructTypedAttribute_491(); break; } @@ -73920,13 +76951,13 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 148: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_ENDPOINT)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 149: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_CLUSTER)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_ENDPOINT)); break; case 150: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_CLUSTER)); break; case 151: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74043,10 +77074,10 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 189: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 190: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 191: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74064,10 +77095,10 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 196: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 197: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 198: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74082,10 +77113,10 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 202: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 203: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 204: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74100,10 +77131,10 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 208: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 209: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 210: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74124,10 +77155,10 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 216: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 217: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 218: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74166,10 +77197,10 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 230: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 231: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 232: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74205,10 +77236,10 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 243: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 244: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 245: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74244,10 +77275,10 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 256: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 257: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 258: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74277,10 +77308,10 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 267: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 268: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 269: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74310,10 +77341,10 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 278: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 279: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 280: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74343,10 +77374,10 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 289: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 290: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 291: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74376,10 +77407,10 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 300: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 301: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 302: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74475,10 +77506,10 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 333: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 334: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 335: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74499,10 +77530,10 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 341: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 342: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 343: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74523,10 +77554,10 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 349: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 350: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 351: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74589,16 +77620,16 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 371: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_ENDPOINT)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 372: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_CLUSTER)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_ENDPOINT)); break; case 373: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_VALUE)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_UNSUPPORTED_CLUSTER)); break; case 374: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 375: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74616,7 +77647,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 380: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 381: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); @@ -74628,7 +77659,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 384: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 385: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74652,7 +77683,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 392: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 393: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); @@ -74664,7 +77695,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 396: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 397: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74688,7 +77719,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 404: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 405: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); @@ -74700,7 +77731,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 408: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 409: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74724,7 +77755,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 416: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 417: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); @@ -74736,7 +77767,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 420: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 421: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74760,7 +77791,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 428: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 429: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); @@ -74772,7 +77803,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 432: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 433: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74802,7 +77833,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 442: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 443: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); @@ -74814,7 +77845,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 446: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 447: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74844,7 +77875,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 456: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 457: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); @@ -74856,7 +77887,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 460: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 461: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74886,7 +77917,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 470: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 471: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); @@ -74898,7 +77929,7 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 474: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); break; case 475: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74925,19 +77956,19 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 483: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_DATA_TYPE)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 484: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_FAILURE)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_DATA_TYPE)); break; case 485: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_DATA_TYPE)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_FAILURE)); break; case 486: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_FAILURE)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_DATA_TYPE)); break; case 487: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_FAILURE)); break; case 488: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -74948,6 +77979,9 @@ class TestCluster : public TestCommandBridge { case 490: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; + case 491: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; } // Go on to the next test. @@ -74961,7 +77995,7 @@ class TestCluster : public TestCommandBridge { private: std::atomic_uint16_t mTestIndex; - const uint16_t mTestCount = 491; + const uint16_t mTestCount = 492; chip::Optional mNodeId; chip::Optional mCluster; @@ -74970,6 +78004,7 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -74977,10 +78012,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestSendTestCommand_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster testWithCompletion:^(NSError * _Nullable err) { @@ -74996,10 +78030,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestSendTestNotHandledCommand_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster testNotHandledWithCompletion:^(NSError * _Nullable err) { @@ -75016,10 +78049,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestSendTestSpecificCommand_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster testSpecificWithCompletion:^( @@ -75041,10 +78073,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestSendTestAddArgumentsCommand_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestAddArgumentsParams alloc] init]; @@ -75070,10 +78101,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestSendFailingTestAddArgumentsCommand_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestAddArgumentsParams alloc] init]; @@ -75097,10 +78127,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeBooleanDefaultValue_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75121,10 +78150,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBooleanTrue_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id booleanArgument; @@ -75143,10 +78171,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeBooleanTrue_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75167,10 +78194,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBooleanFalse_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id booleanArgument; @@ -75189,10 +78215,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeBooleanFalse_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75213,10 +78238,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap8DefaultValue_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75237,10 +78261,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap8MaxValue_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap8Argument; @@ -75259,10 +78282,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap8MaxValue_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75283,10 +78305,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap8MinValue_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap8Argument; @@ -75305,10 +78326,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap8MinValue_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75329,10 +78349,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap16DefaultValue_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75353,10 +78372,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap16MaxValue_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap16Argument; @@ -75375,10 +78393,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap16MaxValue_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75399,10 +78416,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap16MinValue_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap16Argument; @@ -75421,10 +78437,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap16MinValue_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75445,10 +78460,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap32DefaultValue_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75469,10 +78483,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap32MaxValue_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap32Argument; @@ -75491,10 +78504,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap32MaxValue_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75515,10 +78527,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap32MinValue_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap32Argument; @@ -75537,10 +78548,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap32MinValue_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75561,10 +78571,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap64DefaultValue_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap64WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75585,10 +78594,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap64MaxValue_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap64Argument; @@ -75607,10 +78615,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap64MaxValue_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap64WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75631,10 +78638,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap64MinValue_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap64Argument; @@ -75653,10 +78659,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap64MinValue_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap64WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75677,10 +78682,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt8uDefaultValue_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75701,10 +78705,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt8uMaxValue_32() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int8uArgument; @@ -75723,10 +78726,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt8uMaxValue_33() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75747,10 +78749,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt8uMinValue_34() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int8uArgument; @@ -75769,10 +78770,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt8uMinValue_35() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75793,10 +78793,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt16uDefaultValue_36() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75817,10 +78816,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt16uMaxValue_37() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int16uArgument; @@ -75839,10 +78837,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt16uMaxValue_38() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75863,10 +78860,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt16uMinValue_39() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int16uArgument; @@ -75885,10 +78881,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt16uMinValue_40() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75909,10 +78904,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt32uDefaultValue_41() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75933,10 +78927,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt32uMaxValue_42() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int32uArgument; @@ -75955,10 +78948,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt32uMaxValue_43() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -75979,10 +78971,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt32uMinValue_44() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int32uArgument; @@ -76001,10 +78992,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt32uMinValue_45() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76025,10 +79015,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt64uDefaultValue_46() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76049,10 +79038,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt64uMaxValue_47() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int64uArgument; @@ -76071,10 +79059,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt64uMaxValue_48() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76095,10 +79082,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt64uMinValue_49() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int64uArgument; @@ -76117,10 +79103,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt64uMinValue_50() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76141,10 +79126,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt8sDefaultValue_51() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76165,10 +79149,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt8sMaxValue_52() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int8sArgument; @@ -76187,10 +79170,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt8sMaxValue_53() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76211,10 +79193,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt8sMinValue_54() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int8sArgument; @@ -76233,10 +79214,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt8sMinValue_55() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76257,10 +79237,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt8sDefaultValue_56() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int8sArgument; @@ -76279,10 +79258,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt8sDefaultValue_57() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76303,10 +79281,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt16sDefaultValue_58() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76327,10 +79304,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt16sMaxValue_59() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int16sArgument; @@ -76349,10 +79325,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt16sMaxValue_60() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76373,10 +79348,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt16sMinValue_61() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int16sArgument; @@ -76395,10 +79369,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt16sMinValue_62() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76419,10 +79392,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt16sDefaultValue_63() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int16sArgument; @@ -76441,10 +79413,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt16sDefaultValue_64() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76465,10 +79436,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt32sDefaultValue_65() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76489,10 +79459,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt32sMaxValue_66() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int32sArgument; @@ -76511,10 +79480,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt32sMaxValue_67() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76535,10 +79503,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt32sMinValue_68() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int32sArgument; @@ -76557,10 +79524,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt32sMinValue_69() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76581,10 +79547,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt32sDefaultValue_70() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int32sArgument; @@ -76603,10 +79568,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt32sDefaultValue_71() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76627,10 +79591,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt64sDefaultValue_72() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76651,10 +79614,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt64sMaxValue_73() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int64sArgument; @@ -76673,10 +79635,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt64sMaxValue_74() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76697,10 +79658,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt64sMinValue_75() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int64sArgument; @@ -76719,10 +79679,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt64sMinValue_76() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76743,10 +79702,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt64sDefaultValue_77() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int64sArgument; @@ -76765,10 +79723,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt64sDefaultValue_78() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76789,10 +79746,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeSingleDefaultValue_79() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFloatSingleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76813,10 +79769,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeSingleMediumValue_80() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id floatSingleArgument; @@ -76835,10 +79790,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeSingleMediumValue_81() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFloatSingleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76859,10 +79813,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeSingleLargeValue_82() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id floatSingleArgument; @@ -76881,10 +79834,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeSingleLargeValue_83() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFloatSingleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76905,10 +79857,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeSingleSmallValue_84() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id floatSingleArgument; @@ -76927,10 +79878,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeSingleSmallValue_85() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFloatSingleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76951,10 +79901,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeSingleDefaultValue_86() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id floatSingleArgument; @@ -76973,10 +79922,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeSingleDefaultValue_87() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFloatSingleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -76997,10 +79945,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeDoubleDefaultValue_88() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFloatDoubleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -77021,10 +79968,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeDoubleMediumValue_89() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id floatDoubleArgument; @@ -77043,10 +79989,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeDoubleMediumValue_90() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFloatDoubleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -77067,10 +80012,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeDoubleLargeValue_91() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id floatDoubleArgument; @@ -77089,10 +80033,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeDoubleLargeValue_92() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFloatDoubleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -77113,10 +80056,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeDoubleSmallValue_93() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id floatDoubleArgument; @@ -77135,10 +80077,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeDoubleSmallValue_94() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFloatDoubleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -77159,10 +80100,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeDoubleDefaultValue_95() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id floatDoubleArgument; @@ -77181,10 +80121,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeDoubleDefaultValue_96() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFloatDoubleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -77205,10 +80144,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeEnum8DefaultValue_97() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnum8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -77229,10 +80167,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeEnum8MaxValue_98() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id enum8Argument; @@ -77251,10 +80188,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeEnum8MaxValue_99() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnum8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -77275,10 +80211,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeEnum8MinValue_100() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id enum8Argument; @@ -77297,10 +80232,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeEnum8MinValue_101() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnum8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -77321,10 +80255,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeEnum16DefaultValue_102() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnum16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -77345,10 +80278,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeEnum16MaxValue_103() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id enum16Argument; @@ -77367,10 +80299,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeEnum16MaxValue_104() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnum16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -77391,10 +80322,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeEnum16MinValue_105() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id enum16Argument; @@ -77413,10 +80343,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeEnum16MinValue_106() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnum16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -77437,10 +80366,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeOctetStringDefaultValue_107() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -77461,10 +80389,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeOctetStringWithEmbeddedNull_108() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id octetStringArgument; @@ -77483,10 +80410,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeOctetStringWithEmbeddedNull_109() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -77508,10 +80434,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeOctetStringWithHexFormat_110() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id octetStringArgument; @@ -77530,10 +80455,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeOctetStringWithHexFormat_111() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -77555,10 +80479,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeOctetStringWithWeirdChars_112() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id octetStringArgument; @@ -77577,10 +80500,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeOctetStringWithWeirdChars_113() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -77602,10 +80524,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeOctetString_114() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id octetStringArgument; @@ -77624,10 +80545,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeOctetString_115() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -77649,10 +80569,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeOctetString_116() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id octetStringArgument; @@ -77675,10 +80594,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeOctetString_117() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -77700,10 +80618,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeOctetString_118() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id octetStringArgument; @@ -77722,10 +80639,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeLongOctetStringDefaultValue_119() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLongOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -77746,10 +80662,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeLongOctetString_120() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id longOctetStringArgument; @@ -77772,10 +80687,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeLongOctetString_121() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLongOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -77802,10 +80716,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeLongOctetString_122() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id longOctetStringArgument; @@ -77824,10 +80737,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeCharStringDefaultValue_123() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -77848,10 +80760,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeCharString_124() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id charStringArgument; @@ -77870,10 +80781,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeCharString_125() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -77894,10 +80804,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeCharStringValueTooLong_126() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id charStringArgument; @@ -77920,10 +80829,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeCharString_127() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -77944,10 +80852,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeCharStringEmpty_128() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id charStringArgument; @@ -77966,10 +80873,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeLongCharStringDefaultValue_129() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLongCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -77990,10 +80896,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeLongCharString_130() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id longCharStringArgument; @@ -78015,10 +80920,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeLongCharString_131() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLongCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -78042,10 +80946,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeLongCharString_132() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id longCharStringArgument; @@ -78064,10 +80967,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeListLongOctetStringForChunkedRead_133() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeListLongOctetStringWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -78124,10 +81026,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestWriteAttributeListLongOctetStringForChunkedWrite_134() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id listLongOctetStringArgument; @@ -78190,10 +81091,9 @@ class TestCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeListLongOctetStringForChunkedRead_135() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeListLongOctetStringWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -78257,12 +81157,68 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeEpochUsDefaultValue_136() + CHIP_ERROR TestWriteAttributeListLongOctetStringForChunkedWrite_136() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + id listLongOctetStringArgument; + { + NSMutableArray * temp_0 = [[NSMutableArray alloc] init]; + temp_0[0] = [[NSData alloc] + initWithBytes: + "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcd" + "ef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789ab" + "cdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789" + "abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef01234567" + "89abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef" + length:512]; + temp_0[1] = [[NSData alloc] + initWithBytes: + "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcd" + "ef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789ab" + "cdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789" + "abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef01234567" + "89abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef" + length:512]; + temp_0[2] = [[NSData alloc] + initWithBytes: + "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcd" + "ef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789ab" + "cdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789" + "abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef01234567" + "89abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef" + length:512]; + temp_0[3] = [[NSData alloc] + initWithBytes: + "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcd" + "ef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789ab" + "cdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789" + "abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef01234567" + "89abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef" + length:512]; + listLongOctetStringArgument = temp_0; + } + [cluster + writeAttributeListLongOctetStringWithValue:listLongOctetStringArgument + completion:^(NSError * _Nullable err) { + NSLog(@"Write attribute LIST_LONG_OCTET_STRING (for chunked write) Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestReadAttributeEpochUsDefaultValue_137() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEpochUsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -78281,12 +81237,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeEpochUsMaxValue_137() + CHIP_ERROR TestWriteAttributeEpochUsMaxValue_138() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id epochUsArgument; @@ -78303,12 +81258,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeEpochUsMaxValue_138() + CHIP_ERROR TestReadAttributeEpochUsMaxValue_139() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEpochUsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -78327,12 +81281,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeEpochUsMinValue_139() + CHIP_ERROR TestWriteAttributeEpochUsMinValue_140() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id epochUsArgument; @@ -78349,12 +81302,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeEpochUsMinValue_140() + CHIP_ERROR TestReadAttributeEpochUsMinValue_141() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEpochUsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -78373,12 +81325,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeEpochSDefaultValue_141() + CHIP_ERROR TestReadAttributeEpochSDefaultValue_142() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEpochSWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -78397,12 +81348,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeEpochSMaxValue_142() + CHIP_ERROR TestWriteAttributeEpochSMaxValue_143() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id epochSArgument; @@ -78419,12 +81369,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeEpochSMaxValue_143() + CHIP_ERROR TestReadAttributeEpochSMaxValue_144() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEpochSWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -78443,12 +81392,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeEpochSMinValue_144() + CHIP_ERROR TestWriteAttributeEpochSMinValue_145() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id epochSArgument; @@ -78465,12 +81413,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeEpochSMinValue_145() + CHIP_ERROR TestReadAttributeEpochSMinValue_146() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEpochSWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -78489,12 +81436,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeUnsupported_146() + CHIP_ERROR TestReadAttributeUnsupported_147() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeUnsupportedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -78518,12 +81464,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteattributeUnsupported_147() + CHIP_ERROR TestWriteattributeUnsupported_148() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id unsupportedArgument; @@ -78545,12 +81490,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandToUnsupportedEndpoint_148() + CHIP_ERROR TestSendTestCommandToUnsupportedEndpoint_149() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(200) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(200) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster testWithCompletion:^(NSError * _Nullable err) { @@ -78565,12 +81509,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandToUnsupportedCluster_149() + CHIP_ERROR TestSendTestCommandToUnsupportedCluster_150() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster testWithCompletion:^(NSError * _Nullable err) { @@ -78585,12 +81528,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeVendorIdDefaultValue_150() + CHIP_ERROR TestReadAttributeVendorIdDefaultValue_151() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeVendorIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -78609,12 +81551,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeVendorId_151() + CHIP_ERROR TestWriteAttributeVendorId_152() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id vendorIdArgument; @@ -78631,12 +81572,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeVendorId_152() + CHIP_ERROR TestReadAttributeVendorId_153() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeVendorIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -78655,12 +81595,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestRestoreAttributeVendorId_153() + CHIP_ERROR TestRestoreAttributeVendorId_154() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id vendorIdArgument; @@ -78677,12 +81616,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendACommandWithAVendorIdAndEnum_154() + CHIP_ERROR TestSendACommandWithAVendorIdAndEnum_155() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestEnumsRequestParams alloc] init]; @@ -78711,12 +81649,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendACommandWithAVendorIdAndInvalidEnum_155() + CHIP_ERROR TestSendACommandWithAVendorIdAndInvalidEnum_156() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestEnumsRequestParams alloc] init]; @@ -78745,12 +81682,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithStructArgumentAndArg1bIsTrue_156() + CHIP_ERROR TestSendTestCommandWithStructArgumentAndArg1bIsTrue_157() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestStructArgumentRequestParams alloc] init]; @@ -78782,12 +81718,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithStructArgumentAndArg1bIsFalse_157() + CHIP_ERROR TestSendTestCommandWithStructArgumentAndArg1bIsFalse_158() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestStructArgumentRequestParams alloc] init]; @@ -78819,12 +81754,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithNestedStructArgumentAndArg1cbIsTrue_158() + CHIP_ERROR TestSendTestCommandWithNestedStructArgumentAndArg1cbIsTrue_159() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestNestedStructArgumentRequestParams alloc] init]; @@ -78869,12 +81803,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithNestedStructArgumentArg1cbIsFalse_159() + CHIP_ERROR TestSendTestCommandWithNestedStructArgumentArg1cbIsFalse_160() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestNestedStructArgumentRequestParams alloc] init]; @@ -78918,12 +81851,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithNestedStructListArgumentAndAllFieldsBOfArg1dAreTrue_160() + CHIP_ERROR TestSendTestCommandWithNestedStructListArgumentAndAllFieldsBOfArg1dAreTrue_161() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestNestedStructListArgumentRequestParams alloc] init]; @@ -79012,12 +81944,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithNestedStructListArgumentAndSomeFieldsBOfArg1dAreFalse_161() + CHIP_ERROR TestSendTestCommandWithNestedStructListArgumentAndSomeFieldsBOfArg1dAreFalse_162() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestNestedStructListArgumentRequestParams alloc] init]; @@ -79106,12 +82037,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithStructArgumentAndSeeWhatWeGetBack_162() + CHIP_ERROR TestSendTestCommandWithStructArgumentAndSeeWhatWeGetBack_163() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterSimpleStructEchoRequestParams alloc] init]; @@ -79160,12 +82090,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithListOfInt8uAndNoneOfThemIsSetTo0_163() + CHIP_ERROR TestSendTestCommandWithListOfInt8uAndNoneOfThemIsSetTo0_164() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestListInt8UArgumentRequestParams alloc] init]; @@ -79202,12 +82131,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithListOfInt8uAndOneOfThemIsSetTo0_164() + CHIP_ERROR TestSendTestCommandWithListOfInt8uAndOneOfThemIsSetTo0_165() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestListInt8UArgumentRequestParams alloc] init]; @@ -79245,12 +82173,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithListOfInt8uAndGetItReversed_165() + CHIP_ERROR TestSendTestCommandWithListOfInt8uAndGetItReversed_166() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestListInt8UReverseRequestParams alloc] init]; @@ -79295,12 +82222,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithEmptyListOfInt8uAndGetAnEmptyListBack_166() + CHIP_ERROR TestSendTestCommandWithEmptyListOfInt8uAndGetAnEmptyListBack_167() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestListInt8UReverseRequestParams alloc] init]; @@ -79328,12 +82254,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithListOfStructArgumentAndArg1bOfFirstItemIsTrue_167() + CHIP_ERROR TestSendTestCommandWithListOfStructArgumentAndArg1bOfFirstItemIsTrue_168() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestListStructArgumentRequestParams alloc] init]; @@ -79381,12 +82306,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithListOfStructArgumentAndArg1bOfFirstItemIsFalse_168() + CHIP_ERROR TestSendTestCommandWithListOfStructArgumentAndArg1bOfFirstItemIsFalse_169() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestListStructArgumentRequestParams alloc] init]; @@ -79434,12 +82358,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithListOfNestedStructListArgumentAndAllFieldsBOfElementsOfArg1dAreTrue_169() + CHIP_ERROR TestSendTestCommandWithListOfNestedStructListArgumentAndAllFieldsBOfElementsOfArg1dAreTrue_170() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestListNestedStructListArgumentRequestParams alloc] init]; @@ -79534,12 +82457,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithNestedStructListArgumentAndSomeFieldsBOfElementsOfArg1dAreFalse_170() + CHIP_ERROR TestSendTestCommandWithNestedStructListArgumentAndSomeFieldsBOfElementsOfArg1dAreFalse_171() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestListNestedStructListArgumentRequestParams alloc] init]; @@ -79634,12 +82556,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeListWithListOfInt8uAndNoneOfThemIsSetTo0_171() + CHIP_ERROR TestWriteAttributeListWithListOfInt8uAndNoneOfThemIsSetTo0_172() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id listInt8uArgument; @@ -79664,12 +82585,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeListWithListOfInt8u_172() + CHIP_ERROR TestReadAttributeListWithListOfInt8u_173() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeListInt8uWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -79692,12 +82612,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeListWithListOfOctetString_173() + CHIP_ERROR TestWriteAttributeListWithListOfOctetString_174() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id listOctetStringArgument; @@ -79721,12 +82640,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeListWithListOfOctetString_174() + CHIP_ERROR TestReadAttributeListWithListOfOctetString_175() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeListOctetStringWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -79749,12 +82667,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeListWithListOfListStructOctetString_175() + CHIP_ERROR TestWriteAttributeListWithListOfListStructOctetString_176() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id listStructOctetStringArgument; @@ -79792,12 +82709,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeListWithListOfListStructOctetString_176() + CHIP_ERROR TestReadAttributeListWithListOfListStructOctetString_177() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeListStructOctetStringWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -79828,12 +82744,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithOptionalArgSet_177() + CHIP_ERROR TestSendTestCommandWithOptionalArgSet_178() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestNullableOptionalRequestParams alloc] init]; @@ -79872,12 +82787,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendTestCommandWithoutItsOptionalArg_178() + CHIP_ERROR TestSendTestCommandWithoutItsOptionalArg_179() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestNullableOptionalRequestParams alloc] init]; @@ -79899,12 +82813,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadListOfStructsContainingNullablesAndOptionals_179() + CHIP_ERROR TestReadListOfStructsContainingNullablesAndOptionals_180() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeListNullablesAndOptionalsStructWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -79931,12 +82844,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteListOfStructsContainingNullablesAndOptionals_180() + CHIP_ERROR TestWriteListOfStructsContainingNullablesAndOptionals_181() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id listNullablesAndOptionalsStructArgument; @@ -79969,12 +82881,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadListOfStructsContainingNullablesAndOptionalsAfterWriting_181() + CHIP_ERROR TestReadListOfStructsContainingNullablesAndOptionalsAfterWriting_182() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeListNullablesAndOptionalsStructWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -80008,12 +82919,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableBooleanNull_182() + CHIP_ERROR TestWriteAttributeNullableBooleanNull_183() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableBooleanArgument; @@ -80031,12 +82941,11 @@ class TestCluster : public TestCommandBridge { } NSNumber * _Nullable booValueNull; - CHIP_ERROR TestReadAttributeNullableBooleanNull_183() + CHIP_ERROR TestReadAttributeNullableBooleanNull_184() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80058,12 +82967,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableBooleanTrue_184() + CHIP_ERROR TestWriteAttributeNullableBooleanTrue_185() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableBooleanArgument; @@ -80080,12 +82988,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableBooleanTrue_185() + CHIP_ERROR TestReadAttributeNullableBooleanTrue_186() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80105,12 +83012,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableBooleanNotNull_186() + CHIP_ERROR TestReadAttributeNullableBooleanNotNull_187() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80128,12 +83034,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableBitmap8MaxValue_187() + CHIP_ERROR TestWriteAttributeNullableBitmap8MaxValue_188() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableBitmap8Argument; @@ -80150,12 +83055,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableBitmap8MaxValue_188() + CHIP_ERROR TestReadAttributeNullableBitmap8MaxValue_189() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBitmap8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80175,12 +83079,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableBitmap8InvalidValue_189() + CHIP_ERROR TestWriteAttributeNullableBitmap8InvalidValue_190() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableBitmap8Argument; @@ -80202,12 +83105,11 @@ class TestCluster : public TestCommandBridge { } NSNumber * _Nullable nullableValue254; - CHIP_ERROR TestReadAttributeNullableBitmap8UnchangedValue_190() + CHIP_ERROR TestReadAttributeNullableBitmap8UnchangedValue_191() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBitmap8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80230,12 +83132,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableBitmap8NullValue_191() + CHIP_ERROR TestWriteAttributeNullableBitmap8NullValue_192() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableBitmap8Argument; @@ -80252,12 +83153,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableBitmap8NullValue_192() + CHIP_ERROR TestReadAttributeNullableBitmap8NullValue_193() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBitmap8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80276,12 +83176,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableBitmap8Not254Value_193() + CHIP_ERROR TestReadAttributeNullableBitmap8Not254Value_194() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBitmap8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80299,12 +83198,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableBitmap16MaxValue_194() + CHIP_ERROR TestWriteAttributeNullableBitmap16MaxValue_195() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableBitmap16Argument; @@ -80321,12 +83219,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableBitmap16MaxValue_195() + CHIP_ERROR TestReadAttributeNullableBitmap16MaxValue_196() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBitmap16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80346,12 +83243,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableBitmap16InvalidValue_196() + CHIP_ERROR TestWriteAttributeNullableBitmap16InvalidValue_197() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableBitmap16Argument; @@ -80372,12 +83268,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableBitmap16UnchangedValue_197() + CHIP_ERROR TestReadAttributeNullableBitmap16UnchangedValue_198() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBitmap16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80397,12 +83292,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableBitmap16NullValue_198() + CHIP_ERROR TestWriteAttributeNullableBitmap16NullValue_199() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableBitmap16Argument; @@ -80419,12 +83313,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableBitmap16NullValue_199() + CHIP_ERROR TestReadAttributeNullableBitmap16NullValue_200() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBitmap16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80443,12 +83336,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableBitmap32MaxValue_200() + CHIP_ERROR TestWriteAttributeNullableBitmap32MaxValue_201() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableBitmap32Argument; @@ -80465,12 +83357,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableBitmap32MaxValue_201() + CHIP_ERROR TestReadAttributeNullableBitmap32MaxValue_202() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80490,12 +83381,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableBitmap32InvalidValue_202() + CHIP_ERROR TestWriteAttributeNullableBitmap32InvalidValue_203() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableBitmap32Argument; @@ -80516,12 +83406,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableBitmap32UnchangedValue_203() + CHIP_ERROR TestReadAttributeNullableBitmap32UnchangedValue_204() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80541,12 +83430,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableBitmap32NullValue_204() + CHIP_ERROR TestWriteAttributeNullableBitmap32NullValue_205() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableBitmap32Argument; @@ -80563,12 +83451,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableBitmap32NullValue_205() + CHIP_ERROR TestReadAttributeNullableBitmap32NullValue_206() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80587,12 +83474,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableBitmap64MaxValue_206() + CHIP_ERROR TestWriteAttributeNullableBitmap64MaxValue_207() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableBitmap64Argument; @@ -80609,12 +83495,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableBitmap64MaxValue_207() + CHIP_ERROR TestReadAttributeNullableBitmap64MaxValue_208() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBitmap64WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80634,12 +83519,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableBitmap64InvalidValue_208() + CHIP_ERROR TestWriteAttributeNullableBitmap64InvalidValue_209() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableBitmap64Argument; @@ -80660,12 +83544,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableBitmap64UnchangedValue_209() + CHIP_ERROR TestReadAttributeNullableBitmap64UnchangedValue_210() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBitmap64WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80685,12 +83568,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableBitmap64NullValue_210() + CHIP_ERROR TestWriteAttributeNullableBitmap64NullValue_211() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableBitmap64Argument; @@ -80707,12 +83589,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableBitmap64NullValue_211() + CHIP_ERROR TestReadAttributeNullableBitmap64NullValue_212() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableBitmap64WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80731,12 +83612,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt8uMinValue_212() + CHIP_ERROR TestWriteAttributeNullableInt8uMinValue_213() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt8uArgument; @@ -80753,12 +83633,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8uMinValue_213() + CHIP_ERROR TestReadAttributeNullableInt8uMinValue_214() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80778,12 +83657,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt8uMaxValue_214() + CHIP_ERROR TestWriteAttributeNullableInt8uMaxValue_215() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt8uArgument; @@ -80800,12 +83678,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8uMaxValue_215() + CHIP_ERROR TestReadAttributeNullableInt8uMaxValue_216() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80825,12 +83702,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt8uInvalidValue_216() + CHIP_ERROR TestWriteAttributeNullableInt8uInvalidValue_217() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt8uArgument; @@ -80851,12 +83727,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8uUnchangedValue_217() + CHIP_ERROR TestReadAttributeNullableInt8uUnchangedValue_218() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80876,12 +83751,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8uUnchangedValueWithConstraint_218() + CHIP_ERROR TestReadAttributeNullableInt8uUnchangedValueWithConstraint_219() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80899,12 +83773,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt8uNullValue_219() + CHIP_ERROR TestWriteAttributeNullableInt8uNullValue_220() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt8uArgument; @@ -80921,12 +83794,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8uNullValue_220() + CHIP_ERROR TestReadAttributeNullableInt8uNullValue_221() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80945,12 +83817,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8uNullValueRange_221() + CHIP_ERROR TestReadAttributeNullableInt8uNullValueRange_222() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80970,12 +83841,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8uNullValueNot_222() + CHIP_ERROR TestReadAttributeNullableInt8uNullValueNot_223() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -80993,12 +83863,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt8uValue_223() + CHIP_ERROR TestWriteAttributeNullableInt8uValue_224() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt8uArgument; @@ -81015,12 +83884,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8uValueInRange_224() + CHIP_ERROR TestReadAttributeNullableInt8uValueInRange_225() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81040,12 +83908,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8uNotValueOk_225() + CHIP_ERROR TestReadAttributeNullableInt8uNotValueOk_226() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81063,12 +83930,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt16uMinValue_226() + CHIP_ERROR TestWriteAttributeNullableInt16uMinValue_227() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt16uArgument; @@ -81085,12 +83951,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt16uMinValue_227() + CHIP_ERROR TestReadAttributeNullableInt16uMinValue_228() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81110,12 +83975,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt16uMaxValue_228() + CHIP_ERROR TestWriteAttributeNullableInt16uMaxValue_229() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt16uArgument; @@ -81132,12 +83996,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt16uMaxValue_229() + CHIP_ERROR TestReadAttributeNullableInt16uMaxValue_230() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81157,12 +84020,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt16uInvalidValue_230() + CHIP_ERROR TestWriteAttributeNullableInt16uInvalidValue_231() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt16uArgument; @@ -81183,12 +84045,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt16uUnchangedValue_231() + CHIP_ERROR TestReadAttributeNullableInt16uUnchangedValue_232() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81208,12 +84069,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt16uNullValue_232() + CHIP_ERROR TestWriteAttributeNullableInt16uNullValue_233() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt16uArgument; @@ -81230,12 +84090,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt16uNullValue_233() + CHIP_ERROR TestReadAttributeNullableInt16uNullValue_234() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81254,12 +84113,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt16uNullValueRange_234() + CHIP_ERROR TestReadAttributeNullableInt16uNullValueRange_235() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81279,12 +84137,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt16uNullValueNot_235() + CHIP_ERROR TestReadAttributeNullableInt16uNullValueNot_236() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81302,12 +84159,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt16uValue_236() + CHIP_ERROR TestWriteAttributeNullableInt16uValue_237() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt16uArgument; @@ -81324,12 +84180,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt16uValueInRange_237() + CHIP_ERROR TestReadAttributeNullableInt16uValueInRange_238() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81349,12 +84204,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt16uNotValueOk_238() + CHIP_ERROR TestReadAttributeNullableInt16uNotValueOk_239() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81372,12 +84226,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt32uMinValue_239() + CHIP_ERROR TestWriteAttributeNullableInt32uMinValue_240() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt32uArgument; @@ -81394,12 +84247,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt32uMinValue_240() + CHIP_ERROR TestReadAttributeNullableInt32uMinValue_241() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81419,12 +84271,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt32uMaxValue_241() + CHIP_ERROR TestWriteAttributeNullableInt32uMaxValue_242() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt32uArgument; @@ -81441,12 +84292,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt32uMaxValue_242() + CHIP_ERROR TestReadAttributeNullableInt32uMaxValue_243() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81466,12 +84316,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt32uInvalidValue_243() + CHIP_ERROR TestWriteAttributeNullableInt32uInvalidValue_244() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt32uArgument; @@ -81492,12 +84341,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt32uUnchangedValue_244() + CHIP_ERROR TestReadAttributeNullableInt32uUnchangedValue_245() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81517,12 +84365,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt32uNullValue_245() + CHIP_ERROR TestWriteAttributeNullableInt32uNullValue_246() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt32uArgument; @@ -81539,12 +84386,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt32uNullValue_246() + CHIP_ERROR TestReadAttributeNullableInt32uNullValue_247() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81563,12 +84409,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt32uNullValueRange_247() + CHIP_ERROR TestReadAttributeNullableInt32uNullValueRange_248() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81588,12 +84433,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt32uNullValueNot_248() + CHIP_ERROR TestReadAttributeNullableInt32uNullValueNot_249() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81611,12 +84455,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt32uValue_249() + CHIP_ERROR TestWriteAttributeNullableInt32uValue_250() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt32uArgument; @@ -81633,12 +84476,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt32uValueInRange_250() + CHIP_ERROR TestReadAttributeNullableInt32uValueInRange_251() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81658,12 +84500,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt32uNotValueOk_251() + CHIP_ERROR TestReadAttributeNullableInt32uNotValueOk_252() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81681,12 +84522,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt64uMinValue_252() + CHIP_ERROR TestWriteAttributeNullableInt64uMinValue_253() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt64uArgument; @@ -81703,12 +84543,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt64uMinValue_253() + CHIP_ERROR TestReadAttributeNullableInt64uMinValue_254() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81728,12 +84567,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt64uMaxValue_254() + CHIP_ERROR TestWriteAttributeNullableInt64uMaxValue_255() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt64uArgument; @@ -81750,12 +84588,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt64uMaxValue_255() + CHIP_ERROR TestReadAttributeNullableInt64uMaxValue_256() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81775,12 +84612,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt64uInvalidValue_256() + CHIP_ERROR TestWriteAttributeNullableInt64uInvalidValue_257() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt64uArgument; @@ -81801,12 +84637,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt64uUnchangedValue_257() + CHIP_ERROR TestReadAttributeNullableInt64uUnchangedValue_258() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81826,12 +84661,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt64uNullValue_258() + CHIP_ERROR TestWriteAttributeNullableInt64uNullValue_259() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt64uArgument; @@ -81848,12 +84682,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt64uNullValue_259() + CHIP_ERROR TestReadAttributeNullableInt64uNullValue_260() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81872,12 +84705,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt64uNullValueRange_260() + CHIP_ERROR TestReadAttributeNullableInt64uNullValueRange_261() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81898,12 +84730,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt64uNullValueNot_261() + CHIP_ERROR TestReadAttributeNullableInt64uNullValueNot_262() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81921,12 +84752,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt64uValue_262() + CHIP_ERROR TestWriteAttributeNullableInt64uValue_263() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt64uArgument; @@ -81943,12 +84773,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt64uValueInRange_263() + CHIP_ERROR TestReadAttributeNullableInt64uValueInRange_264() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81969,12 +84798,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt64uNotValueOk_264() + CHIP_ERROR TestReadAttributeNullableInt64uNotValueOk_265() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -81992,12 +84820,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt8sMinValue_265() + CHIP_ERROR TestWriteAttributeNullableInt8sMinValue_266() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt8sArgument; @@ -82014,12 +84841,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8sMinValue_266() + CHIP_ERROR TestReadAttributeNullableInt8sMinValue_267() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82039,12 +84865,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt8sInvalidValue_267() + CHIP_ERROR TestWriteAttributeNullableInt8sInvalidValue_268() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt8sArgument; @@ -82065,12 +84890,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8sUnchangedValue_268() + CHIP_ERROR TestReadAttributeNullableInt8sUnchangedValue_269() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82090,12 +84914,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt8sNullValue_269() + CHIP_ERROR TestWriteAttributeNullableInt8sNullValue_270() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt8sArgument; @@ -82112,12 +84935,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8sNullValue_270() + CHIP_ERROR TestReadAttributeNullableInt8sNullValue_271() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82136,12 +84958,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8sNullValueRange_271() + CHIP_ERROR TestReadAttributeNullableInt8sNullValueRange_272() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82161,12 +84982,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8sNullValueNot_272() + CHIP_ERROR TestReadAttributeNullableInt8sNullValueNot_273() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82184,12 +85004,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt8sValue_273() + CHIP_ERROR TestWriteAttributeNullableInt8sValue_274() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt8sArgument; @@ -82206,12 +85025,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8sValueInRange_274() + CHIP_ERROR TestReadAttributeNullableInt8sValueInRange_275() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82231,12 +85049,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt8sNotValueOk_275() + CHIP_ERROR TestReadAttributeNullableInt8sNotValueOk_276() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82254,12 +85071,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt16sMinValue_276() + CHIP_ERROR TestWriteAttributeNullableInt16sMinValue_277() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt16sArgument; @@ -82276,12 +85092,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt16sMinValue_277() + CHIP_ERROR TestReadAttributeNullableInt16sMinValue_278() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82301,12 +85116,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt16sInvalidValue_278() + CHIP_ERROR TestWriteAttributeNullableInt16sInvalidValue_279() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt16sArgument; @@ -82327,12 +85141,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt16sUnchangedValue_279() + CHIP_ERROR TestReadAttributeNullableInt16sUnchangedValue_280() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82352,12 +85165,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt16sNullValue_280() + CHIP_ERROR TestWriteAttributeNullableInt16sNullValue_281() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt16sArgument; @@ -82374,12 +85186,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt16sNullValue_281() + CHIP_ERROR TestReadAttributeNullableInt16sNullValue_282() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82398,12 +85209,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt16sNullValueRange_282() + CHIP_ERROR TestReadAttributeNullableInt16sNullValueRange_283() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82423,12 +85233,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt16sNullValueNot_283() + CHIP_ERROR TestReadAttributeNullableInt16sNullValueNot_284() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82446,12 +85255,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt16sValue_284() + CHIP_ERROR TestWriteAttributeNullableInt16sValue_285() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt16sArgument; @@ -82468,12 +85276,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt16sValueInRange_285() + CHIP_ERROR TestReadAttributeNullableInt16sValueInRange_286() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82493,12 +85300,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt16sNotValueOk_286() + CHIP_ERROR TestReadAttributeNullableInt16sNotValueOk_287() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82516,12 +85322,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt32sMinValue_287() + CHIP_ERROR TestWriteAttributeNullableInt32sMinValue_288() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt32sArgument; @@ -82538,12 +85343,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt32sMinValue_288() + CHIP_ERROR TestReadAttributeNullableInt32sMinValue_289() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82563,12 +85367,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt32sInvalidValue_289() + CHIP_ERROR TestWriteAttributeNullableInt32sInvalidValue_290() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt32sArgument; @@ -82589,12 +85392,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt32sUnchangedValue_290() + CHIP_ERROR TestReadAttributeNullableInt32sUnchangedValue_291() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82614,12 +85416,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt32sNullValue_291() + CHIP_ERROR TestWriteAttributeNullableInt32sNullValue_292() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt32sArgument; @@ -82636,12 +85437,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt32sNullValue_292() + CHIP_ERROR TestReadAttributeNullableInt32sNullValue_293() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82660,12 +85460,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt32sNullValueRange_293() + CHIP_ERROR TestReadAttributeNullableInt32sNullValueRange_294() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82685,12 +85484,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt32sNullValueNot_294() + CHIP_ERROR TestReadAttributeNullableInt32sNullValueNot_295() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82708,12 +85506,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt32sValue_295() + CHIP_ERROR TestWriteAttributeNullableInt32sValue_296() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt32sArgument; @@ -82730,12 +85527,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt32sValueInRange_296() + CHIP_ERROR TestReadAttributeNullableInt32sValueInRange_297() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82755,12 +85551,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt32sNotValueOk_297() + CHIP_ERROR TestReadAttributeNullableInt32sNotValueOk_298() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82778,12 +85573,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt64sMinValue_298() + CHIP_ERROR TestWriteAttributeNullableInt64sMinValue_299() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt64sArgument; @@ -82800,12 +85594,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt64sMinValue_299() + CHIP_ERROR TestReadAttributeNullableInt64sMinValue_300() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82825,12 +85618,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt64sInvalidValue_300() + CHIP_ERROR TestWriteAttributeNullableInt64sInvalidValue_301() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt64sArgument; @@ -82851,12 +85643,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt64sUnchangedValue_301() + CHIP_ERROR TestReadAttributeNullableInt64sUnchangedValue_302() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82876,12 +85667,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt64sNullValue_302() + CHIP_ERROR TestWriteAttributeNullableInt64sNullValue_303() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt64sArgument; @@ -82898,12 +85688,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt64sNullValue_303() + CHIP_ERROR TestReadAttributeNullableInt64sNullValue_304() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82922,12 +85711,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt64sNullValueRange_304() + CHIP_ERROR TestReadAttributeNullableInt64sNullValueRange_305() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82947,12 +85735,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt64sNullValueNot_305() + CHIP_ERROR TestReadAttributeNullableInt64sNullValueNot_306() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -82970,12 +85757,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableInt64sValue_306() + CHIP_ERROR TestWriteAttributeNullableInt64sValue_307() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableInt64sArgument; @@ -82992,12 +85778,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt64sValueInRange_307() + CHIP_ERROR TestReadAttributeNullableInt64sValueInRange_308() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83017,12 +85802,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableInt64sNotValueOk_308() + CHIP_ERROR TestReadAttributeNullableInt64sNotValueOk_309() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83040,12 +85824,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableSingleMediumValue_309() + CHIP_ERROR TestWriteAttributeNullableSingleMediumValue_310() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableFloatSingleArgument; @@ -83062,12 +85845,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableSingleMediumValue_310() + CHIP_ERROR TestReadAttributeNullableSingleMediumValue_311() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableFloatSingleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83087,12 +85869,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableSingleLargestValue_311() + CHIP_ERROR TestWriteAttributeNullableSingleLargestValue_312() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableFloatSingleArgument; @@ -83109,12 +85890,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableSingleLargestValue_312() + CHIP_ERROR TestReadAttributeNullableSingleLargestValue_313() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableFloatSingleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83134,12 +85914,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableSingleSmallestValue_313() + CHIP_ERROR TestWriteAttributeNullableSingleSmallestValue_314() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableFloatSingleArgument; @@ -83156,12 +85935,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableSingleSmallestValue_314() + CHIP_ERROR TestReadAttributeNullableSingleSmallestValue_315() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableFloatSingleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83181,12 +85959,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableSingleNullValue_315() + CHIP_ERROR TestWriteAttributeNullableSingleNullValue_316() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableFloatSingleArgument; @@ -83203,12 +85980,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableSingleNullValue_316() + CHIP_ERROR TestReadAttributeNullableSingleNullValue_317() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableFloatSingleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83227,12 +86003,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableSingle0Value_317() + CHIP_ERROR TestWriteAttributeNullableSingle0Value_318() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableFloatSingleArgument; @@ -83249,12 +86024,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableSingle0Value_318() + CHIP_ERROR TestReadAttributeNullableSingle0Value_319() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableFloatSingleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83274,12 +86048,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableDoubleMediumValue_319() + CHIP_ERROR TestWriteAttributeNullableDoubleMediumValue_320() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableFloatDoubleArgument; @@ -83296,12 +86069,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableDoubleMediumValue_320() + CHIP_ERROR TestReadAttributeNullableDoubleMediumValue_321() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableFloatDoubleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83321,12 +86093,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableDoubleLargestValue_321() + CHIP_ERROR TestWriteAttributeNullableDoubleLargestValue_322() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableFloatDoubleArgument; @@ -83343,12 +86114,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableDoubleLargestValue_322() + CHIP_ERROR TestReadAttributeNullableDoubleLargestValue_323() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableFloatDoubleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83368,12 +86138,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableDoubleSmallestValue_323() + CHIP_ERROR TestWriteAttributeNullableDoubleSmallestValue_324() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableFloatDoubleArgument; @@ -83390,12 +86159,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableDoubleSmallestValue_324() + CHIP_ERROR TestReadAttributeNullableDoubleSmallestValue_325() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableFloatDoubleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83415,12 +86183,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableDoubleNullValue_325() + CHIP_ERROR TestWriteAttributeNullableDoubleNullValue_326() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableFloatDoubleArgument; @@ -83437,12 +86204,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableDoubleNullValue_326() + CHIP_ERROR TestReadAttributeNullableDoubleNullValue_327() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableFloatDoubleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83461,12 +86227,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableDouble0Value_327() + CHIP_ERROR TestWriteAttributeNullableDouble0Value_328() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableFloatDoubleArgument; @@ -83483,12 +86248,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableDouble0Value_328() + CHIP_ERROR TestReadAttributeNullableDouble0Value_329() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableFloatDoubleWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83508,12 +86272,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableEnum8MinValue_329() + CHIP_ERROR TestWriteAttributeNullableEnum8MinValue_330() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableEnum8Argument; @@ -83530,12 +86293,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableEnum8MinValue_330() + CHIP_ERROR TestReadAttributeNullableEnum8MinValue_331() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableEnum8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83555,12 +86317,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableEnum8MaxValue_331() + CHIP_ERROR TestWriteAttributeNullableEnum8MaxValue_332() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableEnum8Argument; @@ -83577,12 +86338,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableEnum8MaxValue_332() + CHIP_ERROR TestReadAttributeNullableEnum8MaxValue_333() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableEnum8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83602,12 +86362,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableEnum8InvalidValue_333() + CHIP_ERROR TestWriteAttributeNullableEnum8InvalidValue_334() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableEnum8Argument; @@ -83628,12 +86387,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableEnum8UnchangedValue_334() + CHIP_ERROR TestReadAttributeNullableEnum8UnchangedValue_335() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableEnum8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83653,12 +86411,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableEnum8NullValue_335() + CHIP_ERROR TestWriteAttributeNullableEnum8NullValue_336() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableEnum8Argument; @@ -83675,12 +86432,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableEnum8NullValue_336() + CHIP_ERROR TestReadAttributeNullableEnum8NullValue_337() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableEnum8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83699,12 +86455,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableEnum16MinValue_337() + CHIP_ERROR TestWriteAttributeNullableEnum16MinValue_338() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableEnum16Argument; @@ -83721,12 +86476,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableEnum16MinValue_338() + CHIP_ERROR TestReadAttributeNullableEnum16MinValue_339() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableEnum16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83746,12 +86500,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableEnum16MaxValue_339() + CHIP_ERROR TestWriteAttributeNullableEnum16MaxValue_340() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableEnum16Argument; @@ -83768,12 +86521,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableEnum16MaxValue_340() + CHIP_ERROR TestReadAttributeNullableEnum16MaxValue_341() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableEnum16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83793,12 +86545,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableEnum16InvalidValue_341() + CHIP_ERROR TestWriteAttributeNullableEnum16InvalidValue_342() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableEnum16Argument; @@ -83819,12 +86570,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableEnum16UnchangedValue_342() + CHIP_ERROR TestReadAttributeNullableEnum16UnchangedValue_343() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableEnum16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83844,12 +86594,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableEnum16NullValue_343() + CHIP_ERROR TestWriteAttributeNullableEnum16NullValue_344() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableEnum16Argument; @@ -83866,12 +86615,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableEnum16NullValue_344() + CHIP_ERROR TestReadAttributeNullableEnum16NullValue_345() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableEnum16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83890,12 +86638,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableSimpleEnumMinValue_345() + CHIP_ERROR TestWriteAttributeNullableSimpleEnumMinValue_346() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableEnumAttrArgument; @@ -83912,12 +86659,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableSimpleEnumMinValue_346() + CHIP_ERROR TestReadAttributeNullableSimpleEnumMinValue_347() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableEnumAttrWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83937,12 +86683,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableSimpleEnumMaxValue_347() + CHIP_ERROR TestWriteAttributeNullableSimpleEnumMaxValue_348() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableEnumAttrArgument; @@ -83959,12 +86704,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableSimpleEnumMaxValue_348() + CHIP_ERROR TestReadAttributeNullableSimpleEnumMaxValue_349() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableEnumAttrWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -83984,12 +86728,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableSimpleEnumInvalidValue_349() + CHIP_ERROR TestWriteAttributeNullableSimpleEnumInvalidValue_350() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableEnumAttrArgument; @@ -84011,12 +86754,11 @@ class TestCluster : public TestCommandBridge { } NSNumber * _Nullable nullableEnumAttr3; - CHIP_ERROR TestReadAttributeNullableSimpleEnumUnchangedValue_350() + CHIP_ERROR TestReadAttributeNullableSimpleEnumUnchangedValue_351() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableEnumAttrWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -84039,12 +86781,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableSimpleEnumNullValue_351() + CHIP_ERROR TestWriteAttributeNullableSimpleEnumNullValue_352() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableEnumAttrArgument; @@ -84061,12 +86802,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableSimpleEnumNullValue_352() + CHIP_ERROR TestReadAttributeNullableSimpleEnumNullValue_353() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableEnumAttrWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -84085,12 +86825,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableSimpleEnumNot3Value_353() + CHIP_ERROR TestReadAttributeNullableSimpleEnumNot3Value_354() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableEnumAttrWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -84108,12 +86847,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableOctetStringDefaultValue_354() + CHIP_ERROR TestReadAttributeNullableOctetStringDefaultValue_355() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -84134,12 +86872,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableOctetString_355() + CHIP_ERROR TestWriteAttributeNullableOctetString_356() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableOctetStringArgument; @@ -84157,12 +86894,11 @@ class TestCluster : public TestCommandBridge { } NSData * _Nullable nullableOctetStrTestValue; - CHIP_ERROR TestReadAttributeNullableOctetString_356() + CHIP_ERROR TestReadAttributeNullableOctetString_357() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -84186,12 +86922,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableOctetString_357() + CHIP_ERROR TestWriteAttributeNullableOctetString_358() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableOctetStringArgument; @@ -84208,12 +86943,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableOctetString_358() + CHIP_ERROR TestReadAttributeNullableOctetString_359() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -84232,12 +86966,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableOctetString_359() + CHIP_ERROR TestWriteAttributeNullableOctetString_360() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableOctetStringArgument; @@ -84254,12 +86987,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableOctetString_360() + CHIP_ERROR TestReadAttributeNullableOctetString_361() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -84280,12 +87012,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableOctetStringNotTestValue_361() + CHIP_ERROR TestReadAttributeNullableOctetStringNotTestValue_362() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -84303,12 +87034,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableCharStringDefaultValue_362() + CHIP_ERROR TestReadAttributeNullableCharStringDefaultValue_363() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -84328,12 +87058,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableCharString_363() + CHIP_ERROR TestWriteAttributeNullableCharString_364() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableCharStringArgument; @@ -84351,12 +87080,11 @@ class TestCluster : public TestCommandBridge { } NSString * _Nullable nullableCharStringSave; - CHIP_ERROR TestReadAttributeNullableCharString_364() + CHIP_ERROR TestReadAttributeNullableCharString_365() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -84379,12 +87107,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableCharString_365() + CHIP_ERROR TestReadAttributeNullableCharString_366() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -84408,12 +87135,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableCharStringValueTooLong_366() + CHIP_ERROR TestWriteAttributeNullableCharStringValueTooLong_367() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableCharStringArgument; @@ -84430,12 +87156,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableCharString_367() + CHIP_ERROR TestReadAttributeNullableCharString_368() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -84454,12 +87179,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeNullableCharStringEmpty_368() + CHIP_ERROR TestWriteAttributeNullableCharStringEmpty_369() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableCharStringArgument; @@ -84476,12 +87200,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableCharString_369() + CHIP_ERROR TestReadAttributeNullableCharString_370() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -84501,12 +87224,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeNullableCharStringNott_370() + CHIP_ERROR TestReadAttributeNullableCharStringNott_371() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -84524,12 +87246,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeFromNonexistentEndpoint_371() + CHIP_ERROR TestReadAttributeFromNonexistentEndpoint_372() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(200) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(200) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeListInt8uWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -84544,12 +87265,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeFromNonexistentCluster_372() + CHIP_ERROR TestReadAttributeFromNonexistentCluster_373() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeListInt8uWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -84564,12 +87284,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestSendACommandThatTakesAnOptionalParameterButDoNotSetIt_373() + CHIP_ERROR TestSendACommandThatTakesAnOptionalParameterButDoNotSetIt_374() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestSimpleOptionalArgumentRequestParams alloc] init]; @@ -84584,19 +87303,18 @@ class TestCluster : public TestCommandBridge { ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_VALUE)); + EMBER_ZCL_STATUS_CONSTRAINT_ERROR)); NextTest(); }]; return CHIP_NO_ERROR; } - CHIP_ERROR TestSendACommandThatTakesAnOptionalParameterButDoNotSetIt_374() + CHIP_ERROR TestSendACommandThatTakesAnOptionalParameterButDoNotSetIt_375() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestSimpleOptionalArgumentRequestParams alloc] init]; @@ -84614,15 +87332,14 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - bool testSendClusterTestCluster_375_WaitForReport_Fulfilled = false; + bool testSendClusterTestCluster_376_WaitForReport_Fulfilled = false; ResponseHandler _Nullable test_TestCluster_list_int8u_Reported = nil; - CHIP_ERROR TestReportSubscribeToListAttribute_375() + CHIP_ERROR TestReportSubscribeToListAttribute_376() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_TestCluster_list_int8u_Reported = ^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -84639,31 +87356,30 @@ class TestCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("", actualValue[3], 4U)); } - testSendClusterTestCluster_375_WaitForReport_Fulfilled = true; + testSendClusterTestCluster_376_WaitForReport_Fulfilled = true; }; NextTest(); return CHIP_NO_ERROR; } - CHIP_ERROR TestSubscribeToListAttribute_376() + CHIP_ERROR TestSubscribeToListAttribute_377() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); uint16_t minIntervalArgument = 2U; uint16_t maxIntervalArgument = 5U; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) - maxInterval:@(maxIntervalArgument)]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) + maxInterval:@(maxIntervalArgument)]; params.filterByFabric = true; params.replaceExistingSubscriptions = true; [cluster subscribeAttributeListInt8uWithParams:params subscriptionEstablished:^{ VerifyOrReturn( - testSendClusterTestCluster_375_WaitForReport_Fulfilled, SetCommandExitStatus(CHIP_ERROR_INCORRECT_STATE)); + testSendClusterTestCluster_376_WaitForReport_Fulfilled, SetCommandExitStatus(CHIP_ERROR_INCORRECT_STATE)); NextTest(); } reportHandler:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -84680,12 +87396,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteSubscribedToListAttribute_377() + CHIP_ERROR TestWriteSubscribedToListAttribute_378() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id listInt8uArgument; @@ -84709,12 +87424,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestCheckForListAttributeReport_378() + CHIP_ERROR TestCheckForListAttributeReport_379() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_TestCluster_list_int8u_Reported = ^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -84737,12 +87451,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadRangeRestrictedUnsigned8BitInteger_379() + CHIP_ERROR TestReadRangeRestrictedUnsigned8BitInteger_380() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -84761,12 +87474,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValueToARangeRestrictedUnsigned8BitInteger_380() + CHIP_ERROR TestWriteMinValueToARangeRestrictedUnsigned8BitInteger_381() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt8uArgument; @@ -84789,12 +87501,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustBelowRangeValueToARangeRestrictedUnsigned8BitInteger_381() + CHIP_ERROR TestWriteJustBelowRangeValueToARangeRestrictedUnsigned8BitInteger_382() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt8uArgument; @@ -84817,12 +87528,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustAboveRangeValueToARangeRestrictedUnsigned8BitInteger_382() + CHIP_ERROR TestWriteJustAboveRangeValueToARangeRestrictedUnsigned8BitInteger_383() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt8uArgument; @@ -84845,12 +87555,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValueToARangeRestrictedUnsigned8BitInteger_383() + CHIP_ERROR TestWriteMaxValueToARangeRestrictedUnsigned8BitInteger_384() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt8uArgument; @@ -84873,12 +87582,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedUnsigned8BitIntegerValueHasNotChanged_384() + CHIP_ERROR TestVerifyRangeRestrictedUnsigned8BitIntegerValueHasNotChanged_385() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -84897,12 +87605,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValidValueToARangeRestrictedUnsigned8BitInteger_385() + CHIP_ERROR TestWriteMinValidValueToARangeRestrictedUnsigned8BitInteger_386() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt8uArgument; @@ -84921,12 +87628,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedUnsigned8BitIntegerValueIsAtMinValid_386() + CHIP_ERROR TestVerifyRangeRestrictedUnsigned8BitIntegerValueIsAtMinValid_387() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -84945,12 +87651,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValidValueToARangeRestrictedUnsigned8BitInteger_387() + CHIP_ERROR TestWriteMaxValidValueToARangeRestrictedUnsigned8BitInteger_388() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt8uArgument; @@ -84969,12 +87674,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedUnsigned8BitIntegerValueIsAtMaxValid_388() + CHIP_ERROR TestVerifyRangeRestrictedUnsigned8BitIntegerValueIsAtMaxValid_389() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -84993,12 +87697,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMiddleValidValueToARangeRestrictedUnsigned8BitInteger_389() + CHIP_ERROR TestWriteMiddleValidValueToARangeRestrictedUnsigned8BitInteger_390() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt8uArgument; @@ -85017,12 +87720,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedUnsigned8BitIntegerValueIsAtMidValid_390() + CHIP_ERROR TestVerifyRangeRestrictedUnsigned8BitIntegerValueIsAtMidValid_391() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85041,12 +87743,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadRangeRestrictedUnsigned16BitInteger_391() + CHIP_ERROR TestReadRangeRestrictedUnsigned16BitInteger_392() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85065,12 +87766,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValueToARangeRestrictedUnsigned16BitInteger_392() + CHIP_ERROR TestWriteMinValueToARangeRestrictedUnsigned16BitInteger_393() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt16uArgument; @@ -85093,12 +87793,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustBelowRangeValueToARangeRestrictedUnsigned16BitInteger_393() + CHIP_ERROR TestWriteJustBelowRangeValueToARangeRestrictedUnsigned16BitInteger_394() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt16uArgument; @@ -85121,12 +87820,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustAboveRangeValueToARangeRestrictedUnsigned16BitInteger_394() + CHIP_ERROR TestWriteJustAboveRangeValueToARangeRestrictedUnsigned16BitInteger_395() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt16uArgument; @@ -85149,12 +87847,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValueToARangeRestrictedUnsigned16BitInteger_395() + CHIP_ERROR TestWriteMaxValueToARangeRestrictedUnsigned16BitInteger_396() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt16uArgument; @@ -85177,12 +87874,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedUnsigned16BitIntegerValueHasNotChanged_396() + CHIP_ERROR TestVerifyRangeRestrictedUnsigned16BitIntegerValueHasNotChanged_397() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85201,12 +87897,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValidValueToARangeRestrictedUnsigned16BitInteger_397() + CHIP_ERROR TestWriteMinValidValueToARangeRestrictedUnsigned16BitInteger_398() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt16uArgument; @@ -85225,12 +87920,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedUnsigned16BitIntegerValueIsAtMinValid_398() + CHIP_ERROR TestVerifyRangeRestrictedUnsigned16BitIntegerValueIsAtMinValid_399() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85249,12 +87943,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValidValueToARangeRestrictedUnsigned16BitInteger_399() + CHIP_ERROR TestWriteMaxValidValueToARangeRestrictedUnsigned16BitInteger_400() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt16uArgument; @@ -85273,12 +87966,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedUnsigned16BitIntegerValueIsAtMaxValid_400() + CHIP_ERROR TestVerifyRangeRestrictedUnsigned16BitIntegerValueIsAtMaxValid_401() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85297,12 +87989,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMiddleValidValueToARangeRestrictedUnsigned16BitInteger_401() + CHIP_ERROR TestWriteMiddleValidValueToARangeRestrictedUnsigned16BitInteger_402() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt16uArgument; @@ -85321,12 +88012,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedUnsigned16BitIntegerValueIsAtMidValid_402() + CHIP_ERROR TestVerifyRangeRestrictedUnsigned16BitIntegerValueIsAtMidValid_403() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85345,12 +88035,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadRangeRestrictedSigned8BitInteger_403() + CHIP_ERROR TestReadRangeRestrictedSigned8BitInteger_404() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85369,12 +88058,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValueToARangeRestrictedSigned8BitInteger_404() + CHIP_ERROR TestWriteMinValueToARangeRestrictedSigned8BitInteger_405() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt8sArgument; @@ -85396,12 +88084,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustBelowRangeValueToARangeRestrictedSigned8BitInteger_405() + CHIP_ERROR TestWriteJustBelowRangeValueToARangeRestrictedSigned8BitInteger_406() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt8sArgument; @@ -85424,12 +88111,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustAboveRangeValueToARangeRestrictedSigned8BitInteger_406() + CHIP_ERROR TestWriteJustAboveRangeValueToARangeRestrictedSigned8BitInteger_407() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt8sArgument; @@ -85452,12 +88138,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValueToARangeRestrictedSigned8BitInteger_407() + CHIP_ERROR TestWriteMaxValueToARangeRestrictedSigned8BitInteger_408() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt8sArgument; @@ -85479,12 +88164,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedSigned8BitIntegerValueHasNotChanged_408() + CHIP_ERROR TestVerifyRangeRestrictedSigned8BitIntegerValueHasNotChanged_409() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85503,12 +88187,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValidValueToARangeRestrictedSigned8BitInteger_409() + CHIP_ERROR TestWriteMinValidValueToARangeRestrictedSigned8BitInteger_410() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt8sArgument; @@ -85528,12 +88211,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedSigned8BitIntegerValueIsAtMinValid_410() + CHIP_ERROR TestVerifyRangeRestrictedSigned8BitIntegerValueIsAtMinValid_411() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85552,12 +88234,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValidValueToARangeRestrictedSigned8BitInteger_411() + CHIP_ERROR TestWriteMaxValidValueToARangeRestrictedSigned8BitInteger_412() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt8sArgument; @@ -85577,12 +88258,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedSigned8BitIntegerValueIsAtMaxValid_412() + CHIP_ERROR TestVerifyRangeRestrictedSigned8BitIntegerValueIsAtMaxValid_413() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85601,12 +88281,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMiddleValidValueToARangeRestrictedSigned8BitInteger_413() + CHIP_ERROR TestWriteMiddleValidValueToARangeRestrictedSigned8BitInteger_414() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt8sArgument; @@ -85625,12 +88304,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedSigned8BitIntegerValueIsAtMidValid_414() + CHIP_ERROR TestVerifyRangeRestrictedSigned8BitIntegerValueIsAtMidValid_415() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85649,12 +88327,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadRangeRestrictedSigned16BitInteger_415() + CHIP_ERROR TestReadRangeRestrictedSigned16BitInteger_416() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85673,12 +88350,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValueToARangeRestrictedSigned16BitInteger_416() + CHIP_ERROR TestWriteMinValueToARangeRestrictedSigned16BitInteger_417() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt16sArgument; @@ -85701,12 +88377,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustBelowRangeValueToARangeRestrictedSigned16BitInteger_417() + CHIP_ERROR TestWriteJustBelowRangeValueToARangeRestrictedSigned16BitInteger_418() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt16sArgument; @@ -85729,12 +88404,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustAboveRangeValueToARangeRestrictedSigned16BitInteger_418() + CHIP_ERROR TestWriteJustAboveRangeValueToARangeRestrictedSigned16BitInteger_419() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt16sArgument; @@ -85757,12 +88431,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValueToARangeRestrictedSigned16BitInteger_419() + CHIP_ERROR TestWriteMaxValueToARangeRestrictedSigned16BitInteger_420() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt16sArgument; @@ -85785,12 +88458,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedSigned16BitIntegerValueHasNotChanged_420() + CHIP_ERROR TestVerifyRangeRestrictedSigned16BitIntegerValueHasNotChanged_421() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85809,12 +88481,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValidValueToARangeRestrictedSigned16BitInteger_421() + CHIP_ERROR TestWriteMinValidValueToARangeRestrictedSigned16BitInteger_422() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt16sArgument; @@ -85833,12 +88504,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedSigned16BitIntegerValueIsAtMinValid_422() + CHIP_ERROR TestVerifyRangeRestrictedSigned16BitIntegerValueIsAtMinValid_423() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85857,12 +88527,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValidValueToARangeRestrictedSigned16BitInteger_423() + CHIP_ERROR TestWriteMaxValidValueToARangeRestrictedSigned16BitInteger_424() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt16sArgument; @@ -85881,12 +88550,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedSigned16BitIntegerValueIsAtMaxValid_424() + CHIP_ERROR TestVerifyRangeRestrictedSigned16BitIntegerValueIsAtMaxValid_425() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85905,12 +88573,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMiddleValidValueToARangeRestrictedSigned16BitInteger_425() + CHIP_ERROR TestWriteMiddleValidValueToARangeRestrictedSigned16BitInteger_426() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id rangeRestrictedInt16sArgument; @@ -85929,12 +88596,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyRangeRestrictedSigned16BitIntegerValueIsAtMidValid_426() + CHIP_ERROR TestVerifyRangeRestrictedSigned16BitIntegerValueIsAtMidValid_427() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRangeRestrictedInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85953,12 +88619,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadNullableRangeRestrictedUnsigned8BitInteger_427() + CHIP_ERROR TestReadNullableRangeRestrictedUnsigned8BitInteger_428() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -85978,12 +88643,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValueToANullableRangeRestrictedUnsigned8BitInteger_428() + CHIP_ERROR TestWriteMinValueToANullableRangeRestrictedUnsigned8BitInteger_429() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8uArgument; @@ -86006,12 +88670,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustBelowRangeValueToANullableRangeRestrictedUnsigned8BitInteger_429() + CHIP_ERROR TestWriteJustBelowRangeValueToANullableRangeRestrictedUnsigned8BitInteger_430() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8uArgument; @@ -86034,12 +88697,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustAboveRangeValueToANullableRangeRestrictedUnsigned8BitInteger_430() + CHIP_ERROR TestWriteJustAboveRangeValueToANullableRangeRestrictedUnsigned8BitInteger_431() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8uArgument; @@ -86062,12 +88724,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValueToANullableRangeRestrictedUnsigned8BitInteger_431() + CHIP_ERROR TestWriteMaxValueToANullableRangeRestrictedUnsigned8BitInteger_432() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8uArgument; @@ -86090,12 +88751,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueHasNotChanged_432() + CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueHasNotChanged_433() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86115,12 +88775,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValidValueToANullableRangeRestrictedUnsigned8BitInteger_433() + CHIP_ERROR TestWriteMinValidValueToANullableRangeRestrictedUnsigned8BitInteger_434() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8uArgument; @@ -86139,12 +88798,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsAtMinValid_434() + CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsAtMinValid_435() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86164,12 +88822,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValidValueToANullableRangeRestrictedUnsigned8BitInteger_435() + CHIP_ERROR TestWriteMaxValidValueToANullableRangeRestrictedUnsigned8BitInteger_436() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8uArgument; @@ -86188,12 +88845,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsAtMaxValid_436() + CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsAtMaxValid_437() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86213,12 +88869,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMiddleValidValueToANullableRangeRestrictedUnsigned8BitInteger_437() + CHIP_ERROR TestWriteMiddleValidValueToANullableRangeRestrictedUnsigned8BitInteger_438() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8uArgument; @@ -86237,12 +88892,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsAtMidValid_438() + CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsAtMidValid_439() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86262,12 +88916,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteNullValueToANullableRangeRestrictedUnsigned8BitInteger_439() + CHIP_ERROR TestWriteNullValueToANullableRangeRestrictedUnsigned8BitInteger_440() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8uArgument; @@ -86286,12 +88939,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsNull_440() + CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned8BitIntegerValueIsNull_441() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86310,12 +88962,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadNullableRangeRestrictedUnsigned16BitInteger_441() + CHIP_ERROR TestReadNullableRangeRestrictedUnsigned16BitInteger_442() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86335,12 +88986,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValueToANullableRangeRestrictedUnsigned16BitInteger_442() + CHIP_ERROR TestWriteMinValueToANullableRangeRestrictedUnsigned16BitInteger_443() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16uArgument; @@ -86363,12 +89013,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustBelowRangeValueToANullableRangeRestrictedUnsigned16BitInteger_443() + CHIP_ERROR TestWriteJustBelowRangeValueToANullableRangeRestrictedUnsigned16BitInteger_444() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16uArgument; @@ -86391,12 +89040,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustAboveRangeValueToANullableRangeRestrictedUnsigned16BitInteger_444() + CHIP_ERROR TestWriteJustAboveRangeValueToANullableRangeRestrictedUnsigned16BitInteger_445() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16uArgument; @@ -86419,12 +89067,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValueToANullableRangeRestrictedUnsigned16BitInteger_445() + CHIP_ERROR TestWriteMaxValueToANullableRangeRestrictedUnsigned16BitInteger_446() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16uArgument; @@ -86447,12 +89094,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueHasNotChanged_446() + CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueHasNotChanged_447() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86472,12 +89118,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValidValueToANullableRangeRestrictedUnsigned16BitInteger_447() + CHIP_ERROR TestWriteMinValidValueToANullableRangeRestrictedUnsigned16BitInteger_448() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16uArgument; @@ -86496,12 +89141,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsAtMinValid_448() + CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsAtMinValid_449() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86521,12 +89165,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValidValueToANullableRangeRestrictedUnsigned16BitInteger_449() + CHIP_ERROR TestWriteMaxValidValueToANullableRangeRestrictedUnsigned16BitInteger_450() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16uArgument; @@ -86545,12 +89188,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsAtMaxValid_450() + CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsAtMaxValid_451() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86570,12 +89212,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMiddleValidValueToANullableRangeRestrictedUnsigned16BitInteger_451() + CHIP_ERROR TestWriteMiddleValidValueToANullableRangeRestrictedUnsigned16BitInteger_452() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16uArgument; @@ -86594,12 +89235,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsAtMidValid_452() + CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsAtMidValid_453() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86619,12 +89259,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteNullValueToANullableRangeRestrictedUnsigned16BitInteger_453() + CHIP_ERROR TestWriteNullValueToANullableRangeRestrictedUnsigned16BitInteger_454() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16uArgument; @@ -86643,12 +89282,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsNull_454() + CHIP_ERROR TestVerifyNullableRangeRestrictedUnsigned16BitIntegerValueIsNull_455() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86667,12 +89305,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadNullableRangeRestrictedSigned8BitInteger_455() + CHIP_ERROR TestReadNullableRangeRestrictedSigned8BitInteger_456() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86692,12 +89329,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValueToANullableRangeRestrictedSigned8BitInteger_456() + CHIP_ERROR TestWriteMinValueToANullableRangeRestrictedSigned8BitInteger_457() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8sArgument; @@ -86720,12 +89356,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustBelowRangeValueToANullableRangeRestrictedSigned8BitInteger_457() + CHIP_ERROR TestWriteJustBelowRangeValueToANullableRangeRestrictedSigned8BitInteger_458() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8sArgument; @@ -86748,12 +89383,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustAboveRangeValueToANullableRangeRestrictedSigned8BitInteger_458() + CHIP_ERROR TestWriteJustAboveRangeValueToANullableRangeRestrictedSigned8BitInteger_459() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8sArgument; @@ -86776,12 +89410,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValueToANullableRangeRestrictedSigned8BitInteger_459() + CHIP_ERROR TestWriteMaxValueToANullableRangeRestrictedSigned8BitInteger_460() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8sArgument; @@ -86804,12 +89437,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedSigned8BitIntegerValueHasNotChanged_460() + CHIP_ERROR TestVerifyNullableRangeRestrictedSigned8BitIntegerValueHasNotChanged_461() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86829,12 +89461,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValidValueToANullableRangeRestrictedSigned8BitInteger_461() + CHIP_ERROR TestWriteMinValidValueToANullableRangeRestrictedSigned8BitInteger_462() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8sArgument; @@ -86853,12 +89484,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtMinValid_462() + CHIP_ERROR TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtMinValid_463() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86878,12 +89508,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValidValueToANullableRangeRestrictedSigned8BitInteger_463() + CHIP_ERROR TestWriteMaxValidValueToANullableRangeRestrictedSigned8BitInteger_464() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8sArgument; @@ -86902,12 +89531,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtMaxValid_464() + CHIP_ERROR TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtMaxValid_465() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86927,12 +89555,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMiddleValidValueToANullableRangeRestrictedSigned8BitInteger_465() + CHIP_ERROR TestWriteMiddleValidValueToANullableRangeRestrictedSigned8BitInteger_466() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8sArgument; @@ -86951,12 +89578,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtMidValid_466() + CHIP_ERROR TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtMidValid_467() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -86976,12 +89602,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteNullValueToANullableRangeRestrictedSigned8BitInteger_467() + CHIP_ERROR TestWriteNullValueToANullableRangeRestrictedSigned8BitInteger_468() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt8sArgument; @@ -87000,12 +89625,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtNull_468() + CHIP_ERROR TestVerifyNullableRangeRestrictedSigned8BitIntegerValueIsAtNull_469() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -87024,12 +89648,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadNullableRangeRestrictedSigned16BitInteger_469() + CHIP_ERROR TestReadNullableRangeRestrictedSigned16BitInteger_470() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -87049,12 +89672,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValueToANullableRangeRestrictedSigned16BitInteger_470() + CHIP_ERROR TestWriteMinValueToANullableRangeRestrictedSigned16BitInteger_471() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16sArgument; @@ -87077,12 +89699,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustBelowRangeValueToANullableRangeRestrictedSigned16BitInteger_471() + CHIP_ERROR TestWriteJustBelowRangeValueToANullableRangeRestrictedSigned16BitInteger_472() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16sArgument; @@ -87105,12 +89726,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteJustAboveRangeValueToANullableRangeRestrictedSigned16BitInteger_472() + CHIP_ERROR TestWriteJustAboveRangeValueToANullableRangeRestrictedSigned16BitInteger_473() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16sArgument; @@ -87133,12 +89753,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValueToANullableRangeRestrictedSigned16BitInteger_473() + CHIP_ERROR TestWriteMaxValueToANullableRangeRestrictedSigned16BitInteger_474() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16sArgument; @@ -87161,12 +89780,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedSigned16BitIntegerValueHasNotChanged_474() + CHIP_ERROR TestVerifyNullableRangeRestrictedSigned16BitIntegerValueHasNotChanged_475() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -87186,12 +89804,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMinValidValueToANullableRangeRestrictedSigned16BitInteger_475() + CHIP_ERROR TestWriteMinValidValueToANullableRangeRestrictedSigned16BitInteger_476() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16sArgument; @@ -87210,12 +89827,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsAtMinValid_476() + CHIP_ERROR TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsAtMinValid_477() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -87235,12 +89851,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMaxValidValueToANullableRangeRestrictedSigned16BitInteger_477() + CHIP_ERROR TestWriteMaxValidValueToANullableRangeRestrictedSigned16BitInteger_478() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16sArgument; @@ -87259,12 +89874,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsAtMaxValid_478() + CHIP_ERROR TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsAtMaxValid_479() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -87284,12 +89898,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteMiddleValidValueToANullableRangeRestrictedSigned16BitInteger_479() + CHIP_ERROR TestWriteMiddleValidValueToANullableRangeRestrictedSigned16BitInteger_480() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16sArgument; @@ -87308,12 +89921,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsAtMidValid_480() + CHIP_ERROR TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsAtMidValid_481() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -87333,12 +89945,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteNullValueToANullableRangeRestrictedSigned16BitInteger_481() + CHIP_ERROR TestWriteNullValueToANullableRangeRestrictedSigned16BitInteger_482() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nullableRangeRestrictedInt16sArgument; @@ -87357,12 +89968,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsNull_482() + CHIP_ERROR TestVerifyNullableRangeRestrictedSigned16BitIntegerValueIsNull_483() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNullableRangeRestrictedInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -87381,12 +89991,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeThatReturnsGeneralStatusOnWrite_483() + CHIP_ERROR TestWriteAttributeThatReturnsGeneralStatusOnWrite_484() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id generalErrorBooleanArgument; @@ -87407,12 +90016,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeThatReturnsClusterSpecificStatusOnWrite_484() + CHIP_ERROR TestWriteAttributeThatReturnsClusterSpecificStatusOnWrite_485() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id clusterErrorBooleanArgument; @@ -87435,12 +90043,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeThatReturnsGeneralStatusOnRead_485() + CHIP_ERROR TestReadAttributeThatReturnsGeneralStatusOnRead_486() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneralErrorBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -87455,12 +90062,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeThatReturnsClusterSpecificStatusOnRead_486() + CHIP_ERROR TestReadAttributeThatReturnsClusterSpecificStatusOnRead_487() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterErrorBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -87475,12 +90081,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAcceptedCommandListAttribute_487() + CHIP_ERROR TestReadAcceptedCommandListAttribute_488() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -87517,12 +90122,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadGeneratedCommandListAttribute_488() + CHIP_ERROR TestReadGeneratedCommandListAttribute_489() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -87550,12 +90154,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteStructTypedAttribute_489() + CHIP_ERROR TestWriteStructTypedAttribute_490() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id structAttrArgument; @@ -87581,12 +90184,11 @@ class TestCluster : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadStructTypedAttribute_490() + CHIP_ERROR TestReadStructTypedAttribute_491() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -87704,91 +90306,95 @@ class TestConstraints : public TestCommandBridge { err = TestReadAttributeBitmap32WithMaskVal1AndMaskVal3AndEnsureMaskval1AndMaskVal3AreSet_10(); break; case 11: - ChipLogProgress(chipTool, " ***** Test Step 11 : Write attribute INT32U Value\n"); - err = TestWriteAttributeInt32uValue_11(); + ChipLogProgress(chipTool, " ***** Test Step 11 : Write attribute BITMAP32 Back to Default Value\n"); + err = TestWriteAttributeBitmap32BackToDefaultValue_11(); break; case 12: - ChipLogProgress(chipTool, " ***** Test Step 12 : Read attribute INT32U Value MinValue Constraints\n"); - err = TestReadAttributeInt32uValueMinValueConstraints_12(); + ChipLogProgress(chipTool, " ***** Test Step 12 : Write attribute INT32U Value\n"); + err = TestWriteAttributeInt32uValue_12(); break; case 13: - ChipLogProgress(chipTool, " ***** Test Step 13 : Read attribute INT32U Value MaxValue Constraints\n"); - err = TestReadAttributeInt32uValueMaxValueConstraints_13(); + ChipLogProgress(chipTool, " ***** Test Step 13 : Read attribute INT32U Value MinValue Constraints\n"); + err = TestReadAttributeInt32uValueMinValueConstraints_13(); break; case 14: - ChipLogProgress(chipTool, " ***** Test Step 14 : Read attribute INT32U Value NotValue Constraints\n"); - err = TestReadAttributeInt32uValueNotValueConstraints_14(); + ChipLogProgress(chipTool, " ***** Test Step 14 : Read attribute INT32U Value MaxValue Constraints\n"); + err = TestReadAttributeInt32uValueMaxValueConstraints_14(); break; case 15: - ChipLogProgress(chipTool, " ***** Test Step 15 : Write attribute INT32U Value Back to Default Value\n"); - err = TestWriteAttributeInt32uValueBackToDefaultValue_15(); + ChipLogProgress(chipTool, " ***** Test Step 15 : Read attribute INT32U Value NotValue Constraints\n"); + err = TestReadAttributeInt32uValueNotValueConstraints_15(); break; case 16: - ChipLogProgress(chipTool, " ***** Test Step 16 : Write attribute CHAR_STRING Value\n"); - err = TestWriteAttributeCharStringValue_16(); + ChipLogProgress(chipTool, " ***** Test Step 16 : Write attribute INT32U Value Back to Default Value\n"); + err = TestWriteAttributeInt32uValueBackToDefaultValue_16(); break; case 17: - ChipLogProgress(chipTool, " ***** Test Step 17 : Read attribute CHAR_STRING Value MinLength Constraints\n"); - err = TestReadAttributeCharStringValueMinLengthConstraints_17(); + ChipLogProgress(chipTool, " ***** Test Step 17 : Write attribute CHAR_STRING Value\n"); + err = TestWriteAttributeCharStringValue_17(); break; case 18: - ChipLogProgress(chipTool, " ***** Test Step 18 : Read attribute CHAR_STRING Value MaxLength Constraints\n"); - err = TestReadAttributeCharStringValueMaxLengthConstraints_18(); + ChipLogProgress(chipTool, " ***** Test Step 18 : Read attribute CHAR_STRING Value MinLength Constraints\n"); + err = TestReadAttributeCharStringValueMinLengthConstraints_18(); break; case 19: - ChipLogProgress(chipTool, " ***** Test Step 19 : Read attribute CHAR_STRING Value StartsWith Constraints\n"); - err = TestReadAttributeCharStringValueStartsWithConstraints_19(); + ChipLogProgress(chipTool, " ***** Test Step 19 : Read attribute CHAR_STRING Value MaxLength Constraints\n"); + err = TestReadAttributeCharStringValueMaxLengthConstraints_19(); break; case 20: - ChipLogProgress(chipTool, " ***** Test Step 20 : Read attribute CHAR_STRING Value EndsWith Constraints\n"); - err = TestReadAttributeCharStringValueEndsWithConstraints_20(); + ChipLogProgress(chipTool, " ***** Test Step 20 : Read attribute CHAR_STRING Value StartsWith Constraints\n"); + err = TestReadAttributeCharStringValueStartsWithConstraints_20(); break; case 21: - ChipLogProgress(chipTool, " ***** Test Step 21 : Write attribute CHAR_STRING Value\n"); - err = TestWriteAttributeCharStringValue_21(); + ChipLogProgress(chipTool, " ***** Test Step 21 : Read attribute CHAR_STRING Value EndsWith Constraints\n"); + err = TestReadAttributeCharStringValueEndsWithConstraints_21(); break; case 22: - ChipLogProgress( - chipTool, " ***** Test Step 22 : Read attribute CHAR_STRING Value isLowerCase/isUpperCase Constraints\n"); - err = TestReadAttributeCharStringValueIsLowerCaseIsUpperCaseConstraints_22(); + ChipLogProgress(chipTool, " ***** Test Step 22 : Write attribute CHAR_STRING Value\n"); + err = TestWriteAttributeCharStringValue_22(); break; case 23: - ChipLogProgress(chipTool, " ***** Test Step 23 : Write attribute CHAR_STRING Value\n"); - err = TestWriteAttributeCharStringValue_23(); + ChipLogProgress( + chipTool, " ***** Test Step 23 : Read attribute CHAR_STRING Value isLowerCase/isUpperCase Constraints\n"); + err = TestReadAttributeCharStringValueIsLowerCaseIsUpperCaseConstraints_23(); break; case 24: - ChipLogProgress( - chipTool, " ***** Test Step 24 : Read attribute CHAR_STRING Value isLowerCase/isUpperCase Constraints\n"); - err = TestReadAttributeCharStringValueIsLowerCaseIsUpperCaseConstraints_24(); + ChipLogProgress(chipTool, " ***** Test Step 24 : Write attribute CHAR_STRING Value\n"); + err = TestWriteAttributeCharStringValue_24(); break; case 25: - ChipLogProgress(chipTool, " ***** Test Step 25 : Write attribute CHAR_STRING Value\n"); - err = TestWriteAttributeCharStringValue_25(); + ChipLogProgress( + chipTool, " ***** Test Step 25 : Read attribute CHAR_STRING Value isLowerCase/isUpperCase Constraints\n"); + err = TestReadAttributeCharStringValueIsLowerCaseIsUpperCaseConstraints_25(); break; case 26: - ChipLogProgress( - chipTool, " ***** Test Step 26 : Read attribute CHAR_STRING Value isLowerCase/isUpperCase Constraints\n"); - err = TestReadAttributeCharStringValueIsLowerCaseIsUpperCaseConstraints_26(); + ChipLogProgress(chipTool, " ***** Test Step 26 : Write attribute CHAR_STRING Value\n"); + err = TestWriteAttributeCharStringValue_26(); break; case 27: - ChipLogProgress(chipTool, " ***** Test Step 27 : Write attribute CHAR_STRING Value\n"); - err = TestWriteAttributeCharStringValue_27(); + ChipLogProgress( + chipTool, " ***** Test Step 27 : Read attribute CHAR_STRING Value isLowerCase/isUpperCase Constraints\n"); + err = TestReadAttributeCharStringValueIsLowerCaseIsUpperCaseConstraints_27(); break; case 28: - ChipLogProgress(chipTool, " ***** Test Step 28 : Read attribute CHAR_STRING Value isHexString Constraints\n"); - err = TestReadAttributeCharStringValueIsHexStringConstraints_28(); + ChipLogProgress(chipTool, " ***** Test Step 28 : Write attribute CHAR_STRING Value\n"); + err = TestWriteAttributeCharStringValue_28(); break; case 29: - ChipLogProgress(chipTool, " ***** Test Step 29 : Write attribute CHAR_STRING Value\n"); - err = TestWriteAttributeCharStringValue_29(); + ChipLogProgress(chipTool, " ***** Test Step 29 : Read attribute CHAR_STRING Value isHexString Constraints\n"); + err = TestReadAttributeCharStringValueIsHexStringConstraints_29(); break; case 30: - ChipLogProgress(chipTool, " ***** Test Step 30 : Read attribute CHAR_STRING Value isHexString Constraints\n"); - err = TestReadAttributeCharStringValueIsHexStringConstraints_30(); + ChipLogProgress(chipTool, " ***** Test Step 30 : Write attribute CHAR_STRING Value\n"); + err = TestWriteAttributeCharStringValue_30(); break; case 31: - ChipLogProgress(chipTool, " ***** Test Step 31 : Write attribute CHAR_STRING Value Back to Default Value\n"); - err = TestWriteAttributeCharStringValueBackToDefaultValue_31(); + ChipLogProgress(chipTool, " ***** Test Step 31 : Read attribute CHAR_STRING Value isHexString Constraints\n"); + err = TestReadAttributeCharStringValueIsHexStringConstraints_31(); + break; + case 32: + ChipLogProgress(chipTool, " ***** Test Step 32 : Write attribute CHAR_STRING Value Back to Default Value\n"); + err = TestWriteAttributeCharStringValueBackToDefaultValue_32(); break; } @@ -87897,6 +90503,9 @@ class TestConstraints : public TestCommandBridge { case 31: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; + case 32: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; } // Go on to the next test. @@ -87910,7 +90519,7 @@ class TestConstraints : public TestCommandBridge { private: std::atomic_uint16_t mTestIndex; - const uint16_t mTestCount = 32; + const uint16_t mTestCount = 33; chip::Optional mNodeId; chip::Optional mCluster; @@ -87919,6 +90528,7 @@ class TestConstraints : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -87926,10 +90536,9 @@ class TestConstraints : public TestCommandBridge { CHIP_ERROR TestWriteAttributeListWithListOfInt8u_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id listInt8uArgument; @@ -87955,10 +90564,9 @@ class TestConstraints : public TestCommandBridge { CHIP_ERROR TestReadAttributeListWithPartialListOfInt8uThatShouldBeInIt_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeListInt8uWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -87978,10 +90586,9 @@ class TestConstraints : public TestCommandBridge { CHIP_ERROR TestReadAttributeListWithPartialListOfInt8uThatShouldNotBeIncluded_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeListInt8uWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -88000,10 +90607,9 @@ class TestConstraints : public TestCommandBridge { CHIP_ERROR TestWriteAttributeListBackToDefaultValue_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id listInt8uArgument; @@ -88025,10 +90631,9 @@ class TestConstraints : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap32DefaultValue_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -88049,10 +90654,9 @@ class TestConstraints : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap32WithMaskVal1AndMaskVal3_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap32Argument; @@ -88071,10 +90675,9 @@ class TestConstraints : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap32WithMaskVal1AndMaskVal3AndEnsureMaskVal2IsNotSet_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -88095,10 +90698,9 @@ class TestConstraints : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap32WithMaskVal1AndMaskVal3AndEnsureMaskVal1IsSet_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -88119,10 +90721,9 @@ class TestConstraints : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap32WithMaskVal1AndMaskVal3AndEnsureMaskVal3IsSet_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -88143,10 +90744,9 @@ class TestConstraints : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap32WithMaskVal1AndMaskVal3AndEnsureMaskval1AndMaskVal3AreSet_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -88165,12 +90765,32 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeInt32uValue_11() + CHIP_ERROR TestWriteAttributeBitmap32BackToDefaultValue_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + id bitmap32Argument; + bitmap32Argument = [NSNumber numberWithUnsignedInt:0UL]; + [cluster writeAttributeBitmap32WithValue:bitmap32Argument + completion:^(NSError * _Nullable err) { + NSLog(@"Write attribute BITMAP32 Back to Default Value Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestWriteAttributeInt32uValue_12() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int32uArgument; @@ -88187,12 +90807,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeInt32uValueMinValueConstraints_12() + CHIP_ERROR TestReadAttributeInt32uValueMinValueConstraints_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -88208,12 +90827,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeInt32uValueMaxValueConstraints_13() + CHIP_ERROR TestReadAttributeInt32uValueMaxValueConstraints_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -88229,12 +90847,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeInt32uValueNotValueConstraints_14() + CHIP_ERROR TestReadAttributeInt32uValueNotValueConstraints_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -88250,12 +90867,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeInt32uValueBackToDefaultValue_15() + CHIP_ERROR TestWriteAttributeInt32uValueBackToDefaultValue_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int32uArgument; @@ -88272,12 +90888,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeCharStringValue_16() + CHIP_ERROR TestWriteAttributeCharStringValue_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id charStringArgument; @@ -88294,12 +90909,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeCharStringValueMinLengthConstraints_17() + CHIP_ERROR TestReadAttributeCharStringValueMinLengthConstraints_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -88314,12 +90928,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeCharStringValueMaxLengthConstraints_18() + CHIP_ERROR TestReadAttributeCharStringValueMaxLengthConstraints_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -88334,12 +90947,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeCharStringValueStartsWithConstraints_19() + CHIP_ERROR TestReadAttributeCharStringValueStartsWithConstraints_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -88354,12 +90966,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeCharStringValueEndsWithConstraints_20() + CHIP_ERROR TestReadAttributeCharStringValueEndsWithConstraints_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -88374,12 +90985,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeCharStringValue_21() + CHIP_ERROR TestWriteAttributeCharStringValue_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id charStringArgument; @@ -88396,12 +91006,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeCharStringValueIsLowerCaseIsUpperCaseConstraints_22() + CHIP_ERROR TestReadAttributeCharStringValueIsLowerCaseIsUpperCaseConstraints_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -88417,12 +91026,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeCharStringValue_23() + CHIP_ERROR TestWriteAttributeCharStringValue_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id charStringArgument; @@ -88439,12 +91047,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeCharStringValueIsLowerCaseIsUpperCaseConstraints_24() + CHIP_ERROR TestReadAttributeCharStringValueIsLowerCaseIsUpperCaseConstraints_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -88460,12 +91067,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeCharStringValue_25() + CHIP_ERROR TestWriteAttributeCharStringValue_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id charStringArgument; @@ -88482,12 +91088,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeCharStringValueIsLowerCaseIsUpperCaseConstraints_26() + CHIP_ERROR TestReadAttributeCharStringValueIsLowerCaseIsUpperCaseConstraints_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -88503,12 +91108,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeCharStringValue_27() + CHIP_ERROR TestWriteAttributeCharStringValue_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id charStringArgument; @@ -88525,12 +91129,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeCharStringValueIsHexStringConstraints_28() + CHIP_ERROR TestReadAttributeCharStringValueIsHexStringConstraints_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -88545,12 +91148,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeCharStringValue_29() + CHIP_ERROR TestWriteAttributeCharStringValue_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id charStringArgument; @@ -88567,12 +91169,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestReadAttributeCharStringValueIsHexStringConstraints_30() + CHIP_ERROR TestReadAttributeCharStringValueIsHexStringConstraints_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -88587,12 +91188,11 @@ class TestConstraints : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestWriteAttributeCharStringValueBackToDefaultValue_31() + CHIP_ERROR TestWriteAttributeCharStringValueBackToDefaultValue_32() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id charStringArgument; @@ -88695,6 +91295,7 @@ class TestDelayCommands : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -88702,6 +91303,7 @@ class TestDelayCommands : public TestCommandBridge { CHIP_ERROR TestWait100ms_1() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -88800,6 +91402,7 @@ class TestLogCommands : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -88807,6 +91410,7 @@ class TestLogCommands : public TestCommandBridge { CHIP_ERROR TestLogASimpleMessage_1() { + chip::app::Clusters::LogCommands::Commands::Log::Type value; value.message = chip::Span("This is a simple messagegarbage: not in length on purpose", 24); return Log("alpha", value); @@ -88814,6 +91418,7 @@ class TestLogCommands : public TestCommandBridge { CHIP_ERROR TestDoASimpleUserPromptMessage_2() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("This is a simple messagegarbage: not in length on purpose", 24); return UserPrompt("alpha", value); @@ -89667,6 +92272,7 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -89675,10 +92281,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestSendTestAddArgumentsCommand_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestAddArgumentsParams alloc] init]; @@ -89707,10 +92312,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestSendTestAddArgumentsCommand_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestAddArgumentsParams alloc] init]; @@ -89736,10 +92340,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestSendTestAddArgumentsCommand_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestAddArgumentsParams alloc] init]; @@ -89764,10 +92367,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeBooleanDefaultValue_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -89791,10 +92393,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBooleanNotDefaultValue_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id booleanArgument; @@ -89813,10 +92414,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeBooleanNotDefaultValue_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -89834,10 +92434,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBooleanDefaultValue_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id booleanArgument; @@ -89856,10 +92455,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeBooleanFalse_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBooleanWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -89881,10 +92479,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap8DefaultValue_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -89908,10 +92505,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap8NotDefaultValue_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap8Argument; @@ -89930,10 +92526,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap8NotDefaultValue_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -89951,10 +92546,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap8DefaultValue_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap8Argument; @@ -89973,10 +92567,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap8DefaultValue_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -89998,10 +92591,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap16DefaultValue_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90025,10 +92617,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap16NotDefaultValue_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap16Argument; @@ -90047,10 +92638,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap16NotDefaultValue_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90068,10 +92658,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap16DefaultValue_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap16Argument; @@ -90090,10 +92679,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap16DefaultValue_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90115,10 +92703,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap32DefaultValue_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90142,10 +92729,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap32NotDefaultValue_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap32Argument; @@ -90164,10 +92750,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap32NotDefaultValue_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90185,10 +92770,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap32DefaultValue_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap32Argument; @@ -90207,10 +92791,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap32DefaultValue_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap32WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90232,10 +92815,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap64DefaultValue_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap64WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90259,10 +92841,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap64NotDefaultValue_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap64Argument; @@ -90281,10 +92862,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap64DefaultValue_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap64WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90302,10 +92882,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeBitmap64DefaultValue_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bitmap64Argument; @@ -90324,10 +92903,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeBitmap64DefaultValue_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBitmap64WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90349,10 +92927,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt8uDefaultValue_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90376,10 +92953,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt8uNotDefaultValue_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int8uArgument; @@ -90398,10 +92974,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt8uNotDefaultValue_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90419,10 +92994,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt8uDefaultValue_32() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int8uArgument; @@ -90441,10 +93015,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt8uDefaultValue_33() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt8uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90466,10 +93039,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt16uDefaultValue_34() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90493,10 +93065,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt16uNotDefaultValue_35() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int16uArgument; @@ -90515,10 +93086,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt16uNotDefaultValue_36() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90536,10 +93106,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt16uDefaultValue_37() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int16uArgument; @@ -90558,10 +93127,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt16uDefaultValue_38() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt16uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90583,10 +93151,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt32uDefaultValue_39() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90610,10 +93177,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt32uNotDefaultValue_40() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int32uArgument; @@ -90632,10 +93198,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt32uNotDefaultValue_41() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90653,10 +93218,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt32uDefaultValue_42() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int32uArgument; @@ -90675,10 +93239,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt32uDefaultValue_43() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90700,10 +93263,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt64uDefaultValue_44() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90727,10 +93289,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt64uNotDefaultValue_45() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int64uArgument; @@ -90749,10 +93310,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt64uNotDefaultValue_46() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90770,10 +93330,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt64uDefaultValue_47() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int64uArgument; @@ -90792,10 +93351,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt64uDefaultValue_48() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt64uWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90817,10 +93375,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt8sDefaultValue_49() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90844,10 +93401,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt8sNotDefaultValue_50() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int8sArgument; @@ -90866,10 +93422,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt8sNotDefaultValue_51() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90887,10 +93442,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt8sDefaultValue_52() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int8sArgument; @@ -90909,10 +93463,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt8sDefaultValue_53() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt8sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90934,10 +93487,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt16sDefaultValue_54() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -90961,10 +93513,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt16sNotDefaultValue_55() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int16sArgument; @@ -90983,10 +93534,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt16sNotDefaultValue_56() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91004,10 +93554,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt16sDefaultValue_57() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int16sArgument; @@ -91026,10 +93575,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt16sDefaultValue_58() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt16sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91051,10 +93599,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt32sDefaultValue_59() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91078,10 +93625,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt32sNotDefaultValue_60() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int32sArgument; @@ -91100,10 +93646,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt32sNotDefaultValue_61() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91121,10 +93666,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt32sDefaultValue_62() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int32sArgument; @@ -91143,10 +93687,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt32sDefaultValue_63() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt32sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91168,10 +93711,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt64sDefaultValue_64() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91195,10 +93737,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeIntsNotDefaultValue_65() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int64sArgument; @@ -91217,10 +93758,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt64sNotDefaultValue_66() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91238,10 +93778,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeInt64sDefaultValue_67() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id int64sArgument; @@ -91260,10 +93799,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeInt64sDefaultValue_68() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeInt64sWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91285,10 +93823,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeEnum8DefaultValue_69() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnum8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91312,10 +93849,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeEnum8NotDefaultValue_70() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id enum8Argument; @@ -91334,10 +93870,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeEnum8NotDefaultValue_71() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnum8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91355,10 +93890,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeEnum8DefaultValue_72() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id enum8Argument; @@ -91377,10 +93911,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeEnum8DefaultValue_73() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnum8WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91402,10 +93935,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeEnum16DefaultValue_74() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnum16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91429,10 +93961,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeEnum16NotDefaultValue_75() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id enum16Argument; @@ -91451,10 +93982,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeEnum16NotDefaultValue_76() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnum16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91472,10 +94002,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeEnum16DefaultValue_77() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id enum16Argument; @@ -91494,10 +94023,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeEnum16DefaultValue_78() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEnum16WithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91519,10 +94047,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeEpochUsDefaultValue_79() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEpochUsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91546,10 +94073,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeEpochUsNotDefaultValue_80() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id epochUsArgument; @@ -91568,10 +94094,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeEpochUsNotDefaultValue_81() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEpochUsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91589,10 +94114,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeEpochUsDefaultValue_82() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id epochUsArgument; @@ -91611,10 +94135,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeEpochUsDefaultValue_83() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEpochUsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91636,10 +94159,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeEpochSDefaultValue_84() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEpochSWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91663,10 +94185,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeEpochSNotDefaultValue_85() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id epochSArgument; @@ -91685,10 +94206,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeEpochSNotDefaultValue_86() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEpochSWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91706,10 +94226,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeEpochSDefaultValue_87() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id epochSArgument; @@ -91728,10 +94247,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeEpochSDefaultValue_88() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeEpochSWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91753,10 +94271,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeVendorIdDefaultValue_89() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeVendorIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91780,10 +94297,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeVendorIdNotDefaultValue_90() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id vendorIdArgument; @@ -91802,10 +94318,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeVendorIdNotDefaultValue_91() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeVendorIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91823,10 +94338,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeVendorIdDefaultValue_92() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id vendorIdArgument; @@ -91845,10 +94359,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeVendorIdDefaultValue_93() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeVendorIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -91870,10 +94383,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeCharStringDefaultValue_94() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -91897,10 +94409,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeCharStringDefaultValueAndCompareToSavedValue_95() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -91921,10 +94432,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeCharStringNotDefaultValue_96() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id charStringArgument; @@ -91944,10 +94454,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeCharStringNotDefaultValue_97() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -91973,10 +94482,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeCharStringNotDefaultValueAndCompareToSavedValue_98() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -91999,10 +94507,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeCharStringNotDefaultValueFromSavedValue_99() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id charStringArgument; @@ -92021,10 +94528,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeCharStringNotDefaultValueAndCompareToExpectedValue_100() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCharStringWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -92045,10 +94551,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeCharStringDefaultValue_101() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id charStringArgument; @@ -92068,10 +94573,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeOctetStringDefaultValue_102() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -92095,10 +94599,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeOctetStringDefaultValueAndCompareToSavedValue_103() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -92119,10 +94622,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeOctetStringNotDefaultValue_104() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id octetStringArgument; @@ -92142,10 +94644,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeOctetStringNotDefaultValue_105() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -92172,10 +94673,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeOctetStringNotDefaultValueAndCompareToSavedValue_106() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -92198,10 +94698,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeOctetStringNotDefaultValueFromSavedValue_107() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id octetStringArgument; @@ -92221,10 +94720,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestReadAttributeOctetStringNotDefaultValueAndCompareToExpectedValue_108() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOctetStringWithCompletion:^(NSData * _Nullable value, NSError * _Nullable err) { @@ -92246,10 +94744,9 @@ class TestSaveAs : public TestCommandBridge { CHIP_ERROR TestWriteAttributeOctetStringDefaultValue_109() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id octetStringArgument; @@ -92363,6 +94860,7 @@ class TestConfigVariables : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -92371,10 +94869,9 @@ class TestConfigVariables : public TestCommandBridge { CHIP_ERROR TestSendTestAddArgumentsCommand_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestAddArgumentsParams alloc] init]; @@ -92403,10 +94900,9 @@ class TestConfigVariables : public TestCommandBridge { CHIP_ERROR TestSendTestAddArgumentsCommand_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUnitTesting * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUnitTesting alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRUnitTestingClusterTestAddArgumentsParams alloc] init]; @@ -92538,6 +95034,7 @@ class TestDescriptorCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -92545,10 +95042,9 @@ class TestDescriptorCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeDeviceList_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeDeviceTypeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -92571,10 +95067,9 @@ class TestDescriptorCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeServerList_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeServerListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -92622,10 +95117,9 @@ class TestDescriptorCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributeClientList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClientListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -92647,10 +95141,9 @@ class TestDescriptorCluster : public TestCommandBridge { CHIP_ERROR TestReadAttributePartsList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDescriptor * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDescriptor alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePartsListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -92869,6 +95362,7 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -92876,8 +95370,9 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestReadLocation_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLocationWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -92898,8 +95393,9 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestWriteLocation_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id locationArgument; @@ -92918,8 +95414,9 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestReadBackLocation_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLocationWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -92940,8 +95437,9 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestRestoreInitialLocationValue_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id locationArgument; @@ -92960,8 +95458,9 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestReadAttributeListValue_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -93007,8 +95506,9 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestReadNodeLabel_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNodeLabelWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -93029,8 +95529,9 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestWriteNodeLabel_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nodeLabelArgument; @@ -93049,8 +95550,9 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestReadBackNodeLabel_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNodeLabelWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -93071,8 +95573,9 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestReadLocalConfigDisabled_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLocalConfigDisabledWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -93093,8 +95596,9 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestWriteLocalConfigDisabled_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id localConfigDisabledArgument; @@ -93113,8 +95617,9 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestReadBackLocalConfigDisabled_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLocalConfigDisabledWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -93135,12 +95640,14 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestRebootTheDevice_12() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestConnectToTheDeviceAgain_13() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -93148,8 +95655,9 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestReadBackNodeLabelAfterReboot_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNodeLabelWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -93170,8 +95678,9 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestRestoreInitialNodeLabelValue_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nodeLabelArgument; @@ -93190,8 +95699,9 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestReadBackLocalConfigDisabledAfterReboot_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLocalConfigDisabledWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -93212,8 +95722,9 @@ class TestBasicInformation : public TestCommandBridge { CHIP_ERROR TestRestoreInitialLocalConfigDisabledValue_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id localConfigDisabledArgument; @@ -93369,6 +95880,7 @@ class TestFabricRemovalWhileSubscribed : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -93376,9 +95888,11 @@ class TestFabricRemovalWhileSubscribed : public TestCommandBridge { CHIP_ERROR TestReadNumberOfCommissionedFabrics_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCommissionedFabricsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -93401,9 +95915,11 @@ class TestFabricRemovalWhileSubscribed : public TestCommandBridge { CHIP_ERROR TestReadCurrentFabricIndex_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentFabricIndexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -93425,9 +95941,11 @@ class TestFabricRemovalWhileSubscribed : public TestCommandBridge { CHIP_ERROR TestOpenCommissioningWindowFromAlpha_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAdministratorCommissioningClusterOpenBasicCommissioningWindowParams alloc] init]; @@ -93446,6 +95964,7 @@ class TestFabricRemovalWhileSubscribed : public TestCommandBridge { CHIP_ERROR TestCommissionFromBeta_4() { + chip::app::Clusters::CommissionerCommands::Commands::PairWithCode::Type value; value.nodeId = 74565ULL; value.payload = mPayload.HasValue() ? mPayload.Value() : chip::Span("MT:-24J0AFN00KA0648G00", 22); @@ -93454,6 +95973,7 @@ class TestFabricRemovalWhileSubscribed : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrievedForBeta_5() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = 74565ULL; return WaitForCommissionee("beta", value); @@ -93463,9 +95983,11 @@ class TestFabricRemovalWhileSubscribed : public TestCommandBridge { CHIP_ERROR TestReportSubscribeFabricsAttributeFromBeta_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_TestFabricRemovalWhileSubscribed_Fabrics_Reported = ^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -93483,15 +96005,17 @@ class TestFabricRemovalWhileSubscribed : public TestCommandBridge { CHIP_ERROR TestSubscribeFabricsAttributeFromBeta_7() { + MTRBaseDevice * device = GetDevice("beta"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); uint16_t minIntervalArgument = 2U; uint16_t maxIntervalArgument = 5U; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) - maxInterval:@(maxIntervalArgument)]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) + maxInterval:@(maxIntervalArgument)]; params.filterByFabric = true; params.replaceExistingSubscriptions = true; [cluster subscribeAttributeFabricsWithParams:params @@ -93516,9 +96040,11 @@ class TestFabricRemovalWhileSubscribed : public TestCommandBridge { CHIP_ERROR TestRemoveSingleOwnFabric_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTROperationalCredentialsClusterRemoveFabricParams alloc] init]; @@ -93832,6 +96358,7 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -93839,10 +96366,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestWriteBreadcrumb12_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id breadcrumbArgument; @@ -93861,10 +96389,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestReadBackBreadcrumb12_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBreadcrumbWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -93885,10 +96414,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestWriteBreadcrumb22_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id breadcrumbArgument; @@ -93907,10 +96437,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestReadBackBreadcrumb22_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBreadcrumbWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -93931,12 +96462,14 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestRebootToResetBreadcrumb_5() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestConnectToTheDeviceAgain_6() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -93944,10 +96477,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestReadBackBreadcrumbAfterRebootAndEnsureItWasNotPersisted_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBreadcrumbWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -93968,10 +96502,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestSetBreadcrumbToNonzeroValue_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id breadcrumbArgument; @@ -93990,10 +96525,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestCheckBreadcrumbSetWorked_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBreadcrumbWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -94014,10 +96550,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestSendCommissioningCompleteWithoutArmedFailSafe_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster commissioningCompleteWithCompletion:^( @@ -94039,10 +96576,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestCheckBreadcrumbWasNotTouchedByInvalidCommissioningComplete_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBreadcrumbWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -94063,9 +96601,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestOpenCommissioningWindowFromAlpha_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAdministratorCommissioningClusterOpenBasicCommissioningWindowParams alloc] init]; @@ -94084,10 +96624,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestTryToArmFailSafe_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGeneralCommissioningClusterArmFailSafeParams alloc] init]; @@ -94113,10 +96654,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestCheckBreadcrumbWasNotTouchedByArmFailSafeWithCommissioningWindowOpen_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBreadcrumbWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -94137,10 +96679,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestResetBreadcrumbTo0SoWeCanCommission_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id breadcrumbArgument; @@ -94159,6 +96702,7 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestCommissionFromBeta_16() { + chip::app::Clusters::CommissionerCommands::Commands::PairWithCode::Type value; value.nodeId = 74565ULL; value.payload = mPayload.HasValue() ? mPayload.Value() : chip::Span("MT:-24J0AFN00KA0648G00", 22); @@ -94167,6 +96711,7 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrievedForBeta_17() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = 74565ULL; return WaitForCommissionee("beta", value); @@ -94174,10 +96719,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestArmFailSafe_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGeneralCommissioningClusterArmFailSafeParams alloc] init]; @@ -94203,10 +96749,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestCheckBreadcrumbWasProperlySetByArmFailSafe_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBreadcrumbWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -94227,10 +96774,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestTryToArmFailSafeFromWrongFabric_20() { + MTRBaseDevice * device = GetDevice("beta"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGeneralCommissioningClusterArmFailSafeParams alloc] init]; @@ -94256,10 +96804,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestCheckBreadcrumbWasNotTouchedByArmFailSafeWithExistingFailSafeArmed_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBreadcrumbWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -94280,10 +96829,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestSendCommissioningCompleteFromWrongFabric_22() { + MTRBaseDevice * device = GetDevice("beta"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster commissioningCompleteWithCompletion:^( @@ -94305,10 +96855,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestCheckBreadcrumbWasNotTouchedByCommissioningCompleteFromWrongFabric_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBreadcrumbWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -94329,10 +96880,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestCloseOutTheFailSafeGracefully_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster commissioningCompleteWithCompletion:^( @@ -94354,10 +96906,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestCheckBreadcrumbWasResetTo0ByCommissioningComplete_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBreadcrumbWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -94378,10 +96931,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestArmFailSafeAgain_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGeneralCommissioningClusterArmFailSafeParams alloc] init]; @@ -94407,10 +96961,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestCheckBreadcrumbWasSetByArmingFailSafeAgain_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBreadcrumbWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -94431,10 +96986,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestForceExpireTheFailSafe_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGeneralCommissioningClusterArmFailSafeParams alloc] init]; @@ -94460,10 +97016,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestCheckBreadcrumbWasResetByExpiringTheFailSafe_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeBreadcrumbWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -94484,10 +97041,11 @@ class TestGeneralCommissioning : public TestCommandBridge { CHIP_ERROR TestValidatePresenceOfSupportsConcurrentConnection_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSupportsConcurrentConnectionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -94588,6 +97146,7 @@ class TestIdentifyCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -94595,10 +97154,9 @@ class TestIdentifyCluster : public TestCommandBridge { CHIP_ERROR TestSendIdentifyCommandAndExpectSuccessResponse_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterIdentify * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterIdentify alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRIdentifyClusterIdentifyParams alloc] init]; @@ -94743,6 +97301,7 @@ class TestOperationalCredentialsCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -94750,9 +97309,11 @@ class TestOperationalCredentialsCluster : public TestCommandBridge { CHIP_ERROR TestReadNumberOfSupportedFabrics_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSupportedFabricsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -94771,9 +97332,11 @@ class TestOperationalCredentialsCluster : public TestCommandBridge { CHIP_ERROR TestReadNumberOfCommissionedFabrics_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCommissionedFabricsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -94793,9 +97356,11 @@ class TestOperationalCredentialsCluster : public TestCommandBridge { CHIP_ERROR TestReadCurrentFabricIndex_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentFabricIndexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -94817,9 +97382,11 @@ class TestOperationalCredentialsCluster : public TestCommandBridge { CHIP_ERROR TestRemoveNonexistentFabric_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTROperationalCredentialsClusterRemoveFabricParams alloc] init]; @@ -94844,12 +97411,14 @@ class TestOperationalCredentialsCluster : public TestCommandBridge { CHIP_ERROR TestReadFabricListBeforeSettingLabel_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; [cluster readAttributeFabricsWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -94875,9 +97444,11 @@ class TestOperationalCredentialsCluster : public TestCommandBridge { CHIP_ERROR TestSetTheFabricLabel_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTROperationalCredentialsClusterUpdateFabricLabelParams alloc] init]; @@ -94907,12 +97478,14 @@ class TestOperationalCredentialsCluster : public TestCommandBridge { CHIP_ERROR TestReadFabricListAfterSettingLabel_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; [cluster readAttributeFabricsWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -95234,6 +97807,7 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -95241,10 +97815,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestReadDescription_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeDescriptionWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -95265,10 +97838,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestReadStandardNamespace_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeStandardNamespaceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -95290,10 +97862,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestReadSupportedModes_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSupportedModesWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -95309,16 +97880,28 @@ class TestModeSelectCluster : public TestCommandBridge { VerifyOrReturn(CheckValue("Mode", ((MTRModeSelectClusterModeOptionStruct *) actualValue[0]).mode, 0U)); VerifyOrReturn(CheckValue("SemanticTags", [((MTRModeSelectClusterModeOptionStruct *) actualValue[0]).semanticTags count], static_cast(1))); + VerifyOrReturn(CheckValue("Value", + ((MTRModeSelectClusterSemanticTag *) ((MTRModeSelectClusterModeOptionStruct *) actualValue[0]).semanticTags[0]) + .value, + 0U)); VerifyOrReturn( CheckValueAsString("Label", ((MTRModeSelectClusterModeOptionStruct *) actualValue[1]).label, @"Cappuccino")); VerifyOrReturn(CheckValue("Mode", ((MTRModeSelectClusterModeOptionStruct *) actualValue[1]).mode, 4U)); VerifyOrReturn(CheckValue("SemanticTags", [((MTRModeSelectClusterModeOptionStruct *) actualValue[1]).semanticTags count], static_cast(1))); + VerifyOrReturn(CheckValue("Value", + ((MTRModeSelectClusterSemanticTag *) ((MTRModeSelectClusterModeOptionStruct *) actualValue[1]).semanticTags[0]) + .value, + 0U)); VerifyOrReturn( CheckValueAsString("Label", ((MTRModeSelectClusterModeOptionStruct *) actualValue[2]).label, @"Espresso")); VerifyOrReturn(CheckValue("Mode", ((MTRModeSelectClusterModeOptionStruct *) actualValue[2]).mode, 7U)); VerifyOrReturn(CheckValue("SemanticTags", [((MTRModeSelectClusterModeOptionStruct *) actualValue[2]).semanticTags count], static_cast(1))); + VerifyOrReturn(CheckValue("Value", + ((MTRModeSelectClusterSemanticTag *) ((MTRModeSelectClusterModeOptionStruct *) actualValue[2]).semanticTags[0]) + .value, + 0U)); } VerifyOrReturn(CheckConstraintType("supportedModes", "list", "list")); @@ -95332,10 +97915,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestReadCurrentMode_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -95356,10 +97938,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestReadStartUpMode_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeStartUpModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -95381,10 +97962,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestReadOnMode_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -95405,10 +97985,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestChangeToSupportedMode_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRModeSelectClusterChangeToModeParams alloc] init]; @@ -95428,10 +98007,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestVerifyCurrentModeChange_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -95455,10 +98033,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestChangeToUnsupportedMode_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRModeSelectClusterChangeToModeParams alloc] init]; @@ -95480,8 +98057,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestToggleOnOff_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -95497,8 +98075,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestToggleOnOff_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -95514,10 +98093,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestVerifyCurrentModeDoesNotChangeWhenOnModeIsNull_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -95538,10 +98116,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestChangeToUnsupportedOnMode_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id onModeArgument; @@ -95564,10 +98141,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestChangeOnMode_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id onModeArgument; @@ -95587,10 +98163,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestVerifyOnMode_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -95615,8 +98190,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestToggleOnOff_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -95632,8 +98208,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestToggleOnOff_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -95649,10 +98226,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestVerifyCurrentModeChangesIfOnModeIsNotNull_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -95673,10 +98249,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestChangeToUnsupportedStartUpMode_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id startUpModeArgument; @@ -95699,10 +98274,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestChangeToSupportedStartUpMode_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id startUpModeArgument; @@ -95721,10 +98295,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestVerifyStartUpModeChange_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeStartUpModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -95746,10 +98319,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestChangeCurrentModeToAnotherValue_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRModeSelectClusterChangeToModeParams alloc] init]; @@ -95768,10 +98340,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestChangeOnMode_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id onModeArgument; @@ -95790,8 +98361,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestSetStartUpOnOff_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id startUpOnOffArgument; @@ -95810,12 +98382,14 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestRebootTargetDevice_25() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_26() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -95823,10 +98397,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestVerifyCurrentModeChangeBasedOnOnModeAsItOverwritesStartUpMode_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -95847,10 +98420,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestChangeOnModeToNull_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id onModeArgument; @@ -95869,12 +98441,14 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestRebootTargetDevice_29() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_30() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -95882,10 +98456,9 @@ class TestModeSelectCluster : public TestCommandBridge { CHIP_ERROR TestVerifyCurrentModeChangeBasedOnNewStartUpMode_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterModeSelect * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterModeSelect alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -96004,6 +98577,7 @@ class TestSelfFabricRemoval : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -96011,9 +98585,11 @@ class TestSelfFabricRemoval : public TestCommandBridge { CHIP_ERROR TestReadNumberOfCommissionedFabrics_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCommissionedFabricsWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -96036,9 +98612,11 @@ class TestSelfFabricRemoval : public TestCommandBridge { CHIP_ERROR TestReadCurrentFabricIndex_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentFabricIndexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -96060,9 +98638,11 @@ class TestSelfFabricRemoval : public TestCommandBridge { CHIP_ERROR TestRemoveSingleOwnFabric_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTROperationalCredentialsClusterRemoveFabricParams alloc] init]; @@ -96309,6 +98889,7 @@ class TestSystemCommands : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -96316,18 +98897,21 @@ class TestSystemCommands : public TestCommandBridge { CHIP_ERROR TestStopTheDefaultAccessory_1() { + chip::app::Clusters::SystemCommands::Commands::Stop::Type value; return Stop("alpha", value); } CHIP_ERROR TestStartTheDefaultAccessoryWithNoCommandLineOptions_2() { + chip::app::Clusters::SystemCommands::Commands::Start::Type value; return Start("alpha", value); } CHIP_ERROR TestStopTheDefaultAccessoryByKey_3() { + chip::app::Clusters::SystemCommands::Commands::Stop::Type value; value.registerKey.Emplace(); value.registerKey.Value() = chip::Span("defaultgarbage: not in length on purpose", 7); @@ -96336,6 +98920,7 @@ class TestSystemCommands : public TestCommandBridge { CHIP_ERROR TestStartTheDefaultAccessoryWithDiscriminatorCommandLineOption_4() { + chip::app::Clusters::SystemCommands::Commands::Start::Type value; value.discriminator.Emplace(); value.discriminator.Value() = 1111U; @@ -96344,12 +98929,14 @@ class TestSystemCommands : public TestCommandBridge { CHIP_ERROR TestStopTheDefaultAccessory_5() { + chip::app::Clusters::SystemCommands::Commands::Stop::Type value; return Stop("alpha", value); } CHIP_ERROR TestStartTheDefaultAccessoryWithDiscriminatorAndPortCommandLineOptions_6() { + chip::app::Clusters::SystemCommands::Commands::Start::Type value; value.discriminator.Emplace(); value.discriminator.Value() = 1111U; @@ -96360,12 +98947,14 @@ class TestSystemCommands : public TestCommandBridge { CHIP_ERROR TestStopTheDefaultAccessory_7() { + chip::app::Clusters::SystemCommands::Commands::Stop::Type value; return Stop("alpha", value); } CHIP_ERROR TestStartTheDefaultAccessoryWithMinCommissioningTimeoutOnly_8() { + chip::app::Clusters::SystemCommands::Commands::Start::Type value; value.minCommissioningTimeout.Emplace(); value.minCommissioningTimeout.Value() = 10U; @@ -96374,12 +98963,14 @@ class TestSystemCommands : public TestCommandBridge { CHIP_ERROR TestStopTheDefaultAccessory_9() { + chip::app::Clusters::SystemCommands::Commands::Stop::Type value; return Stop("alpha", value); } CHIP_ERROR TestStartTheDefaultAccessoryByKeyWithAllCommandLineOptions_10() { + chip::app::Clusters::SystemCommands::Commands::Start::Type value; value.registerKey.Emplace(); value.registerKey.Value() = chip::Span("defaultgarbage: not in length on purpose", 7); @@ -96396,6 +98987,7 @@ class TestSystemCommands : public TestCommandBridge { CHIP_ERROR TestStartASecondAccessoryWithAllCommandLineOptions_11() { + chip::app::Clusters::SystemCommands::Commands::Start::Type value; value.registerKey.Emplace(); value.registerKey.Value() = chip::Span("chip-lock-appgarbage: not in length on purpose", 13); @@ -96410,6 +99002,7 @@ class TestSystemCommands : public TestCommandBridge { CHIP_ERROR TestCommissionSecondAccessoryFromAlpha_12() { + chip::app::Clusters::CommissionerCommands::Commands::PairWithCode::Type value; value.nodeId = 3735928559ULL; value.payload = mPayload.HasValue() ? mPayload.Value() : chip::Span("MT:-24J0IX4122-.548G00", 22); @@ -96418,6 +99011,7 @@ class TestSystemCommands : public TestCommandBridge { CHIP_ERROR TestWaitForTheSecondCommissionedDeviceToBeRetrievedForAlpha_13() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = 3735928559ULL; return WaitForCommissionee("alpha", value); @@ -96425,6 +99019,7 @@ class TestSystemCommands : public TestCommandBridge { CHIP_ERROR TestStopTheSecondAccessory_14() { + chip::app::Clusters::SystemCommands::Commands::Stop::Type value; value.registerKey.Emplace(); value.registerKey.Value() = chip::Span("chip-lock-appgarbage: not in length on purpose", 13); @@ -96433,6 +99028,7 @@ class TestSystemCommands : public TestCommandBridge { CHIP_ERROR TestStartASecondAccessoryWithDifferentKvs_15() { + chip::app::Clusters::SystemCommands::Commands::Start::Type value; value.registerKey.Emplace(); value.registerKey.Value() = chip::Span("chip-lock-appgarbage: not in length on purpose", 13); @@ -96447,12 +99043,14 @@ class TestSystemCommands : public TestCommandBridge { CHIP_ERROR TestRebootTheDefaultAccessory_16() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestRebootTheDefaultAccessoryByKey_17() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; value.registerKey.Emplace(); value.registerKey.Value() = chip::Span("defaultgarbage: not in length on purpose", 7); @@ -96461,6 +99059,7 @@ class TestSystemCommands : public TestCommandBridge { CHIP_ERROR TestRebootTheSecondAccessory_18() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; value.registerKey.Emplace(); value.registerKey.Value() = chip::Span("chip-lock-appgarbage: not in length on purpose", 13); @@ -96469,12 +99068,14 @@ class TestSystemCommands : public TestCommandBridge { CHIP_ERROR TestFactoryResetTheDefaultAccessory_19() { + chip::app::Clusters::SystemCommands::Commands::FactoryReset::Type value; return FactoryReset("alpha", value); } CHIP_ERROR TestFactoryResetTheDefaultAccessoryByKey_20() { + chip::app::Clusters::SystemCommands::Commands::FactoryReset::Type value; value.registerKey.Emplace(); value.registerKey.Value() = chip::Span("defaultgarbage: not in length on purpose", 7); @@ -96483,6 +99084,7 @@ class TestSystemCommands : public TestCommandBridge { CHIP_ERROR TestFactoryResetTheSecondAccessory_21() { + chip::app::Clusters::SystemCommands::Commands::FactoryReset::Type value; value.registerKey.Emplace(); value.registerKey.Value() = chip::Span("chip-lock-appgarbage: not in length on purpose", 13); @@ -96624,6 +99226,7 @@ class TestBinding : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -96631,10 +99234,9 @@ class TestBinding : public TestCommandBridge { CHIP_ERROR TestWriteEmptyBindingTable_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bindingArgument; @@ -96656,13 +99258,12 @@ class TestBinding : public TestCommandBridge { CHIP_ERROR TestReadEmptyBindingTable_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; [cluster readAttributeBindingWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -96683,10 +99284,9 @@ class TestBinding : public TestCommandBridge { CHIP_ERROR TestWriteInvalidBindingTable_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bindingArgument; @@ -96722,10 +99322,9 @@ class TestBinding : public TestCommandBridge { CHIP_ERROR TestWriteBindingTableEndpoint1_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bindingArgument; @@ -96762,13 +99361,12 @@ class TestBinding : public TestCommandBridge { CHIP_ERROR TestReadBindingTableEndpoint1_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; [cluster readAttributeBindingWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -96807,10 +99405,9 @@ class TestBinding : public TestCommandBridge { CHIP_ERROR TestWriteBindingTableEndpoint0_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id bindingArgument; @@ -96837,13 +99434,12 @@ class TestBinding : public TestCommandBridge { CHIP_ERROR TestReadBindingTableEndpoint0_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; [cluster readAttributeBindingWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -96870,13 +99466,12 @@ class TestBinding : public TestCommandBridge { CHIP_ERROR TestVerifyEndpoint1NotChanged_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBinding * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBinding alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; [cluster readAttributeBindingWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -97048,6 +99643,7 @@ class TestUserLabelCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -97055,10 +99651,9 @@ class TestUserLabelCluster : public TestCommandBridge { CHIP_ERROR TestCommitUserLabelList_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id labelListArgument; @@ -97096,10 +99691,9 @@ class TestUserLabelCluster : public TestCommandBridge { CHIP_ERROR TestVerifyCommittedUserLabelList_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLabelListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -97131,10 +99725,9 @@ class TestUserLabelCluster : public TestCommandBridge { CHIP_ERROR TestClearUserLabelList_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id labelListArgument; @@ -97156,10 +99749,9 @@ class TestUserLabelCluster : public TestCommandBridge { CHIP_ERROR TestReadUserLabelList_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLabelListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -97180,10 +99772,9 @@ class TestUserLabelCluster : public TestCommandBridge { CHIP_ERROR TestWriteUserLabelList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id labelListArgument; @@ -97221,12 +99812,14 @@ class TestUserLabelCluster : public TestCommandBridge { CHIP_ERROR TestRebootTargetDevice_6() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_7() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -97234,10 +99827,9 @@ class TestUserLabelCluster : public TestCommandBridge { CHIP_ERROR TestVerifyUserLabelListAfterReboot_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLabelListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -97360,6 +99952,7 @@ class TestUserLabelClusterConstraints : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -97367,10 +99960,9 @@ class TestUserLabelClusterConstraints : public TestCommandBridge { CHIP_ERROR TestAttemptToWriteOverlyLongItemForLabel_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id labelListArgument; @@ -97400,10 +99992,9 @@ class TestUserLabelClusterConstraints : public TestCommandBridge { CHIP_ERROR TestAttemptToWriteOverlyLongItemForValue_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterUserLabel * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterUserLabel alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id labelListArgument; @@ -97564,12 +100155,14 @@ class TestArmFailSafe : public TestCommandBridge { CHIP_ERROR TestRebootTargetDevice_0() { + chip::app::Clusters::SystemCommands::Commands::Reboot::Type value; return Reboot("alpha", value); } CHIP_ERROR TestWaitForTheAlphaDeviceToBeRetrieved_1() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -97577,12 +100170,14 @@ class TestArmFailSafe : public TestCommandBridge { CHIP_ERROR TestQueryFabricsList_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; [cluster readAttributeFabricsWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -97593,6 +100188,9 @@ class TestArmFailSafe : public TestCommandBridge { { id actualValue = value; VerifyOrReturn(CheckValue("Fabrics", [actualValue count], static_cast(1))); + VerifyOrReturn(CheckValue("NodeId", + ((MTROperationalCredentialsClusterFabricDescriptor *) actualValue[0]).nodeId, + mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL)); VerifyOrReturn(CheckValueAsString("Label", ((MTROperationalCredentialsClusterFabricDescriptor *) actualValue[0]).label, @"")); } @@ -97606,10 +100204,11 @@ class TestArmFailSafe : public TestCommandBridge { CHIP_ERROR TestArmFailSafeOnTargetDeviceWithTimeout0_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGeneralCommissioning * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGeneralCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGeneralCommissioningClusterArmFailSafeParams alloc] init]; @@ -97635,8 +100234,9 @@ class TestArmFailSafe : public TestCommandBridge { CHIP_ERROR TestReadsNodeLabelMandatoryAttributeOfTargetDevice_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNodeLabelWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -97657,9 +100257,11 @@ class TestArmFailSafe : public TestCommandBridge { CHIP_ERROR TestInvokeAddTrustedRootCertificateWithoutFailSafe_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTROperationalCredentialsClusterAddTrustedRootCertificateParams alloc] init]; @@ -97682,9 +100284,11 @@ class TestArmFailSafe : public TestCommandBridge { CHIP_ERROR TestInvokeAddNOCWithoutFailSafe_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTROperationalCredentialsClusterAddNOCParams alloc] init]; @@ -97709,9 +100313,11 @@ class TestArmFailSafe : public TestCommandBridge { CHIP_ERROR TestInvokeUpdateNOCWithoutFailSafe_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTROperationalCredentialsClusterUpdateNOCParams alloc] init]; @@ -97733,9 +100339,11 @@ class TestArmFailSafe : public TestCommandBridge { CHIP_ERROR TestInvokeCSRRequestWithoutFailSafe_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTROperationalCredentialsClusterCSRRequestParams alloc] init]; @@ -98004,6 +100612,7 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -98011,10 +100620,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestWriteFanMode_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id fanModeArgument; @@ -98033,10 +100641,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackFanMode_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFanModeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98057,10 +100664,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestWriteFanModeSequence_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id fanModeSequenceArgument; @@ -98079,10 +100685,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackFanModeSequence_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFanModeSequenceWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98103,10 +100708,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestWritePercentSetting_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id percentSettingArgument; @@ -98125,10 +100729,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackPercentSetting_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePercentSettingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98150,10 +100753,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackSpeedSetting_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSpeedSettingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98175,10 +100777,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackSpeedCurrent_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSpeedCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98199,10 +100800,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestWritePercentSetting_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id percentSettingArgument; @@ -98221,10 +100821,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackPercentSetting_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePercentSettingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98246,10 +100845,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestWriteSpeedSetting_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id speedSettingArgument; @@ -98268,10 +100866,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackSpeedSetting_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSpeedSettingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98293,10 +100890,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackPercentSetting_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePercentSettingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98318,10 +100914,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackPercentCurrent_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePercentCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98342,10 +100937,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestWriteSpeedSetting_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id speedSettingArgument; @@ -98364,10 +100958,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackSpeedSetting_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSpeedSettingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98389,10 +100982,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestWriteFanMode_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id fanModeArgument; @@ -98411,10 +101003,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackPercentSetting_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePercentSettingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98436,10 +101027,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackPercentCurrent_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePercentCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98460,10 +101050,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackSpeedSetting_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSpeedSettingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98485,10 +101074,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackSpeedCurrent_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSpeedCurrentWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98509,10 +101097,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestWriteFanMode_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id fanModeArgument; @@ -98531,10 +101118,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackPercentSetting_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributePercentSettingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98555,10 +101141,9 @@ class TestFanControl : public TestCommandBridge { CHIP_ERROR TestReadBackSpeedSetting_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterFanControl * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterFanControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeSpeedSettingWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -98731,6 +101316,7 @@ class TestAccessControlConstraints : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -98738,10 +101324,9 @@ class TestAccessControlConstraints : public TestCommandBridge { CHIP_ERROR TestConstraintErrorPaseReservedForFutureTcAcl24Step29_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -98770,7 +101355,7 @@ class TestAccessControlConstraints : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Constraint error: PASE reserved for future (TC-ACL-2.4 step 29) Error: %@", err); @@ -98787,10 +101372,9 @@ class TestAccessControlConstraints : public TestCommandBridge { CHIP_ERROR TestConstraintErrorInvalidCombinationAdministerGroupTcAcl24Step31_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -98820,7 +101404,7 @@ class TestAccessControlConstraints : public TestCommandBridge { aclArgument = temp_0; } [cluster - writeAttributeAclWithValue:aclArgument + writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Constraint error: Invalid combination administer + group (TC-ACL-2.4 step 31) Error: %@", err); @@ -98838,10 +101422,9 @@ class TestAccessControlConstraints : public TestCommandBridge { CHIP_ERROR TestConstraintErrorInvalidAuthModeTcAcl24Step33_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -98870,7 +101453,7 @@ class TestAccessControlConstraints : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Constraint error: Invalid auth mode (TC-ACL-2.4 step 33) Error: %@", err); @@ -98887,10 +101470,9 @@ class TestAccessControlConstraints : public TestCommandBridge { CHIP_ERROR TestConstraintErrorInvalidSubjectTcAcl24Step34_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -98920,7 +101502,7 @@ class TestAccessControlConstraints : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Constraint error: Invalid subject (TC-ACL-2.4 step 34) Error: %@", err); @@ -98937,10 +101519,9 @@ class TestAccessControlConstraints : public TestCommandBridge { CHIP_ERROR TestConstraintErrorInvalidTargetTcAcl24Step38_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -98974,7 +101555,7 @@ class TestAccessControlConstraints : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Constraint error: Invalid target (TC-ACL-2.4 step 38) Error: %@", err); @@ -98991,10 +101572,9 @@ class TestAccessControlConstraints : public TestCommandBridge { CHIP_ERROR TestConstraintErrorTargetHasBothEndpointAndDeviceTypeTcAcl24Step42_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -99029,7 +101609,7 @@ class TestAccessControlConstraints : public TestCommandBridge { aclArgument = temp_0; } [cluster - writeAttributeAclWithValue:aclArgument + writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Constraint error: target has both endpoint and device type (TC-ACL-2.4 step 42) Error: %@", err); @@ -99047,10 +101627,9 @@ class TestAccessControlConstraints : public TestCommandBridge { CHIP_ERROR TestConstraintErrorInvalidPrivilegeValueStep32_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -99076,7 +101655,7 @@ class TestAccessControlConstraints : public TestCommandBridge { aclArgument = temp_0; } - [cluster writeAttributeAclWithValue:aclArgument + [cluster writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog(@"Constraint error: Invalid privilege value step 32) Error: %@", err); @@ -99093,10 +101672,9 @@ class TestAccessControlConstraints : public TestCommandBridge { CHIP_ERROR TestConstraintErrorInvalidSubject0xFFFFFfffFfffFfffTcAcl24Step35_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -99127,7 +101705,7 @@ class TestAccessControlConstraints : public TestCommandBridge { aclArgument = temp_0; } [cluster - writeAttributeAclWithValue:aclArgument + writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog( @"Constraint error: invalid subject 0xFFFF_FFFF_FFFF_FFFF (TC-ACL-2.4 step 35) Error: %@", err); @@ -99145,10 +101723,9 @@ class TestAccessControlConstraints : public TestCommandBridge { CHIP_ERROR TestConstraintErrorInvalidSubject0xFFFFFffd00000000TcAcl24Step36_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -99179,7 +101756,7 @@ class TestAccessControlConstraints : public TestCommandBridge { aclArgument = temp_0; } [cluster - writeAttributeAclWithValue:aclArgument + writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog( @"Constraint error: invalid subject 0xFFFF_FFFD_0000_0000 (TC-ACL-2.4 step 36) Error: %@", err); @@ -99197,10 +101774,9 @@ class TestAccessControlConstraints : public TestCommandBridge { CHIP_ERROR TestConstraintErrorInvalidSubject0xFFFFFfffFfff0000TcAcl24Step37_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAccessControl * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAccessControl alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id aclArgument; @@ -99231,7 +101807,7 @@ class TestAccessControlConstraints : public TestCommandBridge { aclArgument = temp_0; } [cluster - writeAttributeAclWithValue:aclArgument + writeAttributeACLWithValue:aclArgument completion:^(NSError * _Nullable err) { NSLog( @"Constraint error: invalid subject 0xFFFF_FFFF_FFFF_0000 (TC-ACL-2.4 step 37) Error: %@", err); @@ -99550,6 +102126,7 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -99557,10 +102134,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestSendsAMoveToLevelCommandToSetCurrentLevelToMinValue_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; @@ -99582,6 +102158,7 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestWait100Ms_2() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -99589,10 +102166,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestReadsCurrentLevelAttributeFromDut_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -99614,10 +102190,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestWriteOnOffTransitionTimeAttribute_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id onOffTransitionTimeArgument; @@ -99636,6 +102211,7 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestWait100Ms_5() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -99643,10 +102219,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestReadOnOffTransitionTimeAttribute_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffTransitionTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -99667,10 +102242,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestWriteOnLevelAttribute_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id onLevelArgument; @@ -99689,6 +102263,7 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestWait100Ms_8() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -99696,10 +102271,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestReadOnLevelAttribute_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -99721,10 +102295,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestReadMinValueAttribute_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMinLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -99745,8 +102318,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestSendOnCommand_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -99762,8 +102336,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsTrueAfterOnCommand_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -99784,6 +102359,7 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestWaitOnOffTransitionTime_13() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -99791,10 +102367,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestIfOnLevelIsDefinedCheckCurrentLevelIsOnLevelValue_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -99816,8 +102391,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestSendOffCommand_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -99833,8 +102409,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -99855,6 +102432,7 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestWaitOnOffTransitionTime_17() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 0UL; return WaitForMs("alpha", value); @@ -99862,10 +102440,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestIfOnLevelIsDefinedCheckCurrentLevelIsMinValue_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -99887,10 +102464,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestSendsAMoveToLevelCommandToSetCurrentLevelToAMidValue_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRLevelControlClusterMoveToLevelParams alloc] init]; @@ -99912,6 +102488,7 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestWait100Ms_20() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -99919,10 +102496,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestReadsCurrentLevelAttributeFromDut_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -99944,10 +102520,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestSetOnLevelAttributeToNull_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id onLevelArgument; @@ -99966,6 +102541,7 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestWait100Ms_23() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -99973,10 +102549,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestReadOnLevelAttribute_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -99997,8 +102572,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestSendOnCommand_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -100014,8 +102590,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsTrueAfterOnCommand_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100036,6 +102613,7 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestWaitOnOffTransitionTime_27() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 100UL; return WaitForMs("alpha", value); @@ -100043,10 +102621,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestIfOnLevelIsNotDefinedCheckCurrentLevelIsRestored_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100068,8 +102645,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestSendOffCommand_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -100085,8 +102663,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestCheckOnOffAttributeValueIsFalseAfterOffCommand_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeOnOffWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100107,6 +102686,7 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestWaitOnOffTransitionTime_31() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 0UL; return WaitForMs("alpha", value); @@ -100114,10 +102694,9 @@ class TestLevelControlWithOnOffDependency : public TestCommandBridge { CHIP_ERROR TestIfOnLevelIsNotDefinedCheckCurrentLevelIsRestored_32() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterLevelControl * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterLevelControl alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentLevelWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100411,6 +102990,7 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrievedForAlpha_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -100419,9 +102999,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestGetAlphasFabricIndex_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentFabricIndexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100441,9 +103023,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckThatCommissioningWindowIsNotOpen_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWindowStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100464,9 +103048,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckThatThereIsNoAdminFabricIndex_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAdminFabricIndexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100487,9 +103073,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckThatThereIsNoAdminVendorId_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAdminVendorIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100510,9 +103098,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestOpenCommissioningWindowFromAlpha_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAdministratorCommissioningClusterOpenBasicCommissioningWindowParams alloc] init]; @@ -100531,9 +103121,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckThatCommissioningWindowIsOpen_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWindowStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100554,9 +103146,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckTheAdminFabricIndex_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAdminFabricIndexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100582,9 +103176,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckTheAdminVendorIdIsNotNull_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAdminVendorIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100604,9 +103200,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCloseCommissioningWindow_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster revokeCommissioningWithCompletion:^(NSError * _Nullable err) { @@ -100622,9 +103220,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckThatCommissioningWindowIsAgainNotOpen_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWindowStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100645,9 +103245,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckThatAgainThereIsNoAdminFabricIndex_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAdminFabricIndexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100668,9 +103270,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckThatAgainThereIsNoAdminVendorId_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAdminVendorIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100691,9 +103295,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestOpenCommissioningWindowFromAlphaAgain_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAdministratorCommissioningClusterOpenBasicCommissioningWindowParams alloc] init]; @@ -100712,6 +103318,7 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCommissionFromBeta_14() { + chip::app::Clusters::CommissionerCommands::Commands::PairWithCode::Type value; value.nodeId = mNodeId2.HasValue() ? mNodeId2.Value() : 51966ULL; value.payload = mPayload.HasValue() ? mPayload.Value() : chip::Span("MT:-24J0AFN00KA0648G00", 22); @@ -100720,6 +103327,7 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrievedForBeta_15() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId2.HasValue() ? mNodeId2.Value() : 51966ULL; return WaitForCommissionee("beta", value); @@ -100727,9 +103335,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckThatCommissioningWindowIsNotOpenForTheThirdTime_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWindowStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100750,9 +103360,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckThatThereIsNoAdminFabricIndexForTheThirdTime_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAdminFabricIndexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100773,9 +103385,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckThatThereIsNoAdminVendorIdForTheThirdTime_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAdminVendorIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100797,9 +103411,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestGetBetasFabricIndex_19() { + MTRBaseDevice * device = GetDevice("beta"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentFabricIndexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100819,9 +103435,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestOpenCommissioningWindowFromBeta_20() { + MTRBaseDevice * device = GetDevice("beta"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAdministratorCommissioningClusterOpenBasicCommissioningWindowParams alloc] init]; @@ -100840,9 +103458,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckThatCommissioningWindowIsOpenAgain_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWindowStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100863,9 +103483,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckTheAdminFabricIndexAgain_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAdminFabricIndexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100892,9 +103514,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckTheAdminVendorIdIsNotNullAgain_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAdminVendorIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100917,9 +103541,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestRemoveBetaFabric_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTROperationalCredentialsClusterRemoveFabricParams alloc] init]; @@ -100939,9 +103565,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckThatCommissioningWindowIsStillOpen_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWindowStatusWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100962,9 +103590,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckTheAdminFabricIndexGotReset_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAdminFabricIndexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -100985,9 +103615,11 @@ class TestCommissioningWindow : public TestCommandBridge { CHIP_ERROR TestCheckTheAdminVendorIdDidNotGetReset_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAdminVendorIdWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -101218,12 +103850,14 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestStopTargetDevice_0() { + chip::app::Clusters::SystemCommands::Commands::Stop::Type value; return Stop("alpha", value); } CHIP_ERROR TestStartTargetDeviceWithTheProvidedDiscriminatorForBasicCommissioningAdvertisement_1() { + chip::app::Clusters::SystemCommands::Commands::Start::Type value; value.discriminator.Emplace(); value.discriminator.Value() = mDiscriminator.HasValue() ? mDiscriminator.Value() : 3840U; @@ -101232,6 +103866,7 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrievedForAlpha_2() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -101239,6 +103874,7 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestCommissionFromAlphaWhenTheCommissioningWindowIsNotOpened_3() { + chip::app::Clusters::CommissionerCommands::Commands::PairWithCode::Type value; value.nodeId = mNodeIdForDuplicateCommissioning.HasValue() ? mNodeIdForDuplicateCommissioning.Value() : 17ULL; value.payload = mPayload.HasValue() ? mPayload.Value() : chip::Span("MT:-24J0AFN00KA0648G00", 22); @@ -101247,9 +103883,11 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestOpenCommissioningWindowFromAlpha_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAdministratorCommissioningClusterOpenBasicCommissioningWindowParams alloc] init]; @@ -101268,6 +103906,7 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestCommissionFromAlphaAgain_5() { + chip::app::Clusters::CommissionerCommands::Commands::PairWithCode::Type value; value.nodeId = mNodeIdForDuplicateCommissioning.HasValue() ? mNodeIdForDuplicateCommissioning.Value() : 17ULL; value.payload = mPayload.HasValue() ? mPayload.Value() : chip::Span("MT:-24J0AFN00KA0648G00", 22); @@ -101276,12 +103915,14 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestCheckThatWeJustHaveTheOneFabricAndDidNotAddANewOne_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = false; [cluster readAttributeFabricsWithParams:params completion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -101292,6 +103933,9 @@ class TestMultiAdmin : public TestCommandBridge { { id actualValue = value; VerifyOrReturn(CheckValue("Fabrics", [actualValue count], static_cast(1))); + VerifyOrReturn(CheckValue("NodeId", + ((MTROperationalCredentialsClusterFabricDescriptor *) actualValue[0]).nodeId, + mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL)); } NextTest(); @@ -101302,9 +103946,11 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestCloseCommissioningWindowAfterFailedCommissioning_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster revokeCommissioningWithCompletion:^(NSError * _Nullable err) { @@ -101320,9 +103966,11 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestOpenCommissioningWindowFromAlphaAgain_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAdministratorCommissioningClusterOpenBasicCommissioningWindowParams alloc] init]; @@ -101341,6 +103989,7 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestCommissionFromBeta_9() { + chip::app::Clusters::CommissionerCommands::Commands::PairWithCode::Type value; value.nodeId = mNodeId2.HasValue() ? mNodeId2.Value() : 51966ULL; value.payload = mPayload.HasValue() ? mPayload.Value() : chip::Span("MT:-24J0AFN00KA0648G00", 22); @@ -101349,6 +103998,7 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrievedForBeta_10() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId2.HasValue() ? mNodeId2.Value() : 51966ULL; return WaitForCommissionee("beta", value); @@ -101356,9 +104006,11 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestOpenCommissioningWindowFromBeta_11() { + MTRBaseDevice * device = GetDevice("beta"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAdministratorCommissioningClusterOpenBasicCommissioningWindowParams alloc] init]; @@ -101377,6 +104029,7 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestCommissionFromGamma_12() { + chip::app::Clusters::CommissionerCommands::Commands::PairWithCode::Type value; value.nodeId = mNodeId3.HasValue() ? mNodeId3.Value() : 12586990ULL; value.payload = mPayload.HasValue() ? mPayload.Value() : chip::Span("MT:-24J0AFN00KA0648G00", 22); @@ -101385,6 +104038,7 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrievedForGamma_13() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId3.HasValue() ? mNodeId3.Value() : 12586990ULL; return WaitForCommissionee("gamma", value); @@ -101393,8 +104047,9 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeNodeLabelFromAlpha_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNodeLabelWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -101418,8 +104073,9 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestWriteTheMandatoryAttributeNodeLabelFromBeta_15() { + MTRBaseDevice * device = GetDevice("beta"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nodeLabelArgument; @@ -101438,8 +104094,9 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestReadTheMandatoryAttributeNodeLabelFromGamma_16() { + MTRBaseDevice * device = GetDevice("gamma"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNodeLabelWithCompletion:^(NSString * _Nullable value, NSError * _Nullable err) { @@ -101457,8 +104114,9 @@ class TestMultiAdmin : public TestCommandBridge { CHIP_ERROR TestWriteTheMandatoryAttributeNodeLabelBackToDefault_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterBasic * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterBasic alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id nodeLabelArgument; @@ -101665,6 +104323,7 @@ class Test_TC_DGSW_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -101672,10 +104331,11 @@ class Test_TC_DGSW_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -101697,10 +104357,11 @@ class Test_TC_DGSW_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -101722,10 +104383,11 @@ class Test_TC_DGSW_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDGSWSF00WatermarksEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -101742,10 +104404,11 @@ class Test_TC_DGSW_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAttributeListFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -101768,10 +104431,11 @@ class Test_TC_DGSW_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeThreadMetricsInAttributeList_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -101790,10 +104454,11 @@ class Test_TC_DGSW_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeCurrentHeapFreeInAttributeList_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -101812,10 +104477,11 @@ class Test_TC_DGSW_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeCurrentHeapUsedInAttributeList_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -101834,10 +104500,11 @@ class Test_TC_DGSW_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentAttributeCurrentHeapHighWatermarkInAttributeList_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -101856,10 +104523,11 @@ class Test_TC_DGSW_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAcceptedCommandListFromDut_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -101878,10 +104546,11 @@ class Test_TC_DGSW_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAcceptedCommandListFromDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -101903,10 +104572,11 @@ class Test_TC_DGSW_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsGeneratedCommandListFromDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterSoftwareDiagnostics * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterSoftwareDiagnostics alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -102054,6 +104724,7 @@ class TestSubscribe_OnOff : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -102061,8 +104732,9 @@ class TestSubscribe_OnOff : public TestCommandBridge { CHIP_ERROR TestSetOnOffAttributeToFalse_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -102080,8 +104752,9 @@ class TestSubscribe_OnOff : public TestCommandBridge { CHIP_ERROR TestReportSubscribeOnOffAttribute_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_TestSubscribe_OnOff_OnOff_Reported = ^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -102103,14 +104776,15 @@ class TestSubscribe_OnOff : public TestCommandBridge { CHIP_ERROR TestSubscribeOnOffAttribute_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); uint16_t minIntervalArgument = 2U; uint16_t maxIntervalArgument = 5U; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) - maxInterval:@(maxIntervalArgument)]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) + maxInterval:@(maxIntervalArgument)]; params.filterByFabric = true; params.replaceExistingSubscriptions = true; [cluster subscribeAttributeOnOffWithParams:params @@ -102135,8 +104809,9 @@ class TestSubscribe_OnOff : public TestCommandBridge { CHIP_ERROR TestTurnOnTheLightToSeeAttributeChange_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster onWithCompletion:^(NSError * _Nullable err) { @@ -102152,8 +104827,9 @@ class TestSubscribe_OnOff : public TestCommandBridge { CHIP_ERROR TestCheckForAttributeReport_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_TestSubscribe_OnOff_OnOff_Reported = ^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -102174,8 +104850,9 @@ class TestSubscribe_OnOff : public TestCommandBridge { CHIP_ERROR TestTurnOffTheLightToSeeAttributeChange_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster offWithCompletion:^(NSError * _Nullable err) { @@ -102191,8 +104868,9 @@ class TestSubscribe_OnOff : public TestCommandBridge { CHIP_ERROR TestCheckForAttributeReport_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOnOff * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOnOff alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_TestSubscribe_OnOff_OnOff_Reported = ^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -102425,6 +105103,7 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -102433,9 +105112,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestGetOurfabricIndex_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterOperationalCredentials * cluster = - [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterOperationalCredentials alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeCurrentFabricIndexWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -102457,9 +105138,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestReportSubscribeWindowStatusAttribute_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_TestSubscribe_AdministratorCommissioning_WindowStatus_Reported @@ -102482,15 +105165,17 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestSubscribeWindowStatusAttribute_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); uint16_t minIntervalArgument = 2U; uint16_t maxIntervalArgument = 50U; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) - maxInterval:@(maxIntervalArgument)]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) + maxInterval:@(maxIntervalArgument)]; params.filterByFabric = true; params.replaceExistingSubscriptions = true; [cluster subscribeAttributeWindowStatusWithParams:params @@ -102515,9 +105200,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestOpenTheCommissioningWindow1_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAdministratorCommissioningClusterOpenBasicCommissioningWindowParams alloc] init]; @@ -102536,9 +105223,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestCheckForFirstAttributeReportForWindowStatus_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_TestSubscribe_AdministratorCommissioning_WindowStatus_Reported @@ -102560,9 +105249,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestCloseTheCommissioningWindow1_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster revokeCommissioningWithCompletion:^(NSError * _Nullable err) { @@ -102578,9 +105269,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestCheckForSecondAttributeReportForWindowStatus_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_TestSubscribe_AdministratorCommissioning_WindowStatus_Reported @@ -102604,9 +105297,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestReportSubscribeAdminVendorIdAttribute_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_TestSubscribe_AdministratorCommissioning_AdminVendorId_Reported @@ -102629,15 +105324,17 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestSubscribeAdminVendorIdAttribute_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); uint16_t minIntervalArgument = 2U; uint16_t maxIntervalArgument = 50U; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) - maxInterval:@(maxIntervalArgument)]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) + maxInterval:@(maxIntervalArgument)]; params.filterByFabric = true; params.replaceExistingSubscriptions = true; [cluster subscribeAttributeAdminVendorIdWithParams:params @@ -102662,9 +105359,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestOpenTheCommissioningWindow2_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAdministratorCommissioningClusterOpenBasicCommissioningWindowParams alloc] init]; @@ -102683,9 +105382,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestCheckForFirstAttributeReportForAdminVendorId_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_TestSubscribe_AdministratorCommissioning_AdminVendorId_Reported = ^( @@ -102708,9 +105409,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestCloseTheCommissioningWindow2_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster revokeCommissioningWithCompletion:^(NSError * _Nullable err) { @@ -102726,9 +105429,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestCheckForSecondAttributeReportForAdminVendorId_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_TestSubscribe_AdministratorCommissioning_AdminVendorId_Reported @@ -102752,9 +105457,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestReportSubscribeAdminFabricIndexAttribute_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_TestSubscribe_AdministratorCommissioning_AdminFabricIndex_Reported @@ -102777,15 +105484,17 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestSubscribeAdminFabricIndexAttribute_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); uint16_t minIntervalArgument = 2U; uint16_t maxIntervalArgument = 50U; - MTRSubscribeParams * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) - maxInterval:@(maxIntervalArgument)]; + __auto_type * params = [[MTRSubscribeParams alloc] initWithMinInterval:@(minIntervalArgument) + maxInterval:@(maxIntervalArgument)]; params.filterByFabric = true; params.replaceExistingSubscriptions = true; [cluster subscribeAttributeAdminFabricIndexWithParams:params @@ -102810,9 +105519,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestOpenTheCommissioningWindow3_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRAdministratorCommissioningClusterOpenBasicCommissioningWindowParams alloc] init]; @@ -102831,9 +105542,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestCheckForFirstAttributeReportForAdminFabricIndex_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_TestSubscribe_AdministratorCommissioning_AdminFabricIndex_Reported @@ -102860,9 +105573,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestCloseTheCommissioningWindow2_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster revokeCommissioningWithCompletion:^(NSError * _Nullable err) { @@ -102878,9 +105593,11 @@ class TestSubscribe_AdministratorCommissioning : public TestCommandBridge { CHIP_ERROR TestCheckForSecondAttributeReportForAdminFabricIndex_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterAdministratorCommissioning * cluster = - [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device endpointID:@(0) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterAdministratorCommissioning alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); test_TestSubscribe_AdministratorCommissioning_AdminFabricIndex_Reported @@ -103840,6 +106557,7 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -103847,10 +106565,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadAvailableUserSlotAndVerifyResponseFields_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -103920,10 +106637,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestGetNumberOfSupportedUsersAndVerifyDefaultValue_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNumberOfTotalUsersSupportedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -103947,10 +106663,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadFailsForUserWithIndex0_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -103971,10 +106686,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadFailsForUserWithIndexGreaterThanNumberOfUsersSupported_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -103995,10 +106709,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewUserWithDefaultParameters_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -104023,10 +106736,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheUserBackAndVerifyItsFields_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -104101,10 +106813,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestSetUserAtTheOccupiedIndexFailsWithAppropriateResponse_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -104131,10 +106842,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestModifyUserNameForExistingUser_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -104159,10 +106869,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheModifiedUserBackAndVerifyItsFields_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -104237,10 +106946,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestModifyUserUniqueIdForExistingUser_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -104265,10 +106973,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheModifiedUserBackAndVerifyItsFields_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -104344,10 +107051,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestModifyUserStatusForExistingUser_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -104372,10 +107078,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheModifiedUserBackAndVerifyItsFields_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -104451,10 +107156,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestModifyUserTypeForExistingUser_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -104479,10 +107183,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheModifiedUserBackAndVerifyItsFields_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -104558,10 +107261,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestModifyCredentialRuleForExistingUser_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -104586,10 +107288,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheModifiedUserBackAndVerifyItsFields_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -104665,10 +107366,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestModifyAllFieldsForExistingUser_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -104693,10 +107393,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheModifiedUserBackAndVerifyItsFields_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -104772,10 +107471,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestAddAnotherUserWithNonDefaultFields_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -104800,10 +107498,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheNewUserBackAndVerifyItsFields_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -104879,10 +107576,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestTryToAddAUserWithUserStatus0_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -104909,10 +107605,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestMakeSureTheUserDidNotGetCreated_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -104981,10 +107676,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestTryToAddAUserWithUserStatus2_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -105011,10 +107705,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestMakeSureTheUserDidNotGetCreated_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -105083,10 +107776,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestTryToAddAUserWithUserStatus3_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -105111,10 +107803,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheNewThirdUserBackAndVerifyItsFields_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -105190,10 +107881,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateUserInTheLastSlot_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -105218,10 +107908,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheLastUserBackAndVerifyItsFields_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -105296,10 +107985,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestUserCreationInThe0SlotFails_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -105326,10 +108014,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestUserCreationInTheOutOfBoundsSlotFails_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -105356,10 +108043,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestClearFirstUser_32() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -105378,10 +108064,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadClearedUserAndVerifyItIsAvailable_33() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -105451,10 +108136,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewUserInTheClearedSlot_34() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -105479,10 +108163,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheUserInThePreviouslyClearedSlotAndVerifyItsFields_35() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -105558,10 +108241,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestClearUserWithIndex0Fails_36() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -105583,10 +108265,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestClearUserWithOutOfBoundsIndexFails_37() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -105608,10 +108289,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestClearAllUsers_38() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -105630,10 +108310,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadFirstClearedUserAndVerifyItIsAvailable_39() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -105702,10 +108381,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadLastClearedUserAndVerifyItIsAvailable_40() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -105775,10 +108453,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestGetNumberOfSupportedPinCredentialsAndVerifyDefaultValue_41() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNumberOfPINUsersSupportedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -105802,10 +108479,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCheckThatPinCredentialDoesNotExist_42() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -105853,10 +108529,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadingPinCredentialWithIndex0ReturnsNoCredential_43() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -105904,10 +108579,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadingPinCredentialWithOutOfBoundsIndexReturnsNoCredential_44() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -105957,10 +108631,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestVerifyThatAUserWithUserStatus0CannotBeAddedViaSetCredential_45() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -106004,10 +108677,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestVerifyThatAUserWithUserStatus2CannotBeAddedViaSetCredential_46() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -106051,10 +108723,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewPinCredentialAndUser_47() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -106099,10 +108770,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedUser_48() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -106182,10 +108852,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedPinCredential_49() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -106236,10 +108905,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewPinCredentialAndUserWithIndex0Fails_50() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -106283,10 +108951,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewPinCredentialAndUserWithOutOfBoundsIndexFails_51() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -106331,10 +108998,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestGetNumberOfSupportedRfidCredentialsAndVerifyDefaultValue_52() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNumberOfRFIDUsersSupportedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -106358,10 +109024,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadingRfidCredentialWithIndex0ReturnsNoCredentialDuplicateWithBugWorkaround_53() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -106406,10 +109071,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadingRfidCredentialWithOutOfBoundsIndexReturnsNoCredential_54() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -106459,10 +109123,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCheckThatRfidCredentialDoesNotExist_55() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -106510,10 +109173,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewRfidCredentialAndAddItToExistingUser_56() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -106557,10 +109219,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestVerifyModifiedUser_57() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -106644,10 +109305,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedCredential_58() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -106698,10 +109358,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewRfidCredentialAndUserWithIndex0Fails_59() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -106745,10 +109404,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewRfidCredentialAndUserWithOutOfBoundsIndexFails_60() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -106792,10 +109450,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewCredentialAndTryToAddItTo0User_61() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -106839,10 +109496,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewCredentialAndTryToAddItToOutOfBoundsUser_62() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -106886,10 +109542,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewPinWithTooShortData_63() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -106933,10 +109588,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewPinWithTooLongData_64() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -106980,10 +109634,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewRfidWithTooShortData_65() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -107027,10 +109680,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewPinWithProgrammingUserTypeFails_66() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -107074,10 +109726,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewRfidWithTooShortData_67() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -107121,10 +109772,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewPinCredentialWithDataTheWouldCauseDuplicate_68() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -107168,10 +109818,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewRfidCredentialWithDataTheWouldCauseDuplicate_69() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -107215,10 +109864,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestModifyCredentialDataOfExistingPinCredential_70() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -107262,10 +109910,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestVerifyThatCredentialWasChangedByCreatingNewCredentialWithOldData_71() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -107310,10 +109957,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestVerifyThatCredentialWasChangedByCreatingNewCredentialWithNewData_72() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -107357,10 +110003,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewRfidCredentialAndAddItToExistingUser_73() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -107404,10 +110049,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestVerifyModifiedUser_74() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -107496,10 +110140,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewRfidCredentialAndAddItToExistingUser_75() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -107543,10 +110186,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestVerifyModifiedUser_76() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -107639,10 +110281,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestClearFirstPinCredential_77() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -107664,10 +110305,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadBackTheCredentialAndMakeSureItIsDeleted_78() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -107716,10 +110356,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheUserBackAndMakeSurePinCredentialIsDeleted_79() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -107808,10 +110447,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestClearTheSecondPinCredential_80() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -107833,10 +110471,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadBackTheCredentialAndMakeSureItIsDeleted_81() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -107885,10 +110522,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheUserBackAndMakeSureRelatedUserIsDeleted_82() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -107957,10 +110593,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewRfidCredentialWithUser_83() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -108005,10 +110640,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestClearAllTheRfidCredentials_84() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -108030,10 +110664,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadBackTheFistRfidCredentialAndMakeSureItIsDeleted_85() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -108082,10 +110715,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadBackTheSecondRfidCredentialAndMakeSureItIsDeleted_86() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -108134,10 +110766,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadBackTheThirdRfidCredentialAndMakeSureItIsDeleted_87() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -108186,10 +110817,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheUserRelatedWithFirstRfidBackAndMakeSureItHasOnlyPinCredential_88() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -108270,10 +110900,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheUserRelatedWithSecondRfidBackAndMakeSureItIsDeleted_89() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -108342,10 +110971,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewPinCredentialWithUser_90() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -108390,10 +111018,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewRfidCredentialWithUser_91() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -108438,10 +111065,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateAnotherRfidCredentialWithUser_92() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -108486,10 +111112,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestClearAllTheCredentials_93() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -108508,10 +111133,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadBackTheFirstPinCredentialAndMakeSureItIsDeleted_94() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -108559,10 +111183,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadBackTheFirstRfidCredentialAndMakeSureItIsDeleted_95() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -108610,10 +111233,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadBackTheSecondPinCredentialAndMakeSureItIsDeleted_96() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -108661,10 +111283,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheUserRelatedWithFirstPinBackAndMakeSureItIsDeleted_97() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -108733,10 +111354,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheUserRelatedWithFirstRfidBackAndMakeSureItIsDeleted_98() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -108805,10 +111425,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheUserRelatedWithSecondPinBackAndMakeSureItIsDeleted_99() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -108877,10 +111496,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestReadTheUserRelatedWithLastRfidBackAndMakeSureItIsDeleted_100() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -108949,10 +111567,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewProgrammingPinCredentialWithInvalidIndex_101() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -108995,10 +111612,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewProgrammingPinCredentialWithValidIndex_102() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -109042,10 +111658,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedUser_103() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -109125,10 +111740,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedProgrammingPinCredential_104() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -109179,10 +111793,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestModifyTheProgrammingPinCredential_105() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -109225,10 +111838,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestClearingProgrammingPinFails_106() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -109253,10 +111865,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestClearingProgrammingPinWithInvalidIndexFails_107() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -109281,10 +111892,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestClearingPinCredentialWithZeroIndexFails_108() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -109309,10 +111919,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestClearingPinCredentialWithOutOfBoundIndexFails_109() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -109338,10 +111947,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestClearingRfidCredentialWithZeroIndexFails_110() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -109366,10 +111974,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestClearingRfidCredentialWithOutOfBoundIndexFails_111() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -109395,10 +112002,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestClearTheProgrammingPinUser_112() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -109417,10 +112023,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestMakeSureProgrammingPinUserIsDeleted_113() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -109489,10 +112094,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestMakeSureProgrammingPinCredentialIsDeleted_114() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -109540,10 +112144,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateNewPinCredentialAndUser_115() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -109588,10 +112191,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateSecondPinCredentialAndAddItToExistingUser_116() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -109635,10 +112237,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateThirdPinCredentialAndAddItToExistingUser_117() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -109682,10 +112283,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateFourthPinCredentialAndAddItToExistingUser_118() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -109729,10 +112329,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestCreateFifthPinCredentialAndAddItToExistingUser_119() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -109776,10 +112375,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestTryToCreateSixthPinCredentialAndMakeSureItFails_120() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -109823,10 +112421,9 @@ class DL_UsersAndCredentials : public TestCommandBridge { CHIP_ERROR TestFinalCleanUp_121() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -110183,6 +112780,7 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -110190,10 +112788,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestTryToUnlockTheDoorWithoutPin_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -110211,10 +112808,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestVerifyThatLockStateAttributeValueIsSetToUnlocked_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLockStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -110236,10 +112832,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestTryToLockTheDoorWithoutAPin_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterLockDoorParams alloc] init]; @@ -110257,10 +112852,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestVerifyThatLockStateAttributeValueIsSetToLocked_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLockStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -110282,10 +112876,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestCreateNewPinCredentialAndLockUnlockUser_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -110330,10 +112923,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestSetTheWrongCodeEntryLimitToBigValueSoThatWeCanTestIncorrectPinEntry_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id wrongCodeEntryLimitArgument; @@ -110354,10 +112946,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestTryToUnlockTheDoorWithInvalidPin_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -110379,10 +112970,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestVerifyThatLockStateAttributeValueIsSetToLocked_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLockStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -110404,10 +112994,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestTryToUnlockTheDoorWithValidPin_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -110426,10 +113015,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestVerifyThatLockStateAttributeValueIsSetToUnlocked_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLockStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -110451,10 +113039,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestTryToLockTheDoorWithInvalidPin_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterLockDoorParams alloc] init]; @@ -110476,10 +113063,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestVerifyThatLockStateAttributeValueIsSetToUnlocked_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLockStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -110501,10 +113087,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestTryToLockTheDoorWithValidPin_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterLockDoorParams alloc] init]; @@ -110523,10 +113108,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestVerifyThatLockStateAttributeValueIsSetToLocked_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLockStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -110548,10 +113132,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestSetOperatingModeToNoRemoteLockUnlock_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id operatingModeArgument; @@ -110570,10 +113153,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestTryToUnlockTheDoorWhenOperatingModeIsNoRemoteLockUnlock_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -110594,10 +113176,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestSetOperatingModeToNormal_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id operatingModeArgument; @@ -110616,10 +113197,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestReadTheLockoutTimeout_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeUserCodeTemporaryDisableTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -110640,10 +113220,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestSetTheWrongCodeEntryLimitToSmallValueSoWeCanTestLockout_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id wrongCodeEntryLimitArgument; @@ -110665,10 +113244,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestTryToUnlockTheDoorWithInvalidPinForTheFirstTime_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -110690,10 +113268,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestTryToUnlockTheDoorWithInvalidPinForTheSecondTime_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -110715,10 +113292,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestTryToUnlockTheDoorWithInvalidPinForTheThirdTime_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -110740,10 +113316,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestTryToUnlockTheDoorWithValidPinAndMakeSureItFailsDueToLockout_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -110765,6 +113340,7 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestWaitForTheLockoutToEnd_24() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 10000UL; return WaitForMs("alpha", value); @@ -110772,10 +113348,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestTryToUnlockTheDoorWithValidPinAndMakeSureItSucceeds_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -110794,10 +113369,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestVerifyThatLockStateAttributeValueIsSetToUnlocked_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLockStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -110819,10 +113393,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestLockTheDoorBackPriorToNextTests_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterLockDoorParams alloc] init]; @@ -110841,10 +113414,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestCreateADisabledUserAndCredential_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -110889,10 +113461,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestTryToUnlockTheDoorWithDisabledUserPin_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -110914,10 +113485,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestVerifyThatLockStateAttributeValueIsSetToLocked_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLockStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -110939,10 +113509,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestUnlockTheDoorWithEnabledUserPin_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -110961,10 +113530,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestVerifyThatLockStateAttributeValueIsSetToUnlocked_32() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLockStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -110986,10 +113554,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestTryToLockTheDoorWithDisabledUserPin_33() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterLockDoorParams alloc] init]; @@ -111011,10 +113578,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestVerifyThatLockStateAttributeValueStaysUnlocked_34() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLockStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -111036,10 +113602,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestLockTheDoorWithEnabledUserPin_35() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterLockDoorParams alloc] init]; @@ -111058,10 +113623,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestVerifyThatLockStateAttributeValueIsSetToLocked_36() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLockStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -111083,10 +113647,9 @@ class DL_LockUnlock : public TestCommandBridge { CHIP_ERROR TestCleanAllTheUsersAndCredentials_37() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -111688,46 +114251,46 @@ class DL_Schedules : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 6: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 7: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 8: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 9: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 10: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_FAILURE)); break; case 11: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 12: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 13: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 14: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 15: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 16: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 17: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 18: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 19: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 20: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -111748,16 +114311,16 @@ class DL_Schedules : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 26: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 27: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 28: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 29: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 30: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_FAILURE)); @@ -111784,16 +114347,16 @@ class DL_Schedules : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 38: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 39: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 40: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 41: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 42: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -111823,16 +114386,16 @@ class DL_Schedules : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 51: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 52: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 53: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 54: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 55: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_FAILURE)); @@ -111847,16 +114410,16 @@ class DL_Schedules : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 59: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 60: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 61: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 62: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 63: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_FAILURE)); @@ -111871,10 +114434,10 @@ class DL_Schedules : public TestCommandBridge { VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; case 67: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 68: - VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_FIELD)); + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); break; case 69: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); @@ -112072,6 +114635,7 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -112079,10 +114643,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateNewPinCredentialAndScheduleUser_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -112128,10 +114691,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetNumberOfSupportedUsers_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNumberOfTotalUsersSupportedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -112156,10 +114718,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetMaxNumberOfWeekDaySchedulesForUserAndVerifyDefaultValue_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNumberOfWeekDaySchedulesSupportedPerUserWithCompletion:^( @@ -112185,10 +114746,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetMaxNumberOfYearDaySchedulesForUserAndVerifyDefaultValue_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNumberOfYearDaySchedulesSupportedPerUserWithCompletion:^( @@ -112214,10 +114774,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetMaxNumberOfHolidaySchedulesAndVerifyDefaultValue_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster @@ -112242,10 +114801,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleWith0Index_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -112264,7 +114822,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112273,10 +114831,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleWithOutOfBoundsIndex_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -112295,7 +114852,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112304,10 +114861,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleWith0UserIndex_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -112326,7 +114882,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112335,10 +114891,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleWithOutOfBoundsUserIndex_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -112357,7 +114912,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112366,10 +114921,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleForNonExistingUser_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -112397,10 +114951,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleWith0DaysMask_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -112419,7 +114972,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112428,10 +114981,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleForSundayAndMonday_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -112450,7 +115002,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112459,10 +115011,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleForSundayWednesdayAndSaturday_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -112481,7 +115032,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112490,10 +115041,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleWithInvalidStartHour_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -112512,7 +115062,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112521,10 +115071,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleWithInvalidStartMinute_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -112543,7 +115092,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112552,10 +115101,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleWithInvalidEndHour_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -112574,7 +115122,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112583,10 +115131,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleWithInvalidEndMinute_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -112605,7 +115152,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112614,10 +115161,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleWithStartHourLaterThatEndHour_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -112636,7 +115182,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112645,10 +115191,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleWithStartMinuteLaterThatEndMinuteWhenHoursAreEqual_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -112669,7 +115214,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112678,10 +115223,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatPreviousOperationsDidNotCreateASchedule_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -112717,10 +115261,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetWeekDayScheduleWith0Index_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -112756,10 +115299,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetWeekDayScheduleWithOutOfBoundsIndex_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -112796,10 +115338,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetWeekDayScheduleWith0UserIndex_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -112835,10 +115376,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetWeekDayScheduleWithOutOfBoundsUserIndex_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -112875,10 +115415,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetWeekDayScheduleWithNonExistingUserIndex_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -112914,10 +115453,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateYearDayScheduleWith0Index_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetYearDayScheduleParams alloc] init]; @@ -112933,7 +115471,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112942,10 +115480,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateYearDayScheduleWithOutOfBoundsIndex_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetYearDayScheduleParams alloc] init]; @@ -112961,7 +115498,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112970,10 +115507,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateYearDayScheduleWith0UserIndex_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetYearDayScheduleParams alloc] init]; @@ -112989,7 +115525,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -112998,10 +115534,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateYearDayScheduleWithOutOfBoundsUserIndex_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetYearDayScheduleParams alloc] init]; @@ -113017,7 +115552,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -113026,10 +115561,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateYearDayScheduleForNonExistingUser_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetYearDayScheduleParams alloc] init]; @@ -113054,10 +115588,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateYearDayScheduleWithStartHourLaterThatEndHour_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetYearDayScheduleParams alloc] init]; @@ -113082,10 +115615,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatPreviousOperationsDidNotCreateASchedule_32() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -113121,10 +115653,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetYearDayScheduleWith0Index_33() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -113160,10 +115691,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetYearDayScheduleWithOutOfBoundsIndex_34() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -113200,10 +115730,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetYearDayScheduleWith0UserIndex_35() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -113239,10 +115768,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetYearDayScheduleWithOutOfBoundsUserIndex_36() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -113279,10 +115807,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetYearDayScheduleWithNonExistingUserIndex_37() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -113318,10 +115845,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateHolidayScheduleWith0Index_38() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetHolidayScheduleParams alloc] init]; @@ -113337,7 +115863,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -113346,10 +115872,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateHolidayScheduleWithOutOfBoundsIndex_39() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetHolidayScheduleParams alloc] init]; @@ -113365,7 +115890,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -113374,10 +115899,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateHolidayScheduleWithStartHourLaterThatEndHour_40() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetHolidayScheduleParams alloc] init]; @@ -113393,7 +115917,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -113402,10 +115926,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateHolidayScheduleWithInvalidOperatingMode_41() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetHolidayScheduleParams alloc] init]; @@ -113421,7 +115944,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -113430,10 +115953,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatPreviousOperationsDidNotCreateASchedule_42() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -113463,10 +115985,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetHolidayScheduleWith0Index_43() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -113496,10 +116017,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestGetHolidayScheduleWithOutOfBoundsIndex_44() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -113530,10 +116050,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateHolidayScheduleWithValidParameters_45() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetHolidayScheduleParams alloc] init]; @@ -113555,10 +116074,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedSchedule_46() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -113603,10 +116121,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleWithValidParameters_47() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -113631,10 +116148,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedSchedule_48() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -113695,10 +116211,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateYearDayScheduleWithValidParameters_49() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetYearDayScheduleParams alloc] init]; @@ -113720,10 +116235,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedSchedule_50() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -113769,10 +116283,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearWeekDayScheduleWith0Index_51() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearWeekDayScheduleParams alloc] init]; @@ -113787,7 +116300,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -113796,10 +116309,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearWeekDayScheduleWithOutOfBoundsIndex_52() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearWeekDayScheduleParams alloc] init]; @@ -113814,7 +116326,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -113823,10 +116335,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearWeekDayScheduleWith0UserIndex_53() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearWeekDayScheduleParams alloc] init]; @@ -113841,7 +116352,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -113850,10 +116361,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearWeekDayScheduleWithOutOfBoundsUserIndex_54() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearWeekDayScheduleParams alloc] init]; @@ -113868,7 +116378,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -113877,10 +116387,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearWeekDayScheduleWithNonExistingUser_55() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearWeekDayScheduleParams alloc] init]; @@ -113904,10 +116413,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatWeekDayScheduleWasNotDeleted_56() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -113968,10 +116476,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatYearDayScheduleWasNotDeleted_57() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -114017,10 +116524,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatHolidayScheduleWasNotDeleted_58() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -114065,10 +116571,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearYearDayScheduleWith0Index_59() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearYearDayScheduleParams alloc] init]; @@ -114083,7 +116588,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -114092,10 +116597,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearYearDayScheduleWithOutOfBoundsIndex_60() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearYearDayScheduleParams alloc] init]; @@ -114110,7 +116614,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -114119,10 +116623,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearYearDayScheduleWith0UserIndex_61() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearYearDayScheduleParams alloc] init]; @@ -114137,7 +116640,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -114146,10 +116649,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearYearDayScheduleWithOutOfBoundsUserIndex_62() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearYearDayScheduleParams alloc] init]; @@ -114164,7 +116666,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -114173,10 +116675,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearYearDayScheduleWithNonExistingUser_63() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearYearDayScheduleParams alloc] init]; @@ -114200,10 +116701,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatWeekDayScheduleWasNotDeleted_64() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -114264,10 +116764,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatYearDayScheduleWasNotDeleted_65() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -114313,10 +116812,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatHolidayScheduleWasNotDeleted_66() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -114361,10 +116859,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearHolidayScheduleWith0Index_67() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearHolidayScheduleParams alloc] init]; @@ -114378,7 +116875,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -114387,10 +116884,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearHolidayScheduleWithOutOfBoundsIndex_68() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearHolidayScheduleParams alloc] init]; @@ -114404,7 +116900,7 @@ class DL_Schedules : public TestCommandBridge { err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code : EMBER_ZCL_STATUS_FAILURE) : 0, - EMBER_ZCL_STATUS_INVALID_FIELD)); + EMBER_ZCL_STATUS_INVALID_COMMAND)); NextTest(); }]; @@ -114413,10 +116909,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatWeekDayScheduleWasNotDeleted_69() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -114477,10 +116972,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatYearDayScheduleWasNotDeleted_70() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -114526,10 +117020,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatHolidayScheduleWasNotDeleted_71() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -114574,10 +117067,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateAnotherWeekDayScheduleWithValidParameters_72() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -114602,10 +117094,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedWeekDaySchedule_73() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -114666,10 +117157,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateAnotherYearDayScheduleWithValidParameters_74() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetYearDayScheduleParams alloc] init]; @@ -114691,10 +117181,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedYearDaySchedule_75() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -114740,10 +117229,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateAnotherHolidayScheduleWithValidParameters_76() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetHolidayScheduleParams alloc] init]; @@ -114765,10 +117253,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedHolidaySchedule_77() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -114813,10 +117300,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearASingleWeekDayScheduleForTheFirstUser_78() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearWeekDayScheduleParams alloc] init]; @@ -114836,10 +117322,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyClearedWeekDaySchedule_79() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -114875,10 +117360,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearAllRemainingWeekDaySchedulesForTheFirstUser_80() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearWeekDayScheduleParams alloc] init]; @@ -114898,10 +117382,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyClearedWeekSchedule_81() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -114937,10 +117420,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatFirstYearDayScheduleWasNotDeleted_82() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -114986,10 +117468,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatSecondYearDayScheduleWasNotDeleted_83() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -115035,10 +117516,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatFirstHolidayScheduleWasNotDeleted_84() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -115083,10 +117563,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatSecondHolidayScheduleWasNotDeleted_85() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -115131,10 +117610,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateAnotherWeekDayScheduleWithValidParameters_86() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -115159,10 +117637,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearASingleYearDayScheduleForTheFirstUser_87() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearYearDayScheduleParams alloc] init]; @@ -115182,10 +117659,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyClearedYearDaySchedule_88() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -115221,10 +117697,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearAllRemainingYearSchedulesForTheFirstUser_89() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearYearDayScheduleParams alloc] init]; @@ -115244,10 +117719,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyThatSecondYearDayScheduleWasCleared_90() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -115283,10 +117757,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedWeekDaySchedule_91() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -115347,10 +117820,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearAllRemainingWeekDaySchedulesForTheFirstUser_92() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearWeekDayScheduleParams alloc] init]; @@ -115370,10 +117842,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateNewUserWithoutCredentialSoWeCanAddMoreSchedulesToIt_93() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -115398,10 +117869,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleWithValidParametersForFirstUser_94() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -115426,10 +117896,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedWeekDayScheduleForFirstUser_95() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -115490,10 +117959,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateYearDayScheduleForFirstUser_96() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetYearDayScheduleParams alloc] init]; @@ -115515,10 +117983,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedYearDayScheduleForFirst_97() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -115564,10 +118031,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleWithValidParametersForSecondUser_98() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -115592,10 +118058,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedWeekDayScheduleForFirstUser_99() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -115656,10 +118121,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateYearDayScheduleForSecondUser_100() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetYearDayScheduleParams alloc] init]; @@ -115681,10 +118145,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedYearDayScheduleForFirst_101() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -115730,10 +118193,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCleanupTheUser_102() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -115752,10 +118214,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureClearingFirstUserAlsoClearedWeekDaySchedules_103() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -115791,10 +118252,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureClearingFirstUserAlsoClearedYearDaySchedules_104() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -115830,10 +118290,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureClearingSecondUserAlsoClearedWeekDaySchedules_105() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -115869,10 +118328,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureClearingSecondUserAlsoClearedYearDaySchedules_106() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -115908,10 +118366,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatFirstHolidayScheduleWasNotDeleted_107() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -115956,10 +118413,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatSecondHolidayScheduleWasNotDeleted_108() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -116004,10 +118460,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateAnotherHolidayScheduleAtTheLastSlot_109() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetHolidayScheduleParams alloc] init]; @@ -116029,10 +118484,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedHolidaySchedule_110() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -116078,10 +118532,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateNewPinCredentialAndScheduleUser_111() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -116126,10 +118579,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateWeekDayScheduleForFirstUser_112() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; @@ -116154,10 +118606,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestCreateYearDayScheduleForFirstUser_113() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetYearDayScheduleParams alloc] init]; @@ -116179,10 +118630,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearASingleHolidaySchedule_114() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearHolidayScheduleParams alloc] init]; @@ -116201,10 +118651,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatFirstHolidayScheduleWasNotDeleted_115() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -116249,10 +118698,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatSecondHolidayScheduleWasDeleted_116() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -116282,10 +118730,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatThirdHolidayScheduleWasNotDeleted_117() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -116331,10 +118778,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureClearingHolidayScheduleDidNotClearWeekDaySchedule_118() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -116395,10 +118841,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureClearingHolidayScheduleDidNotClearYearDaySchedule_119() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -116444,10 +118889,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestClearAllRemainingHolidaySchedules_120() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearHolidayScheduleParams alloc] init]; @@ -116466,10 +118910,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatFirstHolidayIsStillDeleted_121() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -116499,10 +118942,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatSecondHolidayScheduleWasDeleted_122() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -116532,10 +118974,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureThatThirdHolidayScheduleWasNotDeleted_123() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; @@ -116566,10 +119007,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureClearingHolidayScheduleDidNotClearWeekDaySchedule_124() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; @@ -116630,10 +119070,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestMakeSureClearingHolidayScheduleDidNotClearYearDaySchedule_125() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -116679,10 +119118,9 @@ class DL_Schedules : public TestCommandBridge { CHIP_ERROR TestFinalCleanup_126() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -117245,6 +119683,7 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -117252,10 +119691,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -117277,10 +119715,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -117302,10 +119739,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDrlksf00pinEnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -117322,10 +119758,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDrlksf01ridEnsureFeaturemapHasTheCorrectBitSet_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -117342,10 +119777,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDrlksf02fgpEnsureFeaturemapHasTheCorrectBitSet_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -117362,10 +119796,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDrlksf04wdschEnsureFeaturemapHasTheCorrectBitSet_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -117382,10 +119815,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDrlksf05dpsEnsureFeaturemapHasTheCorrectBitSet_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -117402,10 +119834,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDrlksf06faceEnsureFeaturemapHasTheCorrectBitSet_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -117422,10 +119853,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDrlksf07cotaEnsureFeaturemapHasTheCorrectBitSet_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -117442,10 +119872,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDrlksf08usrEnsureFeaturemapHasTheCorrectBitSet_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -117462,10 +119891,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDRLKSF0aYDSCHEnsureFeaturemapHasTheCorrectBitSet_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -117482,10 +119910,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenDRLKSF0bHDSCHEnsureFeaturemapHasTheCorrectBitSet_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -117502,10 +119929,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAttributeListFromDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117533,10 +119959,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentDRLKSF05AttributesInAttributeList_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117555,10 +119980,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentDRLKSF08AttributesInAttributeList_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117579,10 +120003,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentDRLKSF00AttributesInAttributeList_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117603,10 +120026,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentDRLKSF01AttributesInAttributeList_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117627,10 +120049,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentDRLKSF04AttributeInAttributeList_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117649,10 +120070,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentDRLKSF0aAttributeInAttributeList_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117671,10 +120091,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentDRLKSF0bAttributeInAttributeList_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117693,10 +120112,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentDRLKSF00OrDrlksf01AttributesInAttributeList_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117716,10 +120134,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentDRLKSF07OrDrlksf00AttributeInAttributeList_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117738,10 +120155,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeLanguageInAttributeList_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117760,10 +120176,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeLEDSettingsInAttributeList_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117782,10 +120197,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeAutoRelockTimeInAttributeList_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117804,10 +120218,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeSoundVolumeInAttributeList_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117826,10 +120239,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeDefaultConfigurationRegisterInAttributeList_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117848,10 +120260,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeEnableLocalProgrammingInAttributeList_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117870,10 +120281,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeEnableOneTouchLockingInAttributeList_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117892,10 +120302,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeEnableInsideStatusLEDInAttributeList_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117914,10 +120323,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeEnablePrivacyModeButtonInAttributeList_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117936,10 +120344,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalAttributeLocalProgrammingFeaturesInAttributeList_32() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117958,10 +120365,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAcceptedCommandListFromDut_33() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -117981,10 +120387,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentCommandsDRLKSF04InAcceptedCommandList_34() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -118005,10 +120410,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentCommandsDRLKSF0aInAcceptedCommandList_35() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -118029,10 +120433,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentCommandsDRLKSF0bInAcceptedCommandList_36() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -118053,10 +120456,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentCommandsDRLKSF08InAcceptedCommandList_37() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -118080,10 +120482,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsOptionalCommandsDRLKSC03RspInAcceptedCommandList_38() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -118102,10 +120503,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentCommandDRLKSF04InGeneratedCommandList_39() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -118124,10 +120524,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentCommandDRLKSF0aInGeneratedCommandList_40() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -118146,10 +120545,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentCommandDRLKSF0bInGeneratedCommandList_41() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -118168,10 +120566,9 @@ class Test_TC_DRLK_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsFeatureDependentCommandDRLKSF08InGeneratedCommandList_42() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -118555,6 +120952,7 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -118562,10 +120960,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestCreateNewUser_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -118590,10 +120987,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestReadTheUserBackAndVerifyItsFields_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -118669,10 +121065,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestCreateNewPinCredentialAndLockUnlockUser_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -118716,10 +121111,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedPinCredential_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -118770,10 +121164,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThWritesTheRequirePINforRemoteOperationAttributeValueAsFalseOnTheDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id requirePINforRemoteOperationArgument; @@ -118794,10 +121187,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThWritesTheRequirePINforRemoteOperationAttributeValueAsFalseOnTheDutAndVerifyDutRespondsWithUnsupportedWrite_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id requirePINforRemoteOperationArgument; @@ -118824,10 +121216,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheRequirePINforRemoteOperationAttributeFromTheDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRequirePINforRemoteOperationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -118848,10 +121239,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThSendsLockDoorCommandToTheDutWithoutPINCode_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterLockDoorParams alloc] init]; @@ -118869,10 +121259,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThSendsLockDoorCommandToTheDutWithValidPINCode_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterLockDoorParams alloc] init]; @@ -118891,10 +121280,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThWritesTheRequirePINforRemoteOperationAttributeValueAsFalseOnTheDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id requirePINforRemoteOperationArgument; @@ -118915,10 +121303,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThWritesTheRequirePINforRemoteOperationAttributeValueAsFalseOnTheDutAndVerifyDutRespondsWithUnsupportedWrite_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id requirePINforRemoteOperationArgument; @@ -118945,10 +121332,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheRequirePINforRemoteOperationAttributeFromTheDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRequirePINforRemoteOperationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -118969,10 +121355,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThSendsLockDoorCommandToTheDutWithValidPINCode_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterLockDoorParams alloc] init]; @@ -118991,10 +121376,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThSendsLockDoorCommandToTheDutWithoutValidPINCode_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterLockDoorParams alloc] init]; @@ -119016,10 +121400,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThSendsLockDoorCommandToTheDutWithoutAnyArgumentPINCode_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterLockDoorParams alloc] init]; @@ -119040,10 +121423,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheWrongCodeEntryLimitAttributeFromTheDut_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeWrongCodeEntryLimitWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -119060,6 +121442,7 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThSendsAnUnlockDoorCommandFromTheDutWithInvalidPINCodeRepeatThisStepPIXITDRLKWrongCodeEntryLimitTimesAndVerifyThatDutSendsFailureResponseToTheTh_17() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -119069,6 +121452,7 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThSendsAnUnlockDoorCommandFromUser1ToTheDutWithTheValidPINCodeAndVerifyTheDutResponse_18() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -119079,6 +121463,7 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestWaitForPIXITDRLKUserCodeTemporaryDisableTimeTHThenSendsAnUnlockDoorCommandFromUser1ToTheDutWithTheValidPINCode_19() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -119088,10 +121473,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThWritesWrongCodeEntryLimitAttributeValueAsBetween1And255OnTheDutAndVerifyThatTheDutSendsSuccessResponse_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id wrongCodeEntryLimitArgument; @@ -119112,10 +121496,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThWritesWrongCodeEntryLimitAttributeValueAsBetween1And255OnTheDutAndVerifyDutRespondsWithUnsupportedWrite_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id wrongCodeEntryLimitArgument; @@ -119140,10 +121523,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThReadsTheUserCodeTemporaryDisableTimeAttributeFromTheDut_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeUserCodeTemporaryDisableTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -119160,10 +121542,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThWritesUserCodeTemporaryDisableTimeAttributeValueAsBetween1And255OnTheDutAndVerifyThatTheDutSendsSuccessResponse_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id userCodeTemporaryDisableTimeArgument; @@ -119186,10 +121567,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestThWritesUserCodeTemporaryDisableTimeAttributeValueAsBetween1And255OnTheDutAndVerifyDutRespondsWithUnsupportedWrite_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id userCodeTemporaryDisableTimeArgument; @@ -119215,10 +121595,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestCleanTheCreatedUser_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -119237,10 +121616,9 @@ class Test_TC_DRLK_2_2 : public TestCommandBridge { CHIP_ERROR TestCleanupTheCreatedCredential_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -119721,6 +122099,7 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -119728,10 +122107,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestCreateNewUser_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -119756,10 +122134,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestReadTheUserBackAndVerifyItsFields_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -119835,10 +122212,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestCreateNewPinCredentialAndLockUnlockUser_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -119882,10 +122258,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedPinCredential_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -119936,10 +122311,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThWritesTheRequirePINforRemoteOperationAttributeValueAsFalseOnTheDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id requirePINforRemoteOperationArgument; @@ -119960,10 +122334,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThWritesTheRequirePINforRemoteOperationAttributeValueAsFalseOnTheDutAndVerifyDutRespondsWithUnsupportedWrite_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id requirePINforRemoteOperationArgument; @@ -119990,10 +122363,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThReadsTheRequirePINforRemoteOperationAttributeFromTheDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRequirePINforRemoteOperationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -120014,10 +122386,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTheUnlockDoorCommandToTheDutWithoutPINCode_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -120035,10 +122406,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTheUnlockDoorCommandToTheDutWithValidPINCode_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -120057,10 +122427,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThWritesTheRequirePINforRemoteOperationAttributeValueAsFalseOnTheDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id requirePINforRemoteOperationArgument; @@ -120081,10 +122450,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThWritesTheRequirePINforRemoteOperationAttributeValueAsFalseOnTheDutAndVerifyDutRespondsWithUnsupportedWrite_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id requirePINforRemoteOperationArgument; @@ -120111,10 +122479,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThReadsTheRequirePINforRemoteOperationAttributeFromTheDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeRequirePINforRemoteOperationWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -120135,10 +122502,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTheUnlockDoorCommandToTheDutWithValidPINCode_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -120157,10 +122523,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTheUnlockDoorCommandToTheDutWithInvalidPINCode_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -120182,10 +122547,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTheUnlockDoorCommandToTheDutWithoutPINCode_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -120206,10 +122570,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThWritesWrongCodeEntryLimitAttributeValueAs3OnTheDutAndVerifyThatTheDutSendsSuccessResponse_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id wrongCodeEntryLimitArgument; @@ -120230,10 +122593,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThWritesWrongCodeEntryLimitAttributeValueAs3OnTheDutAndVerifyDutRespondsWithUnsupportedWrite_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id wrongCodeEntryLimitArgument; @@ -120258,10 +122620,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThWritesUserCodeTemporaryDisableTimeAttributeValueAs15SecondsOnTheDutAndVerifyThatTheDutSendsSuccessResponse_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id userCodeTemporaryDisableTimeArgument; @@ -120283,10 +122644,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThWritesUserCodeTemporaryDisableTimeAttributeValueAs15SecondsOnTheDutAndVerifyThatTheDutSendsSuccessResponse_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id userCodeTemporaryDisableTimeArgument; @@ -120312,10 +122672,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTheUnlockDoorCommandToTheDutWithInvalidPINCode_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -120337,10 +122696,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTheUnlockDoorCommandToTheDutWithInvalidPINCode_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -120362,10 +122720,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTheUnlockDoorCommandToTheDutWithInvalidPINCode_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -120387,10 +122744,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTheUnlockDoorCommandToTheDutWithInvalidPINCode_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -120412,10 +122768,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThReadsTheUserCodeTemporaryDisableTimeAttributeFromTheDutAndCheckAttributeIsTriggered_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeUserCodeTemporaryDisableTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -120437,10 +122792,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTheUnlockDoorCommandToTheDutWithValidPINCode_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockDoorParams alloc] init]; @@ -120462,10 +122816,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThWritesAutoRelockTimeAttributeValueAs10SecondsOnTheDut_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id autoRelockTimeArgument; @@ -120486,10 +122839,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThWritesAutoRelockTimeAttributeValueAs60SecondsOnTheDut_27() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id autoRelockTimeArgument; @@ -120510,10 +122862,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThWritesAutoRelockTimeAttributeValueAs10SecondsOnTheDut_28() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id autoRelockTimeArgument; @@ -120538,10 +122889,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThWritesAutoRelockTimeAttributeValueAs60SecondsOnTheDut_29() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id autoRelockTimeArgument; @@ -120566,10 +122916,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThReadsTheAutoRelockTimeAttributeFromTheDut_30() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAutoRelockTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -120590,10 +122939,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThReadsTheAutoRelockTimeAttributeFromTheDut_31() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAutoRelockTimeWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -120614,6 +122962,7 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThSendsTheUnlockDoorCommandToTheDutWithValidPINCodeAndVerifyThatDutSendsSuccessResponseToTheTh_32() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -120623,6 +122972,7 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestThReadsLockStateAttributeAfterAutoRelockTimeExpiresAndVerifyThatTheDutIsLocked_33() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -120632,10 +122982,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestCleanupTheCreatedUser_34() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -120654,10 +123003,9 @@ class Test_TC_DRLK_2_3 : public TestCommandBridge { CHIP_ERROR TestCleanTheCreatedCredential_35() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -120857,6 +123205,7 @@ class Test_TC_DRLK_2_4 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -120864,10 +123213,9 @@ class Test_TC_DRLK_2_4 : public TestCommandBridge { CHIP_ERROR TestCreateNewUser_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -120892,10 +123240,9 @@ class Test_TC_DRLK_2_4 : public TestCommandBridge { CHIP_ERROR TestReadTheUserBackAndVerifyItsFields_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -120971,10 +123318,9 @@ class Test_TC_DRLK_2_4 : public TestCommandBridge { CHIP_ERROR TestCreateNewPinCredentialAndLockUnlockUser_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -121018,10 +123364,9 @@ class Test_TC_DRLK_2_4 : public TestCommandBridge { CHIP_ERROR TestVerifyCreatedPinCredential_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -121072,10 +123417,9 @@ class Test_TC_DRLK_2_4 : public TestCommandBridge { CHIP_ERROR TestThWritesAutoRelockTimeAttributeValueAs60SecondsOnTheDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id autoRelockTimeArgument; @@ -121096,10 +123440,9 @@ class Test_TC_DRLK_2_4 : public TestCommandBridge { CHIP_ERROR TestThWritesAutoRelockTimeAttributeValueAs60SecondsOnTheDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id autoRelockTimeArgument; @@ -121124,10 +123467,9 @@ class Test_TC_DRLK_2_4 : public TestCommandBridge { CHIP_ERROR TestThSendsTheUnlockWithTimeoutArgumentValueAs60Seconds_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterUnlockWithTimeoutParams alloc] init]; @@ -121147,6 +123489,7 @@ class Test_TC_DRLK_2_4 : public TestCommandBridge { CHIP_ERROR TestWait60s_8() { + chip::app::Clusters::DelayCommands::Commands::WaitForMs::Type value; value.ms = 60000UL; return WaitForMs("alpha", value); @@ -121154,10 +123497,9 @@ class Test_TC_DRLK_2_4 : public TestCommandBridge { CHIP_ERROR TestThReadsLockStateAttribute_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeLockStateWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -121179,10 +123521,9 @@ class Test_TC_DRLK_2_4 : public TestCommandBridge { CHIP_ERROR TestCleanupTheCreatedUser_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -121201,10 +123542,9 @@ class Test_TC_DRLK_2_4 : public TestCommandBridge { CHIP_ERROR TestCleanTheCreatedCredential_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -121412,6 +123752,7 @@ class Test_TC_DRLK_2_5 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -121419,10 +123760,9 @@ class Test_TC_DRLK_2_5 : public TestCommandBridge { CHIP_ERROR TestCreateNewUser_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -121447,10 +123787,9 @@ class Test_TC_DRLK_2_5 : public TestCommandBridge { CHIP_ERROR TestReadTheUserBackAndVerifyItsFields_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -121513,64 +123852,553 @@ class Test_TC_DRLK_2_5 : public TestCommandBridge { VerifyOrReturn(CheckValue("lastModifiedFabricIndex", actualValue, 1U)); } - { - id actualValue = values.nextUserIndex; - VerifyOrReturn(CheckValueNull("nextUserIndex", actualValue)); - } + { + id actualValue = values.nextUserIndex; + VerifyOrReturn(CheckValueNull("nextUserIndex", actualValue)); + } + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + NSNumber * _Nonnull NumberOfWeekDaySchedulesSupportedPerUser; + + CHIP_ERROR TestThReadsNumberOfWeekDaySchedulesSupportedPerUserAttribute_3() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeNumberOfWeekDaySchedulesSupportedPerUserWithCompletion:^( + NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads NumberOfWeekDay SchedulesSupportedPerUser attribute Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn( + CheckConstraintMinValue("numberOfWeekDaySchedulesSupportedPerUser", [value unsignedCharValue], 0U)); + VerifyOrReturn( + CheckConstraintMaxValue("numberOfWeekDaySchedulesSupportedPerUser", [value unsignedCharValue], 255U)); + { + NumberOfWeekDaySchedulesSupportedPerUser = value; + } + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + NSNumber * _Nonnull NumberOfTotalUsersSupported; + + CHIP_ERROR TestThReadsNumberOfTotalUsersSupportedAttribute_4() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeNumberOfTotalUsersSupportedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads NumberOfTotalUsers Supported attribute Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintMinValue("numberOfTotalUsersSupported", [value unsignedShortValue], 0U)); + VerifyOrReturn(CheckConstraintMaxValue("numberOfTotalUsersSupported", [value unsignedShortValue], 65534U)); + { + NumberOfTotalUsersSupported = value; + } + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThSendSetWeekDayScheduleCommand_5() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; + params.weekDayIndex = [NSNumber numberWithUnsignedChar:1U]; + params.userIndex = [NSNumber numberWithUnsignedShort:1U]; + params.daysMask = [NSNumber numberWithUnsignedChar:2U]; + params.startHour = [NSNumber numberWithUnsignedChar:15U]; + params.startMinute = [NSNumber numberWithUnsignedChar:45U]; + params.endHour = [NSNumber numberWithUnsignedChar:16U]; + params.endMinute = [NSNumber numberWithUnsignedChar:55U]; + [cluster setWeekDayScheduleWithParams:params + completion:^(NSError * _Nullable err) { + NSLog(@"TH send Set Week Day Schedule Command Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThSendGetWeekDayScheduleCommandToDut_6() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; + params.weekDayIndex = [NSNumber numberWithUnsignedChar:1U]; + params.userIndex = [NSNumber numberWithUnsignedShort:1U]; + [cluster + getWeekDayScheduleWithParams:params + completion:^( + MTRDoorLockClusterGetWeekDayScheduleResponseParams * _Nullable values, NSError * _Nullable err) { + NSLog(@"TH send Get Week Day Schedule Command to DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = values.weekDayIndex; + VerifyOrReturn(CheckValue("weekDayIndex", actualValue, 1U)); + } + + { + id actualValue = values.userIndex; + VerifyOrReturn(CheckValue("userIndex", actualValue, 1U)); + } + + { + id actualValue = values.status; + VerifyOrReturn(CheckValue("status", actualValue, 0U)); + } + + { + id actualValue = values.daysMask; + VerifyOrReturn(CheckValue("daysMask", actualValue, 2U)); + } + + { + id actualValue = values.startHour; + VerifyOrReturn(CheckValue("startHour", actualValue, 15U)); + } + + { + id actualValue = values.startMinute; + VerifyOrReturn(CheckValue("startMinute", actualValue, 45U)); + } + + VerifyOrReturn(CheckConstraintHasValue("endHour", values.endHour, true)); + if (values.endHour != nil) { + + VerifyOrReturn( + CheckConstraintMinValue("endHour", [values.endHour unsignedCharValue], 16U)); + } + + VerifyOrReturn(CheckConstraintHasValue("endMinute", values.endMinute, true)); + if (values.endMinute != nil) { + + VerifyOrReturn( + CheckConstraintMinValue("endMinute", [values.endMinute unsignedCharValue], 55U)); + } + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThSendSetWeekDayScheduleCommand_7() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; + params.weekDayIndex = [NSNumber numberWithUnsignedChar:0U]; + params.userIndex = [NSNumber numberWithUnsignedShort:1U]; + params.daysMask = [NSNumber numberWithUnsignedChar:7U]; + params.startHour = [NSNumber numberWithUnsignedChar:15U]; + params.startMinute = [NSNumber numberWithUnsignedChar:45U]; + params.endHour = [NSNumber numberWithUnsignedChar:16U]; + params.endMinute = [NSNumber numberWithUnsignedChar:55U]; + [cluster setWeekDayScheduleWithParams:params + completion:^(NSError * _Nullable err) { + NSLog(@"TH send Set Week Day Schedule Command Error: %@", err); + + VerifyOrReturn(CheckValue("status", + err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code + : EMBER_ZCL_STATUS_FAILURE) + : 0, + EMBER_ZCL_STATUS_INVALID_COMMAND)); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThSendGetWeekDayScheduleCommandToDut_8() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; + params.weekDayIndex = [NSNumber numberWithUnsignedChar:0U]; + params.userIndex = [NSNumber numberWithUnsignedShort:1U]; + [cluster getWeekDayScheduleWithParams:params + completion:^(MTRDoorLockClusterGetWeekDayScheduleResponseParams * _Nullable values, + NSError * _Nullable err) { + NSLog(@"TH send Get Week Day Schedule Command to DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = values.weekDayIndex; + VerifyOrReturn(CheckValue("weekDayIndex", actualValue, 0U)); + } + + { + id actualValue = values.userIndex; + VerifyOrReturn(CheckValue("userIndex", actualValue, 1U)); + } + + { + id actualValue = values.status; + VerifyOrReturn(CheckValue("status", actualValue, 133U)); + } + + VerifyOrReturn(CheckConstraintHasValue("daysMask", values.daysMask, false)); + if (values.daysMask != nil) { + } + + VerifyOrReturn(CheckConstraintHasValue("startHour", values.startHour, false)); + if (values.startHour != nil) { + } + + VerifyOrReturn(CheckConstraintHasValue("startMinute", values.startMinute, false)); + if (values.startMinute != nil) { + } + + VerifyOrReturn(CheckConstraintHasValue("endHour", values.endHour, false)); + if (values.endHour != nil) { + } + + VerifyOrReturn(CheckConstraintHasValue("endMinute", values.endMinute, false)); + if (values.endMinute != nil) { + } + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThSendsClearWeekDayScheduleCommandToDut_9() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRDoorLockClusterClearWeekDayScheduleParams alloc] init]; + params.weekDayIndex = [NSNumber numberWithUnsignedChar:1U]; + params.userIndex = [NSNumber numberWithUnsignedShort:1U]; + [cluster clearWeekDayScheduleWithParams:params + completion:^(NSError * _Nullable err) { + NSLog(@"TH sends Clear Week Day Schedule Command to DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThSendsGetWeekDayScheduleCommandToDut_10() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; + params.weekDayIndex = [NSNumber numberWithUnsignedChar:1U]; + params.userIndex = [NSNumber numberWithUnsignedShort:1U]; + [cluster getWeekDayScheduleWithParams:params + completion:^(MTRDoorLockClusterGetWeekDayScheduleResponseParams * _Nullable values, + NSError * _Nullable err) { + NSLog(@"TH sends Get Week Day Schedule Command to DUT Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = values.weekDayIndex; + VerifyOrReturn(CheckValue("weekDayIndex", actualValue, 1U)); + } + + { + id actualValue = values.userIndex; + VerifyOrReturn(CheckValue("userIndex", actualValue, 1U)); + } + + { + id actualValue = values.status; + VerifyOrReturn(CheckValue("status", actualValue, 139U)); + } + + VerifyOrReturn(CheckConstraintHasValue("daysMask", values.daysMask, false)); + if (values.daysMask != nil) { + } + + VerifyOrReturn(CheckConstraintHasValue("startHour", values.startHour, false)); + if (values.startHour != nil) { + } + + VerifyOrReturn(CheckConstraintHasValue("startMinute", values.startMinute, false)); + if (values.startMinute != nil) { + } + + VerifyOrReturn(CheckConstraintHasValue("endHour", values.endHour, false)); + if (values.endHour != nil) { + } + + VerifyOrReturn(CheckConstraintHasValue("endMinute", values.endMinute, false)); + if (values.endMinute != nil) { + } + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestCleanupTheCreatedUser_11() + { + + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; + params.userIndex = [NSNumber numberWithUnsignedShort:1U]; + [cluster clearUserWithParams:params + completion:^(NSError * _Nullable err) { + NSLog(@"Cleanup the created user Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + NextTest(); + }]; + + return CHIP_NO_ERROR; + } +}; + +class Test_TC_DRLK_2_6 : public TestCommandBridge { +public: + // NOLINTBEGIN(clang-analyzer-nullability.NullPassedToNonnull): Test constructor nullability not enforced + Test_TC_DRLK_2_6() + : TestCommandBridge("Test_TC_DRLK_2_6") + , mTestIndex(0) + { + AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); + AddArgument("cluster", &mCluster); + AddArgument("endpoint", 0, UINT16_MAX, &mEndpoint); + AddArgument("timeout", 0, UINT16_MAX, &mTimeout); + } + // NOLINTEND(clang-analyzer-nullability.NullPassedToNonnull) + + ~Test_TC_DRLK_2_6() {} + + /////////// TestCommand Interface ///////// + void NextTest() override + { + CHIP_ERROR err = CHIP_NO_ERROR; + + if (0 == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Start: Test_TC_DRLK_2_6\n"); + } + + if (mTestCount == mTestIndex) { + ChipLogProgress(chipTool, " **** Test Complete: Test_TC_DRLK_2_6\n"); + SetCommandExitStatus(CHIP_NO_ERROR); + return; + } + + Wait(); + + // Ensure we increment mTestIndex before we start running the relevant + // command. That way if we lose the timeslice after we send the message + // but before our function call returns, we won't end up with an + // incorrect mTestIndex value observed when we get the response. + switch (mTestIndex++) { + case 0: + ChipLogProgress(chipTool, " ***** Test Step 0 : Wait for commissionee\n"); + err = TestWaitForCommissionee_0(); + break; + case 1: + ChipLogProgress( + chipTool, " ***** Test Step 1 : TH reads NumberOfHoliday SchedulesSupported and saves for future use.\n"); + if (ShouldSkip("DRLK.S.F0b && DRLK.S.A0016")) { + NextTest(); + return; + } + err = TestThReadsNumberOfHolidaySchedulesSupportedAndSavesForFutureUse_1(); + break; + case 2: + ChipLogProgress(chipTool, " ***** Test Step 2 : Create Holiday schedule with 1 index\n"); + if (ShouldSkip("DRLK.S.F0b && DRLK.S.C11.Rsp")) { + NextTest(); + return; + } + err = TestCreateHolidayScheduleWith1Index_2(); + break; + case 3: + ChipLogProgress(chipTool, " ***** Test Step 3 : Get Holiday Schedule with HolidayIndex as 1\n"); + if (ShouldSkip("DRLK.S.F0b && DRLK.S.C12.Rsp && DRLK.S.C12.Tx")) { + NextTest(); + return; + } + err = TestGetHolidayScheduleWithHolidayIndexAs1_3(); + break; + case 4: + ChipLogProgress(chipTool, " ***** Test Step 4 : Create Holiday schedule with invalid operating mode\n"); + if (ShouldSkip("DRLK.S.C11.Rsp")) { + NextTest(); + return; + } + err = TestCreateHolidayScheduleWithInvalidOperatingMode_4(); + break; + case 5: + ChipLogProgress(chipTool, " ***** Test Step 5 : Get Holiday Schedule with Invalid HolidayIndex 15.\n"); + if (ShouldSkip("DRLK.S.F0b && DRLK.S.C12.Rsp && DRLK.S.C12.Tx")) { + NextTest(); + return; + } + err = TestGetHolidayScheduleWithInvalidHolidayIndex15_5(); + break; + case 6: + ChipLogProgress(chipTool, " ***** Test Step 6 : Get Holiday Schedule with the Non-scheduled HolidayIndex\n"); + if (ShouldSkip("DRLK.S.F0b && DRLK.S.C12.Rsp && DRLK.S.C12.Tx")) { + NextTest(); + return; + } + err = TestGetHolidayScheduleWithTheNonScheduledHolidayIndex_6(); + break; + case 7: + ChipLogProgress(chipTool, " ***** Test Step 7 : Clear Holiday schedule with 1 index\n"); + if (ShouldSkip("DRLK.S.F0b && DRLK.S.C13.Rsp")) { + NextTest(); + return; + } + err = TestClearHolidayScheduleWith1Index_7(); + break; + case 8: + ChipLogProgress(chipTool, " ***** Test Step 8 : Make sure that holiday schedule was deleted\n"); + if (ShouldSkip("DRLK.S.F0b && DRLK.S.C12.Rsp && DRLK.S.C12.Tx")) { + NextTest(); + return; + } + err = TestMakeSureThatHolidayScheduleWasDeleted_8(); + break; + case 9: + ChipLogProgress(chipTool, " ***** Test Step 9 : Cleanup the created user\n"); + err = TestCleanupTheCreatedUser_9(); + break; + } + + if (CHIP_NO_ERROR != err) { + ChipLogError(chipTool, " ***** Test Failure: %s\n", chip::ErrorStr(err)); + SetCommandExitStatus(err); + } + } - NextTest(); - }]; + void OnStatusUpdate(const chip::app::StatusIB & status) override + { + switch (mTestIndex - 1) { + case 0: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 1: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 2: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 4: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), EMBER_ZCL_STATUS_INVALID_COMMAND)); + break; + case 5: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 6: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 7: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 8: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 9: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + } - return CHIP_NO_ERROR; + // Go on to the next test. + ContinueOnChipMainThread(CHIP_NO_ERROR); } - NSNumber * _Nonnull NumberOfWeekDaySchedulesSupportedPerUser; - CHIP_ERROR TestThReadsNumberOfWeekDaySchedulesSupportedPerUserAttribute_3() + chip::System::Clock::Timeout GetWaitDuration() const override { - MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; - VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - - [cluster readAttributeNumberOfWeekDaySchedulesSupportedPerUserWithCompletion:^( - NSNumber * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH reads NumberOfWeekDay SchedulesSupportedPerUser attribute Error: %@", err); + return chip::System::Clock::Seconds16(mTimeout.ValueOr(kTimeoutInSeconds)); + } - VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); +private: + std::atomic_uint16_t mTestIndex; + const uint16_t mTestCount = 10; - VerifyOrReturn( - CheckConstraintMinValue("numberOfWeekDaySchedulesSupportedPerUser", [value unsignedCharValue], 0U)); - VerifyOrReturn( - CheckConstraintMaxValue("numberOfWeekDaySchedulesSupportedPerUser", [value unsignedCharValue], 255U)); - { - NumberOfWeekDaySchedulesSupportedPerUser = value; - } + chip::Optional mNodeId; + chip::Optional mCluster; + chip::Optional mEndpoint; + chip::Optional mTimeout; - NextTest(); - }]; + CHIP_ERROR TestWaitForCommissionee_0() + { - return CHIP_NO_ERROR; + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; + value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; + return WaitForCommissionee("alpha", value); } - NSNumber * _Nonnull NumberOfTotalUsersSupported; + NSNumber * _Nonnull NumberOfHolidaySchedulesSupported; - CHIP_ERROR TestThReadsNumberOfTotalUsersSupportedAttribute_4() + CHIP_ERROR TestThReadsNumberOfHolidaySchedulesSupportedAndSavesForFutureUse_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - [cluster readAttributeNumberOfTotalUsersSupportedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { - NSLog(@"TH reads NumberOfTotalUsers Supported attribute Error: %@", err); + [cluster readAttributeNumberOfHolidaySchedulesSupportedWithCompletion:^( + NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"TH reads NumberOfHoliday SchedulesSupported and saves for future use. Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - VerifyOrReturn(CheckConstraintMinValue("numberOfTotalUsersSupported", [value unsignedShortValue], 0U)); - VerifyOrReturn(CheckConstraintMaxValue("numberOfTotalUsersSupported", [value unsignedShortValue], 65534U)); + VerifyOrReturn(CheckConstraintMinValue("numberOfHolidaySchedulesSupported", [value unsignedCharValue], 0U)); + VerifyOrReturn(CheckConstraintMaxValue("numberOfHolidaySchedulesSupported", [value unsignedCharValue], 255U)); { - NumberOfTotalUsersSupported = value; + NumberOfHolidaySchedulesSupported = value; } NextTest(); @@ -121579,25 +124407,21 @@ class Test_TC_DRLK_2_5 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThSendSetWeekDayScheduleCommand_5() + CHIP_ERROR TestCreateHolidayScheduleWith1Index_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; - params.weekDayIndex = [NSNumber numberWithUnsignedChar:1U]; - params.userIndex = [NSNumber numberWithUnsignedShort:1U]; - params.daysMask = [NSNumber numberWithUnsignedChar:2U]; - params.startHour = [NSNumber numberWithUnsignedChar:15U]; - params.startMinute = [NSNumber numberWithUnsignedChar:45U]; - params.endHour = [NSNumber numberWithUnsignedChar:16U]; - params.endMinute = [NSNumber numberWithUnsignedChar:55U]; - [cluster setWeekDayScheduleWithParams:params + __auto_type * params = [[MTRDoorLockClusterSetHolidayScheduleParams alloc] init]; + params.holidayIndex = [NSNumber numberWithUnsignedChar:1U]; + params.localStartTime = [NSNumber numberWithUnsignedInt:20UL]; + params.localEndTime = [NSNumber numberWithUnsignedInt:30UL]; + params.operatingMode = [NSNumber numberWithUnsignedChar:0U]; + [cluster setHolidayScheduleWithParams:params completion:^(NSError * _Nullable err) { - NSLog(@"TH send Set Week Day Schedule Command Error: %@", err); + NSLog(@"Create Holiday schedule with 1 index Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); @@ -121607,94 +124431,74 @@ class Test_TC_DRLK_2_5 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThSendGetWeekDayScheduleCommandToDut_6() + CHIP_ERROR TestGetHolidayScheduleWithHolidayIndexAs1_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; - params.weekDayIndex = [NSNumber numberWithUnsignedChar:1U]; - params.userIndex = [NSNumber numberWithUnsignedShort:1U]; - [cluster - getWeekDayScheduleWithParams:params - completion:^( - MTRDoorLockClusterGetWeekDayScheduleResponseParams * _Nullable values, NSError * _Nullable err) { - NSLog(@"TH send Get Week Day Schedule Command to DUT Error: %@", err); - - VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - - { - id actualValue = values.weekDayIndex; - VerifyOrReturn(CheckValue("weekDayIndex", actualValue, 1U)); - } - - { - id actualValue = values.userIndex; - VerifyOrReturn(CheckValue("userIndex", actualValue, 1U)); - } + __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; + params.holidayIndex = [NSNumber numberWithUnsignedChar:1U]; + [cluster getHolidayScheduleWithParams:params + completion:^(MTRDoorLockClusterGetHolidayScheduleResponseParams * _Nullable values, + NSError * _Nullable err) { + NSLog(@"Get Holiday Schedule with HolidayIndex as 1 Error: %@", err); - { - id actualValue = values.status; - VerifyOrReturn(CheckValue("status", actualValue, 0U)); - } + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); - { - id actualValue = values.daysMask; - VerifyOrReturn(CheckValue("daysMask", actualValue, 2U)); - } + { + id actualValue = values.holidayIndex; + VerifyOrReturn(CheckValue("holidayIndex", actualValue, 1U)); + } - { - id actualValue = values.startHour; - VerifyOrReturn(CheckValue("startHour", actualValue, 15U)); - } + { + id actualValue = values.status; + VerifyOrReturn(CheckValue("status", actualValue, 0U)); + } - { - id actualValue = values.startMinute; - VerifyOrReturn(CheckValue("startMinute", actualValue, 45U)); - } + { + id actualValue = values.localStartTime; + VerifyOrReturn(CheckValue("localStartTime", actualValue, 20UL)); + } - VerifyOrReturn(CheckConstraintHasValue("endHour", values.endHour, true)); - if (values.endHour != nil) { + { + id actualValue = values.localEndTime; + VerifyOrReturn(CheckValue("localEndTime", actualValue, 30UL)); + } - VerifyOrReturn( - CheckConstraintMinValue("endHour", [values.endHour unsignedCharValue], 16U)); - } + if (values.localEndTime != nil) { - VerifyOrReturn(CheckConstraintHasValue("endMinute", values.endMinute, true)); - if (values.endMinute != nil) { + VerifyOrReturn(CheckConstraintMinValue( + "localEndTime", [values.localEndTime unsignedIntValue], 21UL)); + } - VerifyOrReturn( - CheckConstraintMinValue("endMinute", [values.endMinute unsignedCharValue], 55U)); - } + { + id actualValue = values.operatingMode; + VerifyOrReturn(CheckValue("operatingMode", actualValue, 0U)); + } - NextTest(); - }]; + NextTest(); + }]; return CHIP_NO_ERROR; } - CHIP_ERROR TestThSendSetWeekDayScheduleCommand_7() + CHIP_ERROR TestCreateHolidayScheduleWithInvalidOperatingMode_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - __auto_type * params = [[MTRDoorLockClusterSetWeekDayScheduleParams alloc] init]; - params.weekDayIndex = [NSNumber numberWithUnsignedChar:0U]; - params.userIndex = [NSNumber numberWithUnsignedShort:1U]; - params.daysMask = [NSNumber numberWithUnsignedChar:7U]; - params.startHour = [NSNumber numberWithUnsignedChar:15U]; - params.startMinute = [NSNumber numberWithUnsignedChar:45U]; - params.endHour = [NSNumber numberWithUnsignedChar:16U]; - params.endMinute = [NSNumber numberWithUnsignedChar:55U]; - [cluster setWeekDayScheduleWithParams:params + __auto_type * params = [[MTRDoorLockClusterSetHolidayScheduleParams alloc] init]; + params.holidayIndex = [NSNumber numberWithUnsignedChar:1U]; + params.localStartTime = [NSNumber numberWithUnsignedInt:20UL]; + params.localEndTime = [NSNumber numberWithUnsignedInt:30UL]; + params.operatingMode = [NSNumber numberWithUnsignedChar:5U]; + [cluster setHolidayScheduleWithParams:params completion:^(NSError * _Nullable err) { - NSLog(@"TH send Set Week Day Schedule Command Error: %@", err); + NSLog(@"Create Holiday schedule with invalid operating mode Error: %@", err); VerifyOrReturn(CheckValue("status", err ? ([err.domain isEqualToString:MTRInteractionErrorDomain] ? err.code @@ -121707,32 +124511,25 @@ class Test_TC_DRLK_2_5 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThSendGetWeekDayScheduleCommandToDut_8() + CHIP_ERROR TestGetHolidayScheduleWithInvalidHolidayIndex15_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; - params.weekDayIndex = [NSNumber numberWithUnsignedChar:0U]; - params.userIndex = [NSNumber numberWithUnsignedShort:1U]; - [cluster getWeekDayScheduleWithParams:params - completion:^(MTRDoorLockClusterGetWeekDayScheduleResponseParams * _Nullable values, + __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; + params.holidayIndex = [NSNumber numberWithUnsignedChar:15U]; + [cluster getHolidayScheduleWithParams:params + completion:^(MTRDoorLockClusterGetHolidayScheduleResponseParams * _Nullable values, NSError * _Nullable err) { - NSLog(@"TH send Get Week Day Schedule Command to DUT Error: %@", err); + NSLog(@"Get Holiday Schedule with Invalid HolidayIndex 15. Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); { - id actualValue = values.weekDayIndex; - VerifyOrReturn(CheckValue("weekDayIndex", actualValue, 0U)); - } - - { - id actualValue = values.userIndex; - VerifyOrReturn(CheckValue("userIndex", actualValue, 1U)); + id actualValue = values.holidayIndex; + VerifyOrReturn(CheckValue("holidayIndex", actualValue, 15U)); } { @@ -121740,24 +124537,36 @@ class Test_TC_DRLK_2_5 : public TestCommandBridge { VerifyOrReturn(CheckValue("status", actualValue, 133U)); } - VerifyOrReturn(CheckConstraintHasValue("daysMask", values.daysMask, false)); - if (values.daysMask != nil) { - } + NextTest(); + }]; - VerifyOrReturn(CheckConstraintHasValue("startHour", values.startHour, false)); - if (values.startHour != nil) { - } + return CHIP_NO_ERROR; + } - VerifyOrReturn(CheckConstraintHasValue("startMinute", values.startMinute, false)); - if (values.startMinute != nil) { - } + CHIP_ERROR TestGetHolidayScheduleWithTheNonScheduledHolidayIndex_6() + { - VerifyOrReturn(CheckConstraintHasValue("endHour", values.endHour, false)); - if (values.endHour != nil) { + MTRBaseDevice * device = GetDevice("alpha"); + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; + params.holidayIndex = [NSNumber numberWithUnsignedChar:10U]; + [cluster getHolidayScheduleWithParams:params + completion:^(MTRDoorLockClusterGetHolidayScheduleResponseParams * _Nullable values, + NSError * _Nullable err) { + NSLog(@"Get Holiday Schedule with the Non-scheduled HolidayIndex Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + { + id actualValue = values.holidayIndex; + VerifyOrReturn(CheckValue("holidayIndex", actualValue, 10U)); } - VerifyOrReturn(CheckConstraintHasValue("endMinute", values.endMinute, false)); - if (values.endMinute != nil) { + { + id actualValue = values.status; + VerifyOrReturn(CheckValue("status", actualValue, 139U)); } NextTest(); @@ -121766,20 +124575,18 @@ class Test_TC_DRLK_2_5 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThSendsClearWeekDayScheduleCommandToDut_9() + CHIP_ERROR TestClearHolidayScheduleWith1Index_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - __auto_type * params = [[MTRDoorLockClusterClearWeekDayScheduleParams alloc] init]; - params.weekDayIndex = [NSNumber numberWithUnsignedChar:1U]; - params.userIndex = [NSNumber numberWithUnsignedShort:1U]; - [cluster clearWeekDayScheduleWithParams:params + __auto_type * params = [[MTRDoorLockClusterClearHolidayScheduleParams alloc] init]; + params.holidayIndex = [NSNumber numberWithUnsignedChar:1U]; + [cluster clearHolidayScheduleWithParams:params completion:^(NSError * _Nullable err) { - NSLog(@"TH sends Clear Week Day Schedule Command to DUT Error: %@", err); + NSLog(@"Clear Holiday schedule with 1 index Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); @@ -121789,32 +124596,25 @@ class Test_TC_DRLK_2_5 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThSendsGetWeekDayScheduleCommandToDut_10() + CHIP_ERROR TestMakeSureThatHolidayScheduleWasDeleted_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - __auto_type * params = [[MTRDoorLockClusterGetWeekDayScheduleParams alloc] init]; - params.weekDayIndex = [NSNumber numberWithUnsignedChar:1U]; - params.userIndex = [NSNumber numberWithUnsignedShort:1U]; - [cluster getWeekDayScheduleWithParams:params - completion:^(MTRDoorLockClusterGetWeekDayScheduleResponseParams * _Nullable values, + __auto_type * params = [[MTRDoorLockClusterGetHolidayScheduleParams alloc] init]; + params.holidayIndex = [NSNumber numberWithUnsignedChar:1U]; + [cluster getHolidayScheduleWithParams:params + completion:^(MTRDoorLockClusterGetHolidayScheduleResponseParams * _Nullable values, NSError * _Nullable err) { - NSLog(@"TH sends Get Week Day Schedule Command to DUT Error: %@", err); + NSLog(@"Make sure that holiday schedule was deleted Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); { - id actualValue = values.weekDayIndex; - VerifyOrReturn(CheckValue("weekDayIndex", actualValue, 1U)); - } - - { - id actualValue = values.userIndex; - VerifyOrReturn(CheckValue("userIndex", actualValue, 1U)); + id actualValue = values.holidayIndex; + VerifyOrReturn(CheckValue("holidayIndex", actualValue, 1U)); } { @@ -121822,38 +124622,17 @@ class Test_TC_DRLK_2_5 : public TestCommandBridge { VerifyOrReturn(CheckValue("status", actualValue, 139U)); } - VerifyOrReturn(CheckConstraintHasValue("daysMask", values.daysMask, false)); - if (values.daysMask != nil) { - } - - VerifyOrReturn(CheckConstraintHasValue("startHour", values.startHour, false)); - if (values.startHour != nil) { - } - - VerifyOrReturn(CheckConstraintHasValue("startMinute", values.startMinute, false)); - if (values.startMinute != nil) { - } - - VerifyOrReturn(CheckConstraintHasValue("endHour", values.endHour, false)); - if (values.endHour != nil) { - } - - VerifyOrReturn(CheckConstraintHasValue("endMinute", values.endMinute, false)); - if (values.endMinute != nil) { - } - NextTest(); }]; return CHIP_NO_ERROR; } - CHIP_ERROR TestCleanupTheCreatedUser_11() + CHIP_ERROR TestCleanupTheCreatedUser_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -122120,6 +124899,7 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -122127,10 +124907,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestCreateNewUser_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -122155,10 +124934,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestReadTheUserBackAndVerifyItsFields_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -122235,10 +125013,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestThReadsNumberOfYearDaySchedulesSupportedPerUserAttribute_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNumberOfYearDaySchedulesSupportedPerUserWithCompletion:^( @@ -122264,10 +125041,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestThReadsNumberOfTotalUsersSupportedAttribute_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNumberOfTotalUsersSupportedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -122289,10 +125065,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestThSendsSetYearDayScheduleCommandToDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetYearDayScheduleParams alloc] init]; @@ -122314,10 +125089,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestThSendsGetYearDayScheduleCommandToDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -122369,10 +125143,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestThSendSetYearDayScheduleCommandToDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetYearDayScheduleParams alloc] init]; @@ -122397,10 +125170,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestThSendsGetYearDayScheduleCommandToDut_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -122444,10 +125216,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestCreateAUserWithUserIndexAs5_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -122472,10 +125243,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestThSendsGetYearDayScheduleCommandToDut_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -122520,10 +125290,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestThSendsClearYearDayScheduleToDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearYearDayScheduleParams alloc] init]; @@ -122543,10 +125312,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestThSendsGetYearDayScheduleCommandToDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -122590,10 +125358,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestThSendsSetYearDayScheduleCommandToDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetYearDayScheduleParams alloc] init]; @@ -122615,10 +125382,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestThSendsGetYearDayScheduleCommandToDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetYearDayScheduleParams alloc] init]; @@ -122670,10 +125436,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestThSendsClearYearDayScheduleToDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearYearDayScheduleParams alloc] init]; @@ -122697,10 +125462,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestClearAYearDayScheduleForTheFirstUser_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearYearDayScheduleParams alloc] init]; @@ -122720,10 +125484,9 @@ class Test_TC_DRLK_2_7 : public TestCommandBridge { CHIP_ERROR TestCleanupTheCreatedUser_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -123030,6 +125793,7 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -123037,10 +125801,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestCreateNewUserWithDefaultParameters_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -123065,10 +125828,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestReadTheUserBackAndVerifyItsFields_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetUserParams alloc] init]; @@ -123145,10 +125907,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThReadsNumberOfTotalUsersSupportedAttributeAndSavesForFutureUse_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeNumberOfTotalUsersSupportedWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -123170,10 +125931,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThSendsSetCredentialCommandToDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -123217,10 +125977,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThSendsGetCredentialStatusCommand_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -123267,10 +126026,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThSendsSetCredentialCommandToDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -123314,10 +126072,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThSendsSetCredentialCommandToDut_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -123362,6 +126119,7 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThSendsSetCredentialCommandToDutAndVerifyThatTheDutSendsSetCredentialResponseCommandWithStatusAsDuplicateOrOccupied_8() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -123372,6 +126130,7 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThSendsSetCredentialCommandToDutAndVerifyThatTheDutSendsSetCredentialResponseCommandWithResponseAsOccupiedIfTheCredentialIndexIsRepeated_9() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -123382,6 +126141,7 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThSendsSetCredentialCommandToDutAndVerifyThatTheDutSendsSetCredentialResponseCommandWithResponseAsOccupiedIfTheCredentialIndexIsRepeated_10() { + chip::app::Clusters::LogCommands::Commands::UserPrompt::Type value; value.message = chip::Span("Please enter 'y' for successgarbage: not in length on purpose", 28); value.expectedValue.Emplace(); @@ -123391,10 +126151,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThSendsClearCredentialCommandToDut_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -123416,10 +126175,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThSendsGetCredentialStatusCommandToDut_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -123467,10 +126225,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThSendsSetUserCommandToDut_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetUserParams alloc] init]; @@ -123495,10 +126252,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThSendsSetCredentialCommandToDut_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterSetCredentialParams alloc] init]; @@ -123542,10 +126298,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThSendsClearCredentialCommandToDut_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -123567,10 +126322,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThSendsGetCredentialStatusCommand_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -123618,10 +126372,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThSendsGetCredentialStatusCommand_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterGetCredentialStatusParams alloc] init]; @@ -123669,10 +126422,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestThSendsClearCredentialCommandToDut_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearCredentialParams alloc] init]; @@ -123697,10 +126449,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestCleanupTheFirstCreatedUser_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -123719,10 +126470,9 @@ class Test_TC_DRLK_2_9 : public TestCommandBridge { CHIP_ERROR TestCleanupTheSecondCreatedUser_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterDoorLock * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device - endpointID:@(1) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterDoorLock alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRDoorLockClusterClearUserParams alloc] init]; @@ -124000,6 +126750,7 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -124007,8 +126758,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestViewGroup0Invalid_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterViewGroupParams alloc] init]; @@ -124037,8 +126789,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestViewFirstGroupNotFound_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterViewGroupParams alloc] init]; @@ -124067,8 +126820,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestAddFirstGroupNoKeys_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterAddGroupParams alloc] init]; @@ -124098,10 +126852,11 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestAddKeySet_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupKeyManagementClusterKeySetWriteParams alloc] init]; @@ -124137,10 +126892,11 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestWriteGroupKeys_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id groupKeyMapArgument; @@ -124172,8 +126928,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestAddFirstGroupNew_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterAddGroupParams alloc] init]; @@ -124203,8 +126960,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestViewFirstGroupNew_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterViewGroupParams alloc] init]; @@ -124238,8 +126996,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestViewSecondGroupNotFound_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterViewGroupParams alloc] init]; @@ -124268,8 +127027,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestGetGroupMembership1All_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterGetGroupMembershipParams alloc] init]; @@ -124303,8 +127063,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestAddSecondGroupNew_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterAddGroupParams alloc] init]; @@ -124334,8 +127095,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestViewSecondGroupNew_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterViewGroupParams alloc] init]; @@ -124369,8 +127131,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestViewGroup3NotFound_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterViewGroupParams alloc] init]; @@ -124399,8 +127162,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestViewFirstGroupExisting_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterViewGroupParams alloc] init]; @@ -124434,8 +127198,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestViewSecondGroupExisting_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterViewGroupParams alloc] init]; @@ -124469,8 +127234,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestGetGroupMembership2_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterGetGroupMembershipParams alloc] init]; @@ -124507,8 +127273,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestRemoveGroup0Invalid_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterRemoveGroupParams alloc] init]; @@ -124537,8 +127304,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestRemoveGroup4NotFound_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterRemoveGroupParams alloc] init]; @@ -124567,8 +127335,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestRemoveSecondGroupExisting_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterRemoveGroupParams alloc] init]; @@ -124597,8 +127366,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestViewFirstGroupNotRemoved_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterViewGroupParams alloc] init]; @@ -124632,8 +127402,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestViewSecondGroupRemoved_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterViewGroupParams alloc] init]; @@ -124662,8 +127433,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestGetGroupMembership3_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterGetGroupMembershipParams alloc] init]; @@ -124701,8 +127473,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestRemoveAll_22() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster removeAllGroupsWithCompletion:^(NSError * _Nullable err) { @@ -124718,8 +127491,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestViewFirstGroupRemoved_23() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterViewGroupParams alloc] init]; @@ -124748,8 +127522,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestViewSecondGroupStillRemoved_24() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterViewGroupParams alloc] init]; @@ -124778,8 +127553,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestViewGroup3Removed_25() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterViewGroupParams alloc] init]; @@ -124808,8 +127584,9 @@ class TestGroupsCluster : public TestCommandBridge { CHIP_ERROR TestGetGroupMembership4_26() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterGetGroupMembershipParams alloc] init]; @@ -125071,6 +127848,7 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -125078,10 +127856,11 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestReadMaxGroupsPerFabric_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxGroupsPerFabricWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -125099,10 +127878,11 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestReadMaxGroupKeysPerFabric_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeMaxGroupKeysPerFabricWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -125120,10 +127900,11 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestKeySetWrite1_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupKeyManagementClusterKeySetWriteParams alloc] init]; @@ -125159,10 +127940,11 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestKeySetWrite2_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupKeyManagementClusterKeySetWriteParams alloc] init]; @@ -125198,10 +127980,11 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestKeySetRead_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupKeyManagementClusterKeySetReadParams alloc] init]; @@ -125248,10 +128031,11 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestWriteGroupKeysInvalid_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id groupKeyMapArgument; @@ -125282,10 +128066,11 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestWriteGroupKeysTooMany_7() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id groupKeyMapArgument; @@ -125331,10 +128116,11 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestWriteGroupKeys_8() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); id groupKeyMapArgument; @@ -125371,13 +128157,14 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestReadGroupKeys_9() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; [cluster readAttributeGroupKeyMapWithParams:params @@ -125424,8 +128211,9 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestAddGroup1_10() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterAddGroupParams alloc] init]; @@ -125455,8 +128243,9 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestAddGroup2_11() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterAddGroupParams alloc] init]; @@ -125486,13 +128275,14 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestReadGroupTable_12() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; [cluster readAttributeGroupTableWithParams:params @@ -125530,10 +128320,11 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestKeySetRemove1_13() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupKeyManagementClusterKeySetRemoveParams alloc] init]; @@ -125552,10 +128343,11 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestKeySetReadRemoved_14() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupKeyManagementClusterKeySetReadParams alloc] init]; @@ -125578,10 +128370,11 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestKeySetReadNotRemoved_15() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupKeyManagementClusterKeySetReadParams alloc] init]; @@ -125628,8 +128421,9 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestRemoveGroup1_16() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupsClusterRemoveGroupParams alloc] init]; @@ -125658,13 +128452,14 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestReadGroupTable2_17() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; [cluster readAttributeGroupTableWithParams:params @@ -125694,8 +128489,9 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestRemoveAll_18() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster removeAllGroupsWithCompletion:^(NSError * _Nullable err) { @@ -125711,13 +128507,14 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestReadGroupTable3_19() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); - MTRReadParams * params = [[MTRReadParams alloc] init]; + __auto_type * params = [[MTRReadParams alloc] init]; params.filterByFabric = true; [cluster readAttributeGroupTableWithParams:params @@ -125739,10 +128536,11 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestKeySetRemove2_20() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupKeyManagementClusterKeySetRemoveParams alloc] init]; @@ -125761,10 +128559,11 @@ class TestGroupKeyManagementCluster : public TestCommandBridge { CHIP_ERROR TestKeySetReadAlsoRemoved_21() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroupKeyManagement * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device - endpointID:@(0) - queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroupKeyManagement alloc] initWithDevice:device + endpointID:@(0) + queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); __auto_type * params = [[MTRGroupKeyManagementClusterKeySetReadParams alloc] init]; @@ -125914,6 +128713,7 @@ class Test_TC_G_1_1 : public TestCommandBridge { CHIP_ERROR TestWaitForTheCommissionedDeviceToBeRetrieved_0() { + chip::app::Clusters::DelayCommands::Commands::WaitForCommissionee::Type value; value.nodeId = mNodeId.HasValue() ? mNodeId.Value() : 305414945ULL; return WaitForCommissionee("alpha", value); @@ -125921,8 +128721,9 @@ class Test_TC_G_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheClusterRevisionFromDut_1() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeClusterRevisionWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -125944,8 +128745,9 @@ class Test_TC_G_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsTheFeatureMapFromDut_2() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -125967,8 +128769,9 @@ class Test_TC_G_1_1 : public TestCommandBridge { CHIP_ERROR TestGivenGsf00EnsureFeaturemapHasTheCorrectBitSet_3() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { @@ -125985,8 +128788,9 @@ class Test_TC_G_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAttributeListFromDut_4() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -126010,8 +128814,9 @@ class Test_TC_G_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsAcceptedCommandListFromDut_5() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAcceptedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -126035,8 +128840,9 @@ class Test_TC_G_1_1 : public TestCommandBridge { CHIP_ERROR TestThReadsGeneratedCommandListFromDut_6() { + MTRBaseDevice * device = GetDevice("alpha"); - MTRBaseClusterGroups * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; + __auto_type * cluster = [[MTRBaseClusterGroups alloc] initWithDevice:device endpointID:@(1) queue:mCallbackQueue]; VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeGeneratedCommandListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { @@ -126071,8 +128877,10 @@ void registerCommandsTests(Commands & commands) make_unique(), make_unique(), make_unique(), + make_unique(), make_unique(), make_unique(), + make_unique(), make_unique(), make_unique(), make_unique(), @@ -126134,6 +128942,7 @@ void registerCommandsTests(Commands & commands) make_unique(), make_unique(), make_unique(), + make_unique(), make_unique(), make_unique(), make_unique(), @@ -126143,6 +128952,7 @@ void registerCommandsTests(Commands & commands) make_unique(), make_unique(), make_unique(), + make_unique(), make_unique(), make_unique(), make_unique(), @@ -126257,6 +129067,7 @@ void registerCommandsTests(Commands & commands) make_unique(), make_unique(), make_unique(), + make_unique(), make_unique(), make_unique(), make_unique(),